From b0212fcc5e1db411545da15d0f6e5cc955bedcdc Mon Sep 17 00:00:00 2001
From: hongchao <3228015117@qq.com>
Date: Wed, 19 Mar 2025 18:14:18 +0800
Subject: [PATCH] =?UTF-8?q?bug=E4=BF=AE=E5=A4=8D?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/cost/cost.js | 9 ++-
src/api/repair/scrapLedgerReview.js | 9 +++
.../material/cost/component/applyHome.vue | 49 +++++++++------
.../inventoryScrap/component/homeApply.vue | 61 +++++++++++++------
4 files changed, 88 insertions(+), 40 deletions(-)
diff --git a/src/api/cost/cost.js b/src/api/cost/cost.js
index 0e595f39..4a5d62f0 100644
--- a/src/api/cost/cost.js
+++ b/src/api/cost/cost.js
@@ -128,7 +128,14 @@ export function getProjectListByUnitIds(params){
})
}
-
+// 协议
+export function getAgreementInfoById(data) {
+ return request({
+ url: '/material/slt_agreement_info/getAgreementInfoById',
+ method: 'post',
+ data: data,
+ })
+}
diff --git a/src/api/repair/scrapLedgerReview.js b/src/api/repair/scrapLedgerReview.js
index 8b4eae4d..cb003654 100644
--- a/src/api/repair/scrapLedgerReview.js
+++ b/src/api/repair/scrapLedgerReview.js
@@ -99,4 +99,13 @@ export function getScrapDetailsList(query) {
method: 'get',
params: query
})
+}
+
+//盘点报废通过与驳回
+export function inventoryPass(data) {
+ return request({
+ url: '/material/scrap_apply_details/inventoryApprove',
+ method: 'post',
+ data: data
+ })
}
\ No newline at end of file
diff --git a/src/views/material/cost/component/applyHome.vue b/src/views/material/cost/component/applyHome.vue
index 38011c0f..34e190e1 100644
--- a/src/views/material/cost/component/applyHome.vue
+++ b/src/views/material/cost/component/applyHome.vue
@@ -44,7 +44,12 @@
> -->
-
+
+
+ {{ queryParams.agreementCode }}
+
+
+
0 && this.queryParams.projectId) {
const params = {
- unitId: this.queryParams.unitId,
+ unitIds: this.unitIds,
projectId: this.queryParams.projectId,
}
const res = await getAgreementInfoById(params)
console.log(res)
- if (!(res.data && res.data.agreementId)) {
+ if ((!res.data && res.data.some(item => !item.agreementId))) {
this.$message.error('当前单位和工程无协议!')
this.queryParams.unitId = null
this.queryParams.projectId = null
this.GetUnitData()
this.GetProData()
} else {
- this.queryParams.agreementId = res.data.agreementId
- this.queryParams.agreementCode = res.data.agreementCode
+ this.queryParams.agreementId = res.data.map(item => item.agreementId);
+ this.queryParams.agreementCode = res.data.map(item => item.agreementCode).join(',');
}
}
},
/** 查询列表 */
getList() {
this.loading = true
- getSltAgreementInfo(this.queryParams).then((response) => {
+ const params = {
+ pageNum: this.queryParams.pageNum,
+ pageSize: this.queryParams.pageSize,
+ projectId: this.queryParams.projectId,
+ sltStatus: this.queryParams.sltStatus,
+ // ...this.queryParams,
+ unitIds: this.unitIds,
+
+ }
+ getSltAgreementInfo(params).then((response) => {
this.tableList = response.rows
this.total = response.total
this.loading = false
@@ -418,7 +434,7 @@ export default {
isCommit:'',
unitId: null,
projectId: null,
- agreementId: '',
+ agreementId: [],
agreementCode: '',
}
this.resetForm('queryForm')
@@ -440,17 +456,12 @@ export default {
},
handleApplyList() {
if (this.ids.length < 1) {
- this.$message.error('请候选需要结算的数据!')
+ this.$message.error('请勾选需要结算的数据!')
return
}
if (this.ids.length > 0) {
let arr = this.ids
- this.$tab.closeOpenPage({
- path: '/cost/cost/costApplyAdd',
- query: {
- rowData: JSON.stringify(arr),
- },
- })
+ this.$emit("goDetail",JSON.stringify(arr));
}
},
// 多选框选中数据
diff --git a/src/views/material/repair/inventoryScrap/component/homeApply.vue b/src/views/material/repair/inventoryScrap/component/homeApply.vue
index e6f044cd..af3ac7ed 100644
--- a/src/views/material/repair/inventoryScrap/component/homeApply.vue
+++ b/src/views/material/repair/inventoryScrap/component/homeApply.vue
@@ -138,18 +138,10 @@