diff --git a/src/api/eam/equipmentRepairJobDetail/index.ts b/src/api/eam/equipmentRepairJobDetail/index.ts new file mode 100644 index 000000000..efe6bdaa8 --- /dev/null +++ b/src/api/eam/equipmentRepairJobDetail/index.ts @@ -0,0 +1,59 @@ +import request from '@/config/axios' + +export interface EquipmentRepairJobDetailVO { + id: number + number: string + masterId: number + describing: string + faultCause: string + workOut: string + maintenances: string + departmentCode: string + remark: string + siteId: string + available: string + deletionTime: Date + deleterId: byte[] + concurrencyStamp: number +} + +// 查询维修工单子列表 +export const getEquipmentRepairJobDetailPage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/eam/equipment-repair-job-detail/senior', data }) + } else { + return await request.get({ url: `/eam/equipment-repair-job-detail/page`, params }) + } +} + +// 查询维修工单子详情 +export const getEquipmentRepairJobDetail = async (id: number) => { + return await request.get({ url: `/eam/equipment-repair-job-detail/get?id=` + id }) +} + +// 新增维修工单子 +export const createEquipmentRepairJobDetail = async (data: EquipmentRepairJobDetailVO) => { + return await request.post({ url: `/eam/equipment-repair-job-detail/create`, data }) +} + +// 修改维修工单子 +export const updateEquipmentRepairJobDetail = async (data: EquipmentRepairJobDetailVO) => { + return await request.put({ url: `/eam/equipment-repair-job-detail/update`, data }) +} + +// 删除维修工单子 +export const deleteEquipmentRepairJobDetail = async (id: number) => { + return await request.delete({ url: `/eam/equipment-repair-job-detail/delete?id=` + id }) +} + +// 导出维修工单子 Excel +export const exportEquipmentRepairJobDetail = async (params) => { + return await request.download({ url: `/eam/equipment-repair-job-detail/export-excel`, params }) +} + +// 下载用户导入模板 +export const importTemplate = () => { + return request.download({ url: '/eam/equipment-repair-job-detail/get-import-template' }) +} \ No newline at end of file diff --git a/src/api/eam/equipmentRepairJobMain/index.ts b/src/api/eam/equipmentRepairJobMain/index.ts new file mode 100644 index 000000000..471f98905 --- /dev/null +++ b/src/api/eam/equipmentRepairJobMain/index.ts @@ -0,0 +1,93 @@ +import request from '@/config/axios' +import {EquipmentReportRepairRequestVO} from "@/api/eam/equipmentReportRepairRequest"; + +export interface EquipmentRepairJobMainVO { + id: number + number: string + type: string + repairNumber: string + sources: string + maintenanceDesc: string + urgency: string + level: string + equipmentCode: string + shutDown: boolean + startTime: Date + endTime: Date + totalMinutes: number + verifyer: number + verifyContent: string + verifyTime: Date + maintenancer: number + maintenancePhone: string + completeResult: string + completionTime: Date + maintenanceTime: Date + repairTime: Date + repairer: number + faultType: string + status: string + autoOrder: string + autoPerform: string + autoVerify: string + directCreateRecord: string + classType: string + factoryAreaCode: string + workshopCode: string + lineCode: string + processCode: string + workstationCode: string + departmentCode: string + remark: string + siteId: string + available: string + deletionTime: Date + deleterId: byte[] + concurrencyStamp: number +} + +// 查询维修工单主列表 +export const getEquipmentRepairJobMainPage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/eam/equipment-repair-job-main/senior', data }) + } else { + return await request.get({ url: `/eam/equipment-repair-job-main/page`, params }) + } +} + +// 查询维修工单主详情 +export const getEquipmentRepairJobMain = async (id: number) => { + return await request.get({ url: `/eam/equipment-repair-job-main/get?id=` + id }) +} + +// 新增维修工单主 +export const createEquipmentRepairJobMain = async (data: EquipmentRepairJobMainVO) => { + return await request.post({ url: `/eam/equipment-repair-job-main/create`, data }) +} + +// 修改维修工单主 +export const updateEquipmentRepairJobMain = async (data: EquipmentRepairJobMainVO) => { + return await request.put({ url: `/eam/equipment-repair-job-main/update`, data }) +} + +// 删除维修工单主 +export const deleteEquipmentRepairJobMain = async (id: number) => { + return await request.delete({ url: `/eam/equipment-repair-job-main/delete?id=` + id }) +} + +// 导出维修工单主 Excel +export const exportEquipmentRepairJobMain = async (params) => { + return await request.download({ url: `/eam/equipment-repair-job-main/export-excel`, params }) +} + +// 下载用户导入模板 +export const importTemplate = () => { + return request.download({ url: '/eam/equipment-repair-job-main/get-import-template' }) +} + +// 修改维修工单状态 +export const updateEquipmentRepairOrder = async (data: EquipmentRepairJobMainVO) => { + return await request.post({ url: `/eam/equipment-repair-job-main/updateOrder`, data }) +} diff --git a/src/components/SearchTable/src/SearchTable.vue b/src/components/SearchTable/src/SearchTable.vue index 084a68806..e3790bca0 100644 --- a/src/components/SearchTable/src/SearchTable.vue +++ b/src/components/SearchTable/src/SearchTable.vue @@ -10,6 +10,7 @@ :HeadButttondata="HeadButttondata" :routeName="routeName" @searchFormClick="searchFormClick" + @buttonBaseClick="buttonBaseClick" :allSchemas="allSchemasRef" /> @@ -26,6 +27,7 @@ v-model:sort="tableObjectRef.sort" :searchTableSelectionsList="searchTableSelectionsList" :selection="true" + :selectionTotal="multipleBol" :reserveSelection="true" row-key="id" /> @@ -53,10 +55,18 @@ routeName.value = route.name const searchDialogVisible = ref(false) // 弹窗的是否展示 const dialogTitle = ref('') // 弹窗的标题 const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用 +const multipleBol = ref(false) + // 列表头部按钮 -const HeadButttondata = ref([ +const HeadButttondata = ref(multipleBol.value? +[ + defaultButtons.defaultWhenPageBtn(null), // 选择当页 + defaultButtons.defaultUnselectPageBtn(null), // 反选当页 + defaultButtons.defaultDeselectAllBtn(null), // 取消全选 defaultButtons.defaultFilterBtn(null), // 筛选 +]:[ + defaultButtons.defaultFilterBtn(null) // 筛选 ]) /** 打开弹窗 */ @@ -71,28 +81,39 @@ const searchFieldRef = ref() const typeRef = ref() const rowRef = ref() const allSchemasRef = ref() -const multipleBol = ref(false) const searchConditionRef = ref() const searchTableSelectionsList = ref()//表格弹窗回显的列表 const openData = (titleName: any, tableObject:any ,allSchemas: any,multiple: any) => { dialogWidth.value = '80%' - HeadButttondata.value = [ + multipleBol.value = multiple + HeadButttondata.value = multiple?[ + defaultButtons.defaultWhenPageBtn(null), // 选择当页 + defaultButtons.defaultUnselectPageBtn(null), // 反选当页 + defaultButtons.defaultDeselectAllBtn(null), // 取消全选 + defaultButtons.defaultFilterBtn(null), // 筛选 + ]:[ defaultButtons.defaultFilterBtn(null), // 筛选 ] dialogTitle.value = t(`ts.${titleName}`).replace('ts.','') tableObjectRef.value = tableObject searchDialogVisible.value = true - multipleBol.value = multiple allSchemasRef.value = allSchemas searchSchema.value = allSchemas.searchSchema tableColumns.value = allSchemas.tableColumns } const open = (titleName: any, allSchemas: any,getApiPage: any, formField: any, searchField: any,multiple: any, type: any, row: any, searchCondition:any , isCountRequestRe:any,isConcatDetailSchemas=false,detailSchemas: any, searchTableSelections:any) => { dialogWidth.value = '80%' - HeadButttondata.value = [ + multipleBol.value = multiple + HeadButttondata.value = multiple?[ + defaultButtons.defaultWhenPageBtn(null), // 选择当页 + defaultButtons.defaultUnselectPageBtn(null), // 反选当页 + defaultButtons.defaultDeselectAllBtn(null), // 取消全选 defaultButtons.defaultFilterBtn(null), // 筛选 - ] + ]: + [ + defaultButtons.defaultFilterBtn(null), // 筛选 + ] searchDialogVisible.value = true formFieldRef.value = formField searchFieldRef.value = searchField @@ -108,7 +129,6 @@ const open = (titleName: any, allSchemas: any,getApiPage: any, formField: any, s getPage.value = getApiPage typeRef.value = type rowRef.value = row - multipleBol.value = multiple // dialogTitle.value = t('action.' + type) dialogTitle.value = t(`ts.${titleName}`).replace('ts.','') searchTableSelectionsList.value = searchTableSelections @@ -175,6 +195,20 @@ const searchFormClick = (searchData) => { } getListRef.value() // 刷新当前列表 } +const buttonBaseClick = (val, item) => { + // 设置按钮 + if (val == 'DeselectAll') { + // 取消全选 + searchTableRef.value.clearSelection() + } else if (val == 'UnselectPage') { + // 反选当页 + searchTableRef.value.togglePageSelection() + } else if (val == 'WhenPage') { + // 选择当页 + searchTableRef.value.toggleAllSelection(true) + } +} + defineExpose({ open,openData,hiddenFilterButton ,changeDialogWidth}) // 提供 open 方法,用于打开弹窗 diff --git a/src/components/Table/src/Table.vue b/src/components/Table/src/Table.vue index 811321e7d..493c9f35e 100644 --- a/src/components/Table/src/Table.vue +++ b/src/components/Table/src/Table.vue @@ -21,6 +21,8 @@ export default defineComponent({ currentPage: propTypes.number.def(1), // 是否多选 selection: propTypes.bool.def(false), + // 是否显示多选数量 + selectionTotal: propTypes.bool.def(false), // 是否所有的超出隐藏,优先级低于schema中的showOverflowTooltip, showOverflowTooltip: propTypes.bool.def(true), // 表头 @@ -115,12 +117,36 @@ export default defineComponent({ const selections = ref([]) const sortRef = ref() + // 选中某行 const selectRow = ()=>{ emit('getSelectionRows', currentPageRef.value,elTableRef.value?.getSelectionRows()) } - const selectAll = (val)=>{ + //全选回调 + const selectAll = ()=>{ emit('getSelectionRows', currentPageRef.value,elTableRef.value?.getSelectionRows()) } + //反选 + const togglePageSelection = ()=>{ + unref(getProps).data.forEach(row=>{ + elTableRef.value!.toggleRowSelection(row) + }) + } + // 切换全选/不全选 + const toggleAllSelection = (isAll)=>{ + if(isAll){ + //全选 + if(elTableRef.value?.getSelectionRows().length{ + console.log('clearSelection') + elTableRef.value!.clearSelection() + } + const selectionChange = (selection: Recordable[]) => { selections.value = selection } @@ -134,7 +160,11 @@ export default defineComponent({ setProps, setColumn, selections, - toggleRowSelection + toggleRowSelection, + selectAll, + toggleAllSelection, + togglePageSelection, + clearSelection }) const pagination = computed(() => { @@ -358,13 +388,15 @@ export default defineComponent({ append: () => getSlot(slots, 'append') }} - + {unref(getProps).selectionTotal ? ( +
已选{selections.value.length}条数据
+ ):undefined} {unref(getProps).pagination ? ( // update by 芋艿:保持和 Pagination 组件一致 ) : undefined} diff --git a/src/layout/components/Menu/src/components/useRenderMenuTitle.tsx b/src/layout/components/Menu/src/components/useRenderMenuTitle.tsx index 87bcecb8e..cdeb35d32 100644 --- a/src/layout/components/Menu/src/components/useRenderMenuTitle.tsx +++ b/src/layout/components/Menu/src/components/useRenderMenuTitle.tsx @@ -9,7 +9,8 @@ export const useRenderMenuTitle = () => { return icon ? ( <> - {t(`ts.${title}` as string).replace('ts.','')} + {/* ellipsis */} + {t(`ts.${title}` as string).replace('ts.','')} ) : ( {t(`ts.${title}` as string).replace('ts.','')} diff --git a/src/locales/en-US.ts b/src/locales/en-US.ts index 49b7ca904..d24ed744a 100644 --- a/src/locales/en-US.ts +++ b/src/locales/en-US.ts @@ -864,6 +864,9 @@ export default { 导出:'Export', 刷新:'Refresh', 筛选:'Filter', + 选择当页:'As Page', + 反选当页:'Unselect Page', + 取消全选:'Deselect All', 设置:'Settings', 确定:'Confirm', '确 定':'Confirm', diff --git a/src/locales/zh-CN.ts b/src/locales/zh-CN.ts index b7cf05325..f42aae706 100644 --- a/src/locales/zh-CN.ts +++ b/src/locales/zh-CN.ts @@ -864,6 +864,9 @@ export default { 导出:'导出', 刷新:'刷新', 筛选:'筛选', + 选择当页:'选择当页', + 反选当页:'反选当页', + 取消全选:'取消全选', 设置:'设置', 确定:'确定', '确 定':'确 定', diff --git a/src/utils/dict.ts b/src/utils/dict.ts index bee45f6c3..67b6c1bc0 100644 --- a/src/utils/dict.ts +++ b/src/utils/dict.ts @@ -356,6 +356,10 @@ export enum DICT_TYPE { MAINTENANCE_CYCLE ='maintenance_cycle', // 保养周期 EAM_ORDER_STATUS = 'eam_order_status',// 保养工单状态 EAM_PLAN_STATUS = 'eam_plan_status', // 保养计划状态 - EAM_REPAIR_STATUS = 'eam_repair_status', // 报修状态 + EAM_REPAIR_REPORT_STATUS = 'eam_repair_report_status', // 报修状态 + EAM_MAINTENANCE_SOURCES = 'eam_maintenance_sources', // 维保数据来源 + EAM_MAINTENANCE_URGENCY = 'eam_maintenance_urgency', // 维保紧急程度 + EAM_MAINTENANCE_LEVEL = 'eam_maintenance_level', // 维保维修级别 + EAM_REPAIR_STATUS = 'eam_repair_status', // 维修状态 OFF_BACK_STATUS = 'off_back_status' } diff --git a/src/utils/disposition/defaultButtons.ts b/src/utils/disposition/defaultButtons.ts index a38217b56..1bf11445b 100644 --- a/src/utils/disposition/defaultButtons.ts +++ b/src/utils/disposition/defaultButtons.ts @@ -159,7 +159,45 @@ export function defaultSearchResetBtn(option:any) { hasPermi: '' }) } - +// 选择当页 +export function defaultWhenPageBtn(option:any) { + return __defaultBtnOption(option,{ + label: t(`ts.选择当页`).replace('ts.', ''), + name: 'WhenPage', + hide: false, + type: 'primary', + color: '', + float:'right', + link: false, // 文本展现按钮 + hasPermi: '' + }) +} +// 反选当页 +export function defaultUnselectPageBtn(option:any) { + return __defaultBtnOption(option,{ + label: t(`ts.反选当页`).replace('ts.', ''), + name: 'UnselectPage', + hide: false, + type: 'primary', + color: '', + float:'right', + link: false, // 文本展现按钮 + hasPermi: '' + }) +} +// 取消全选 +export function defaultDeselectAllBtn(option:any) { + return __defaultBtnOption(option,{ + label: t(`ts.取消全选`).replace('ts.', ''), + name: 'DeselectAll', + hide: false, + type: 'primary', + color: '', + float:'right', + link: false, // 文本展现按钮 + hasPermi: '' + }) +} // form表单-保存按钮 export function formSaveBtn(option:any) { return __defaultBtnOption(option,{ diff --git a/src/views/eam/basicFaultCause/basicFaultCause.data.ts b/src/views/eam/basicFaultCause/basicFaultCause.data.ts index 3dc367434..b2861cce7 100644 --- a/src/views/eam/basicFaultCause/basicFaultCause.data.ts +++ b/src/views/eam/basicFaultCause/basicFaultCause.data.ts @@ -31,7 +31,7 @@ export const BasicFaultCause = useCrudSchemas(reactive([ }, }, { - label: '设备编码', + label: '编码', field: 'code', sort: 'custom', isSearch: true, diff --git a/src/views/eam/basicFaultType/basicFaultType.data.ts b/src/views/eam/basicFaultType/basicFaultType.data.ts index 8fe42a032..dd36093d0 100644 --- a/src/views/eam/basicFaultType/basicFaultType.data.ts +++ b/src/views/eam/basicFaultType/basicFaultType.data.ts @@ -18,7 +18,7 @@ export const BasicFaultType = useCrudSchemas(reactive([ isDetail:false, }, { - label: '设备编码', + label: '编码', field: 'code', sort: 'custom', isSearch: true, diff --git a/src/views/eam/equipmentMaintenanceMain/equipmentMaintenanceMain.data.ts b/src/views/eam/equipmentMaintenanceMain/equipmentMaintenanceMain.data.ts index cd1c845de..6f9553762 100644 --- a/src/views/eam/equipmentMaintenanceMain/equipmentMaintenanceMain.data.ts +++ b/src/views/eam/equipmentMaintenanceMain/equipmentMaintenanceMain.data.ts @@ -89,6 +89,8 @@ export const EquipmentMaintenanceMain = useCrudSchemas(reactive([ label: '故障类型枚举', field: 'faultType', sort: 'custom', + dictType: DICT_TYPE.FAILURE_REASON, + dictClass: 'string', isSearch: true, isSearch: false, }, diff --git a/src/views/eam/equipmentMaintenanceMain/index.vue b/src/views/eam/equipmentMaintenanceMain/index.vue index 4db1801b9..e4219bc6d 100644 --- a/src/views/eam/equipmentMaintenanceMain/index.vue +++ b/src/views/eam/equipmentMaintenanceMain/index.vue @@ -353,39 +353,6 @@ const handleFinish = async (row) => { //打开提交表单 finishForm2Ref.value.open('update', row); - - //let res = await EquipmentMaintenanceMainApi.getMaintenanceOrderConfig(); - //系统配置需要验证 - // if(res.remark === 'TRUE'){ - // try { - // - // - // // // 二次确认 - // // await message.delConfirm('是否完成所选中工单?'); - // // const params = ref({ - // // id: '', - // // status:'', - // // }) - // // params.value.id = row.id - // // params.value.status = '5' - // // // 发起 - // // await EquipmentMaintenanceMainApi.executeMaintenanceOrder(params.value) - // // message.success(t('工单已完成')) - // // // 刷新列表 - // // await getList() - // } catch {} - // } - // //系统配置不需要验证 - // if(res.remark === 'FALSE'){ - // try { - // // 二次确认 - // await message.delConfirm('是否完成所选中工单?'); - // - // //打开提交表单 - // finishForm2Ref.value.open('update', row); - // - // } catch {} - // } } /** 验证按钮操作 */ @@ -406,8 +373,6 @@ const handleValidate = async (row) => { await getList() }) - - } /** 启用 */ diff --git a/src/views/eam/equipmentRepairJobDetail/equipmentRepairJobDetail.data.ts b/src/views/eam/equipmentRepairJobDetail/equipmentRepairJobDetail.data.ts new file mode 100644 index 000000000..cae967cf5 --- /dev/null +++ b/src/views/eam/equipmentRepairJobDetail/equipmentRepairJobDetail.data.ts @@ -0,0 +1,145 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' + +// 表单校验 +export const EquipmentRepairJobDetailRules = reactive({ + number: [required], + masterId: [required], + concurrencyStamp: [required], +}) + +export const EquipmentRepairJobDetail = useCrudSchemas(reactive([ + { + label: 'id', + field: 'id', + sort: 'custom', + isForm: false, + }, + { + label: '维修工单号', + field: 'number', + sort: 'custom', + isSearch: true, + }, + { + label: '主表id', + field: 'masterId', + sort: 'custom', + isSearch: true, + form: { + component: 'InputNumber', + value: 0 + }, + }, + { + label: '故障描述', + field: 'describing', + sort: 'custom', + isSearch: true, + }, + { + label: '故障原因关联基础数据', + field: 'faultCause', + sort: 'custom', + isSearch: true, + }, + { + label: '解决措施', + field: 'workOut', + sort: 'custom', + isSearch: true, + }, + { + label: '维修人员字符串多个', + field: 'maintenances', + sort: 'custom', + isSearch: true, + }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: true, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isForm: false, + }, + { + label: '部门id', + field: 'departmentCode', + sort: 'custom', + isSearch: true, + }, + { + label: '备注', + field: 'remark', + sort: 'custom', + isSearch: true, + }, + { + label: '地点ID', + field: 'siteId', + sort: 'custom', + isSearch: true, + }, + { + label: '是否可用默认TRUE', + field: 'available', + sort: 'custom', + isSearch: true, + }, + { + label: '删除时间', + field: 'deletionTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: true, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '删除人id', + field: 'deleterId', + sort: 'custom', + isSearch: true, + }, + { + label: '并发乐观锁', + field: 'concurrencyStamp', + sort: 'custom', + isSearch: true, + form: { + component: 'InputNumber', + value: 0 + }, + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) diff --git a/src/views/eam/equipmentRepairJobDetail/index.vue b/src/views/eam/equipmentRepairJobDetail/index.vue new file mode 100644 index 000000000..bdfae4458 --- /dev/null +++ b/src/views/eam/equipmentRepairJobDetail/index.vue @@ -0,0 +1,244 @@ + + + diff --git a/src/views/eam/equipmentRepairJobMain/EquipmentRepairJobDetail.vue b/src/views/eam/equipmentRepairJobMain/EquipmentRepairJobDetail.vue new file mode 100644 index 000000000..7626c0627 --- /dev/null +++ b/src/views/eam/equipmentRepairJobMain/EquipmentRepairJobDetail.vue @@ -0,0 +1,1086 @@ + + + + + diff --git a/src/views/eam/equipmentRepairJobMain/equipmentRepairJobMain.data.ts b/src/views/eam/equipmentRepairJobMain/equipmentRepairJobMain.data.ts new file mode 100644 index 000000000..4be0eadb5 --- /dev/null +++ b/src/views/eam/equipmentRepairJobMain/equipmentRepairJobMain.data.ts @@ -0,0 +1,668 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' +import {EquipmentAccounts} from "@/views/eam/equipmentAccounts/equipmentAccounts.data"; +import * as EquipmentItemApi from "@/api/eam/equipmentAccounts"; +import {BasicFaultCause} from "@/views/eam/basicFaultCause/basicFaultCause.data"; +import * as ItemApi from "@/api/eam/basicFaultCause"; +import {getBasicFaultCausePage} from "@/api/eam/basicFaultCause"; + +// 表单校验 +export const EquipmentRepairJobMainRules = reactive({ + number: [required], + type: [required], + sources: [required], + urgency: [required], + level: [required], + equipmentCode: [required], + totalMinutes: [required], + faultType: [required], + status: [required], +}) + +export const EquipmentRepairJobMain = useCrudSchemas(reactive([ + { + label: 'id', + field: 'id', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '维修工单号', + field: 'number', + sort: 'custom', + isSearch: true, + }, + { + label: '设备类别', + field: 'type', + sort: 'custom', + dictType: DICT_TYPE.DEVICE_TYPE, + dictClass: 'string', + isSearch: true, + }, + { + label: '报修工单号', + field: 'repairNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '来源字典', + field: 'sources', + sort: 'custom', + dictType: DICT_TYPE.EAM_MAINTENANCE_SOURCES, + dictClass: 'string', + isSearch: false, + }, + { + label: '维修描述', + field: 'maintenanceDesc', + sort: 'custom', + isSearch: false, + }, + { + label: '紧急程度', + field: 'urgency', + sort: 'custom', + dictType: DICT_TYPE.EAM_MAINTENANCE_URGENCY, + dictClass: 'string', + isSearch: true, + }, + { + label: '维修级别', + field: 'level', + sort: 'custom', + dictType: DICT_TYPE.EAM_MAINTENANCE_LEVEL, + dictClass: 'string', + isSearch: true, + }, + { + label: '设备编号', + field: 'equipmentCode', + sort: 'custom', + isSearch: true, + isForm: true, + form: { + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchTitle: '设备信息', // 查询弹窗标题 + searchListPlaceholder: '请选择 设备编号', // 输入框占位文本 + searchAllSchemas: EquipmentAccounts.allSchemas, // 查询弹窗所需类 + searchField: 'code', // 查询弹窗赋值字段 + searchPage: EquipmentItemApi.getEquipmentAccountsPage, // 查询弹窗所需分页方法 + multiple:true, + searchCondition: [{ + key: 'status', + value: 'NORMAL', + action: '==', + isSearch: true, + isMainValue: false + }] + } + } + }, + { + label: '是否停机', + field: 'shutDown', + sort: 'custom', + dictType: DICT_TYPE.INFRA_BOOLEAN_STRING, + dictClass: 'string', + isSearch: true, + form: { + component: 'Radio' + } + }, + { + label: '维修开始时间', + field: 'startTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '维修结束时间', + field: 'endTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '维修时长', + field: 'totalMinutes', + sort: 'custom', + isSearch: false, + }, + { + label: '验证人', + field: 'verifyer', + sort: 'custom', + isSearch: false, + }, + { + label: '验证内容', + field: 'verifyContent', + sort: 'custom', + isSearch: false, + }, + { + label: '验证时间', + field: 'verifyTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '执行人', + field: 'maintenancer', + sort: 'custom', + isSearch: false, + }, + { + label: '维修人联系电话', + field: 'maintenancePhone', + sort: 'custom', + isSearch: false, + }, + { + label: '结果', + field: 'completeResult', + sort: 'custom', + isSearch: true, + }, + { + label: '完成时间', + field: 'completionTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '执行时间', + field: 'maintenanceTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '报修时间', + field: 'repairTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '报修人', + field: 'repairer', + sort: 'custom', + isSearch: false, + }, + { + label: '故障类型', + field: 'faultType', + dictType: DICT_TYPE.FAILURE_REASON, + dictClass: 'string', + sort: 'custom', + isSearch: true, + }, + { + label: '流程状态', + field: 'status', + sort: 'custom', + dictType: DICT_TYPE.EAM_REPAIR_STATUS, + dictClass: 'string', + isSearch: true, + }, + // { + // label: '自动接单', + // field: 'autoOrder', + // sort: 'custom', + // isSearch: true, + // }, + // { + // label: '自动执行', + // field: 'autoPerform', + // sort: 'custom', + // isSearch: true, + // }, + // { + // label: '自动验证', + // field: 'autoVerify', + // sort: 'custom', + // isSearch: true, + // }, + { + label: '直接生成记录', + field: 'directCreateRecord', + sort: 'custom', + isSearch: false, + }, + { + label: '班组类型', + field: 'classType', + sort: 'custom', + isSearch: false, + }, + // { + // label: '所属厂区编号', + // field: 'factoryAreaCode', + // sort: 'custom', + // isSearch: true, + // }, + { + label: '车间编号', + field: 'workshopCode', + sort: 'custom', + isSearch: false, + }, + // { + // label: '产线编号', + // field: 'lineCode', + // sort: 'custom', + // isSearch: true, + // }, + // { + // label: '工序编号', + // field: 'processCode', + // sort: 'custom', + // isSearch: true, + // }, + // { + // label: '工位编号', + // field: 'workstationCode', + // sort: 'custom', + // isSearch: true, + // }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '部门id', + field: 'departmentCode', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '备注', + field: 'remark', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '地点ID', + field: 'siteId', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '是否可用默认TRUE', + field: 'available', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '删除时间', + field: 'deletionTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '删除人id', + field: 'deleterId', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '并发乐观锁', + field: 'concurrencyStamp', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + form: { + component: 'InputNumber', + value: 0 + }, + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) + +// 表单校验 +export const EquipmentRepairJobDetailRules = reactive({ + number: [required], + masterId: [required], + concurrencyStamp: [required], +}) + +export const EquipmentRepairJobDetail = useCrudSchemas(reactive([ + { + label: 'id', + field: 'id', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '维修工单号', + field: 'number', + sort: 'custom', + isSearch: true, + form:{ + componentProps: { + disabled: true + } + } + }, + { + label: '主表id', + field: 'masterId', + sort: 'custom', + isSearch: true, + form:{ + componentProps: { + disabled: true + } + }, + }, + { + label: '故障描述', + field: 'describing', + sort: 'custom', + isSearch: true, + }, + { + label: '故障原因', + field: 'faultCause', + sort: 'custom', + isSearch: true, + form: { + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchListPlaceholder: '请选择 故障原因', + searchTitle: '故障原因', // 查询弹窗标题 + searchAllSchemas: BasicFaultCause.allSchemas, // 查询弹窗所需类 + searchField: 'code', // 查询弹窗赋值字段 + searchPage: ItemApi.getBasicFaultCausePage, // 查询弹窗所需分页方法 + searchCondition: [{ + key: 'available', + value: 'TRUE', + action: '==', + isSearch: true, + isMainValue: false + }] + } + }, + }, + { + label: '解决措施', + field: 'workOut', + sort: 'custom', + isSearch: true, + }, + { + label: '维修人员字符串多个', + field: 'maintenances', + sort: 'custom', + isSearch: true, + }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isForm: false, + }, + { + label: '部门id', + field: 'departmentCode', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '备注', + field: 'remark', + sort: 'custom', + isSearch: true, + }, + { + label: '地点ID', + field: 'siteId', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '是否可用默认TRUE', + field: 'available', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '删除时间', + field: 'deletionTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '删除人id', + field: 'deleterId', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + }, + { + label: '并发乐观锁', + field: 'concurrencyStamp', + sort: 'custom', + isSearch: false, + isTable: false, + isForm: false, + isDetail:false, + form: { + component: 'InputNumber', + value: 0 + }, + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) diff --git a/src/views/eam/equipmentRepairJobMain/index.vue b/src/views/eam/equipmentRepairJobMain/index.vue new file mode 100644 index 000000000..2d5d60699 --- /dev/null +++ b/src/views/eam/equipmentRepairJobMain/index.vue @@ -0,0 +1,320 @@ + + + diff --git a/src/views/eam/equipmentReportRepairRequest/equipmentReportRepairRequest.data.ts b/src/views/eam/equipmentReportRepairRequest/equipmentReportRepairRequest.data.ts index 9785ed4d6..c20a61e45 100644 --- a/src/views/eam/equipmentReportRepairRequest/equipmentReportRepairRequest.data.ts +++ b/src/views/eam/equipmentReportRepairRequest/equipmentReportRepairRequest.data.ts @@ -144,7 +144,7 @@ export const EquipmentReportRepairRequest = useCrudSchemas(reactive { }) params.value.id = id params.value.status = '5' - await EquipmentReportRepairRequestApi.updateEquipmentReportRepairOrder(params.value) + await EquipmentReportRepairRequestApi.createEquipmentWeixiuOrder(params.value) message.success(t('common.updateSuccess')) // 刷新列表 await getList() diff --git a/src/views/wms/basicDataManage/customerManage/customerDeliveryForecast/customerDeliveryForecast.data.ts b/src/views/wms/basicDataManage/customerManage/customerDeliveryForecast/customerDeliveryForecast.data.ts index ef5e1682f..cda8e2e8e 100644 --- a/src/views/wms/basicDataManage/customerManage/customerDeliveryForecast/customerDeliveryForecast.data.ts +++ b/src/views/wms/basicDataManage/customerManage/customerDeliveryForecast/customerDeliveryForecast.data.ts @@ -116,7 +116,15 @@ export const CustomerDeliveryForecast = useCrudSchemas(reactive([ field: 'createTime', sort: 'custom', formatter: dateFormatter, - isForm: false + isForm: false, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + dateFormat: 'YYYY-MM-DD HH:mm:ss', + valueFormat: 'x', + } + }, }, { label: '是否可用', diff --git a/src/views/wms/basicDataManage/strategySetting/strategy/downShelfStrategy/AddForm.vue b/src/views/wms/basicDataManage/strategySetting/strategy/downShelfStrategy/AddForm.vue index 80baf7b2b..4b075a056 100644 --- a/src/views/wms/basicDataManage/strategySetting/strategy/downShelfStrategy/AddForm.vue +++ b/src/views/wms/basicDataManage/strategySetting/strategy/downShelfStrategy/AddForm.vue @@ -759,7 +759,7 @@ const getFormLocationgrouList = async () => { const getFormLocationList = async () => { options.warehouseList = await getLocationList() } -getFormLocationList() +getFormWarehouseList() // 选择仓库/库位/库位组/库区 const changeWarehouse = (e) => { formData.value.configuration.WarehouseCode = '' diff --git a/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts b/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts index 298e1bf5a..3578520b6 100644 --- a/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts +++ b/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts @@ -39,7 +39,7 @@ export const DeliverRecordMain = useCrudSchemas(reactive([ table: { width: 150 }, - isSearch: true, + isSearch: false, }, // { // label: '发货计划单号', @@ -62,7 +62,7 @@ export const DeliverRecordMain = useCrudSchemas(reactive([ field: 'status', dictType: DICT_TYPE.REQUEST_STATUS, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, isForm: false, sort: 'custom', @@ -366,7 +366,7 @@ export const DeliverRecordMain = useCrudSchemas(reactive([ field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: false, sort: 'custom', table: { diff --git a/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue b/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue index d75a19e9f..fb6bd2c07 100644 --- a/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue +++ b/src/views/wms/deliversettlementManage/deliver/deliverRequestMain/index.vue @@ -559,6 +559,10 @@ const importSuccess = () => { // 筛选提交 const searchFormClick = (searchData) => { tableObject.params.isSearch = true + console.log('searchData',searchData.filters); + if(!searchData.filters){//重置的时候应用 + searchData.filters = [] + } let filters = [...searchData.filters] if(!filters.find(item=>item.column=='business_type')){ if ( routeName.value == 'DeliverRequestMain') { diff --git a/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/deliverPlanMain.data.ts b/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/deliverPlanMain.data.ts index b4239de99..ed61ebad9 100644 --- a/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/deliverPlanMain.data.ts +++ b/src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/deliverPlanMain.data.ts @@ -256,7 +256,7 @@ export const DeliverPlanMain = useCrudSchemas(reactive([ field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: false, sort: 'custom', table: { diff --git a/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts b/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts index 39362227c..2123a4199 100644 --- a/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts +++ b/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts @@ -249,7 +249,7 @@ export const SaleMain = useCrudSchemas(reactive([ field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { diff --git a/src/views/wms/inventoryManage/locationcapacity/locationcapacity.data.ts b/src/views/wms/inventoryManage/locationcapacity/locationcapacity.data.ts index 8c6945dfe..b0e43194f 100644 --- a/src/views/wms/inventoryManage/locationcapacity/locationcapacity.data.ts +++ b/src/views/wms/inventoryManage/locationcapacity/locationcapacity.data.ts @@ -20,7 +20,7 @@ export const Locationcapacity = useCrudSchemas(reactive([ label: '已用容量百分比', field: 'usedCapacity', sort: 'custom', - isSearch: true, + isSearch: false, }, { label: '可用容量百分比', diff --git a/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts b/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts index c2cf324bd..ee26644e3 100644 --- a/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts +++ b/src/views/wms/inventoryjobManage/containermanage/containerMainRequest/containerMainRequest.data.ts @@ -95,7 +95,7 @@ export const ContainerMainRequest = useCrudSchemas(reactive([ label: '备注', field: 'remark', sort: 'custom', - isSearch: true, + isSearch: false, isTable: false }, { diff --git a/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts b/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts index 74474265e..e15a50fe0 100644 --- a/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts +++ b/src/views/wms/inventoryjobManage/containermanage/initialContainerMainRequest/initialContainerMainRequest.data.ts @@ -99,7 +99,7 @@ export const ContainerMainRequest = useCrudSchemas(reactive([ label: '备注', field: 'remark', sort: 'custom', - isSearch: true, + isSearch: false, isTable:false, }, { diff --git a/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts b/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts index ad74af33a..4c182dbf4 100644 --- a/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts +++ b/src/views/wms/inventoryjobManage/containermanage/scrapContainerMainRequest/scrapContainerMainRequest.data.ts @@ -95,7 +95,7 @@ export const ContainerMainRequest = useCrudSchemas(reactive([ label: '备注', field: 'remark', sort: 'custom', - isSearch: true, + isSearch: false, isTable: false }, { diff --git a/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRecordMain/index.vue b/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRecordMain/index.vue index 96032625d..b3f3f93b1 100644 --- a/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRecordMain/index.vue +++ b/src/views/wms/inventoryjobManage/inventoryinitial/inventoryinitRecordMain/index.vue @@ -221,6 +221,9 @@ const handleSelectionPoint = async ()=>{ const src = ref(BASE_URL + '/jmreport/view/922729953438072832?token=' + getAccessToken()) window.open(src.value+'&asn_number='+res.cgLabel) } + if(!res.cgLabel&&!res.zzLabel){ + message.error('包装不存在,无法打印') + } }).catch(err => { console.log(err) getLoading?.close() diff --git a/src/views/wms/inventoryjobManage/packageManage/packagemergeMain/packagemergeMain.data.ts b/src/views/wms/inventoryjobManage/packageManage/packagemergeMain/packagemergeMain.data.ts index 0b0a8acd2..a63d7609e 100644 --- a/src/views/wms/inventoryjobManage/packageManage/packagemergeMain/packagemergeMain.data.ts +++ b/src/views/wms/inventoryjobManage/packageManage/packagemergeMain/packagemergeMain.data.ts @@ -154,7 +154,7 @@ export const PackagemergeMain = useCrudSchemas(reactive([ dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', isTable: true, - isSearch: true, + isSearch: false, sort: 'custom', table: { width: 150 diff --git a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts index bebab56c9..68249d568 100644 --- a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts +++ b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/packageoverRequestMain.data.ts @@ -867,6 +867,14 @@ export const PackageoverRequestDetail = useCrudSchemas(reactive([ table: { width: 180 }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + dateFormat: 'YYYY-MM-DD HH:mm:ss', + valueFormat: 'x', + } + }, isTableForm: false, }, { diff --git a/src/views/wms/inventoryjobManage/packageManage/packagesplitMain/packagesplitMain.data.ts b/src/views/wms/inventoryjobManage/packageManage/packagesplitMain/packagesplitMain.data.ts index fef7aa3e7..858b188df 100644 --- a/src/views/wms/inventoryjobManage/packageManage/packagesplitMain/packagesplitMain.data.ts +++ b/src/views/wms/inventoryjobManage/packageManage/packagesplitMain/packagesplitMain.data.ts @@ -155,7 +155,7 @@ export const PackagesplitMain = useCrudSchemas(reactive([ dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', isTable: true, - isSearch: true, + isSearch: false, sort: 'custom', table: { width: 150 diff --git a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRecordMain/sparepartsrequisitionRecordMain.data.ts b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRecordMain/sparepartsrequisitionRecordMain.data.ts index 77a6dd37a..6a0e8b1c3 100644 --- a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRecordMain/sparepartsrequisitionRecordMain.data.ts +++ b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRecordMain/sparepartsrequisitionRecordMain.data.ts @@ -263,7 +263,7 @@ export const UnplannedissueRecordMain = useCrudSchemas(reactive([ field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { diff --git a/src/views/wms/issueManage/issue/issueRequestMain/issueRequestMain.data.ts b/src/views/wms/issueManage/issue/issueRequestMain/issueRequestMain.data.ts index 38407d012..07a0de8ab 100644 --- a/src/views/wms/issueManage/issue/issueRequestMain/issueRequestMain.data.ts +++ b/src/views/wms/issueManage/issue/issueRequestMain/issueRequestMain.data.ts @@ -451,7 +451,7 @@ export const IssueRequestMain = useCrudSchemas(reactive([ isDetail: false, isForm: false, table: { - width: 200, + width: 230, fixed: 'right' }, }, @@ -579,7 +579,7 @@ export const IssueRequestDetail = useCrudSchemas(reactive([ field: 'packingNumber', sort: 'custom', table: { - width: 150 + width: 180 }, isSearch: true, sortSearchDefault:4, @@ -846,7 +846,7 @@ export const IssueRequestDetail = useCrudSchemas(reactive([ field: 'itemName', sort: 'custom', table: { - width: 150 + width: 300 }, sortTableDefault:4, isTableForm: false, diff --git a/src/views/wms/moveManage/inventorychange/inventorychangeRecordMain/inventorychangeRecordMain.data.ts b/src/views/wms/moveManage/inventorychange/inventorychangeRecordMain/inventorychangeRecordMain.data.ts index bd30dfe67..5164cae9b 100644 --- a/src/views/wms/moveManage/inventorychange/inventorychangeRecordMain/inventorychangeRecordMain.data.ts +++ b/src/views/wms/moveManage/inventorychange/inventorychangeRecordMain/inventorychangeRecordMain.data.ts @@ -205,7 +205,7 @@ export const InventorychangeRecordMain = useCrudSchemas(reactive([ field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { diff --git a/src/views/wms/moveManage/inventorymove/inventorymoveRecordMain/index.vue b/src/views/wms/moveManage/inventorymove/inventorymoveRecordMain/index.vue index abd19c83a..53692862e 100644 --- a/src/views/wms/moveManage/inventorymove/inventorymoveRecordMain/index.vue +++ b/src/views/wms/moveManage/inventorymove/inventorymoveRecordMain/index.vue @@ -272,7 +272,7 @@ onMounted(async () => { if(routeName.value == "InventorymoveRecordMain"){ importTemplateData.templateUrl = await InventorymoveRecordMainApi.importTemplate() }else { - importTemplateData.templateUrl = await InventorymoveRecordMainApi.importTemplateExceptMove() + //importTemplateData.templateUrl = await InventorymoveRecordMainApi.importTemplateExceptMove() } }) diff --git a/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts b/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts index 8ea88ad19..e42334189 100644 --- a/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts +++ b/src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts @@ -796,6 +796,7 @@ export const PurchasereceiptRequestDetail = useCrudSchemas(reactive console.log("type:",type) console.log("formField:",formField) console.log(formField, searchField, val, formRef, type, row) + if (type == 'tableForm') { // 明细查询页赋值 // row[formField] = val[0][searchField] @@ -185,18 +186,23 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) => newRow['poLine'] = item['poLine'] newRow['orderQty'] = item['orderQty'] newRow['uom'] = item['uom'] + if(tableData.value.find(item1=>item1['itemCode'] == item['itemCode']&&item1['poLine'] == item['poLine']&&item1['poNumber'] == item['poNumber'])) return + itemCodes.push(item['itemCode']) tableData.value.push(newRow) }) - //有效期 - ItembasicApi.getItembasicPage({ - code:itemCodes.join(',') - }).then((res)=>{ - res.list.forEach((item,index)=>{ - const findItem = tableData.value.find(item1=>item1['itemCode']==item['code']) - findItem['expireTime'] = item['expireTime'] + if(itemCodes.length>0){ + //有效期 + ItembasicApi.getItembasicPage({ + code:itemCodes.join(',') + }).then((res)=>{ + res.list.forEach((item,index)=>{ + const findItem = tableData.value.find(item1=>item1['itemCode']==item['code']) + findItem['expireTime'] = item['expireTime'] + }) }) - }) + } + } else { const setV = {} setV[formField] = val[0][searchField]