From f38122f8f50f11a285eb1340dbd6d56b31064975 Mon Sep 17 00:00:00 2001
From: yufei0306 <13417315+yufei0306@user.noreply.gitee.com>
Date: Mon, 22 Apr 2024 16:12:48 +0800
Subject: [PATCH] =?UTF-8?q?=E4=B8=8B=E7=BA=BF=E7=BB=93=E7=AE=97--=E4=B8=BB?=
=?UTF-8?q?=E5=AD=90=E8=A1=A8=E5=90=88=E5=B9=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../offlinesettlementRecordMain/index.vue | 15 ++++++++++-----
.../offlinesettlementRequestMain/index.vue | 17 +++++++++++------
2 files changed, 21 insertions(+), 11 deletions(-)
diff --git a/src/views/wms/productionManage/offlinesettlement/offlinesettlementRecordMain/index.vue b/src/views/wms/productionManage/offlinesettlement/offlinesettlementRecordMain/index.vue
index 10463d157..24c75b7de 100644
--- a/src/views/wms/productionManage/offlinesettlement/offlinesettlementRecordMain/index.vue
+++ b/src/views/wms/productionManage/offlinesettlement/offlinesettlementRecordMain/index.vue
@@ -1,7 +1,7 @@
-
+
@@ -12,6 +12,7 @@
@updataTableColumns="updataTableColumns"
@searchFormClick="searchFormClick"
:allSchemas="OfflinesettlementRecordMain.allSchemas"
+ :detailAllSchemas="OfflinesettlementRecordDetail.allSchemas"
/>
@@ -32,8 +33,8 @@
{{ row.number }}
-
-
+
+
@@ -76,7 +77,7 @@ const { t } = useI18n() // 国际化
const route = useRoute() // 路由信息
const routeName = ref()
routeName.value = route.name
-const tableColumns = ref(OfflinesettlementRecordMain.allSchemas.tableColumns)
+const tableColumns = ref([...OfflinesettlementRecordMain.allSchemas.tableColumns,...OfflinesettlementRecordDetail.allSchemas.tableMainColumns])
// 字段设置 更新主列表字段
const updataTableColumns = (val) => {
@@ -125,7 +126,11 @@ const buttonBaseClick = (val, item) => {
}
// 列表-操作按钮
-const butttondata = (row) => {
+const butttondata = (row,$index) => {
+ const findIndex = row['masterId']?tableObject.tableList.findIndex(item=>item['masterId'] == row['masterId']):-1
+ if(findIndex>0&&findIndex<$index){
+ return []
+ }
return []
}
diff --git a/src/views/wms/productionManage/offlinesettlement/offlinesettlementRequestMain/index.vue b/src/views/wms/productionManage/offlinesettlement/offlinesettlementRequestMain/index.vue
index a1edcc084..0ca3857b3 100644
--- a/src/views/wms/productionManage/offlinesettlement/offlinesettlementRequestMain/index.vue
+++ b/src/views/wms/productionManage/offlinesettlement/offlinesettlementRequestMain/index.vue
@@ -1,7 +1,7 @@
-
+
@@ -12,6 +12,7 @@
@updataTableColumns="updataTableColumns"
@searchFormClick="searchFormClick"
:allSchemas="OfflinesettlementRequestMain.allSchemas"
+ :detailAllSchemas="OfflinesettlementRequestDetail.allSchemas"
/>
@@ -32,8 +33,8 @@
{{ row.number }}
-
-
+
+
@@ -94,7 +95,7 @@ const { t } = useI18n() // 国际化
const route = useRoute() // 路由信息
const routeName = ref()
routeName.value = route.name
-const tableColumns = ref(OfflinesettlementRequestMain.allSchemas.tableColumns)
+const tableColumns = ref([...OfflinesettlementRequestMain.allSchemas.tableColumns,...OfflinesettlementRequestDetail.allSchemas.tableMainColumns])
// 字段设置 更新主列表字段
const updataTableColumns = (val) => {
@@ -197,7 +198,11 @@ const isShowMainButton = (row,val) => {
}
// 列表-操作按钮
-const butttondata = (row) => {
+const butttondata = (row,$index) => {
+ const findIndex = row['masterId']?tableObject.tableList.findIndex(item=>item['masterId'] == row['masterId']):-1
+ if(findIndex>0&&findIndex<$index){
+ return []
+ }
return [
defaultButtons.mainListCloseBtn({hide:isShowMainButton(row,['1','2','3','4','6'])}), // 关闭
defaultButtons.mainListReAddBtn({hide:isShowMainButton(row,['4','5'])}), // 重新添加
@@ -226,7 +231,7 @@ const buttonTableClick = async (val, row) => {
} else if (val == 'edit') { // 编辑
openForm('update', row)
} else if (val == 'delete') { // 删除
- handleDelete(row.id)
+ handleDelete(row.masterId)
}
}