Browse Source

Merge branch 'master_hella' of http://dev.ccwin-in.com:3000/sfms3.0/sfms3.0-ui into master_hella

master_hella_20240701
songguoqiang 6 months ago
parent
commit
2a2bfea15a
  1. 10
      src/components/BasicForm/src/BasicForm.vue
  2. 9
      src/components/XButton/src/ButtonBase.vue
  3. 1
      src/locales/en-US.ts
  4. 1
      src/locales/zh-CN.ts
  5. 1
      src/utils/dict.ts
  6. 2
      src/views/eam/equipmentRepairJobMain/equipmentRepairJobMain.data.ts
  7. 1
      src/views/eam/equipmentRepairJobMain/index.vue
  8. 155
      src/views/eam/equipmentRepairRecordMain/equipmentRepairRecordMain.data.ts
  9. 29
      src/views/eam/equipmentRepairRecordMain/index.vue
  10. 14
      src/views/eam/sparepartsinlocation/index.vue
  11. 93
      src/views/eam/sparepartsinlocation/sparePartsInLocationMain.data.ts
  12. 2
      src/views/login/forgetPassword.vue

10
src/components/BasicForm/src/BasicForm.vue

@ -566,9 +566,15 @@ const buttonBaseClick = (val) => {
} }
// //
else if (val == 'save') { else if (val == 'save') {
debounce(() => { let timer = null
if(!timer){
submitForm() submitForm()
}, 2000)() timer = setTimeout(()=>{
if(timer){
clearTimeout(timer)
}
},2000)
}
} }
// //
else if (val == 'close') { else if (val == 'close') {

9
src/components/XButton/src/ButtonBase.vue

@ -72,8 +72,17 @@ const props = defineProps({
const emit = defineEmits(['buttonBaseClick', 'updataTableColumns']) const emit = defineEmits(['buttonBaseClick', 'updataTableColumns'])
const buttonBaseClick = (val, item, $event) => { const buttonBaseClick = (val, item, $event) => {
let timer = null
if(!timer){
clearButtonBlurHandle($event) //el-button clearButtonBlurHandle($event) //el-button
emit('buttonBaseClick', val, item, $event) emit('buttonBaseClick', val, item, $event)
timer = setTimeout(()=>{
if(timer){
clearTimeout(timer)
}
},2000)
}
} }
const popoverVisible = ref(false) const popoverVisible = ref(false)
// //

1
src/locales/en-US.ts

@ -44,6 +44,7 @@ export default {
importMessage: 'Whether to confirm import data item?', importMessage: 'Whether to confirm import data item?',
createSuccess: 'Create Success', createSuccess: 'Create Success',
updateSuccess: 'Update Success', updateSuccess: 'Update Success',
emailSentSuccess: 'Email sent successfully',
delMessage: 'Delete the selected data?', delMessage: 'Delete the selected data?',
delDataMessage: 'Delete the data?', delDataMessage: 'Delete the data?',
delNoData: 'Please select the data to delete', delNoData: 'Please select the data to delete',

1
src/locales/zh-CN.ts

@ -44,6 +44,7 @@ export default {
importMessage: '是否确认导入数据项?', importMessage: '是否确认导入数据项?',
createSuccess: '新增成功', createSuccess: '新增成功',
updateSuccess: '修改成功', updateSuccess: '修改成功',
emailSentSuccess: '邮件发送成功',
delMessage: '是否删除所选中数据?', delMessage: '是否删除所选中数据?',
delDataMessage: '是否删除数据?', delDataMessage: '是否删除数据?',
delNoData: '请选择需要删除的数据', delNoData: '请选择需要删除的数据',

1
src/utils/dict.ts

@ -363,6 +363,7 @@ export enum DICT_TYPE {
EAM_MAINTENANCE_URGENCY = 'eam_maintenance_urgency', // 维保紧急程度 EAM_MAINTENANCE_URGENCY = 'eam_maintenance_urgency', // 维保紧急程度
EAM_MAINTENANCE_LEVEL = 'eam_maintenance_level', // 维保维修级别 EAM_MAINTENANCE_LEVEL = 'eam_maintenance_level', // 维保维修级别
EAM_REPAIR_STATUS = 'eam_repair_status', // 维修状态 EAM_REPAIR_STATUS = 'eam_repair_status', // 维修状态
EAM_COMPLETE_RESULT = 'eam_complete_result', // 维修状态
OFF_BACK_STATUS = 'off_back_status', OFF_BACK_STATUS = 'off_back_status',
SPAREPARTS_APPLY_STATUS_ENUM = 'spareparts_apply_status_enum',// 流程状态 SPAREPARTS_APPLY_STATUS_ENUM = 'spareparts_apply_status_enum',// 流程状态
IS_LINE_ITEM = 'is_line_item', // 是否是线边 IS_LINE_ITEM = 'is_line_item', // 是否是线边

2
src/views/eam/equipmentRepairJobMain/equipmentRepairJobMain.data.ts

@ -249,6 +249,8 @@ export const EquipmentRepairJobMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '结果', label: '结果',
field: 'completeResult', field: 'completeResult',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.EAM_COMPLETE_RESULT,
dictClass: 'string',
isSearch: true, isSearch: true,
}, },
{ {

1
src/views/eam/equipmentRepairJobMain/index.vue

@ -88,7 +88,6 @@ import Detail from '@/views/eam/equipmentRepairJobMain/EquipmentRepairJobDetail.
import FinishForm1 from '@/views/eam/equipmentRepairJobMain/finishForm1.vue' import FinishForm1 from '@/views/eam/equipmentRepairJobMain/finishForm1.vue'
import FinishForm2 from '@/views/eam/equipmentRepairJobMain/finishForm2.vue' import FinishForm2 from '@/views/eam/equipmentRepairJobMain/finishForm2.vue'
import FinishForm3 from '@/views/eam/equipmentRepairJobMain/finishForm3.vue' import FinishForm3 from '@/views/eam/equipmentRepairJobMain/finishForm3.vue'
import {createEquipmentRepairNewOrder} from "@/api/eam/equipmentRepairJobMain";
defineOptions({ name: 'EquipmentRepairJobMain' }) defineOptions({ name: 'EquipmentRepairJobMain' })

155
src/views/eam/equipmentRepairRecordMain/equipmentRepairRecordMain.data.ts

@ -1,5 +1,7 @@
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 {EquipmentAccounts} from "@/views/eam/equipmentAccounts/equipmentAccounts.data";
import * as EquipmentItemApi from "@/api/eam/equipmentAccounts";
// 表单校验 // 表单校验
export const EquipmentRepairRecordMainRules = reactive({ export const EquipmentRepairRecordMainRules = reactive({
@ -11,7 +13,6 @@ export const EquipmentRepairRecordMainRules = reactive({
equipmentCode: [required], equipmentCode: [required],
totalMinutes: [required], totalMinutes: [required],
faultType: [required], faultType: [required],
concurrencyStamp: [required]
}) })
export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
@ -28,12 +29,9 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
dictType: DICT_TYPE.DEVICE_TYPE, dictType: DICT_TYPE.DEVICE_TYPE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true, isSearch: true,
form: {
component: 'SelectV2'
}
}, },
{ {
label: '报修工单申请号', label: '报修工单号',
field: 'repairNumber', field: 'repairNumber',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: true
@ -42,43 +40,56 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '来源字典', label: '来源字典',
field: 'sources', field: 'sources',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.INFRA_BOOLEAN_STRING, dictType: DICT_TYPE.EAM_MAINTENANCE_SOURCES,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true isSearch: false
}, },
{ {
label: '维修描述', label: '维修描述',
field: 'maintenanceDesc', field: 'maintenanceDesc',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false
}, },
{ {
label: '紧急程度', label: '紧急程度',
field: 'urgency', field: 'urgency',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.REPAIR_DEGREE, dictType: DICT_TYPE.EAM_MAINTENANCE_URGENCY,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true, isSearch: true,
form: {
component: 'SelectV2'
}
}, },
{ {
label: '维修级别', label: '维修级别',
field: 'level', field: 'level',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.REPAIR_LEVEL, dictType: DICT_TYPE.EAM_MAINTENANCE_LEVEL,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true, isSearch: true,
form: {
component: 'SelectV2'
}
}, },
{ {
label: '设备编号', label: '设备编号',
field: 'equipmentCode', field: 'equipmentCode',
sort: 'custom', sort: 'custom',
isSearch: true 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: '是否停机', label: '是否停机',
@ -96,7 +107,7 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'startTime', field: 'startTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isSearch: true, isSearch: false,
search: { search: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -118,7 +129,7 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'endTime', field: 'endTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isSearch: true, isSearch: false,
search: { search: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -139,23 +150,25 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '维修时间', label: '维修时间',
field: 'totalMinutes', field: 'totalMinutes',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false
}, },
{ {
label: '验证人', label: '验证人',
field: 'verifyer', field: 'verifyer',
sort: 'custom', sort: 'custom',
isSearch: true, isSearch: false,
form: { isTable: false,
component: 'InputNumber', isForm: false,
value: 0 isDetail:false,
}
}, },
{ {
label: '验证内容', label: '验证内容',
field: 'verifyContent', field: 'verifyContent',
sort: 'custom', sort: 'custom',
isSearch: true, isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
form: { form: {
component: 'Editor', component: 'Editor',
componentProps: { componentProps: {
@ -169,7 +182,10 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'verifyTime', field: 'verifyTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isSearch: true, isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
search: { search: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -190,35 +206,31 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '执行人', label: '执行人',
field: 'maintenancer', field: 'maintenancer',
sort: 'custom', sort: 'custom',
isSearch: true, isSearch: false,
form: {
component: 'InputNumber',
value: 0
}
}, },
{ {
label: '维修人联系电话', label: '维修人联系电话',
field: 'maintenancePhone', field: 'maintenancePhone',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false
}, },
{ {
label: '结果枚举', label: '结果枚举',
field: 'completeResult', field: 'completeResult',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.INFRA_BOOLEAN_STRING, dictType: DICT_TYPE.EAM_COMPLETE_RESULT,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true, isSearch: false,
form: { isTable: false,
component: 'SelectV2' isForm: false,
} isDetail:false,
}, },
{ {
label: '完成时间', label: '完成时间',
field: 'completionTime', field: 'completionTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isSearch: true, isSearch: false,
search: { search: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -240,7 +252,10 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'maintenanceTime', field: 'maintenanceTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isSearch: true, isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
search: { search: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -262,7 +277,7 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'repairTime', field: 'repairTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isSearch: true, isSearch: false,
search: { search: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -283,11 +298,7 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '报修人', label: '报修人',
field: 'repairer', field: 'repairer',
sort: 'custom', sort: 'custom',
isSearch: true, isSearch: false,
form: {
component: 'InputNumber',
value: 0
}
}, },
{ {
label: '故障类型', label: '故障类型',
@ -296,75 +307,86 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
dictType: DICT_TYPE.FAILURE_REASON, dictType: DICT_TYPE.FAILURE_REASON,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true, isSearch: true,
form: {
component: 'SelectV2'
}
}, },
{ {
label: '流程状态', label: '流程状态',
field: 'status', field: 'status',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.EAM_REPAIR_STATUS,
dictClass: 'string',
isSearch: true, isSearch: true,
form: {
component: 'Radio'
}
}, },
{ {
label: '自动接单', label: '自动接单',
field: 'autoOrder', field: 'autoOrder',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '自动执行', label: '自动执行',
field: 'autoPerform', field: 'autoPerform',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '自动验证', label: '自动验证',
field: 'autoVerify', field: 'autoVerify',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '直接生成记录', label: '直接生成记录',
field: 'directCreateRecord', field: 'directCreateRecord',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false
}, },
{ {
label: '班组类型', label: '班组类型',
field: 'classType', field: 'classType',
sort: 'custom', sort: 'custom',
isSearch: true, isSearch: false,
form: {
component: 'SelectV2'
}
}, },
{ {
label: '所属厂区编号', label: '所属厂区编号',
field: 'factoryAreaCode', field: 'factoryAreaCode',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '车间编号', label: '车间编号',
field: 'workshopCode', field: 'workshopCode',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false
}, },
{ {
label: '工段编号', label: '工段编号',
field: 'workshopSectionCode', field: 'workshopSectionCode',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '备注', label: '备注',
field: 'remark', field: 'remark',
sort: 'custom', sort: 'custom',
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '是否可用', label: '是否可用',
@ -372,7 +394,10 @@ export const EquipmentRepairRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.TRUE_FALSE, dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', // 默认都是字符串类型其他暂不考虑 dictClass: 'string', // 默认都是字符串类型其他暂不考虑
isSearch: true isSearch: false,
isTable: false,
isForm: false,
isDetail:false,
}, },
{ {
label: '操作', label: '操作',

29
src/views/eam/equipmentRepairRecordMain/index.vue

@ -27,9 +27,9 @@
v-model:currentPage="tableObject.currentPage" v-model:currentPage="tableObject.currentPage"
v-model:sort="tableObject.sort" v-model:sort="tableObject.sort"
> >
<template #code="{row}"> <template #number="{row}">
<el-button type="primary" link @click="openDetail(row, '代码', row.code)"> <el-button type="primary" link @click="openDetail(row, '代码', row.number)">
<span>{{ row.code }}</span> <span>{{ row.number }}</span>
</el-button> </el-button>
</template> </template>
<template #action="{ row }"> <template #action="{ row }">
@ -51,7 +51,16 @@
/> />
<!-- 详情 --> <!-- 详情 -->
<Detail ref="detailRef" :isBasic="true" :allSchemas="EquipmentRepairRecordMain.allSchemas" /> <Detail ref="detailRef"
:isBasic="false"
:allSchemas="EquipmentRepairRecordMain.allSchemas"
:detailAllSchemas="EquipmentRepairRecordDetail.allSchemas"
:detailAllSchemasRules="EquipmentRepairRecordDetailRules"
:apiPage="EquipmentRepairRecordDetailApi.getEquipmentRepairRecordDetailPage"
:detailButtonIsShowAdd=false
:detailButtonIsShowEdit=false
:detailButtonIsShowDelete=false
/>
<!-- 导入 --> <!-- 导入 -->
<ImportForm ref="importFormRef" url="/eam/equipment-repair-record-main/import" :importTemplateData="importTemplateData" @success="importSuccess" /> <ImportForm ref="importFormRef" url="/eam/equipment-repair-record-main/import" :importTemplateData="importTemplateData" @success="importSuccess" />
@ -60,7 +69,9 @@
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import { EquipmentRepairRecordMain,EquipmentRepairRecordMainRules } from './equipmentRepairRecordMain.data' import { EquipmentRepairRecordMain,EquipmentRepairRecordMainRules } from './equipmentRepairRecordMain.data'
import { EquipmentRepairRecordDetail,EquipmentRepairRecordDetailRules } from '../equipmentRepairRecordDetail/equipmentRepairRecordDetail.data'
import * as EquipmentRepairRecordMainApi from '@/api/eam/equipmentRepairRecordMain' import * as EquipmentRepairRecordMainApi from '@/api/eam/equipmentRepairRecordMain'
import * as EquipmentRepairRecordDetailApi from '@/api/eam/equipmentRepairRecordDetail'
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'
@ -99,9 +110,9 @@ const { getList, setSearchParams } = tableMethods
// //
const HeadButttondata = [ const HeadButttondata = [
defaultButtons.defaultAddBtn({hasPermi:'wms:equipmentRepairRecordMain:create'}), // // defaultButtons.defaultAddBtn({hasPermi:'eam:equipmentRepairRecordMain:create'}), //
defaultButtons.defaultImportBtn({hasPermi:'wms:equipmentRepairRecordMain:import'}), // // defaultButtons.defaultImportBtn({hasPermi:'eam:equipmentRepairRecordMain:import'}), //
defaultButtons.defaultExportBtn({hasPermi:'wms:equipmentRepairRecordMain:export'}), // defaultButtons.defaultExportBtn({hasPermi:'eam:equipmentRepairRecordMain:export'}), //
defaultButtons.defaultFreshBtn(null), // defaultButtons.defaultFreshBtn(null), //
defaultButtons.defaultFilterBtn(null), // defaultButtons.defaultFilterBtn(null), //
defaultButtons.defaultSetBtn(null), // defaultButtons.defaultSetBtn(null), //
@ -133,8 +144,8 @@ const buttonBaseClick = (val, item) => {
// - // -
const butttondata = [ const butttondata = [
defaultButtons.mainListEditBtn({hasPermi:'wms:equipmentRepairRecordMain:update'}), // // defaultButtons.mainListEditBtn({hasPermi:'eam:equipmentRepairRecordMain:update'}), //
defaultButtons.mainListDeleteBtn({hasPermi:'wms:equipmentRepairRecordMain:delete'}), // // defaultButtons.mainListDeleteBtn({hasPermi:'eam:equipmentRepairRecordMain:delete'}), //
] ]
// - // -

14
src/views/eam/sparepartsinlocation/index.vue

@ -76,8 +76,7 @@
:apiDelete="SparePartsInLocationDetailApi.deleteSparePartsInLocationDetail" :apiDelete="SparePartsInLocationDetailApi.deleteSparePartsInLocationDetail"
@searchTableSuccessDetail="searchTableSuccessDetail" @searchTableSuccessDetail="searchTableSuccessDetail"
:isShowAddBtn="true" :isShowAddBtn="true"
:detailButtonIsShowAdd="true" :detailButtonIsShowAdd="false"
:detailButtonIsShowAddStatusArray="['0']"
/> />
<!-- 导入 --> <!-- 导入 -->
@ -126,17 +125,22 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row) =>
const setV = {} const setV = {}
setV[formField] = val[0][searchField] setV[formField] = val[0][searchField]
if (type == 'tableForm') { if (type == 'tableForm') {
if (formField == 'sparePartsCode') { if (formField == 'locationCode') {
row['sparePartsCode'] = val[0].itemNumber // row['sparePartsCode'] = val[0].itemNumber
row['locationCode'] = val[0].code
row['areaCode'] = val[0].areaCode
row['sparePartsCode'] = val[0].sparePartsCode
row['currentQty'] = val[0].qty row['currentQty'] = val[0].qty
} }
} else { } else {
if (formField == 'locationCode') { if (formField == 'locationCode') {
setV['locationCode'] = val[0].code setV['locationCode'] = val[0].code
setV['areaCode'] = val[0].areaCode setV['areaCode'] = val[0].areaCode
setV['sparePartsCode'] = val[0].sparePartsCode
setV['currentQty'] = val[0].qty
} }
} }
formRef.setValues(setV) formRef.setValues(setV)
}) })
}) })

93
src/views/eam/sparepartsinlocation/sparePartsInLocationMain.data.ts

@ -112,40 +112,7 @@ export const SparePartsInLocationMain = useCrudSchemas(reactive<CrudSchema[]>([
dateFormat: 'YYYY-MM-DD HH:mm:ss' dateFormat: 'YYYY-MM-DD HH:mm:ss'
}, },
}, },
{
label: '库位编号',
field: 'locationCode',
sort: 'custom',
isSearch: false,
form: {
componentProps: {
isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择库位编号', // 输入框占位文本
searchField: 'code', // 查询弹窗赋值字段
searchTitle: '库位信息', // 查询弹窗标题
searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法
searchCondition: [
{
key: 'available',
value: 'TRUE',
isMainValue: false
}
]
}
},
},
{
label: '库区编号',
field: 'areaCode',
sort: 'custom',
isSearch: false,
form: {
componentProps: {
disabled: true
}
}
},
{ {
label: '备注', label: '备注',
@ -187,6 +154,8 @@ export const SparePartsInLocationMain = useCrudSchemas(reactive<CrudSchema[]>([
export const SparePartsInLocationDetailRules = reactive({ export const SparePartsInLocationDetailRules = reactive({
number: [required], number: [required],
masterId: [required], masterId: [required],
locationCode: [required],
areaCode: [required],
sparePartsCode: [required], sparePartsCode: [required],
applyQty: [required], applyQty: [required],
concurrencyStamp: [required], concurrencyStamp: [required],
@ -228,21 +197,18 @@ export const SparePartsInLocationDetail = useCrudSchemas(reactive<CrudSchema[]>(
isTableForm:false isTableForm:false
}, },
{ {
label: '备件编号', label: '库位编号',
field: 'sparePartsCode', field: 'locationCode',
sort: 'custom', sort: 'custom',
table: { isSearch: false,
width: 150
},
form: { form: {
// labelMessage: '信息提示说明!!!',
componentProps: { componentProps: {
isSearchList: true, // 开启查询弹窗 isSearchList: true, // 开启查询弹窗
searchListPlaceholder: '请选择备件编号', // 输入框占位文本 searchListPlaceholder: '请选择库位编号', // 输入框占位文本
searchField: 'itemNumber', // 查询弹窗赋值字段 searchField: 'code', // 查询弹窗赋值字段
searchTitle: '备件信息', // 查询弹窗标题 searchTitle: '库位信息', // 查询弹窗标题
searchAllSchemas: ItemAccounts.allSchemas, // 查询弹窗所需类 searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
searchPage: ItemAccountsApi.getItemAccountsPage, // 查询弹窗所需分页方法 searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法
searchCondition: [ searchCondition: [
{ {
key: 'available', key: 'available',
@ -257,8 +223,8 @@ export const SparePartsInLocationDetail = useCrudSchemas(reactive<CrudSchema[]>(
searchListPlaceholder: '请选择备件编号', // 输入框占位文本 searchListPlaceholder: '请选择备件编号', // 输入框占位文本
searchField: 'itemNumber', // 查询弹窗赋值字段 searchField: 'itemNumber', // 查询弹窗赋值字段
searchTitle: '备件信息', // 查询弹窗标题 searchTitle: '备件信息', // 查询弹窗标题
searchAllSchemas: ItemAccounts.allSchemas, // 查询弹窗所需类 searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
searchPage: ItemAccountsApi.getItemAccountsPage, // 查询弹窗所需分页方法 searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法
searchCondition: [ searchCondition: [
{ {
key: 'available', key: 'available',
@ -268,6 +234,36 @@ export const SparePartsInLocationDetail = useCrudSchemas(reactive<CrudSchema[]>(
] ]
} }
}, },
{
label: '库区编号',
field: 'areaCode',
sort: 'custom',
isSearch: false,
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
}
},
{
label: '备件编号',
field: 'sparePartsCode',
sort: 'custom',
table: {
width: 150
},
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
}
},
{ {
label: '库存数量', label: '库存数量',
field: 'currentQty', field: 'currentQty',
@ -321,7 +317,8 @@ export const SparePartsInLocationDetail = useCrudSchemas(reactive<CrudSchema[]>(
width: 150, width: 150,
fixed: 'right' fixed: 'right'
}, },
isTableForm:false isTableForm:false,
isTable:false
} }
])) ]))

2
src/views/login/forgetPassword.vue

@ -50,7 +50,7 @@
try { try {
const data = loginData as unknown as UserApi.UserVO const data = loginData as unknown as UserApi.UserVO
await UserApi.forgetPassword(data) await UserApi.forgetPassword(data)
message.success(t('common.updateSuccess')) message.success(t('common.emailSentSuccess'))
// //
router.go(-1) router.go(-1)
} finally { } finally {

Loading…
Cancel
Save