Browse Source

BUG修改

hella_online_20240816
parent
commit
37333b4ce9
  1. 26
      src/views/qms/inspectionQ3/index.vue
  2. 36
      src/views/qms/inspectionQ3/inspectionQ3.data.ts

26
src/views/qms/inspectionQ3/index.vue

@ -71,7 +71,6 @@
@searchTableSuccess="searchTableSuccess"
@submitForm="submitForm"
@inputNumberChange="inputNumberChange"
@clearSearchInput="onChange"
:sumFormDataByTableCustom="
(formRef, formModel, tableData) => {
tableData.forEach((item) => {
@ -360,26 +359,15 @@ const handleFinish = async (id: number) => {
/** 添加/修改操作 */
const formRef = ref()
const openForm = async (type: string, row?: any) => {
tableData.value = [] //
//
if (type == 'update') {
// tableform
InspectionQ3Main.allSchemas.formSchema.map((itemColumns) => {
if (itemColumns.field == 'workshopCode') {
itemColumns.componentProps.isSearchList = false
itemColumns.componentProps.disabled = true
}
formRef.value.open(type, row)
if (type == 'create') {
nextTick(() => {
formRef.value.formRef.setValues({
handleTime: new Date().getTime(),
priority: '3'
})
} else {
// tableform
InspectionQ3Main.allSchemas.formSchema.map((itemColumns) => {
if (itemColumns.field == 'workshopCode') {
itemColumns.componentProps.isSearchList = true
itemColumns.componentProps.disabled = false
}
})
}
formRef.value.open(type, row)
}
//
@ -391,7 +379,7 @@ const openDetail = (row: any, titleName: any, titleValue: any) => {
.get(CACHE_KEY.DEPT)
.find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
detailRef.value.openDetail(row, titleName, titleValue, 'requestIssueMain')
detailRef.value.openDetail(row, titleName, titleValue, 'inspectionQ3Main')
}
/** 删除按钮操作 */

36
src/views/qms/inspectionQ3/inspectionQ3.data.ts

@ -10,7 +10,6 @@ import { Itembasic } from '@/views/wms/basicDataManage/itemManage/itembasic/item
import * as ProductionlineitemApi from '@/api/wms/productionlineitem'
import { Productionlineitem } from '@/views/wms/basicDataManage/itemManage/productionlineitem/productionlineitem.data'
import * as QadCostcentreApi from '@/api/wms/qadCostcentre'
import { QadCostcentre } from '@/views/wms/basicDataManage/subject/qadCostcentre/qadCostcentre.data'
@ -115,7 +114,7 @@ export const InspectionQ3Main = useCrudSchemas(
dictType: DICT_TYPE.QUALITY_NOTIFICATION_PRIORITY,
dictClass: 'string',
isSearch: false,
isTable: false,
isTable: true,
tableForm: {
type: 'Select'
}
@ -153,7 +152,8 @@ export const InspectionQ3Main = useCrudSchemas(
component: 'InputNumber',
componentProps: {
min: 0,
precision: 6
precision: 6,
disabled: true
}
}
},
@ -208,7 +208,7 @@ export const InspectionQ3Main = useCrudSchemas(
field: 'costCode',
sort: 'custom',
isSearch: false,
isTable: false,
isTable: true,
isForm: false,
form: {
// labelMessage: '信息提示说明!!!',
@ -245,8 +245,17 @@ export const InspectionQ3Main = useCrudSchemas(
label: '缺陷编码',
field: 'defectCode',
sort: 'custom',
dictType: DICT_TYPE.QMS_Q3_CODE,
dictClass: 'string',
isSearch: false,
isForm: false
isForm: false,
isTable: true,
table: {
width: 180
},
tableForm: {
type: 'Select'
}
},
{
label: '缺陷位置',
@ -360,15 +369,9 @@ export const InspectionQ3Main = useCrudSchemas(
)
export const InspectionQ3MainRules = reactive({
workshopCode: [{ required: true, message: '请选择车间代码', trigger: 'change' }],
productionLineCode: [{ required: true, message: '请选择生产线代码', trigger: 'change' }],
// fromWarehouseCode: [
// { required: true, message: '请选择从仓库代码', trigger: 'change' }
// ],
// dueTime: [
// { required: true, message: '请选择截止时间', trigger: 'change' }
// ],
remark: [{ max: 50, message: '不得超过50个字符', trigger: 'blur' }]
priority: [{ required: true, message: '请选择优先级', trigger: 'change' }],
handleTime: [{ required: true, message: '请选择处理时间', trigger: 'change' }],
desc: [{ max: 50, message: '不得超过50个字符', trigger: 'blur' }]
})
/**
@ -389,6 +392,7 @@ export const InspectionQ3Detail = useCrudSchemas(
field: 'itemCode',
sort: 'custom',
isTable: false,
isDetail: true,
isSearch: false,
table: {
width: 150
@ -553,7 +557,7 @@ export const InspectionQ3Detail = useCrudSchemas(
dictType: DICT_TYPE.QMS_Q3_CODE,
dictClass: 'string',
isSearch: true,
isTable: true,
isTable: false,
tableForm: {
type: 'Select'
}
@ -580,7 +584,6 @@ export const InspectionQ3Detail = useCrudSchemas(
type: 'Select',
valueField: 'productionLineName',
labelField: 'productionLineCode'
}
},
{
@ -596,6 +599,7 @@ export const InspectionQ3Detail = useCrudSchemas(
{
label: '问题原因',
field: 'problemReason',
hiddenInMain: true,
sort: 'custom',
isSearch: false,
isTable: false,

Loading…
Cancel
Save