Browse Source

生产退料隔离退料添加导入功能

master_hella_20240701
陈薪名 9 months ago
parent
commit
e4d06464fc
  1. 2
      src/api/wms/productionreturnRequestMainNo/index.ts
  2. 26
      src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue
  3. 26
      src/views/wms/issueManage/productionreturn/productionreturnRequestMainNo/index.vue

2
src/api/wms/productionreturnRequestMainNo/index.ts

@ -70,7 +70,7 @@ export const exportProductionreturnRequestMain = async (params) => {
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/productionreturn-request-main/get-import-template' })
return request.download({ url: '/wms/productionreturn-request-main/get-import-template-hold' })
}
// 关闭

26
src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue

@ -85,6 +85,11 @@
@searchTableSuccess="searchTableSuccess"
@submitForm="submitFormLabel"
/>
<!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/productionreturn-request-main/import" :importTemplateData="importTemplateData"
@success="importSuccess" :updateIsDisable="true" :coverIsDisable="true" :mode="2" />
</template>
<script setup lang="ts">
@ -232,6 +237,7 @@ const { getList, setSearchParams } = tableMethods
//
const HeadButttondata = [
defaultButtons.defaultAddBtn({hasPermi:'wms:productionreturn-request-main:create'}), //
defaultButtons.defaultImportBtn({hasPermi:'wms:productionreturn-request-main:import'}), //
defaultButtons.defaultExportBtn({hasPermi:'wms:productionreturn-request-main:export'}), //
defaultButtons.defaultFreshBtn(null), //
defaultButtons.defaultFilterBtn(null), //
@ -243,6 +249,8 @@ const HeadButttondata = [
const buttonBaseClick = (val, item) => {
if (val == 'add') { //
openForm('create')
} else if (val == 'import') { //
handleImport()
} else if (val == 'export') { //
handleExport()
} else if (val == 'refresh') { //
@ -625,6 +633,23 @@ const handlePoint = async (row) => {
}
}
/** 导入 */
const importFormRef = ref()
const handleImport = () => {
importFormRef.value.open()
}
//
const importTemplateData = reactive({
templateUrl: '',
templateTitle: '生产退料导入模版.xlsx'
})
//
const importSuccess = () => {
getList()
}
//
const searchFormClick = (searchData) => {
tableObject.params = {
@ -637,5 +662,6 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
getList()
importTemplateData.templateUrl = await ProductionreturnRequestMainApi.importTemplate()
})
</script>

26
src/views/wms/issueManage/productionreturn/productionreturnRequestMainNo/index.vue

@ -84,6 +84,11 @@
@searchTableSuccess="searchTableSuccess"
@submitForm="submitFormLabel"
/>
<!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/productionreturn-request-main/importNO" :importTemplateData="importTemplateData"
@success="importSuccess" :updateIsDisable="true" :coverIsDisable="true" :mode="2" />
</template>
<script setup lang="ts">
@ -237,6 +242,7 @@ const { getList, setSearchParams } = tableMethods
//
const HeadButttondata = [
defaultButtons.defaultAddBtn({hasPermi:'wms:productionreturn-request-main:create'}), //
defaultButtons.defaultImportBtn({hasPermi:'wms:productionreturn-request-main:import'}), //
defaultButtons.defaultExportBtn({hasPermi:'wms:productionreturn-request-main:export'}), //
defaultButtons.defaultFreshBtn(null), //
defaultButtons.defaultFilterBtn(null), //
@ -248,6 +254,8 @@ const HeadButttondata = [
const buttonBaseClick = (val, item) => {
if (val == 'add') { //
openForm('create')
} else if (val == 'import') { //
handleImport()
} else if (val == 'export') { //
handleExport()
} else if (val == 'refresh') { //
@ -618,6 +626,23 @@ const handlePoint = async (row) => {
}
}
/** 导入 */
const importFormRef = ref()
const handleImport = () => {
importFormRef.value.open()
}
//
const importTemplateData = reactive({
templateUrl: '',
templateTitle: '隔离退料导入模版.xlsx'
})
//
const importSuccess = () => {
getList()
}
//
const searchFormClick = (searchData) => {
tableObject.params = {
@ -630,5 +655,6 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
getList()
importTemplateData.templateUrl = await ProductionreturnRequestMainNoApi.importTemplate()
})
</script>

Loading…
Cancel
Save