领料申请
This commit is contained in:
parent
94b92c7f84
commit
6d2104dff3
|
|
@ -62,8 +62,21 @@ export function getAgreement(data) {
|
|||
})
|
||||
}
|
||||
|
||||
// 领料申请-删除
|
||||
export function applyRemove(ids) {
|
||||
return request({
|
||||
url: '/material/lease_apply_info/' + ids,
|
||||
method: 'delete',
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
// 领料申请-发布
|
||||
export function applySend(ids) {
|
||||
return request({
|
||||
url: '/material/lease_apply_info/' + ids,
|
||||
method: 'delete',
|
||||
})
|
||||
}
|
||||
|
||||
//新购到货-二级列表详情
|
||||
export function getPurchaseCheckInfo(query) {
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
clearable
|
||||
filterable
|
||||
style="width: 240px"
|
||||
@change="projectChange"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in projectList"
|
||||
|
|
@ -333,29 +332,15 @@ export default {
|
|||
},
|
||||
methods: {
|
||||
uniteChange(val) {
|
||||
if (this.isEdit) {
|
||||
this.maForm.leaseProjectId = null;
|
||||
getListProject({ unitId: val }).then((response) => {
|
||||
if (response.data.length != 0) {
|
||||
this.projectList = response.data;
|
||||
} else {
|
||||
this.projectList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
this.projectList = [];
|
||||
this.$set(this.maForm, "leaseProjectId", null);
|
||||
getListProject({ unitId: val }).then((response) => {
|
||||
this.projectList = response.data;
|
||||
});
|
||||
this.unitTemp = val;
|
||||
},
|
||||
projectChange(val) {
|
||||
if (this.isEdit) {
|
||||
this.maForm.leaseUnitId = null;
|
||||
getListUnite({ projectId: val }).then((response) => {
|
||||
if (response.data.length != 0) {
|
||||
this.uniteList = response.data;
|
||||
} else {
|
||||
this.uniteList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
this.maForm.leaseProjectId = val;
|
||||
this.projectTemp = val;
|
||||
},
|
||||
/** 租赁单位和工程-下拉选 */
|
||||
|
|
@ -363,9 +348,9 @@ export default {
|
|||
getListUnite({ id: null }).then((response) => {
|
||||
this.uniteList = response.data;
|
||||
});
|
||||
getListProject({ id: null }).then((response) => {
|
||||
this.projectList = response.data;
|
||||
});
|
||||
// getListProject({ id: null }).then((response) => {
|
||||
// this.projectList = response.data;
|
||||
// });
|
||||
},
|
||||
//选择物资厂家
|
||||
// changeSupplier(supplierId) {
|
||||
|
|
|
|||
|
|
@ -406,6 +406,7 @@ import {
|
|||
getAcceptanceForm,
|
||||
purchaseCheckInfoRemove,
|
||||
queryStatusDataApi,
|
||||
applyRemove,
|
||||
} from "@/api/lease/apply";
|
||||
|
||||
export default {
|
||||
|
|
@ -585,10 +586,13 @@ export default {
|
|||
/** 删除按钮操作 */
|
||||
handleDeletePurchase(row) {
|
||||
// console.log(row)
|
||||
let ids = [];
|
||||
ids.push(row.id);
|
||||
console.log("ids", ids);
|
||||
this.$modal
|
||||
.confirm("是否确认删除所选择的数据项?")
|
||||
.then(function () {
|
||||
return purchaseCheckInfoRemove(row.id);
|
||||
return applyRemove(ids);
|
||||
})
|
||||
.then(() => {
|
||||
this.getList();
|
||||
|
|
@ -608,7 +612,18 @@ export default {
|
|||
|
||||
//发布按钮
|
||||
handleSend(row) {
|
||||
console.log("发布");
|
||||
let ids = [];
|
||||
ids.push(row.id);
|
||||
this.$modal
|
||||
.confirm("是否确认发布所选择的数据项?")
|
||||
.then(function () {
|
||||
return applySend(ids);
|
||||
})
|
||||
.then(() => {
|
||||
this.getList();
|
||||
this.$modal.msgSuccess("发布成功");
|
||||
})
|
||||
.catch(() => {});
|
||||
},
|
||||
|
||||
handleSendAll() {
|
||||
|
|
@ -619,8 +634,16 @@ export default {
|
|||
});
|
||||
return;
|
||||
} else {
|
||||
const ids = this.ids.join(",");
|
||||
console.log("发布");
|
||||
this.$modal
|
||||
.confirm("是否确认发布所选择的数据项?")
|
||||
.then(function () {
|
||||
return applySend(this.ids);
|
||||
})
|
||||
.then(() => {
|
||||
this.getList();
|
||||
this.$modal.msgSuccess("发布成功");
|
||||
})
|
||||
.catch(() => {});
|
||||
}
|
||||
},
|
||||
},
|
||||
|
|
|
|||
Loading…
Reference in New Issue