|
@@ -768,6 +768,7 @@ export default {
|
|
|
},
|
|
|
// 表单字段数值发生改变事件
|
|
|
handleChange (value, key) {
|
|
|
+ // debugger
|
|
|
if(key == 'proposer' && this.processData.businessTable == 'regular_employee_apply'){//员工转正申请:申请人部门
|
|
|
this.$refs.KFB.setData({apply_department:this.deptInfo[value]})
|
|
|
}
|
|
@@ -780,6 +781,15 @@ export default {
|
|
|
if(key == 'employee_name' && this.processData.businessTable == 'separation_application'){//离职申请
|
|
|
this.$refs.KFB.setData({job_title:this.postInfo[value]})
|
|
|
}
|
|
|
+
|
|
|
+ if(this.processData.businessTable == 'incident_ticket' &&key=='child&incident_ticket_children'){
|
|
|
+ var all = 0
|
|
|
+ value.map(item=>{
|
|
|
+ item.accident_sum = item.accident_sum?item.accident_sum:0
|
|
|
+ all+=item.accident_sum
|
|
|
+ })
|
|
|
+ this.$refs.KFB.setData({total_money:all})
|
|
|
+ }
|
|
|
//技能博物馆-----退休录入
|
|
|
if(key == 'name' && this.processData.businessTable == 'bwg_retire_input'){//技能博物馆 ---- 退休录入
|
|
|
this.dynamicData.personListJn.map(item =>{
|
|
@@ -887,7 +897,7 @@ export default {
|
|
|
}
|
|
|
|
|
|
//改变的表单是主子表类型时----物质申请单
|
|
|
- if(this.processData.businessTable == 'supplieses_apply_a'){
|
|
|
+ if(this.processData.businessTable == 'supplieses_apply_a' && key =='child&supplieses_apply'){
|
|
|
this.tableCalculation(value)
|
|
|
}
|
|
|
//特别字段
|
|
@@ -966,7 +976,6 @@ export default {
|
|
|
},
|
|
|
// handler
|
|
|
handleSubmit (e) {
|
|
|
-
|
|
|
// return new Promise((resolve)=>{
|
|
|
// 通过函数获取数据
|
|
|
this.$refs.KFB.getData()
|
|
@@ -985,6 +994,25 @@ export default {
|
|
|
addForm = 'yes'
|
|
|
}
|
|
|
}
|
|
|
+ if(this.processData.businessTable == 'incident_ticket'){
|
|
|
+ var supplier = this.$refs.KFB.form.getFieldValue('responsibility_company')
|
|
|
+ var responsibility = this.$refs.KFB.form.getFieldValue('responsibility_person1')
|
|
|
+ var factory = this.$refs.KFB.form.getFieldValue('factory_signature')
|
|
|
+ if((!supplier||supplier=='') && (!responsibility || responsibility=='')){
|
|
|
+ this.$message.error('责任人和责任单位必填其一')
|
|
|
+ addForm = 'yes'
|
|
|
+ }
|
|
|
+ if(supplier&&supplier!==''){
|
|
|
+ var type = this.$refs.KFB.form.getFieldValue('business_type')
|
|
|
+ if(!type|| type==''){
|
|
|
+ this.$message.error('请选择业务类型')
|
|
|
+ addForm = 'yes'
|
|
|
+ }else if(!factory || factory==''){
|
|
|
+ this.$message.error('请上传工厂签章')
|
|
|
+ addForm = 'yes'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
let formData1 = JSON.parse(JSON.stringify(res))
|
|
|
console.log("orl",formData1)
|
|
|
// 处理手机端子表数据
|