| | |
| | | this.saveChangeRowTable(); |
| | | } |
| | | else { // 开户提交 |
| | | me.loading_pass = true ; |
| | | var bo_JCXX = this.$refs.JCXX.checkForm(); |
| | | |
| | | if (!bo_JCXX) { |
| | |
| | | } |
| | | tableData_.push(row_); |
| | | }) |
| | | if (me.formData_criteria && me.formData_criteria.length > 0) { //不是新增 |
| | | me.formdata_rule_group.map(group => {// |
| | | group.children.map(unitobj => { |
| | | var row_ = { |
| | | id: unitobj.id, |
| | | parent_id: me.formData.id, |
| | | criteria_id: unitobj.criteria_id, |
| | | criteria_value: unitobj.criteria_value, |
| | | remark: unitobj.remark ? unitobj.remark : '', |
| | | } |
| | | md_org_account_criteria_.push(row_); |
| | | }) |
| | | }) |
| | | } |
| | | else { |
| | | me.formdata_rule_group.map(group => {// |
| | | group.children.map(unitobj => { |
| | | var row_ = { |
| | | parent_id: me.formData.id, |
| | | criteria_id: unitobj.id, |
| | | criteria_value: unitobj.criteria_value, |
| | | remark: unitobj.remark ? unitobj.remark : '', |
| | | } |
| | | md_org_account_criteria_.push(row_); |
| | | }) |
| | | }) |
| | | } |
| | | |
| | | if (tableData_.length == 0) { |
| | | Root.message({ |
| | |
| | | me.iscommit = false |
| | | return |
| | | } |
| | | |
| | | if (md_org_account_criteria_.some(e=>e.criteria_value == '' || e.criteria_value == null)) { |
| | | Root.message({ |
| | | type: 'warning', |
| | | message: '请先添加明细数据' |
| | | }); |
| | | me.iscommit = false |
| | | return |
| | | } |
| | | let param = { |
| | | dataname: 'md_org_account', |
| | | data: {}, |
| | |
| | | } |
| | | |
| | | } |
| | | if (me.formData_criteria && me.formData_criteria.length > 0) { //不是新增 |
| | | me.formdata_rule_group.map(group => {// |
| | | group.children.map(unitobj => { |
| | | if (!unitobj.criteria_value) { |
| | | Root.message({ |
| | | type: 'warning', |
| | | message: '请先添加明细数据' |
| | | }); |
| | | me.iscommit = false |
| | | return |
| | | } |
| | | var row_ = { |
| | | id: unitobj.id, |
| | | parent_id: me.formData.id, |
| | | criteria_id: unitobj.criteria_id, |
| | | criteria_value: unitobj.criteria_value, |
| | | remark: unitobj.remark ? unitobj.remark : '', |
| | | } |
| | | md_org_account_criteria_.push(row_); |
| | | }) |
| | | }) |
| | | } |
| | | else { |
| | | me.formdata_rule_group.map(group => {// |
| | | group.children.map(unitobj => { |
| | | if (!unitobj.criteria_value) { |
| | | Root.message({ |
| | | type: 'warning', |
| | | message: '请先添加明细数据' |
| | | }); |
| | | me.iscommit = false |
| | | return |
| | | } |
| | | var row_ = { |
| | | parent_id: me.formData.id, |
| | | criteria_id: unitobj.id, |
| | | criteria_value: unitobj.criteria_value, |
| | | remark: unitobj.remark ? unitobj.remark : '', |
| | | } |
| | | md_org_account_criteria_.push(row_); |
| | | }) |
| | | }) |
| | | } |
| | | |
| | | param.data["md_org_account_criteria"] = md_org_account_criteria_.length ? md_org_account_criteria_ : null; |
| | | |
| | | param.data[this.dataname] = entity; |
| | |
| | | if (result.success) { |
| | | if(me.iscommit){ |
| | | me.iscommit = false; |
| | | Root.message({ |
| | | type: 'success', |
| | | message: '提交成功' |
| | | }); |
| | | me.saveAfter(); |
| | | // Root.message({ |
| | | // type: 'success', |
| | | // message: '提交成功' |
| | | // }); |
| | | me.doapprove() |
| | | } |
| | | else { |
| | | Root.message({ |
| | |
| | | } |
| | | }); |
| | | }, |
| | | doapprove(){ |
| | | var me = this |
| | | me.loading_pass = true; |
| | | let param = { |
| | | dataname: "md_org_account", |
| | | id: me.formData.id, |
| | | remark: this.approveremark |
| | | } |
| | | Server.call("root/data/approve", param, function(result) { |
| | | me.loading_pass = false; |
| | | // Root.message({ |
| | | // type: 'success', |
| | | // message: '审批成功' |
| | | // }); |
| | | Root.message({ |
| | | type: 'success', |
| | | message: '提交成功' |
| | | }); |
| | | me.saveAfter() |
| | | }, function(errorresult) { |
| | | console.log("错误信息", errorresult); |
| | | me.loading_pass = false; |
| | | if (errorresult.messages && errorresult.messages.count && errorresult.messages.count.error) { |
| | | if (errorresult.messages.list) { |
| | | var config = { |
| | | totab: false, |
| | | // width: "1200px", |
| | | // height: 800, |
| | | icon: "icon-product", |
| | | text: "错误信息", |
| | | url: "module/tool/page/popup_error_messages.html", |
| | | data: {}, |
| | | delta: errorresult.messages.list, |
| | | callback: function(obj, callback) { |
| | | if (callback) { |
| | | callback(); |
| | | } |
| | | } |
| | | }; |
| | | me.doPopupByPublic(config); |
| | | |
| | | } |
| | | } |
| | | else { |
| | | Root.message({ |
| | | type: 'error', |
| | | message: '提交失败' |
| | | }); |
| | | } |
| | | }); |
| | | }, |
| | | |
| | | // 通过或拒绝 |
| | | onShowApproval(passOrRefuse) { |
| | |
| | | // this.getMachine(function(next_step, up_step) { // |
| | | // me.doRunApproval(next_step, up_step); |
| | | // }); |
| | | }, |
| | | |
| | | getMachine(callback) { |
| | | var me = this; |
| | | let param = { |
| | | dataname: "md_org_account", |
| | | } |
| | | Server.call("root/state/getMachine", param, function(result) { |
| | | var next_step = {}; // 向下流程 |
| | | var up_step = {}; // 向上流程 |
| | | |
| | | if (result && result.machine && result.machine.detail) { |
| | | result.machine.detail.map(md=>{ |
| | | next_step[md.from_code] = md.to_code; |
| | | up_step[md.to_code] = md.from_code; |
| | | }) |
| | | |
| | | callback(next_step, up_step); |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | doRunApproval(next_step, up_step) { |
| | |
| | | <el-button size="small" type="default" @click="closeDialog">取 消</el-button> |
| | | <el-button size="small" v-if="!isChange && isedit" type="success" @click="submitRowTable":icon="buttonsconfig.submit.icon">{{buttonsconfig.submit.name}}</el-button> |
| | | |
| | | <el-button size="small" v-if="isChange" type="success" @click="submitRowTable":icon="buttonsconfig.submit.icon">{{buttonsconfig.submit.name}}</el-button> |
| | | <el-button size="small" v-if="isChange" type="success" :loading="loading_pass" @click="submitRowTable":icon="buttonsconfig.submit.icon">{{buttonsconfig.submit.name}}</el-button> |
| | | |
| | | <el-button size="small" v-if="isrefuseedit" type="success" @click="">再次提交</el-button> |
| | | |
| | |
| | | } |
| | | }, |
| | | { |
| | | name: "预合作申请", isbuttonshow: true,type:"success",icon: "el-icon-news", |
| | | name: "转预合作", isbuttonshow: true,type:"success",icon: "el-icon-news", |
| | | code: "account",isselected: true,classname: "", |
| | | disabled: function(selectRowList) { |
| | | var bo_ = true; |
| | | if (selectRowList[0] && selectRowList[0].state_code == "Open") { |
| | | if (selectRowList[0] && (selectRowList[0].state_code == "Open" || selectRowList[0].state_code == "Prepared")) { |
| | | bo_ = false; |
| | | } |
| | | return bo_ |
| | |
| | | // } |
| | | // }, |
| | | |
| | | { |
| | | isbuttonshow: me.cbuttons_r.delete ? me.cbuttons_r.delete : false, type: "danger", |
| | | code: "repeal", isselected: true, classname:"", |
| | | // { |
| | | // isbuttonshow: me.cbuttons_r.delete ? me.cbuttons_r.delete : false, type: "danger", |
| | | // code: "repeal", isselected: true, classname:"", |
| | | // disabled: function(selectRowList) { |
| | | // var bo_ = true ; |
| | | // if (selectRowList[0] && selectRowList[0].source == "DMS") { |
| | | // bo_ = false |
| | | // } |
| | | // return bo_; |
| | | // }, |
| | | // onclick: function(obj) { |
| | | // me.repealDataPolicy(obj, obj.selectedList[0]) |
| | | // } |
| | | // }, |
| | | { |
| | | // name: "删除", // type: "primary", // icon: "el-icon-edit", |
| | | isbuttonshow: me.cbuttons_r.delete ? me.cbuttons_r.delete : false, type: "danger", |
| | | code: "delete", isselected: true, classname: "", |
| | | disabled: function(selectRowList) { |
| | | var bo_ = true ; |
| | | if (selectRowList[0] && selectRowList[0].source == "DMS") { |
| | | bo_ = false |
| | | } |
| | | return bo_; |
| | | var bo_ = true ; |
| | | if (selectRowList[0] && selectRowList[0].state_code == 'Input') { |
| | | bo_ = false |
| | | } |
| | | return bo_; |
| | | }, |
| | | onclick: function(obj) { |
| | | me.repealDataPolicy(obj, obj.selectedList[0]) |
| | | me.delData() |
| | | // obj.selectedList |
| | | // me.closeData('browse', obj.selectedList[0]); |
| | | // me.closeData(); |
| | | } |
| | | }, |
| | | |
| | |
| | | ] |
| | | |
| | | tablebuttonClick.WaitOpen = [ |
| | | { |
| | | // name: "提交", // type: "primary", // icon: "el-icon-edit", |
| | | { |
| | | name: "转合作", // type: "primary", // icon: "el-icon-edit", |
| | | isbuttonshow: me.cbuttons_r.commitData ? me.cbuttons_r.commitData : false, type: "success", |
| | | code: "submit", isselected: true, classname: "", |
| | | code: "toCooperation", isselected: true, classname: "", |
| | | disabled: function(selectRowList) { |
| | | var bo_ = true ; |
| | | if (selectRowList[0] && selectRowList[0].state_code == 'Open') { |
| | |
| | | }, |
| | | commitnCustomerUser(sceneCode, row) { |
| | | var me = this; |
| | | Root.confirm('是否确认提交', '提交提示', { |
| | | confirmButtonText: '确 认', |
| | | Root.confirm('确认提交正式合作?', '提交提示', { |
| | | confirmButtonText: '转 合 作', |
| | | cancelButtonText: '取 消', |
| | | type: 'warning' |
| | | }).then(() => { |