From ca0834714d6bb1bd75abcca9af7e01e5118f87e6 Mon Sep 17 00:00:00 2001 From: ljlong_2630 Date: Mon, 23 Dec 2024 10:33:36 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=9F=E4=BA=A7bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../eam/basic/applicantInfoConfig/index.vue | 2 +- src/views/eam/basic/assetsAccount/index.vue | 2 +- .../deviceMaintenance.data.ts | 2 + .../eam/basic/deviceMaintenance/index.vue | 4 +- src/views/eam/basic/inspection/index.vue | 2 +- src/views/eam/basic/item/index.vue | 2 +- src/views/eam/basic/item/item.data.ts | 29 ++++++++--- src/views/eam/basic/moldInspection/index.vue | 4 +- src/views/eam/basic/moldMaintenance/index.vue | 2 +- .../moldMaintenance/moldMaintenance.data.ts | 18 +------ src/views/eam/device/deviceAccounts/index.vue | 2 +- .../eam/device/deviceMaintainPlan/index.vue | 2 +- src/views/eam/device/deviceRepair/index.vue | 2 +- .../deviceSpotInspectionRecordMain/index.vue | 2 +- .../eam/device/deviceinspectionjob/index.vue | 2 +- .../eam/device/devicemaintainjob/index.vue | 2 +- .../deviceMaintenanceMain.data.ts | 4 +- .../eam/device/devicemaintenancejob/index.vue | 7 +-- src/views/eam/device/techRepair/index.vue | 2 +- .../eam/device/techmaintenancejob/index.vue | 5 +- src/views/eam/item/itemAccounts/index.vue | 2 +- .../itemLocationReplace.data.ts | 37 ++++++++++---- src/views/eam/item/itemMaintenance/index.vue | 2 +- src/views/eam/mold/moldAccounts/index.vue | 2 +- .../mold/moldAccounts/moldAccounts.data.ts | 3 ++ src/views/eam/mold/moldMaintainPlan/index.vue | 2 +- src/views/eam/mold/moldRepair/index.vue | 2 +- .../moldSpotInspectionRecordMain/index.vue | 2 +- .../eam/mold/moldinspectionjob/index.vue | 4 +- .../moldInspectionMain.data.ts | 1 + src/views/eam/mold/moldmaintainjob/index.vue | 2 +- .../eam/mold/moldmaintenancejob/index.vue | 11 ++-- .../moldMaintenanceMain.data.ts | 51 ++++++++++++------- 33 files changed, 129 insertions(+), 89 deletions(-) diff --git a/src/views/eam/basic/applicantInfoConfig/index.vue b/src/views/eam/basic/applicantInfoConfig/index.vue index 8c71265..358189b 100644 --- a/src/views/eam/basic/applicantInfoConfig/index.vue +++ b/src/views/eam/basic/applicantInfoConfig/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/basic/assetsAccount/index.vue b/src/views/eam/basic/assetsAccount/index.vue index 328c050..14d536f 100644 --- a/src/views/eam/basic/assetsAccount/index.vue +++ b/src/views/eam/basic/assetsAccount/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts index eac0e94..7229fbb 100644 --- a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts +++ b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts @@ -9,6 +9,8 @@ export const DeviceMaintenanceRules = reactive({ type: [required], status: [required], concurrencyStamp: [required], + executionCycle:[required], + estimatedMinutes: [required], }) export const DeviceMOLD = useCrudSchemas(reactive([ diff --git a/src/views/eam/basic/deviceMaintenance/index.vue b/src/views/eam/basic/deviceMaintenance/index.vue index 0d2e329..4223d4e 100644 --- a/src/views/eam/basic/deviceMaintenance/index.vue +++ b/src/views/eam/basic/deviceMaintenance/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > @@ -56,7 +56,7 @@ ([ @@ -275,12 +279,21 @@ export const Item = useCrudSchemas(reactive([ label: '描述', field: 'describes', sort: 'custom', + form: { + component: 'Input', + componentProps: { + type: 'textarea', + }, + colProps: { + span: 24, + } + } }, - { - label: '图片', - field: 'upload', - isTable: true, - }, + // { + // label: '图片', + // field: 'upload', + // isTable: true, + // }, // { // label: '文件', // field: 'filePathListView', @@ -303,9 +316,9 @@ export const Item = useCrudSchemas(reactive([ table: { }, form: { - component: 'UploadFile', - componentProps: { - + component: 'UploadImgs', + colProps: { + span: 24 } } }, diff --git a/src/views/eam/basic/moldInspection/index.vue b/src/views/eam/basic/moldInspection/index.vue index 0d0c040..ed31912 100644 --- a/src/views/eam/basic/moldInspection/index.vue +++ b/src/views/eam/basic/moldInspection/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > @@ -54,7 +54,7 @@ ([ @@ -182,22 +184,6 @@ export const MoldMaintenance = useCrudSchemas(reactive([ } }, }, - { - label: '保养所需时间(分钟)', - field: 'estimatedMinutes', - sort: 'custom', - isSearch: false, - table: { - width: 200, - }, - form: { - component: 'InputNumber', - componentProps: { - min: 1, - precision: 0 - } - }, - }, // { // label: '是否可用', // field: 'available', diff --git a/src/views/eam/device/deviceAccounts/index.vue b/src/views/eam/device/deviceAccounts/index.vue index 5fbf0d1..4b647a9 100644 --- a/src/views/eam/device/deviceAccounts/index.vue +++ b/src/views/eam/device/deviceAccounts/index.vue @@ -16,7 +16,7 @@ }" v-model:pageSize="tableObject.pageSize" v-model:currentPage="tableObject.currentPage" v-model:sort="tableObject.sort"> diff --git a/src/views/eam/device/deviceMaintainPlan/index.vue b/src/views/eam/device/deviceMaintainPlan/index.vue index f07992f..a1bb45e 100644 --- a/src/views/eam/device/deviceMaintainPlan/index.vue +++ b/src/views/eam/device/deviceMaintainPlan/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/device/deviceRepair/index.vue b/src/views/eam/device/deviceRepair/index.vue index 379d862..e65a1ed 100644 --- a/src/views/eam/device/deviceRepair/index.vue +++ b/src/views/eam/device/deviceRepair/index.vue @@ -15,7 +15,7 @@ }" v-model:pageSize="tableObject.pageSize" v-model:currentPage="tableObject.currentPage" v-model:sort="tableObject.sort"> diff --git a/src/views/eam/device/deviceSpotInspectionRecordMain/index.vue b/src/views/eam/device/deviceSpotInspectionRecordMain/index.vue index 4fd580b..154ec2c 100644 --- a/src/views/eam/device/deviceSpotInspectionRecordMain/index.vue +++ b/src/views/eam/device/deviceSpotInspectionRecordMain/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/device/deviceinspectionjob/index.vue b/src/views/eam/device/deviceinspectionjob/index.vue index b111939..a322bfd 100644 --- a/src/views/eam/device/deviceinspectionjob/index.vue +++ b/src/views/eam/device/deviceinspectionjob/index.vue @@ -23,7 +23,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/device/devicemaintainjob/index.vue b/src/views/eam/device/devicemaintainjob/index.vue index 8d6c50a..c0516c3 100644 --- a/src/views/eam/device/devicemaintainjob/index.vue +++ b/src/views/eam/device/devicemaintainjob/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/device/devicemaintenancejob/deviceMaintenanceMain.data.ts b/src/views/eam/device/devicemaintenancejob/deviceMaintenanceMain.data.ts index c160f1b..0a2520e 100644 --- a/src/views/eam/device/devicemaintenancejob/deviceMaintenanceMain.data.ts +++ b/src/views/eam/device/devicemaintenancejob/deviceMaintenanceMain.data.ts @@ -724,7 +724,9 @@ export const DeviceMaintenanceDetailRules = reactive({ required, { max: 200, message: '不得超过200个字符', trigger: 'blur' }, ], - maintenances: [required], + maintenances: [ + { required: true, message: '维修人不能为空', trigger: 'blur' }, + ], }) diff --git a/src/views/eam/device/devicemaintenancejob/index.vue b/src/views/eam/device/devicemaintenancejob/index.vue index 227fd29..9a242f6 100644 --- a/src/views/eam/device/devicemaintenancejob/index.vue +++ b/src/views/eam/device/devicemaintenancejob/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > @@ -714,7 +714,7 @@ const buttonTableClick = async (val, row) => { } else if (val == 'acceptOrder') { acceptOrder(row) } else if (val == 'repair') { - openDetail(row, '代码', row.number) + openDetail(row, '维修工单编号', row.number) } else if (val == 'turnOrder') { turnOrder('turnOrder', row) } else if (val == 'finishOrder') { @@ -734,7 +734,7 @@ const buttonTableClick = async (val, row) => { const openForm = async (type: string, row?: any) => { if(type == 'update'){ - row.classes = String(row.classes?row.classes:'') + row.classes = String(row.classes||row.classes==0?row.classes:'') } tableData.value = [] // 重置明细数据 await DeviceAccountsApi.getDeviceAccountsNoPage({}).then(res => { @@ -747,6 +747,7 @@ const openForm = async (type: string, row?: any) => { const openFormSec = async (type: string, row?: any) => { tableData.value = [] // 重置明细数据 newRow.value = { ...row } + newRow.value.classes = String(row.classes||row.classes==0?row.classes:'') newRow.value.turnType = '0' DeviceMaintenanceMainSecRules.classes = [{ required: false }] DeviceMaintenanceMainSecRules.faultType = [{ required: false }] diff --git a/src/views/eam/device/techRepair/index.vue b/src/views/eam/device/techRepair/index.vue index 8ca2fb2..b6e1472 100644 --- a/src/views/eam/device/techRepair/index.vue +++ b/src/views/eam/device/techRepair/index.vue @@ -15,7 +15,7 @@ }" v-model:pageSize="tableObject.pageSize" v-model:currentPage="tableObject.currentPage" v-model:sort="tableObject.sort"> diff --git a/src/views/eam/device/techmaintenancejob/index.vue b/src/views/eam/device/techmaintenancejob/index.vue index ff00409..cd8c0e5 100644 --- a/src/views/eam/device/techmaintenancejob/index.vue +++ b/src/views/eam/device/techmaintenancejob/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > @@ -694,7 +694,7 @@ const openForm = async (type: string, row?: any) => { }).value = 'TECH' } if(type == 'update'){ - row.classes = String(row.classes) + row.classes = String(row.classes||row.classes==0?row.classes:'') } tableData.value = [] // 重置明细数据 await DeviceAccountsApi.getDeviceAccountsNoPage({}).then(res => { @@ -708,6 +708,7 @@ const openFormSec = async (type: string, row?: any) => { tableData.value = [] // 重置明细数据 newRow.value = { ...row } newRow.value.turnType = '0' + newRow.value.classes = String(row.classes||row.classes==0?row.classes:'') DeviceMaintenanceMainSecRules.classes = [{ required: false }] DeviceMaintenanceMainSecRules.faultType = [{ required: false }] DeviceMaintenanceMainSecRules.describes = [{ required: false }] diff --git a/src/views/eam/item/itemAccounts/index.vue b/src/views/eam/item/itemAccounts/index.vue index 742d1ec..c8b7085 100644 --- a/src/views/eam/item/itemAccounts/index.vue +++ b/src/views/eam/item/itemAccounts/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts b/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts index 916b737..6002795 100644 --- a/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts +++ b/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts @@ -12,6 +12,9 @@ export const ItemLocationReplaceRules = reactive({ locationNumber: [required], itemNumber: [required], oldLocationNumber: [required], + ranks: [ + { max: 2000, message: '不得超过2000个字符', trigger: 'blur' }, + ] }) export const ItemLocationReplace = useCrudSchemas(reactive([ @@ -114,20 +117,18 @@ export const ItemLocationReplace = useCrudSchemas(reactive([ } }, { - label: '变更时间', - field: 'createTime', + label: '描述', + field: 'ranks', sort: 'custom', - formatter: dateFormatter, - isSearch: false, - search: { - component: 'DatePicker', + form: { + component: 'Input', componentProps: { - valueFormat: 'YYYY-MM-DD HH:mm:ss', - type: 'daterange', - defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + type: 'textarea', } }, - isForm: false, + table: { + width: 170 + }, }, { label: '变更人', @@ -141,6 +142,22 @@ export const ItemLocationReplace = useCrudSchemas(reactive([ width: 170 }, }, + { + label: '变更时间', + field: 'createTime', + 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')] + } + }, + isForm: false, + }, // { // label: '操作', // field: 'action', diff --git a/src/views/eam/item/itemMaintenance/index.vue b/src/views/eam/item/itemMaintenance/index.vue index a54d483..24f72e3 100644 --- a/src/views/eam/item/itemMaintenance/index.vue +++ b/src/views/eam/item/itemMaintenance/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/mold/moldAccounts/index.vue b/src/views/eam/mold/moldAccounts/index.vue index 633dc55..33961f8 100644 --- a/src/views/eam/mold/moldAccounts/index.vue +++ b/src/views/eam/mold/moldAccounts/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/mold/moldAccounts/moldAccounts.data.ts b/src/views/eam/mold/moldAccounts/moldAccounts.data.ts index 1b04122..77825b0 100644 --- a/src/views/eam/mold/moldAccounts/moldAccounts.data.ts +++ b/src/views/eam/mold/moldAccounts/moldAccounts.data.ts @@ -227,6 +227,9 @@ export const MoldAccounts = useCrudSchemas(reactive([ type: 'datetime', valueFormat: 'x' } + }, + detail:{ + dateFormat:'YYYY-MM-DD' } }, { diff --git a/src/views/eam/mold/moldMaintainPlan/index.vue b/src/views/eam/mold/moldMaintainPlan/index.vue index 0898385..9e7d2ba 100644 --- a/src/views/eam/mold/moldMaintainPlan/index.vue +++ b/src/views/eam/mold/moldMaintainPlan/index.vue @@ -28,7 +28,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/mold/moldRepair/index.vue b/src/views/eam/mold/moldRepair/index.vue index 09c0d09..3342c61 100644 --- a/src/views/eam/mold/moldRepair/index.vue +++ b/src/views/eam/mold/moldRepair/index.vue @@ -15,7 +15,7 @@ }" v-model:pageSize="tableObject.pageSize" v-model:currentPage="tableObject.currentPage" v-model:sort="tableObject.sort"> diff --git a/src/views/eam/mold/moldSpotInspectionRecordMain/index.vue b/src/views/eam/mold/moldSpotInspectionRecordMain/index.vue index bc74601..c0c4a0c 100644 --- a/src/views/eam/mold/moldSpotInspectionRecordMain/index.vue +++ b/src/views/eam/mold/moldSpotInspectionRecordMain/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/mold/moldinspectionjob/index.vue b/src/views/eam/mold/moldinspectionjob/index.vue index da6e095..f02c9f8 100644 --- a/src/views/eam/mold/moldinspectionjob/index.vue +++ b/src/views/eam/mold/moldinspectionjob/index.vue @@ -23,7 +23,7 @@ v-model:sort="tableObject.sort" > @@ -547,7 +547,7 @@ const detailSubmitForm = async (formType, data, formRef, tableList) => { estimatedMinutes: data.estimatedMinutes, actualMinutes: data.actualMinutes, chargePeoples: data.chargePeoples.join(','), - completionTime: data.completionTime, + completionTime: data.completionTime?data.completionTime:null, engineer: data.engineer, uncompleted: data.uncompleted, itemNumbers: data.itemNumbers, diff --git a/src/views/eam/mold/moldinspectionjob/moldInspectionMain.data.ts b/src/views/eam/mold/moldinspectionjob/moldInspectionMain.data.ts index f4a4fba..c7a07f0 100644 --- a/src/views/eam/mold/moldinspectionjob/moldInspectionMain.data.ts +++ b/src/views/eam/mold/moldinspectionjob/moldInspectionMain.data.ts @@ -20,6 +20,7 @@ const moldListAll = await MoldAccountsApi.getMoldAccountsAllNoPage({}) const moldListByFactory = moldListAll.filter(item => item.factoryAreaNumber == userStore.userSelfInfo.deptId) const userList = await selecUserByType({ classType: 'MOLD', factoryAreaNumber: '', flag: 1 }) const dutyUserList = await selecUserByType({ classType: 'MOLD', factoryAreaNumber: '', flag: null }) +dutyUserList.push({ name:userStore.user.nickname,id:userStore.user.id,deptId:userStore.userSelfInfo.deptId }) const engineerList = await selecUserByType({ classType: 'MOLD', factoryAreaNumber: '', flag: 2}) const repairList = await MoldMaintenanceMainApi.getMoldMainTempList('MOLD') // 表单校验 diff --git a/src/views/eam/mold/moldmaintainjob/index.vue b/src/views/eam/mold/moldmaintainjob/index.vue index 1d0249f..639dd9b 100644 --- a/src/views/eam/mold/moldmaintainjob/index.vue +++ b/src/views/eam/mold/moldmaintainjob/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > diff --git a/src/views/eam/mold/moldmaintenancejob/index.vue b/src/views/eam/mold/moldmaintenancejob/index.vue index 21ff132..75a0009 100644 --- a/src/views/eam/mold/moldmaintenancejob/index.vue +++ b/src/views/eam/mold/moldmaintenancejob/index.vue @@ -32,7 +32,7 @@ v-model:sort="tableObject.sort" > @@ -548,7 +548,7 @@ const buttonTableClick = async (val, row) => { const openForm = async (type: string, row?: any) => { if(type == 'update'){ - row.classes = String(row.classes) + row.classes = String(row.classes||row.classes==0?row.classes:'') } await MoldAccountsApi.getMoldAccountsNoPage({}).then(res => { MoldMaintenanceMain.allSchemas.formSchema.find(item => { @@ -913,6 +913,7 @@ const openFormSec = async (type: string, row?: any) => { tableData.value = [] // 重置明细数据 newRow.value = { ...row } newRow.value.turnType = '0' + newRow.value.classes = String(row.classes||row.classes==0?row.classes:'') MoldMaintenanceMainSecRules.classes = [{ required: false }] MoldMaintenanceMainSecRules.faultType = [{ required: false }] MoldMaintenanceMainSecRules.describes = [{ required: false }] @@ -1065,7 +1066,7 @@ const onChangeSec = (field, cur, item,formRefSec) => { setV['deviceNumber'] = newRow.value.deviceNumber setV['type'] = newRow.value.type formRefSec.setValues(setV) - MoldMaintenanceMainSecRules.maintenance = [{ required: true }] + MoldMaintenanceMainSecRules.maintenance = [{ required: true, message: '维修人不能为空', trigger: 'blur' },] MoldMaintenanceMainSec.allSchemas.formSchema.find(item => { return item.field == 'type' }).componentProps.disabled = true @@ -1106,8 +1107,8 @@ const onChangeSec = (field, cur, item,formRefSec) => { formRefSec.setValues(setV) MoldMaintenanceMainSec.allSchemas.formSchema.find(item => { return item.field == 'maintenance' - }).componentProps.disabled = false - MoldMaintenanceMainSecRules.maintenance = [{ required: true }] + }).componentProps.disabled = false + MoldMaintenanceMainSecRules.maintenance = [{ required: true, message: '维修人不能为空', trigger: 'blur' },] MoldMaintenanceMainSec.allSchemas.formSchema.find(item => { return item.field == 'maintenance' }).componentProps.options = res diff --git a/src/views/eam/mold/moldmaintenancejob/moldMaintenanceMain.data.ts b/src/views/eam/mold/moldmaintenancejob/moldMaintenanceMain.data.ts index ef29868..4aa0acd 100644 --- a/src/views/eam/mold/moldmaintenancejob/moldMaintenanceMain.data.ts +++ b/src/views/eam/mold/moldmaintenancejob/moldMaintenanceMain.data.ts @@ -8,6 +8,8 @@ import * as ItemApi from '@/api/eam/basic/item' import * as UserApi from '@/api/system/user' import { getStrDictOptions } from '@/utils/dict' import { dateFormatter } from '@/utils/formatTime' +import Message from '@/layout/components/Message/src/Message.vue' +import { t } from '@/hooks/web/useI18n' const userListAll = await UserApi.getSimpleUserList() console.log(userListAll) const userStore = useUserStore() @@ -546,19 +548,19 @@ export const MoldMaintenanceDetail = useCrudSchemas(reactive([ field: 'maintenances', sort: 'custom', isDetail: false, - // formatter: (_: Recordable, __: TableColumn, cellValue) => { - // let cellValueList = [] - // if (Array.isArray(cellValue)) { - // cellValueList = cellValue - // } else { - // cellValueList = cellValue ? cellValue.split(',') : []; - // } - // // const cellValueList = cellValue ? cellValue.split(',') : []; - // return userListAll - // .filter(item => cellValueList.includes(item.id.toString())) - // .map(item => item.nickname) - // .join(','); - // }, + formatter: (_: Recordable, __: TableColumn, cellValue) => { + let cellValueList = [] + if (Array.isArray(cellValue)) { + cellValueList = cellValue + } else { + cellValueList = cellValue ? cellValue.split(',') : []; + } + // const cellValueList = cellValue ? cellValue.split(',') : []; + return userListAll + .filter(item => cellValueList.includes(item.id.toString())) + .map(item => item.nickname) + .join(','); + }, isTable:false, tableForm: { type: 'Select', @@ -663,11 +665,19 @@ export const MoldMaintenanceDetail = useCrudSchemas(reactive([ ])) // 表单校验 export const MoldMaintenanceDetailRules = reactive({ - describes: [required], - describes1: [required], - workOut: [required], - maintenance: [required], - itemNumbers: [required], + describes: [ + required, + { max: 200, message: '不得超过200个字符', trigger: 'blur' }, + ], + describes1: [ + required, + { max: 200, message: '不得超过200个字符', trigger: 'blur' }, + ], + workOut: [ + required, + { max: 200, message: '不得超过200个字符', trigger: 'blur' }, + ], + maintenances: [required], }) @@ -677,7 +687,10 @@ export const MoldMaintenanceMainSecRules = reactive({ requestNumber: [required], deviceNumber: [required], factoryAreaNumber: [required], - maintenance: [required], + maintenance: [ + { + required: true, Message: '维修人不能为空', trigger: 'blur' + }], turnType: [required], type: [required], classes: [required],