Browse Source

【pc端 添加网格实体化指标详情】-【页面修改】-(魏凯)-2020/12/10

master
weikai 5 years ago
parent
commit
b90534b04d
  1. 33
      src/views/modules/kpi/kpisubpositiondetail.vue

33
src/views/modules/kpi/kpisubpositiondetail.vue

@ -111,7 +111,7 @@
</div>
<el-form :model="dataForm" :rules="dataRule" ref="dataForm">
<el-form :model="dataForm" :rules="dataRule" ref="dataForm" :disabled="pageDisabled">
<el-form-item label="关联网格:" prop="grids" label-width="90px" style="font-weight:bold">
<el-select
v-model="dataForm.grids"
@ -132,8 +132,8 @@
<el-form-item style="margin-left:35px;">
<el-button type="primary" @click="backToUserRelationList">{{"返回"}}</el-button>
<el-button v-if="status === '0'" type="primary" :disabled="isAble" @click="dataFormSubmitHandle()">{{ $t('confirm') }}</el-button>
<el-button v-if="status === '1'" type="primary" @click="firstTrial()">初审</el-button>
<el-button v-if="status === '2'" type="primary" @click="acceptance()">验收</el-button>
<el-button v-if="status === '2'" type="primary" @click="firstTrial()">初审</el-button>
<el-button v-if="status === '3'" type="primary" @click="acceptance()">验收</el-button>
</el-form-item>
</el-form>
@ -204,7 +204,7 @@ export default {
// this.uploadFileUrl = `${window.SITE_CONFIG['apiURL']}/oss/file/uploadAllFile?token=${Cookies.get('token')}`
this.uploadUrl = `http://localhost:9094/epdc-api/oss/file/uploadImg?token=${Cookies.get('token')}`
this.uploadFileUrl = `http://localhost:9094/epdc-api/oss/file/uploadAllFile?token=${Cookies.get('token')}`
this.getOptions();
this.init();
},
@ -234,9 +234,11 @@ export default {
this.dataForm.grids = res.data
}).catch(() => {})
this.getInfoById()
this.getInfoById();
this.getOptionsById();
}else {
this.getCheckInfo();
this.getOptions();
}
})
},
@ -285,9 +287,9 @@ export default {
return false
}
if (type ===2){
this.checkDiction[index].childDiction[index1].images.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 1, fileName: res.data.fileName })
this.checkDiction[index].childDiction[index1].images.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 1, name: res.data.fileName })
}else {
this.checkDiction[index].images.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 1, fileName: res.data.fileName })
this.checkDiction[index].images.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 1, name: res.data.fileName })
}
@ -342,6 +344,7 @@ export default {
},
beforeFileRemove (file, fileList) {
if (this.isAutoRemoveFile) {
return this.$confirm(`确定移除${file.name}`)
}
this.isAutoRemoveFile = true
@ -354,9 +357,9 @@ export default {
return false
}
if (type ===2){
this.checkDiction[index].childDiction[index1].files.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 2, fileName: res.data.fileName })
this.checkDiction[index].childDiction[index1].files.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 2, name: res.data.fileName })
}else {
this.checkDiction[index].files.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 2, fileName: res.data.fileName })
this.checkDiction[index].files.push({ url: res.data.imgUrl, thumbnail: res.data.thumbnail, fileType: 2, name: res.data.fileName })
}
},
handleFileRemove (file, fileList,index,index1,type) {
@ -411,6 +414,18 @@ export default {
.catch(() => {})
},
getOptionsById(){
this.$http
.get(`/kpi/subinfogridrelation/getgrids/${this.dataForm.id}`)
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.options = res.data
})
.catch(() => {})
},
getCheckInfo(){
this.$http.get(`kpi/subcheckdictionary/getdetaildict`).then(({ data: res }) => {
this.pageloading = false

Loading…
Cancel
Save