From 2226e5f345f395a9ad1d03b477f1ad55209caedd Mon Sep 17 00:00:00 2001
From: yufei0306 <13417315+yufei0306@user.noreply.gitee.com>
Date: Wed, 24 Apr 2024 08:21:08 +0800
Subject: [PATCH] =?UTF-8?q?=E7=BB=93=E7=AE=97--=E4=B8=BB=E5=AD=90=E8=A1=A8?=
=?UTF-8?q?=E5=90=88=E5=B9=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../customersettleRecordMain/index.vue | 15 ++++++----
.../customersettleRequestMain/index.vue | 29 +++++++++++--------
.../stockupMainRequest.data.ts | 1 -
3 files changed, 27 insertions(+), 18 deletions(-)
diff --git a/src/views/wms/deliversettlementManage/customersettle/customersettleRecordMain/index.vue b/src/views/wms/deliversettlementManage/customersettle/customersettleRecordMain/index.vue
index 3cc5fd025..4ad315706 100644
--- a/src/views/wms/deliversettlementManage/customersettle/customersettleRecordMain/index.vue
+++ b/src/views/wms/deliversettlementManage/customersettle/customersettleRecordMain/index.vue
@@ -1,7 +1,7 @@
-
+
@@ -12,6 +12,7 @@
@updataTableColumns="updataTableColumns"
@searchFormClick="searchFormClick"
:allSchemas="CustomersettleRecordMain.allSchemas"
+ :detailAllSchemas="CustomersettleRecordDetail.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(CustomersettleRecordMain.allSchemas.tableColumns)
+const tableColumns = ref([...CustomersettleRecordMain.allSchemas.tableColumns,...CustomersettleRecordDetail.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/deliversettlementManage/customersettle/customersettleRequestMain/index.vue b/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue
index 014e8b64c..97d3ccb28 100644
--- a/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue
+++ b/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue
@@ -1,7 +1,7 @@
-
+
@@ -12,6 +12,7 @@
@updataTableColumns="updataTableColumns"
@searchFormClick="searchFormClick"
:allSchemas="CustomersettleRequestMain.allSchemas"
+ :detailAllSchemas="CustomersettleRequestDetail.allSchemas"
/>
@@ -32,8 +33,8 @@
{{ row.number }}
-
-
+
+
@@ -96,7 +97,7 @@ const { t } = useI18n() // 国际化
const route = useRoute() // 路由信息
const routeName = ref()
routeName.value = route.name
-const tableColumns = ref(CustomersettleRequestMain.allSchemas.tableColumns)
+const tableColumns = ref([...CustomersettleRequestMain.allSchemas.tableColumns,...CustomersettleRequestDetail.allSchemas.tableMainColumns])
// 字段设置 更新主列表字段
const updataTableColumns = (val) => {
@@ -205,7 +206,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']),hasPermi:'wms:customersettle-request-main:close'}), // 关闭
defaultButtons.mainListReAddBtn({hide:isShowMainButton(row,['4','5']),hasPermi:'wms:customersettle-request-main:reAdd'}), //重新添加
@@ -224,7 +229,7 @@ const buttonTableClick = async (val, row) => {
if (val == 'mainClose') { // 关闭
await message.confirm('确认要关闭吗?')
tableObject.loading = true
- CustomersettleRequestMainApi.close(row.id).then(() => {
+ CustomersettleRequestMainApi.close(row.masterId).then(() => {
tableObject.loading = false
message.success(t('common.updateSuccess'))
getList()
@@ -234,7 +239,7 @@ const buttonTableClick = async (val, row) => {
}) } else if (val == 'mainReAdd') { // 重新添加
await message.confirm('确认要重新添加吗?')
tableObject.loading = true
- CustomersettleRequestMainApi.reAdd(row.id).then(() => {
+ CustomersettleRequestMainApi.reAdd(row.masterId).then(() => {
tableObject.loading = false
message.success(t('common.updateSuccess'))
getList()
@@ -245,7 +250,7 @@ const buttonTableClick = async (val, row) => {
} else if (val == 'mainSubmit') { // 提交审批
await message.confirm('确认要提交审批吗?')
tableObject.loading = true
- CustomersettleRequestMainApi.submit(row.id).then(() => {
+ CustomersettleRequestMainApi.submit(row.masterId).then(() => {
tableObject.loading = false
message.success(t('common.updateSuccess'))
getList()
@@ -256,7 +261,7 @@ const buttonTableClick = async (val, row) => {
} else if (val == 'mainTurnDown') { // 驳回
await message.confirm('确认要重新添加吗?')
tableObject.loading = true
- CustomersettleRequestMainApi.refused(row.id).then(() => {
+ CustomersettleRequestMainApi.refused(row.masterId).then(() => {
message.success(t('common.updateSuccess'))
getList()
}).catch(err => {
@@ -264,7 +269,7 @@ const buttonTableClick = async (val, row) => {
})
} else if (val == 'mainApprove') { // 审批通过
tableObject.loading = true
- CustomersettleRequestMainApi.agree(row.id).then(() => {
+ CustomersettleRequestMainApi.agree(row.masterId).then(() => {
tableObject.loading = false
message.success(t('common.updateSuccess'))
getList()
@@ -274,7 +279,7 @@ const buttonTableClick = async (val, row) => {
})
} else if (val == 'mainHandle') { // 处理
tableObject.loading = true
- CustomersettleRequestMainApi.handle(row.id).then(() => {
+ CustomersettleRequestMainApi.handle(row.masterId).then(() => {
tableObject.loading = false
message.success(t('common.updateSuccess'))
getList()
@@ -285,7 +290,7 @@ const buttonTableClick = async (val, row) => {
} else if (val == 'edit') { // 编辑
openForm('update', row)
} else if (val == 'delete') { // 删除
- handleDelete(row.id)
+ handleDelete(row.masterId)
}
}
diff --git a/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts b/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts
index c9f1f60d3..eafa982ad 100644
--- a/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts
+++ b/src/views/wms/deliversettlementManage/stockup/stockupMainRequest/stockupMainRequest.data.ts
@@ -283,7 +283,6 @@ export const StockupMainRequest = useCrudSchemas(reactive([
table: {
width: 150
},
- isForm: false,
},
{
label: '备注',