刘翔宇-旅管家 2 years ago
parent b32d3c9648
commit 939c2845e7

@ -2,6 +2,6 @@
ENV = 'development' ENV = 'development'
# base api # base api
#VUE_APP_BASE_API = 'http://safety.115.langye.net/' VUE_APP_BASE_API = 'http://safety.115.langye.net/'
VUE_APP_BASE_API = http://192.168.60.99:9001/ #VUE_APP_BASE_API = http://192.168.60.99:9001/

@ -4,3 +4,4 @@ ENV = 'production'
# base api # base api
VUE_APP_BASE_API = http://192.168.60.99:9001/ VUE_APP_BASE_API = http://192.168.60.99:9001/
#VUE_APP_BASE_API = 'http://safety.115.langye.net/'

@ -48,17 +48,19 @@ const actions = {
}, userInfo) { }, userInfo) {
const { const {
token, token,
tp tp,
loginId
} = userInfo } = userInfo
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
loginOss({ loginOss({
token: token, token: token,
tp: tp tp: tp,
loginId: loginId
}).then(response => { }).then(response => {
//console.log(response) //console.log(response)
const { const {
data data
} = response; } = response;

@ -28,7 +28,7 @@
<div v-else-if="column.type=='opt'"> <div v-else-if="column.type=='opt'">
<Button v-if="safe.status==0" ghost size="small" @click="edit(scope.row)" type="primary" <Button v-if="safe.status==0" ghost size="small" @click="edit(scope.row)" type="primary"
style="margin-left: 10px;">新增上报</Button> style="margin-left: 10px;">新增上报</Button>
<Button v-if="safe.status==1" ghost size="small" @click="edit(safe,true)" type="primary" <Button v-if="safe.status==1||safe.status==2" ghost size="small" @click="edit(safe,true)" type="primary"
style="margin-left: 10px;">编辑上报</Button> style="margin-left: 10px;">编辑上报</Button>
<Button v-if="safe.status==2" ghost size="small" @click="$refs['detailUpInfo'].getinfo(safe.id),$refs['detailUpInfo'].dialogFormVisible = true" type="primary" <Button v-if="safe.status==2" ghost size="small" @click="$refs['detailUpInfo'].getinfo(safe.id),$refs['detailUpInfo'].dialogFormVisible = true" type="primary"
style="margin-left: 10px;">查看上报</Button> style="margin-left: 10px;">查看上报</Button>
@ -82,11 +82,12 @@
</div> </div>
<div slot="footer" class="dialog-footer" v-if="!isReportSave"> <div slot="footer" class="dialog-footer" v-if="!isReportSave">
<el-button @click="resetForm('form')"> </el-button> <el-button @click="resetForm('form')"> </el-button>
<el-button type="primary" v-preventReClick @click="submitForm('form','1')"> </el-button> <el-button type="primary" v-preventReClick @click="submitForm('form', '2')"> </el-button>
<!-- <el-button type="primary" v-preventReClick @click="submitForm('form','1')"> </el-button> -->
</div> </div>
<div slot="footer" class="dialog-footer" v-if="isReportSave"> <div slot="footer" class="dialog-footer" v-if="isReportSave">
<el-button @click="resetForm('form')"> </el-button> <el-button @click="resetForm('form')"> </el-button>
<el-button type="primary" v-preventReClick @click="submitForm('form','1')"> </el-button> <!-- <el-button type="primary" v-preventReClick @click="submitForm('form','1')"> </el-button> -->
<el-button type="primary" v-preventReClick @click="submitForm('form', '2')"> </el-button> <el-button type="primary" v-preventReClick @click="submitForm('form', '2')"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
@ -300,6 +301,9 @@
edit(obj, isnew) { edit(obj, isnew) {
this.form = this.$options.data().form; this.form = this.$options.data().form;
this.clientHeight = document.documentElement.clientHeight - 84 - 110; this.clientHeight = document.documentElement.clientHeight - 84 - 110;
this.$nextTick(function(){
this.$refs.tinymce.setContent("");
})
if (isnew) { if (isnew) {
var that = this; var that = this;
that.form.content = ""; that.form.content = "";
@ -321,14 +325,15 @@
if (valid) { if (valid) {
if (status == "2") { if (status == "2") {
that.form.status = status; that.form.status = status;
submitsave(that.form).then(response => { save(that.form).then(response => {
//console.log(response) //console.log(response)
this.$Message.success('操作成功'); this.$Message.success('操作成功');
that.load(); that.load();
that.dialogFormVisible = false; that.dialogFormVisible = false;
}).catch(error => { }).catch(error => {
//reject(error) //reject(error)
}) })
} else { } else {
save(that.form).then(response => { save(that.form).then(response => {
//console.log(response) //console.log(response)

@ -93,7 +93,8 @@
this.loading = true this.loading = true
this.$store.dispatch('user/loginskip', { this.$store.dispatch('user/loginskip', {
token: query.token, token: query.token,
tp: query.tp tp: query.tp,
loginId: query.loginId
}).then(() => { }).then(() => {
this.$router.push({ this.$router.push({
path: "/" path: "/"

Loading…
Cancel
Save