Browse Source

解决eam备件报错

master_hella_20240701
songguoqiang 5 months ago
parent
commit
4fe135f4ed
  1. 54
      src/views/eam/applicationRecord/applicationRecordMain.data.ts
  2. 10
      src/views/eam/applicationRecord/index.vue
  3. 4
      src/views/eam/itemApplyMain/index.vue
  4. 160
      src/views/eam/itemApplyMain/itemApplyMain.data.ts

54
src/views/eam/applicationRecord/applicationRecordMain.data.ts

@ -1,8 +1,8 @@
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
import { dateFormatter } from '@/utils/formatTime' import { dateFormatter } from '@/utils/formatTime'
import { ItemAccounts } from '@/views/eam/item/itemAccounts/itemAccounts.data' import { ItemAccounts } from '@/views/eam/itemAccounts/itemAccounts.data'
import * as ItemAccountsApi from '@/api/eam/item/itemAccounts' import * as ItemAccountsApi from '@/api/eam/itemAccounts'
import * as DeviceMoldItemsApi from '@/api/eam/basic/deviceMaintenance' //import * as DeviceMoldItemsApi from '@/api/eam/basic/deviceMaintenance'
import { validateHanset, validateEmail } from '@/utils/validator' import { validateHanset, validateEmail } from '@/utils/validator'
const { t } = useI18n() // 国际化 const { t } = useI18n() // 国际化
@ -154,30 +154,30 @@ export const ApplicationRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([
}, },
{ // {
label: '设备/模具编号', // label: '设备/模具编号',
field: 'deviceNumber', // field: 'deviceNumber',
sort: 'custom', // sort: 'custom',
isSearch: true, // isSearch: true,
tableForm: { // tableForm: {
isInpuFocusShow: true, // isInpuFocusShow: true,
searchListPlaceholder: '请选择单号', // searchListPlaceholder: '请选择单号',
searchField: 'number', // searchField: 'number',
searchTitle: '单号信息', // searchTitle: '单号信息',
searchAllSchemas: DeviceMOLD.allSchemas, // 查询弹窗所需类 // searchAllSchemas: DeviceMOLD.allSchemas, // 查询弹窗所需类
searchPage: DeviceMoldItemsApi.getNumber, // 查询弹窗所需分页方法 // searchPage: DeviceMoldItemsApi.getNumber, // 查询弹窗所需分页方法
searchCondition: [{ // searchCondition: [{
key: 'available', // key: 'available',
value: "TRUE", // value: "TRUE",
isMainValue: false // isMainValue: false
}, { // }, {
key: 'type', // key: 'type',
value: "type", // value: "type",
isMainValue: true // isMainValue: true
} // }
] // ]
}, // },
}, // },
{ {
label: '申领数量', label: '申领数量',
field: 'qty', field: 'qty',

10
src/views/eam/applicationRecord/index.vue

@ -47,13 +47,13 @@
:isShowAddBtn="false" :isShowAddBtn="false"
:detailButtonIsShow="true" /> :detailButtonIsShow="true" />
<!-- 审批详情 --> <!-- 审批详情 -->
<approveDetail ref="detailRef1" :isBasic="false" :allSchemas="ApplicationRecordMain.allSchemas" <!-- <approveDetail ref="detailRef1" :isBasic="false" :allSchemas="ApplicationRecordMain.allSchemas"
:detailAllSchemas="ApplicationRecordDetail.allSchemas" :detailAllSchemasRules="ApplicationRecordDetailRules" :detailAllSchemas="ApplicationRecordDetail.allSchemas" :detailAllSchemasRules="ApplicationRecordDetailRules"
:apiAgree="ApplicationRecordMainApi.agreeApplicationRecordMain" :apiAgree="ApplicationRecordMainApi.agreeApplicationRecordMain"
:apiDisAgree="ApplicationRecordMainApi.disAgreeApplicationRecordMain" :apiDisAgree="ApplicationRecordMainApi.disAgreeApplicationRecordMain"
:apiPage="ApplicationRecordDetailApi.getApplicationRecordDetailPage" :apiPage="ApplicationRecordDetailApi.getApplicationRecordDetailPage"
@searchTableSuccessDetail="searchTableSuccessDetail" @searchTableSuccessDetail="searchTableSuccessDetail"
@agree="getList"/> @agree="getList"/> -->
<!-- 导入 --> <!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/purchase-main/import" :importTemplateData="importTemplateData" <ImportForm ref="importFormRef" url="/wms/purchase-main/import" :importTemplateData="importTemplateData"
@success="importSuccess" :isShowOut="true" :updateIsDisable="true" :coverIsDisable="true" :mode="2" /> @success="importSuccess" :isShowOut="true" :updateIsDisable="true" :coverIsDisable="true" :mode="2" />
@ -62,12 +62,12 @@
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import { ApplicationRecordMain, ApplicationRecordMainRules, ApplicationRecordDetail, ApplicationRecordDetailRules } from './applicationRecordMain.data' import { ApplicationRecordMain, ApplicationRecordMainRules, ApplicationRecordDetail, ApplicationRecordDetailRules } from './applicationRecordMain.data'
import * as ApplicationRecordMainApi from '@/api/eam/item/applicationRecordMain' import * as ApplicationRecordMainApi from '@/api/eam/applicationRecordMain'
import * as ApplicationRecordDetailApi from '@/api/eam/item/applicationRecordDetail' import * as ApplicationRecordDetailApi from '@/api/eam/applicationRecordDetail'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
import TableHead from '@/components/TableHead/src/TableHead.vue' import TableHead from '@/components/TableHead/src/TableHead.vue'
import ImportForm from '@/components/ImportForm/src/ImportForm.vue' import ImportForm from '@/components/ImportForm/src/ImportForm.vue'
import approveDetail from '@/components/Detail/src/approveDetail.vue' //import approveDetail from '@/components/Detail/src/approveDetail.vue'
// //
defineOptions({ name: 'ApplicationRecord' }) defineOptions({ name: 'ApplicationRecord' })

4
src/views/eam/itemApplyMain/index.vue

@ -49,8 +49,8 @@
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import { ItemApplyMain, ItemApplyMainRules, ItemApplyDetail, ItemApplyDetailRules } from './itemApplyMain.data' import { ItemApplyMain, ItemApplyMainRules, ItemApplyDetail, ItemApplyDetailRules } from './itemApplyMain.data'
import * as ItemApplyMainApi from '@/api/eam/item/itemApplyMain' import * as ItemApplyMainApi from '@/api/eam/itemApplyMain'
import * as ItemApplyDetailApi from '@/api/eam/item/itemApplyDetail' import * as ItemApplyDetailApi from '@/api/eam/itemApplyDetail'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
import TableHead from '@/components/TableHead/src/TableHead.vue' import TableHead from '@/components/TableHead/src/TableHead.vue'
import ImportForm from '@/components/ImportForm/src/ImportForm.vue' import ImportForm from '@/components/ImportForm/src/ImportForm.vue'

160
src/views/eam/itemApplyMain/itemApplyMain.data.ts

@ -1,8 +1,8 @@
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
import { dateFormatter } from '@/utils/formatTime' import { dateFormatter } from '@/utils/formatTime'
import { ItemAccounts } from '@/views/eam/item/itemAccounts/itemAccounts.data' import { ItemAccounts } from '@/views/eam/itemAccounts/itemAccounts.data'
import * as ItemAccountsApi from '@/api/eam/item/itemAccounts' import * as ItemAccountsApi from '@/api/eam/itemAccounts'
import * as DeviceMoldItemsApi from '@/api/eam/basic/deviceMaintenance' //import * as DeviceMoldItemsApi from '@/api/eam/basic/deviceMaintenance'
import { validateHanset, validateEmail } from '@/utils/validator' import { validateHanset, validateEmail } from '@/utils/validator'
const { t } = useI18n() // 国际化 const { t } = useI18n() // 国际化
@ -43,23 +43,23 @@ export const ItemApplyMain = useCrudSchemas(reactive<CrudSchema[]>([
isSearch: false, isSearch: false,
}, },
{ // {
label: '状态', // label: '状态',
field: 'status', // field: 'status',
sort: 'custom', // sort: 'custom',
dictType: DICT_TYPE.ITEM_APPLY_STATUS, // dictType: DICT_TYPE.ITEM_APPLY_STATUS,
dictClass: 'string', // dictClass: 'string',
isSearch: true, // isSearch: true,
isTable: true, // isTable: true,
isForm: false, // isForm: false,
table: { // table: {
width: 150 // width: 150
}, // },
tableForm: { // tableForm: {
type: 'Select', // type: 'Select',
disabled: false // disabled: false
} // }
}, // },
{ {
label: '描述', label: '描述',
field: 'name', field: 'name',
@ -156,66 +156,66 @@ export const ItemApplyDetail = useCrudSchemas(reactive<CrudSchema[]>([
} }
} }
}, },
{ // {
label: '类型', // label: '类型',
field: 'type', // field: 'type',
sort: 'custom', // sort: 'custom',
dictType: DICT_TYPE.DEVICE_MOLD_TYPE, // dictType: DICT_TYPE.DEVICE_MOLD_TYPE,
dictClass: 'string', // dictClass: 'string',
isSearch: true, // isSearch: true,
isTable: true, // isTable: true,
table: { // table: {
width: 150 // width: 150
}, // },
tableForm: { // tableForm: {
type: 'Select', // type: 'Select',
disabled: false // disabled: false
} // }
}, // },
{ // {
label: '设备/模具编号', // label: '设备/模具编号',
field: 'deviceNumber', // field: 'deviceNumber',
sort: 'custom', // sort: 'custom',
isSearch: true, // isSearch: true,
tableForm: { // tableForm: {
isInpuFocusShow: true, // isInpuFocusShow: true,
searchListPlaceholder: '请选择单号', // searchListPlaceholder: '请选择单号',
searchField: 'number', // searchField: 'number',
searchTitle: '单号信息', // searchTitle: '单号信息',
searchAllSchemas: DeviceMOLD.allSchemas, // 查询弹窗所需类 // searchAllSchemas: DeviceMOLD.allSchemas, // 查询弹窗所需类
searchPage: DeviceMoldItemsApi.getNumber, // 查询弹窗所需分页方法 // searchPage: DeviceMoldItemsApi.getNumber, // 查询弹窗所需分页方法
searchCondition: [{ // searchCondition: [{
key: 'available', // key: 'available',
value: "TRUE", // value: "TRUE",
isMainValue: false // isMainValue: false
}, { // }, {
key: 'type', // key: 'type',
value: "type", // value: "type",
isMainValue: true // isMainValue: true
} // }
] // ]
}, // },
form: { // form: {
// labelMessage: '信息提示说明!!!', // // labelMessage: '信息提示说明!!!',
componentProps: { // componentProps: {
isSearchList: true, // isSearchList: true,
searchListPlaceholder: '请选择单号', // searchListPlaceholder: '请选择单号',
searchField: 'number', // searchField: 'number',
searchTitle: '单号信息', // searchTitle: '单号信息',
searchAllSchemas: DeviceMOLD.allSchemas, // 查询弹窗所需类 // searchAllSchemas: DeviceMOLD.allSchemas, // 查询弹窗所需类
searchPage: DeviceMoldItemsApi.getNumber, // 查询弹窗所需分页方法 // searchPage: DeviceMoldItemsApi.getNumber, // 查询弹窗所需分页方法
searchCondition: [{ // searchCondition: [{
key: 'available', // key: 'available',
value: "TRUE", // value: "TRUE",
isMainValue: false // isMainValue: false
}, { // }, {
key: 'type', // key: 'type',
value: "type", // value: "type",
isMainValue: true // isMainValue: true
}] // }]
} // }
} // }
}, // },
{ {
label: '申领数量', label: '申领数量',
field: 'qty', field: 'qty',

Loading…
Cancel
Save