Browse Source

备件领用修改

master_hella_20240701
zhaoxuebing 7 months ago
parent
commit
19d8c9da2d
  1. 47
      src/api/wms/unplannedissueRequestMain/index.ts
  2. 6
      src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue

47
src/api/wms/unplannedissueRequestMain/index.ts

@ -40,26 +40,6 @@ export const getUnplannedissueRequestMainPage = async (params) => {
}
}
// 查询计划外出库申请主列表
export const getUnplannedissueRequestMainPageSpare = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
const dataTypeCondition = {
'column':'dataType',
'action':'==',
'value':'2'
}
data.filters.push(dataTypeCondition)
return await request.post({ url: '/wms/unplannedissue-request-main/senior', data })
} else {
params.dataType='2'
return await request.get({ url: `/wms/unplannedissue-request-main/page`, params })
}
}
// 查询计划外出库申请主详情
export const getUnplannedissueRequestMain = async (id: number) => {
return await request.get({ url: `/wms/unplannedissue-request-main/get?id=` + id })
@ -95,6 +75,8 @@ export const importTemplate = () => {
return request.download({ url: '/wms/unplannedissue-request-main/get-import-template' })
}
// 关闭-计划外出库申请
export const closeUnplannedissueRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedissue-request-main/close?id=` + id })
@ -124,3 +106,28 @@ export const agreeUnplannedissueRequestMain = async (id) => {
export const handleUnplannedissueRequestMain = async (id) => {
return await request.put({ url: `/wms/unplannedissue-request-main/handle?id=` + id })
}
// 查询备件领用主列表
export const getUnplannedissueRequestMainPageSpare = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
const dataTypeCondition = {
'column':'dataType',
'action':'==',
'value':'2'
}
data.filters.push(dataTypeCondition)
return await request.post({ url: '/wms/unplannedissue-request-main/senior', data })
} else {
params.dataType='2'
return await request.get({ url: `/wms/unplannedissue-request-main/page`, params })
}
}
// 备件领用下载用户导入模板
export const spareImportTemplate = () => {
return request.download({ url: '/wms/unplannedissue-request-main/get-import-template-spare' })
}

6
src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue

@ -75,7 +75,7 @@
/>
<!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/unplannedissue-request-main/import" :importTemplateData="importTemplateData"
<ImportForm ref="importFormRef" url="/wms/unplannedissue-request-main/importSpare" :importTemplateData="importTemplateData"
@success="importSuccess" :updateIsDisable="true" :coverIsDisable="true" :mode="2" />
</template>
@ -436,7 +436,7 @@ const handleImport = () => {
//
const importTemplateData = reactive({
templateUrl: '',
templateTitle: '计划外出库申请主导入模版.xlsx'
templateTitle: '备件领用申请导入模版.xlsx'
})
//
@ -456,6 +456,6 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
getList()
importTemplateData.templateUrl = await UnplannedissueRequestMainApi.importTemplate()
importTemplateData.templateUrl = await UnplannedissueRequestMainApi.spareImportTemplate()
})
</script>

Loading…
Cancel
Save