|
|
@ -34,6 +34,14 @@ |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row v-show="surplusNumber"> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>未盘原因</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="20"> |
|
|
|
<el-form-item><el-input v-model="formobj.reason" clearable placeholder="因存在未盘记录,请填写未盘原因" /></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>具体情况</span> |
|
|
@ -89,6 +97,7 @@ export default { |
|
|
|
name: 'pankubaogaoAdd', |
|
|
|
data() { |
|
|
|
return { |
|
|
|
surplusNumber: false, |
|
|
|
recipientList: [], |
|
|
|
user_list: [], |
|
|
|
formobj: { |
|
|
@ -104,6 +113,7 @@ export default { |
|
|
|
profitRemarks: '', |
|
|
|
damageRemarks: '', |
|
|
|
lossRemarks: '', |
|
|
|
reason: '', |
|
|
|
recipientList: [] |
|
|
|
} |
|
|
|
} |
|
|
@ -121,6 +131,9 @@ export default { |
|
|
|
this.$nextTick(() => { |
|
|
|
this.$refs['form_obj'].clearValidate() |
|
|
|
}) |
|
|
|
if (row.surplusNumber !== '0') { |
|
|
|
this.surplusNumber = true |
|
|
|
} |
|
|
|
this.formobj.mainSid = row.sid |
|
|
|
this.formobj.userSid = window.sessionStorage.getItem('userSid') |
|
|
|
req.getCarInventoryReport(row.sid, window.sessionStorage.getItem('userSid')).then((resp) => { |
|
|
@ -157,6 +170,10 @@ export default { |
|
|
|
} |
|
|
|
this.formobj.recipientList = aa |
|
|
|
} |
|
|
|
if (!this.surplusNumber && this.formobj.reason === '') { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '因存在未盘记录,请填写未盘原因' }) |
|
|
|
return |
|
|
|
} |
|
|
|
this.$refs['form_obj'].validate((valid) => { |
|
|
|
if (valid) { |
|
|
|
req.sendReport(this.formobj).then((resp) => { |
|
|
@ -187,6 +204,7 @@ export default { |
|
|
|
lossRemarks: '', |
|
|
|
recipientList: [] |
|
|
|
} |
|
|
|
this.surplusNumber = false |
|
|
|
this.$refs['form_obj'].resetFields() |
|
|
|
this.$emit('doback') |
|
|
|
} |
|
|
|