diff --git a/src/views/wms/basicDataManage/itemManage/itembasic/itembasic.data.ts b/src/views/wms/basicDataManage/itemManage/itembasic/itembasic.data.ts index 33be69fc9..52892f9a5 100644 --- a/src/views/wms/basicDataManage/itemManage/itembasic/itembasic.data.ts +++ b/src/views/wms/basicDataManage/itemManage/itembasic/itembasic.data.ts @@ -387,7 +387,6 @@ export const Itembasic = useCrudSchemas(reactive([ type: 'datetime', dateFormat: 'YYYY-MM-DD HH:mm:ss', valueFormat: 'x', - disabled: true } }, }, diff --git a/src/views/wms/deliversettlementManage/customerreceipt/customerreceiptRequestMain/index.vue b/src/views/wms/deliversettlementManage/customerreceipt/customerreceiptRequestMain/index.vue index c13b413bc..7bb86c985 100644 --- a/src/views/wms/deliversettlementManage/customerreceipt/customerreceiptRequestMain/index.vue +++ b/src/views/wms/deliversettlementManage/customerreceipt/customerreceiptRequestMain/index.vue @@ -72,6 +72,8 @@ :apiDelete="CustomerreceiptRequestDetailApi.deleteCustomerreceiptRequestDetail" fromeWhere="customerreceipt" :detailButtonIsShowAdd="false" + :detailButtonIsShowEdit="false" + :detailButtonIsShowDelete="false" /> diff --git a/src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/index.vue b/src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/index.vue index a2d6419ad..d0de662c8 100644 --- a/src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/index.vue +++ b/src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/index.vue @@ -68,6 +68,9 @@ :apiPage="CustomerreturnRequestDetailApi.getCustomerreturnRequestDetailPage" :apiDelete="CustomerreturnRequestDetailApi.deleteCustomerreturnRequestDetail" @searchTableSuccessDetail="searchTableSuccessDetail" + :detailButtonIsShowAdd="trueFalse" + :detailButtonIsShowDelete="trueFalse" + @detailOpenForm="detailOpenForm" /> @@ -171,7 +174,7 @@ const { tableObject, tableMethods } = useTable({ // 获得表格的各种操作 const { getList, setSearchParams } = tableMethods -const trueFalse = ref() +const trueFalse = ref(true) // 列表头部按钮 const HeadButttondata = [ defaultButtons.defaultAddBtn({hasPermi:'wms:customerreturn-request-main:create'}), // 新增——需要手动修改下权限 @@ -290,14 +293,66 @@ const buttonTableClick = async (val, row) => { /** 添加/修改操作 */ const formRef = ref() const openForm =async (type: string, row?: number) => { + if(type == "update"){ + CustomerreturnRequestMain.allSchemas.formSchema.forEach((item) => { + if(item.field == 'deliverRecordNumber'){ + item.componentProps.isSearchList = false, + item.componentProps.disabled = true + } + if(item.field == 'customerCode'){ + item.componentProps.isSearchList = false, + item.componentProps.disabled = true + } + if(item.field == 'customerDockCode'){ + item.componentProps.isSearchList = false, + item.componentProps.disabled = true + } + }) + }else { + CustomerreturnRequestMain.allSchemas.formSchema.forEach((item) => { + if(item.field == 'deliverRecordNumber'){ + item.componentProps.isSearchList = true + } + if(item.field == 'customerCode'){ + item.componentProps.isSearchList = true + } + if(item.field == 'customerDockCode'){ + item.componentProps.isSearchList = true + } + }) + CustomerreturnRequestDetail.allSchemas.formSchema.forEach((itemDetail) => { + if(itemDetail.field == 'packingNumber'){ + itemDetail.componentProps.isSearchList = true + } + }) + } tableData.value = [] // 重置明细数据 formRef.value.open(type, row) } +/** + * 详情 编辑页面打开 + * @param type + */ +const detailOpenForm = (type) => { + if(type == 'update'){ + CustomerreturnRequestDetail.allSchemas.formSchema.forEach((itemDetail) => { + if(itemDetail.field == 'packingNumber'){ + itemDetail.componentProps.isSearchList = false + itemDetail.componentProps.disabled = true + } + })}else { + CustomerreturnRequestDetail.allSchemas.formSchema.forEach((itemDetail) => { + if(itemDetail.field == 'packingNumber'){ + itemDetail.componentProps.isSearchList = true + } + }) + } +} + /** 详情操作 */ const detailRef = ref() const openDetail = (row: any, titleName: any, titleValue: any) => { - console.log(999,row.deliverPlanNumber); if(row.deliverPlanNumber != null){ trueFalse.value = false }else { diff --git a/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue b/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue index 9c6cd29a7..bb5f8ca4f 100644 --- a/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue +++ b/src/views/wms/deliversettlementManage/customersettle/customersettleRequestMain/index.vue @@ -70,6 +70,7 @@ :Echo="Echo" @searchTableSuccessDetail="searchTableSuccessDetail" :detailButtonIsShowEdit="false" + :detailButtonIsShowAdd="false" :detailButtonIsShowDelete="false" /> diff --git a/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue b/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue index 114af73b4..30115c516 100644 --- a/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue +++ b/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue @@ -73,8 +73,9 @@ :apiDelete="DeliverRequestDetailApi.deleteDeliverRequestDetail" fromeWhere="DeliverRequestMain" @searchTableSuccessDetail="searchTableSuccessDetail" - :detailButtonIsShowAdd="false" - :detailButtonIsShowDelete="false" + :detailButtonIsShowAdd="trueFalse" + :detailButtonIsShowDelete="trueFalse" + @detailOpenForm="detailOpenForm" /> @@ -313,14 +314,34 @@ const openForm =async (type: string, row?: number) => { formRef.value.open(type, row) } +/** + * 详情 编辑页面打开 + * @param row + */ + const detailOpenForm = (type) => { + if(type == 'update'){ + DeliverRequestDetail.allSchemas.formSchema.forEach((itemDetail) => { + if(itemDetail.field == 'itemCode'){ + itemDetail.componentProps.isSearchList = false + itemDetail.componentProps.disabled = true + } + })}else { + DeliverRequestDetail.allSchemas.formSchema.forEach((itemDetail) => { + if(itemDetail.field == 'itemCode'){ + itemDetail.componentProps.isSearchList = true + } + }) + } +} + /** 详情操作 */ const detailRef = ref() const openDetail = (row: any, titleName: any, titleValue: any) => { console.log(999,row.deliverPlanNumber); if(row.deliverPlanNumber != null){ - trueFalse.value = true + trueFalse.value = false }else { - trueFalse.value = false + trueFalse.value = true } detailRef.value.openDetail(row, titleName, titleValue,'requestDeliverMain') }