Browse Source

测试采购收货任务

master
liuchen864 1 year ago
parent
commit
76e9149ff5
  1. 7
      src/api/wms/purchasereceiptJobMain/index.ts
  2. 20
      src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptJobMain/index.vue
  3. 2
      src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue
  4. 20
      src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestMain/index.vue

7
src/api/wms/purchasereceiptJobMain/index.ts

@ -86,4 +86,9 @@ export const exportPurchasereceiptJobMain = async (params) => {
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/purchasereceipt-job-main/get-import-template' })
}
}
// 关闭采购收货任务主
export const closePurchasereceiptJobMain = (id: number) => {
return request.download({ url: '/wms/purchasereceipt-job-main/close?id=' + id })
}

20
src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptJobMain/index.vue

@ -174,9 +174,9 @@ const isShowMainButton = (row,val) => {
// -
const butttondata = (row) => {
return [
defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), //
defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1'])}), //
defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), //
// defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), //
defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-job-main:close'}), //
// defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), //
// defaultButtons.mainListJobExeBtn({hide:isShowMainButton(row,['2'])}), //
]
}
@ -188,12 +188,22 @@ const buttonTableClick = async (val, row) => {
} else if (val == 'mainJobAba') { //
console.log('列表-操作按钮事件-放弃')
} else if (val == 'mainJobClo') { //
console.log('列表-操作按钮事件-关闭')
handleClose(row.id)
} else if (val == 'mainJobAcc') { //
console.log('列表-操作按钮事件-承接')
}
}
/** 关闭按钮操作 */
const handleClose = async (id: number) => {
try {
await message.confirm(t('common.confirmColse'))
await PurchasereceiptJobMainApi.closePurchasereceiptJobMain(id)
message.success(t('common.closeSuccess'))
await getList()
} catch {}
}
/** 详情操作 */
const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => {
@ -209,7 +219,7 @@ const handleExport = async () => {
//
exportLoading.value = true
const data = await PurchasereceiptJobMainApi.exportPurchasereceiptJobMain(setSearchParams)
download.excel(data, '采购收货任务主.xls')
download.excel(data, '采购收货任务主.xlsx')
} catch {
} finally {
exportLoading.value = false

2
src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue

@ -142,7 +142,7 @@ const handleExport = async () => {
//
exportLoading.value = true
const data = await PurchasereceiptRecordMainApi.exportPurchasereceiptRecordMain(setSearchParams)
download.excel(data, '采购收货记录主.xls')
download.excel(data, '采购收货记录主.xlsx')
} catch {
} finally {
exportLoading.value = false

20
src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRequestMain/index.vue

@ -177,15 +177,15 @@ const isShowMainButton = (row,val) => {
// -
const butttondata = (row) => {
return [
defaultButtons.mainListCloseBtn({hide:isShowMainButton(row,['1','2','3','4','6'])}), //
defaultButtons.mainListReAddBtn({hide:isShowMainButton(row,['5'])}), //
defaultButtons.mainListSubmitBtn({hide:isShowMainButton(row,['1'])}), //
defaultButtons.mainListTurnDownBtn({hide:isShowMainButton(row,['2'])}), //
defaultButtons.mainListApproveBtn({hide:isShowMainButton(row,['2'])}), //
defaultButtons.mainListHandleBtn({hide:isShowMainButton(row,['3'])}), //
defaultButtons.mainListEditBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-request-main:update'}), //
]
return [
defaultButtons.mainListCloseBtn({hide:isShowMainButton(row,['1','2','3','4','6']),hasPermi:'wms:purchasereceipt-request-main:close'}), //
defaultButtons.mainListReAddBtn({hide:isShowMainButton(row,['5']),hasPermi:'wms:purchasereceipt-request-main:reAdd'}), //
defaultButtons.mainListSubmitBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-request-main:submit'}), //
defaultButtons.mainListTurnDownBtn({hide:isShowMainButton(row,['2']),hasPermi:'wms:purchasereceipt-request-main:refused'}), //
defaultButtons.mainListApproveBtn({hide:isShowMainButton(row,['2']),hasPermi:'wms:purchasereceipt-request-main:agree'}), //
defaultButtons.mainListHandleBtn({hide:isShowMainButton(row,['3']),hasPermi:'wms:purchasereceipt-request-main:handle'}), //
defaultButtons.mainListEditBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-request-main:update'}), //
]
}
// -
@ -289,7 +289,7 @@ const handleExport = async () => {
//
exportLoading.value = true
const data = await PurchasereceiptRequestMainApi.exportPurchasereceiptRequestMain(setSearchParams)
download.excel(data, '采购收货申请主.xls')
download.excel(data, '采购收货申请主.xlsx')
} catch {
} finally {
exportLoading.value = false

Loading…
Cancel
Save