This commit is contained in:
wulin 2020-08-26 14:22:16 +08:00
commit a815f0925a
4 changed files with 28 additions and 19 deletions

View File

@ -59,3 +59,7 @@ export const downZip = params => {
export const deleteRecord = params => {
return http({url: '/lz_management/user/lzresultrecord/deleteRecord', method: 'get', params})
}
export const preWeightCheck = params => {
return http({url: '/lz_management/user/lzresultrecord/preWeightCheck', method: 'post', params})
}

View File

@ -230,7 +230,8 @@ export default {
departmentList3: [],
addOrUpdateVisible: false,
recordIdsSelect: [],
tabValue: '1,2,5'
tabValue: '1,2,5',
isChangeDepartmentrtment: 0
}
},
computed: {},
@ -281,6 +282,7 @@ export default {
})
},
async changeDepartment (i) {
this.isChangeDepartmentrtment = 1
let departmentId = 0
if (i === '2') {
departmentId = this.dataForm.department1
@ -321,17 +323,20 @@ export default {
'department3': this.dataForm.department3,
'name': this.dataForm.name,
'remark': this.dataForm.remark,
'isSelf': 2
'isSelf': 2,
'isChangeDepartmentrtment': this.isChangeDepartmentrtment
}).then(data => {
if (data && data.code === 0) {
this.dataList = data.page.list
this.totalPage = data.page.totalCount
this.departmentList1 = data.departmentList1
this.departmentList2 = data.departmentList2
this.departmentList3 = data.departmentList3
this.dataForm.department1 = data.department1
this.dataForm.department2 = data.department2
this.dataForm.department3 = data.department3
if (this.isChangeDepartmentrtment === 0) {
this.departmentList1 = data.departmentList1
this.departmentList2 = data.departmentList2
this.departmentList3 = data.departmentList3
this.dataForm.department1 = data.department1
this.dataForm.department2 = data.department2
this.dataForm.department3 = data.department3
}
} else {
this.dataList = []
this.totalPage = 0

View File

@ -55,8 +55,9 @@
<script>
import {apiDetailInfo, recorddetailAddOrUpdate, recorddetailDelete, weightCheck} from '@/api/api_result'
import {apiDetailInfo, recorddetailAddOrUpdate, recorddetailDelete, weightCheck, preWeightCheck} from '@/api/api_result'
import E from 'wangeditor'
var Base64 = require('js-base64').Base64
export default {
@ -177,7 +178,7 @@ export default {
this.auth = auth
this.recordType = recordType
this.dataForm.id = id || 0
let data = await weightCheck({
let data = await preWeightCheck({
'recordResultId': this.recordResultId,
'type': this.type,
'id': this.dataForm.id

View File

@ -184,8 +184,10 @@ export default {
UploadAddOrUpdate
},
activated () {
this.recordResultId = this.$route.query.id
this.recordType = this.$route.query.recordType
if (this.$route.query.id >= 0) {
this.recordResultId = this.$route.query.id
this.recordType = this.$route.query.recordType
}
this.getDataList()
},
methods: {
@ -258,9 +260,10 @@ export default {
'recordResultId': this.recordResultId,
'status': 2
}).then(data => {
if (data){
if(data.code === 0) {
this.getDataList()
if (data) {
if (data.code === 0) {
this.getDataList()
}
this.$message({
message: data.msg,
type: 'success',
@ -268,13 +271,9 @@ export default {
onClose: () => {
}
})
} else {
this.$message.error(data.msg)
}
} else {
this.$message.error('网络异常')
}
})
}).catch(() => {
})