张立 1 year ago
parent
commit
9ea53718df
  1. 32
      src/api/wms/unplannedreceiptRequestMain/index.ts
  2. 16
      src/components/ImportForm/src/ImportForm.vue
  3. 6
      src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptJobMain/index.vue
  4. 85
      src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue
  5. 42
      src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/index.vue
  6. 8
      src/views/wms/purchasereceiptManage/inspect/inspectJobMain/inspectJobMain.data.ts
  7. 4
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnJobMain/purchasereturnJobMain.data.ts
  8. 8
      src/views/wms/purchasereceiptManage/putaway/putawayJobMain/putawayJobMain.data.ts
  9. 6
      src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/index.vue
  10. 2
      src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/index.vue

32
src/api/wms/unplannedreceiptRequestMain/index.ts

@ -62,9 +62,37 @@ export const exportUnplannedreceiptRequestMain = async (params) => {
} }
} }
// 下载用户导入模板 // 下载用户导入模板
export const importTemplate = () => { export const importTemplate = () => {
return request.download({ url: '/wms/unplannedreceipt-request-main/get-import-template' }) return request.download({ url: '/wms/unplannedreceipt-request-main/get-import-template' })
} }
// 关闭-计划外入库申请
export const closeUnplannedreceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedreceipt-request-main/close?id=` + id })
}
// 重新添加-计划外入库申请
export const reAddUnplannedreceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedreceipt-request-main/reAdd?id=` + id })
}
// 提交审批-计划外入库申请
export const submitUnplannedreceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedreceipt-request-main/submit?id=` + id })
}
// 审批驳回-计划外入库申请
export const refusedUnplannedreceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedreceipt-request-main/refused?id=` + id })
}
// 审批通过-计划外入库申请
export const agreeUnplannedreceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedreceipt-request-main/agree?id=` + id })
}
// 处理-计划外入库申请
export const handleUnplannedreceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedreceipt-request-main/handle?id=` + id })
}

16
src/components/ImportForm/src/ImportForm.vue

@ -13,7 +13,9 @@
'&updatePart=' + '&updatePart=' +
updatePart + updatePart +
'&outFile=' + '&outFile=' +
outFile outFile +
'&fromInventoryStatus=' + fromInventoryStatus +
'&toInventoryStatus=' + toInventoryStatus
" "
:auto-upload="false" :auto-upload="false"
:disabled="formLoading" :disabled="formLoading"
@ -168,6 +170,18 @@ const props = defineProps({
type: Boolean, type: Boolean,
required: false, required: false,
default: false default: false
},
//
fromInventoryStatus: {
type: String,
required: false,
default: ''
},
//
toInventoryStatus: {
type: String,
required: false,
default: ''
} }
}) })
const importTemplateData = ref(props.importTemplateData) const importTemplateData = ref(props.importTemplateData)

6
src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptJobMain/index.vue

@ -174,9 +174,9 @@ const isShowMainButton = (row,val) => {
// - // -
const butttondata = (row) => { const butttondata = (row) => {
return [ return [
defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), // // defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), //
defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1'])}), // // defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1'])}), //
defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), // // defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), //
// defaultButtons.mainListJobExeBtn({hide:isShowMainButton(row,['2'])}), // // defaultButtons.mainListJobExeBtn({hide:isShowMainButton(row,['2'])}), //
] ]
} }

85
src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue

@ -198,30 +198,37 @@ const isShowMainButton = (row,val) => {
// - // -
const butttondata = (row) => { const butttondata = (row) => {
return [ return [
defaultButtons.mainListCloseBtn({hide:isShowMainButton(row,['1','2','3','4','6'])}), // defaultButtons.mainListCloseBtn({hide:isShowMainButton(row,['1','2','3','4']),hasPermi:'wms:unplannedreceipt-request-main:close'}), //
defaultButtons.mainListReAddBtn({hide:isShowMainButton(row,['4','5'])}), // defaultButtons.mainListReAddBtn({hide:isShowMainButton(row,['5']),hasPermi:'wms:unplannedreceipt-request-main:reAdd'}), //
defaultButtons.mainListSubmitBtn({hide:isShowMainButton(row,['1'])}), // defaultButtons.mainListSubmitBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:unplannedreceipt-request-main:submit'}), //
defaultButtons.mainListTurnDownBtn({hide:isShowMainButton(row,['2'])}), // defaultButtons.mainListTurnDownBtn({hide:isShowMainButton(row,['2']),hasPermi:'wms:unplannedreceipt-request-main:refused'}), //
defaultButtons.mainListApproveBtn({hide:isShowMainButton(row,['2'])}), // defaultButtons.mainListApproveBtn({hide:isShowMainButton(row,['2']),hasPermi:'wms:unplannedreceipt-request-main:agree'}), //
defaultButtons.mainListEditBtn({hasPermi:'wms:unplannedreceipt-request-main:update'}), // defaultButtons.mainListHandleBtn({hide:isShowMainButton(row,['3']),hasPermi:'wms:unplannedreceipt-request-main:handle'}), //
defaultButtons.mainListDeleteBtn({hasPermi:'wms:unplannedreceipt-request-main:delete'}), // defaultButtons.mainListEditBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:unplannedreceipt-request-main:update'}), //
// defaultButtons.mainListDeleteBtn({hasPermi:'wms:unplannedreceipt-request-main:delete'}), //
] ]
} }
// - // -
const buttonTableClick = async (val, row) => { const buttonTableClick = async (val, row) => {
if (val == 'mainClose') { // if (val == 'mainClose') { //
console.log('列表-操作按钮事件-关闭') console.log('列表-操作按钮事件-关闭')
handleClose(row.id)
} else if (val == 'mainReAdd') { // } else if (val == 'mainReAdd') { //
console.log('列表-操作按钮事件-重新添加') console.log('列表-操作按钮事件-重新添加')
handleReAdd(row.id)
} else if (val == 'mainSubmit') { // } else if (val == 'mainSubmit') { //
console.log('列表-操作按钮事件-提交审批') console.log('列表-操作按钮事件-提交审批')
handleSubmit(row.id)
} else if (val == 'mainTurnDown') { // } else if (val == 'mainTurnDown') { //
console.log('列表-操作按钮事件-驳回') console.log('列表-操作按钮事件-驳回')
handleRefused(row.id)
} else if (val == 'mainApprove') { // } else if (val == 'mainApprove') { //
console.log('列表-操作按钮事件-审批通过') console.log('列表-操作按钮事件-审批通过')
handleAgree(row.id)
} else if (val == 'mainHandle') { //
console.log('列表-操作按钮事件-处理')
handleHandle(row.id)
} else if (val == 'edit') { // } else if (val == 'edit') { //
openForm('update', row) openForm('update', row)
} else if (val == 'delete') { // } else if (val == 'delete') { //
@ -229,6 +236,66 @@ const buttonTableClick = async (val, row) => {
} }
} }
/** 关闭按钮操作 */
const handleClose = async (id: number) => {
try {
await message.confirm(t('common.confirmColse'))
await UnplannedreceiptRequestMainApi.closeUnplannedreceiptRequestMain(id)
message.success(t('common.closeSuccess'))
await getList()
} catch {}
}
/** 重新添加按钮操作 */
const handleReAdd = async (id: number) => {
try {
await message.confirm(t('common.confirmReAdd'))
await UnplannedreceiptRequestMainApi.reAddUnplannedreceiptRequestMain(id)
message.success(t('common.reAddSuccess'))
await getList()
} catch {}
}
/** 提交按钮操作 */
const handleSubmit = async (id: number) => {
try {
await message.confirm(t('common.confirmSubmit'))
await UnplannedreceiptRequestMainApi.submitUnplannedreceiptRequestMain(id)
message.success(t('common.submitSuccess'))
await getList()
} catch {}
}
/** 审批驳回按钮操作 */
const handleRefused = async (id: number) => {
try {
await message.confirm(t('common.confirmRefused'))
await UnplannedreceiptRequestMainApi.refusedUnplannedreceiptRequestMain(id)
message.success(t('common.refusedSuccess'))
await getList()
} catch {}
}
/** 审批通过按钮操作 */
const handleAgree = async (id: number) => {
try {
await message.confirm(t('common.confirmAgree'))
await UnplannedreceiptRequestMainApi.agreeUnplannedreceiptRequestMain(id)
message.success(t('common.agreeSuccess'))
await getList()
} catch {}
}
/** 处理按钮操作 */
const handleHandle = async (id: number) => {
try {
await message.confirm(t('common.confirmHandle'))
await UnplannedreceiptRequestMainApi.handleUnplannedreceiptRequestMain(id)
message.success(t('common.handleSuccess'))
await getList()
} catch {}
}
/** 添加/修改操作 */ /** 添加/修改操作 */
const formRef = ref() const formRef = ref()
const openForm =async (type: string, row?: number) => { const openForm =async (type: string, row?: number) => {

42
src/views/wms/moveManage/inventorychange/inventorychangeRequestMain/index.vue

@ -67,13 +67,12 @@
:apiUpdate="InventorychangeRequestDetailApi.updateInventorychangeRequestDetail" :apiUpdate="InventorychangeRequestDetailApi.updateInventorychangeRequestDetail"
:apiPage="InventorychangeRequestDetailApi.getInventorychangeRequestDetailPage" :apiPage="InventorychangeRequestDetailApi.getInventorychangeRequestDetailPage"
:apiDelete="InventorychangeRequestDetailApi.deleteInventorychangeRequestDetail" :apiDelete="InventorychangeRequestDetailApi.deleteInventorychangeRequestDetail"
:Echo="Echo"
@searchTableSuccessDetail="searchTableSuccessDetail" @searchTableSuccessDetail="searchTableSuccessDetail"
/> />
<!-- 导入 --> <!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/inventorychange-request-main/import" :importTemplateData="importTemplateData" <ImportForm ref="importFormRef" url="/wms/inventorychange-request-main/import" :importTemplateData="importTemplateData"
@success="importSuccess" :updateIsDisable="true" :coverIsDisable="true" :mode="2" /> @success="importSuccess" :updateIsDisable="true" :coverIsDisable="true" :mode="2" :fromInventoryStatus= "fromInventoryStatus" :toInventoryStatus="toInventoryStatus" />
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
@ -83,7 +82,7 @@ import * as InventorychangeRequestMainApi from '@/api/wms/inventorychangeRequest
import * as InventorychangeRequestDetailApi from '@/api/wms/inventorychangeRequestDetail' import * as InventorychangeRequestDetailApi from '@/api/wms/inventorychangeRequestDetail'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
// //
defineOptions({ name: 'InventorychangeRequestMain' }) defineOptions({ name: 'InventorychangeRequestMain' })
const message = useMessage() // const message = useMessage() //
@ -94,6 +93,32 @@ const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref(InventorychangeRequestMain.allSchemas.tableColumns) const tableColumns = ref(InventorychangeRequestMain.allSchemas.tableColumns)
console.log(99 , routeName.value)
const fromInventoryStatus = ref()
const toInventoryStatus = ref()
const { tableObject, tableMethods } = useTable({
getListApi: InventorychangeRequestMainApi.getInventorychangeRequestMainPage //
})
//
/**
* OktoholdRequestMain 合格转隔离
*/
if ( routeName.value == 'OktoholdRequestMain') {
tableObject.params = {
fromInventoryStatus: 'OK'
}
fromInventoryStatus.value = 'OK'
toInventoryStatus.value = "HODxxx"
} else if ( routeName.value == 'xxxx') {
tableObject.params = {
fromInventoryStatus: 'xxx'
}
fromInventoryStatus.value = 'xxx'
toInventoryStatus.value = "xxx"
}
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val
@ -129,13 +154,6 @@ const searchTableSuccessDetail = (formField, searchField, val, formRef ) => {
}) })
} }
//
// const Echo = ['ppNumber','poLine', 'batch', 'altBatch', 'itemCode', 'itemName', 'itemDesc1', 'itemDesc2', 'projectCode', 'qty', 'uom']
const Echo = []
const { tableObject, tableMethods } = useTable({
getListApi: InventorychangeRequestMainApi.getInventorychangeRequestMainPage //
})
// //
const { getList, setSearchParams } = tableMethods const { getList, setSearchParams } = tableMethods
@ -251,7 +269,7 @@ const handleExport = async () => {
await message.exportConfirm() await message.exportConfirm()
// //
exportLoading.value = true exportLoading.value = true
const data = await InventorychangeRequestMainApi.exportInventorychangeRequestMain(setSearchParams) const data = await InventorychangeRequestMainApi.exportInventorychangeRequestMain(tableObject.params)
download.excel(data, '库存修改申请主.xlsx') download.excel(data, '库存修改申请主.xlsx')
} catch { } catch {
} finally { } finally {
@ -280,6 +298,8 @@ const handleDeleteTable = (item, index) => {
// //
const submitForm = async (formType, data) => { const submitForm = async (formType, data) => {
data.subList = tableData.value // data.subList = tableData.value //
data.fromInventoryStatus = fromInventoryStatus.value
data.toInventoryStatus = toInventoryStatus.value
try { try {
if (formType === 'create') { if (formType === 'create') {
await InventorychangeRequestMainApi.createInventorychangeRequestMain(data) await InventorychangeRequestMainApi.createInventorychangeRequestMain(data)

8
src/views/wms/purchasereceiptManage/inspect/inspectJobMain/inspectJobMain.data.ts

@ -177,8 +177,8 @@ export const InspectJobMain = useCrudSchemas(reactive<CrudSchema[]>([
}, },
}, },
{ {
label: '承接人用户名', label: '承接人',
field: 'acceptUserId', field: 'acceptUserName',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -205,8 +205,8 @@ export const InspectJobMain = useCrudSchemas(reactive<CrudSchema[]>([
}, },
}, },
{ {
label: '完成人用户名', label: '完成人',
field: 'completeUserId', field: 'completeUserName',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150

4
src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnJobMain/purchasereturnJobMain.data.ts

@ -271,7 +271,7 @@ export const PurchasereturnJobMain = useCrudSchemas(reactive<CrudSchema[]>([
}, },
{ {
label: '承接人', label: '承接人',
field: 'acceptUserId', field: 'acceptUserName',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -299,7 +299,7 @@ export const PurchasereturnJobMain = useCrudSchemas(reactive<CrudSchema[]>([
}, },
{ {
label: '完成人', label: '完成人',
field: 'completeUserId', field: 'completeUserName',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150

8
src/views/wms/purchasereceiptManage/putaway/putawayJobMain/putawayJobMain.data.ts

@ -170,8 +170,8 @@ export const PutawayJobMain = useCrudSchemas(reactive<CrudSchema[]>([
}, },
}, },
{ {
label: '承接人用户名', label: '承接人',
field: 'acceptUserId', field: 'acceptUserName',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -198,8 +198,8 @@ export const PutawayJobMain = useCrudSchemas(reactive<CrudSchema[]>([
}, },
}, },
{ {
label: '完成人用户名', label: '完成人',
field: 'completeUserId', field: 'completeUserName',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150

6
src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/index.vue

@ -172,9 +172,9 @@
defaultButtons.mainListPurchasePlanOpeBtn({ hide: isShowMainButton(row, ['5']) }), // defaultButtons.mainListPurchasePlanOpeBtn({ hide: isShowMainButton(row, ['5']) }), //
defaultButtons.mainListPurchasePlanCloBtn({ hide: isShowMainButton(row, ['1']) }), // defaultButtons.mainListPurchasePlanCloBtn({ hide: isShowMainButton(row, ['1']) }), //
defaultButtons.mainListPurchasePlanPubBtn({ hide: isShowMainButton(row, ['1']) }), // defaultButtons.mainListPurchasePlanPubBtn({ hide: isShowMainButton(row, ['1']) }), //
defaultButtons.mainListPurchasePlanAccBtn({ hide: isShowMainButton(row, ['6']) }), // defaultButtons.mainListPurchasePlanAccBtn({ hide: isShowMainButton(row, ['3']) }), //
defaultButtons.mainListPurchasePlanRejBtn({ hide: isShowMainButton(row, ['6']) }), // defaultButtons.mainListPurchasePlanRejBtn({ hide: isShowMainButton(row, ['3']) }), //
defaultButtons.mainListPurchasePlanWitBtn({ hide: isShowMainButton(row, ['6']) }), // defaultButtons.mainListPurchasePlanWitBtn({ hide: isShowMainButton(row, ['3']) }), //
defaultButtons.mainListEditBtn({ hide: isShowMainButton(row, ['1']), hasPermi: 'wms:purchase-plan-main:update' }), // defaultButtons.mainListEditBtn({ hide: isShowMainButton(row, ['1']), hasPermi: 'wms:purchase-plan-main:update' }), //
// defaultButtons.mainListDeleteBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchase-plan-main:delete'}), // // defaultButtons.mainListDeleteBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchase-plan-main:delete'}), //
] ]

2
src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/index.vue

@ -121,7 +121,7 @@ const buttonBaseClick = (val, item) => {
// - // -
const butttondata = (row) => { const butttondata = (row) => {
return [ return [
defaultButtons.mainListGenerateApplicationBtn(null), // // defaultButtons.mainListGenerateApplicationBtn(null), //
] ]
} }

Loading…
Cancel
Save