diff --git a/.env.hella16 b/.env.hella16 index 251fa31e6..e739fa5c3 100644 --- a/.env.hella16 +++ b/.env.hella16 @@ -4,10 +4,10 @@ NODE_ENV=production VITE_DEV=false # 请求路径 -VITE_BASE_URL='https://172.21.32.16:55563/api' +VITE_BASE_URL='https://scptest.faway-hella.com/api' # 上传路径 -VITE_UPLOAD_URL='https://172.21.32.16:55563/api/admin-api/infra/file/upload' +VITE_UPLOAD_URL='https://scptest.faway-hella.com/api/admin-api/infra/file/upload' # 接口前缀 VITE_API_BASEPATH= diff --git a/src/utils/dict.ts b/src/utils/dict.ts index b8a84e8e6..92d89451e 100644 --- a/src/utils/dict.ts +++ b/src/utils/dict.ts @@ -340,5 +340,6 @@ export enum DICT_TYPE { // ========== eam - 业务 - ========== DEVICE_TYPE = 'device_type', // 设备类型 + IS_UPDATED = 'is_updated', //是否可修改 } diff --git a/src/views/eam/basicInspectionOption/basicInspectionOption.data.ts b/src/views/eam/basicInspectionOption/basicInspectionOption.data.ts index d826259c0..13bf5fff5 100644 --- a/src/views/eam/basicInspectionOption/basicInspectionOption.data.ts +++ b/src/views/eam/basicInspectionOption/basicInspectionOption.data.ts @@ -40,7 +40,13 @@ export const BasicInspectionOption = useCrudSchemas(reactive([ label: '项是否可修改', field: 'isUpdated', sort: 'custom', + dictType: DICT_TYPE.IS_UPDATED, + dictClass: 'string', // 默认都是字符串类型其他暂不考虑 + isTable: true, + isDetail: false, isSearch: true, + isTableForm: false, + isForm: true, form: { component: 'Switch', value: 'TRUE', @@ -100,14 +106,13 @@ export const BasicInspectionOption = useCrudSchemas(reactive([ label: '是否可用', field: 'available', sort: 'custom', - form: { - component: 'Switch', - value: 'TRUE', - componentProps: { - inactiveValue: 'FALSE', - activeValue: 'TRUE' - } - }, + dictType: DICT_TYPE.TRUE_FALSE, + dictClass: 'string', // 默认都是字符串类型其他暂不考虑 + isTable: true, + isDetail: false, + isSearch: false, + isTableForm: false, + isForm: false, }, { label: '删除时间', diff --git a/src/views/mes/hrPersonAbility/hrPersonAbility.data.ts b/src/views/mes/hrPersonAbility/hrPersonAbility.data.ts index 81c779e86..614e2ef7f 100644 --- a/src/views/mes/hrPersonAbility/hrPersonAbility.data.ts +++ b/src/views/mes/hrPersonAbility/hrPersonAbility.data.ts @@ -1,8 +1,9 @@ import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import { dateFormatter } from '@/utils/formatTime' import * as AbilityInfoApi from '@/api/mes/abilityInfo' +import * as UserApi from "@/api/system/user"; import { AbilityInfo } from '../abilityInfo/abilityInfo.data' - +import {searchUser} from "@/views/wms/basicDataManage/orderManage/team/team.data"; // 表单校验 export const HrPersonAbilityRules = reactive({ @@ -116,6 +117,20 @@ export const HrPersonAbility = useCrudSchemas(reactive([ field: 'personCode', sort: 'custom', isSearch: true, + form: { + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchTitle: '人员信息', // 查询弹窗标题 + searchAllSchemas: searchUser.allSchemas, // 查询弹窗所需类 + searchField: 'username', // 查询弹窗赋值字段 + searchPage: UserApi.getUserPage, // 查询弹窗所需分页方法 + searchCondition: [{ + action: "==", + column: 'userType', + value: 'WORKER' + }] + } + } }, { label: '能力编号', diff --git a/src/views/mes/hrPersonAbility/index.vue b/src/views/mes/hrPersonAbility/index.vue index f4b11845f..a4bc513f0 100644 --- a/src/views/mes/hrPersonAbility/index.vue +++ b/src/views/mes/hrPersonAbility/index.vue @@ -49,7 +49,7 @@ @searchTableSuccess="searchTableSuccess" :isBusiness="false" /> - + @@ -80,9 +80,17 @@ const tableColumns = ref(HrPersonAbility.allSchemas.tableColumns) // 查询页面返回 const searchTableSuccess = (formField, searchField, val, formRef) => { nextTick(() => { - const setV = {} - setV[formField] = val[0][searchField] - formRef.setValues(setV) + if (formField === 'ablityCode') { + const setV = {} + setV[formField] = val[0][searchField] + formRef.setValues(setV) + } + if (formField === 'personCode') { + const setV = {} + setV[formField] = val[0][searchField] + formRef.setValues(setV) + } + }) } diff --git a/src/views/mes/opersteps/index.vue b/src/views/mes/opersteps/index.vue index 4e2c1abc8..6250e6ef1 100644 --- a/src/views/mes/opersteps/index.vue +++ b/src/views/mes/opersteps/index.vue @@ -149,6 +149,16 @@ const buttonTableClick = async (val, row) => { /** 添加/修改操作 */ const basicFormRef = ref() const openForm = (type: string, row?: any) => { + let disabledFlag = false + if(type==='update'){ + disabledFlag = true + } + Opersteps.allSchemas.formSchema.forEach(item => { + if (item.field == 'stepsCode') { + item.componentProps.disabled =disabledFlag + } + }) + basicFormRef.value.open(type, row) basicFormRef.value.open(type, row) } diff --git a/src/views/mes/opersteps/opersteps.data.ts b/src/views/mes/opersteps/opersteps.data.ts index 96dc16c9d..6dc4c1f12 100644 --- a/src/views/mes/opersteps/opersteps.data.ts +++ b/src/views/mes/opersteps/opersteps.data.ts @@ -5,7 +5,10 @@ import { OperstepsType } from '../operstepsType/operstepsType.data' // 表单校验 export const OperstepsRules = reactive({ - concurrencyStamp: [required], + //concurrencyStamp: [required], + stepsCode: [required], + stepsName: [required], + collectCode: [required], }) export const Opersteps = useCrudSchemas(reactive([ diff --git a/src/views/mes/operstepsType/index.vue b/src/views/mes/operstepsType/index.vue index 20c4d9940..761b74318 100644 --- a/src/views/mes/operstepsType/index.vue +++ b/src/views/mes/operstepsType/index.vue @@ -149,6 +149,15 @@ const buttonTableClick = async (val, row) => { /** 添加/修改操作 */ const basicFormRef = ref() const openForm = (type: string, row?: any) => { + let disabledFlag = false + if(type==='update'){ + disabledFlag = true + } + OperstepsType.allSchemas.formSchema.forEach(item => { + if (item.field == 'collectCode') { + item.componentProps.disabled =disabledFlag + } + }) basicFormRef.value.open(type, row) } diff --git a/src/views/mes/processroute/components/configDialog.vue b/src/views/mes/processroute/components/configDialog.vue index 589d36a19..08cdcd6bb 100644 --- a/src/views/mes/processroute/components/configDialog.vue +++ b/src/views/mes/processroute/components/configDialog.vue @@ -42,7 +42,7 @@ @@ -250,10 +250,16 @@ const searchTableSuccess = (formField, searchField, val, type, row) => { }) } } -const deleteNode=(row)=>{ - processData.value.splice(processData.value.indexOf(row),1) +const deleteNode=(row,index:number)=>{ + //console.log('row------',index) + //showProcessNodeData.value.splice(index,1) + processData.value.splice((page.value.current-1)*page.value.size+index,1) page.value.total=processData.value.length page.value.current=1 + showProcessNodeData.value=processData.value.slice(1,1+page.value.size); + + //page.value.current=1 + //showProcessNodeData.value=processData.value.slice((page.value.current-1)*page.value.size,page.value.size) graph.value.removeNode(row.code) } @@ -278,6 +284,9 @@ const openDetail = (row: any) => { materialData.value = [] mouldData.value = [] workStationList.value = [] + processData.value=[] + showProcessNodeData.value = [] + showMaterialsData.value = [] graph.value.on('node:dblclick', ({ e, x, y, node, view }) => { nodeClick(e, x, y, node, view) }) @@ -297,6 +306,7 @@ const handleDrawerClose = () => { //console.log(graph.value.toJSON()) rowData.value=null } + emit('close') } //**获取 工序信息 */ const getProcessInfo = async (id: any) => { @@ -440,15 +450,15 @@ const saveResult = async () => { processrouteId: processRouteId.value } - let res = ProcessrouteApi.saveGraphData(gdata) - if (res) { - message.success('保存成功!') - } else { - message.error('保存失败!') - } + await ProcessrouteApi.saveGraphData(gdata) + // if (res) { + // message.success('保存成功!') + // } else { + // message.error('保存失败!') + // } isShowDrawer.value = false handleDrawerClose() - emit('close') + //emit('close',) //return res } diff --git a/src/views/mes/processroute/index.vue b/src/views/mes/processroute/index.vue index 45d4c879d..98b69f762 100644 --- a/src/views/mes/processroute/index.vue +++ b/src/views/mes/processroute/index.vue @@ -157,16 +157,25 @@ const buttonTableClick = async (val, row) => { openDetail(row) } } -const dailogClose=() => { - console.log('close'); - nextTick?.(()=>{ - getList() - }) +const dailogClose= () => { + //console.log('dailogClose--confge',getList()); + //nextTick?.(()=>{ + getList() + //}) } /** 添加/修改操作 */ const basicFormRef = ref() const openForm = (type: string, row?: any) => { + let disabledFlag = false + if(type==='update'){ + disabledFlag = true + } + Processroute.allSchemas.formSchema.forEach(item => { + if (item.field == 'processrouteCode') { + item.componentProps.disabled =disabledFlag + } + }) basicFormRef.value.open(type, row) } diff --git a/src/views/mes/processroute/processroute.data.ts b/src/views/mes/processroute/processroute.data.ts index 077aecc88..06fe7caff 100644 --- a/src/views/mes/processroute/processroute.data.ts +++ b/src/views/mes/processroute/processroute.data.ts @@ -4,11 +4,9 @@ import * as ItembasicApi from '@/api/wms/itembasic' import { Itembasic } from '@/views/wms/basicDataManage/itemManage/itembasic/itembasic.data' // 表单校验 export const ProcessrouteRules = reactive({ - processrouteCode: [required], - processName: [required], - productCode: [required], - ablityCode: [required], - ablityCode: [required], + processrouteCode: [{ required: true, message: '请输入工艺路线编码!', trigger: 'blur' },], + processName: [{ required: true, message: '请输入工艺路线名称!', trigger: 'blur' },], + productCode: [{ required: true, message: '请输入产品编码!', trigger: 'blur' },], }) export const Processroute = useCrudSchemas(reactive([ @@ -59,15 +57,7 @@ export const Processroute = useCrudSchemas(reactive([ field: 'processrouteCode', sort: 'custom', isSearch: true, - // form: { - // component: 'Input', - - // componentProps: { - // slots:{ - // default:} - // disabled: true - // } - // } + }, { diff --git a/src/views/mes/workScheduling/components/qualifiedCheck.vue b/src/views/mes/workScheduling/components/qualifiedCheck.vue index 0ce7768bf..013b47986 100644 --- a/src/views/mes/workScheduling/components/qualifiedCheck.vue +++ b/src/views/mes/workScheduling/components/qualifiedCheck.vue @@ -7,38 +7,37 @@ width="600px" > - - - + + + + + - - + + - + - - + + - - + + - - + diff --git a/src/views/wms/deliversettlementManage/saleShipmentMainRecord/saleShipmentMainRecord.data.ts b/src/views/wms/deliversettlementManage/saleShipmentMainRecord/saleShipmentMainRecord.data.ts index 1d97d749b..e0aebfe76 100644 --- a/src/views/wms/deliversettlementManage/saleShipmentMainRecord/saleShipmentMainRecord.data.ts +++ b/src/views/wms/deliversettlementManage/saleShipmentMainRecord/saleShipmentMainRecord.data.ts @@ -114,6 +114,7 @@ export const SaleShipmentMainRecord = useCrudSchemas(reactive([ }, isForm: false, isTable:false + isTable:false }, { label: '地点ID',