Commit eee16d85 authored by renjintao's avatar renjintao

配套申请--申请&&申请单--撤回

parent 06b7d0e1
...@@ -342,7 +342,8 @@ export default { ...@@ -342,7 +342,8 @@ export default {
Api.supportmainCreate(parms).then((res) => { Api.supportmainCreate(parms).then((res) => {
if (res.success) { if (res.success) {
this.$Message.success("申请成功"); this.$Message.success("申请成功");
this.$emit("cancel"); //this.$emit("cancel");
this.$emit('on-ok')
} }
}); });
} }
......
...@@ -50,5 +50,8 @@ export default { ...@@ -50,5 +50,8 @@ export default {
groupitemlist(params){//申请单列表 groupitemlist(params){//申请单列表
return Api.post(`${technologyUrl}supportmain/groupitemlist`, params); return Api.post(`${technologyUrl}supportmain/groupitemlist`, params);
}, },
batchdelete(params){//批量撤回
return Api.post(`${technologyUrl}supportitem/batchdelete`, params);
},
} }
\ No newline at end of file
...@@ -94,7 +94,7 @@ export default { ...@@ -94,7 +94,7 @@ export default {
oprate: "detail", oprate: "detail",
}, },
on: { on: {
click: () => this.application(0,params.row), click: () => this.application(0, params.row),
}, },
}, },
"撤回" "撤回"
...@@ -135,18 +135,22 @@ export default { ...@@ -135,18 +135,22 @@ export default {
} }
}); });
}, },
application(type, arr) {//撤回配套申请 type:0 单条 1 全部
application(type,arr) { let parms = [];
let msg="" if (type == 0) {
if(type==0) parms.push(arr.id);
{ } else {
msg="行内数据" arr.forEach((ele) => {
parms.push(ele.id);
});
} }
else Api.batchdelete(parms).then(res=>{
if(res.success&&res.result)
{ {
msg="整个申请单数据" this.$Message.success("撤销成功");
this.$emit('on-ok')
} }
alert(msg+"_____"+JSON.stringify(arr)); })
}, },
}, },
watch: { watch: {
......
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
:drawnNumber="drawnNumber" :drawnNumber="drawnNumber"
:count="count" :count="count"
@on-close="cancel" @on-close="cancel"
@on-ok="ok" @on-ok="addOk"
/> />
</Modal> </Modal>
</div> </div>
...@@ -652,6 +652,7 @@ export default { ...@@ -652,6 +652,7 @@ export default {
this.listBatchIds = []; this.listBatchIds = [];
this.listBatchIds1 = []; this.listBatchIds1 = [];
this.canselFooter(); this.canselFooter();
this.modalAccessory = false;
}, },
search() { search() {
this.$refs.grid.reload(this.easySearch); this.$refs.grid.reload(this.easySearch);
...@@ -689,6 +690,7 @@ export default { ...@@ -689,6 +690,7 @@ export default {
//aps //aps
this.dispatchModal = false; this.dispatchModal = false;
this.scheduleModal = false; this.scheduleModal = false;
this.modalAccessory = false;
// this.listBatchIds = [] // this.listBatchIds = []
// this.listBatchIds1 = [] // this.listBatchIds1 = []
// this.canselFooter() // this.canselFooter()
...@@ -821,10 +823,6 @@ export default { ...@@ -821,10 +823,6 @@ export default {
this.modalAccessory = true; this.modalAccessory = true;
}, },
cancel() {
this.curId = 0;
this.modalAccessory = false;
},
ok() { ok() {
this.modalAccessory = false; this.modalAccessory = false;
this.curId = 0; this.curId = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment