You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2542 lines
60 KiB
2542 lines
60 KiB
import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
|
|
import { dateFormatter } from '@/utils/formatTime'
|
|
import * as getRequestsettingApi from '@/api/wms/requestsetting/index'
|
|
|
|
import * as WorkshopApi from '@/api/wms/workshop'
|
|
import { Workshop } from '@/views/wms/basicDataManage/factoryModeling/workshop/workshop.data'
|
|
|
|
import * as ProductionlineApi from '@/api/wms/productionline'
|
|
import { Productionline } from '@/views/wms/basicDataManage/factoryModeling/productionline/productionline.data'
|
|
|
|
import * as WorkstationApi from '@/api/wms/workstation'
|
|
|
|
import * as BalanceApi from '@/api/wms/balance'
|
|
import { Balance } from '@/views/wms/inventoryManage/balance/balance.data'
|
|
|
|
import * as ItempackagingApi from '@/api/wms/itempackage'
|
|
import { Itempackaging } from '@/views/wms/basicDataManage/itemManage/itempackage/itempackage.data'
|
|
|
|
import * as SupplieritemApi from '@/api/wms/supplieritem'
|
|
import { Supplieritem } from '@/views/wms/basicDataManage/supplierManage/supplieritem/supplieritem.data'
|
|
|
|
import { useUserStore } from '@/store/modules/user'
|
|
import { TableColumn } from '@/types/table'
|
|
|
|
import * as InspectionQ3Api from '@/api/qms/inspectionQ3/inspectionQ3Main'
|
|
import { InspectionQ3Main } from '@/views/qms/inspectionQ3/inspectionQ3.data'
|
|
|
|
import { QadCostcentre } from '@/views/wms/basicDataManage/subject/qadCostcentre/qadCostcentre.data'
|
|
import * as QadCostcentreApi from '@/api/wms/qadCostcentre/index'
|
|
|
|
import { QadProject } from '@/views/wms/basicDataManage/subject/qadProject/qadProject.data'
|
|
import * as QadProjectApi from '@/api/wms/qadProject'
|
|
|
|
import * as SubjectAccountApi from '@/api/wms/subjectAccount'
|
|
import { SubjectAccount } from '@/views/wms/basicDataManage/subject/subjectAccount/subjectAccount.data'
|
|
|
|
import { Location } from '@/views/wms/basicDataManage/factoryModeling/location/location.data'
|
|
import { dateFormatter, dateFormatter2 } from '@/utils/formatTime'
|
|
|
|
import * as confgiApi from '@/api/infra/config'
|
|
|
|
// import * as LocationApi from '@/api/wms/location'
|
|
// import { Location } from '@/views/wms/basicDataManage/factoryModeling/location/location.data'
|
|
|
|
const { t } = useI18n() // 国际化
|
|
|
|
// 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值
|
|
const queryParams = {
|
|
pageSize: 10,
|
|
pageNo: 1,
|
|
code: 'MaterialReturnRequest'
|
|
}
|
|
const data = await getRequestsettingApi.getRequestsettingPage(queryParams)
|
|
const requestsettingData = data?.list[0] || {}
|
|
|
|
//console.log(34, requestsettingData)
|
|
const userStore = useUserStore()
|
|
const userDept = userStore.userSelfInfo.dept
|
|
// id 转str 否则form回显匹配不到
|
|
userDept.id = userDept.id.toString()
|
|
const userDeptArray: any = [userDept]
|
|
|
|
const confgiDataOne = await confgiApi.queryByKey("WorkStation-IN")
|
|
const confgiDataTwo = await confgiApi.queryByKey("WorkStation-OUT")
|
|
const BalanceCopy = useCrudSchemas(
|
|
reactive<CrudSchema[]>([
|
|
{
|
|
label: '物料代码',
|
|
field: 'itemCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '物料名称',
|
|
field: 'itemName',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '库存数量',
|
|
field: 'qty',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'InputNumber'
|
|
}
|
|
},
|
|
{
|
|
label: '库位代码',
|
|
field: 'locationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '物料描述1',
|
|
field: 'itemDesc1',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
hiddenSearchHigh: true,// 高级筛选中隐藏
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '物料描述2',
|
|
field: 'itemDesc2',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
hiddenSearchHigh: true,// 高级筛选中隐藏
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '物料类型',
|
|
field: 'itemType',
|
|
sort: 'custom',
|
|
dictType: DICT_TYPE.ITEM_TYPE,
|
|
dictClass: 'string',
|
|
isSearch: true,
|
|
table: {
|
|
width: 100
|
|
}
|
|
},
|
|
{
|
|
label: '批次',
|
|
field: 'batch',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '供应商批次',
|
|
field: 'altBatch',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: false
|
|
},
|
|
{
|
|
label: '包装号',
|
|
field: 'packingNumber',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '包装规格',
|
|
field: 'packUnit',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '包装数量',
|
|
field: 'packQty',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '创建者',
|
|
field: 'creator',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '计量单位',
|
|
field: 'uom',
|
|
dictType: DICT_TYPE.UOM,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '库存状态',
|
|
field: 'inventoryStatus',
|
|
dictType: DICT_TYPE.INVENTORY_STATUS,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '库区类型',
|
|
field: 'areaType',
|
|
sort: 'custom',
|
|
dictType: DICT_TYPE.AREA_TYPE,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
|
|
{
|
|
label: '仓库代码',
|
|
field: 'warehouseCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '库位组代码',
|
|
field: 'locationGroupCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '库区代码',
|
|
field: 'areaCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '到货日期',
|
|
field: 'arriveDate',
|
|
isTable: true,
|
|
formatter: dateFormatter2,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'date',
|
|
dateFormat: 'YYYY-MM-DD',
|
|
valueFormat: 'x'
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '生产日期',
|
|
field: 'produceDate',
|
|
isTable: true,
|
|
formatter: dateFormatter2,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'date',
|
|
dateFormat: 'YYYY-MM-DD',
|
|
valueFormat: 'x'
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '失效日期',
|
|
field: 'expireDate',
|
|
isTable: true,
|
|
formatter: dateFormatter2,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'date',
|
|
dateFormat: 'YYYY-MM-DD',
|
|
valueFormat: 'x'
|
|
}
|
|
}
|
|
},
|
|
|
|
{
|
|
label: '是否冻结',
|
|
field: 'frozen',
|
|
dictType: DICT_TYPE.TRUE_FALSE,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'Switch',
|
|
value: 'TRUE',
|
|
componentProps: {
|
|
inactiveValue: 'FALSE',
|
|
activeValue: 'TRUE'
|
|
}
|
|
}
|
|
},
|
|
|
|
{
|
|
label: '最后事务号',
|
|
field: 'lastTransNumber',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '创建时间',
|
|
field: 'createTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x'
|
|
}
|
|
},
|
|
isForm: false,
|
|
isSearch: true,
|
|
search: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
valueFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
type: 'datetimerange',
|
|
defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')]
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '最后更新时间',
|
|
field: 'updateTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x'
|
|
}
|
|
},
|
|
isForm: false,
|
|
isTable: true
|
|
},
|
|
{
|
|
label: '最后更新者',
|
|
field: 'updater',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isForm: false,
|
|
isTable: true
|
|
}
|
|
])
|
|
)
|
|
|
|
|
|
/**
|
|
* @returns {Array} 工位
|
|
*/
|
|
export const Workstation = useCrudSchemas(reactive<CrudSchema[]>([
|
|
{
|
|
label: '代码',
|
|
field: 'code',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150,
|
|
fixed: 'left'
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '名称',
|
|
field: 'name',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '原料库位',
|
|
field: 'rawLocationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择库位代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '库位信息', // 查询弹窗标题
|
|
searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
|
|
searchPage: WorkstationApi.selectAreaTypeToLocation, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},
|
|
{
|
|
key: 'areaType',
|
|
value: confgiDataOne.areaType,
|
|
isMainValue: false
|
|
}],
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '成品库位',
|
|
field: 'fgLocationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择库位代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '库位信息', // 查询弹窗标题
|
|
searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
|
|
searchPage: WorkstationApi.selectAreaTypeToLocation, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},
|
|
{
|
|
key: 'areaType',
|
|
value: confgiDataTwo.areaType,
|
|
isMainValue: false
|
|
}],
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
// {
|
|
// label: '类型',
|
|
// field: 'type',
|
|
// dictType: DICT_TYPE.WORK_STATION_TYPE,
|
|
// dictClass: 'string',
|
|
// isTable: true,
|
|
// sort: 'custom',
|
|
// table: {
|
|
// width: 150
|
|
// },
|
|
// },
|
|
{
|
|
label: '车间代码',
|
|
field: 'workshopCode',
|
|
sort: 'custom',
|
|
isSearch: true,
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择车间代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '车间信息', // 查询弹窗标题
|
|
searchAllSchemas: Workshop.allSchemas, // 查询弹窗所需类
|
|
searchPage: WorkshopApi.getWorkshopPage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}],
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '生产线代码',
|
|
field: 'productionLineCode',
|
|
sort: 'custom',
|
|
isSearch: true,
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择生产线代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '生产线信息', // 查询弹窗标题
|
|
searchAllSchemas: Productionline.allSchemas, // 查询弹窗所需类
|
|
searchPage: ProductionlineApi.getProductionlinePage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key:'workshopCode',
|
|
value:'workshopCode',
|
|
message: '请填写车间代码!',
|
|
isMainValue: true
|
|
},{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}],
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
|
|
{
|
|
label: '是否可用',
|
|
field: 'available',
|
|
dictType: DICT_TYPE.TRUE_FALSE,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'Switch',
|
|
value: 'TRUE',
|
|
componentProps: {
|
|
inactiveValue: 'FALSE',
|
|
activeValue: 'TRUE'
|
|
}
|
|
},
|
|
},
|
|
{
|
|
label: '生效时间',
|
|
field: 'activeTime',
|
|
isTable: true,
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: {width:'100%'},
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x',
|
|
}
|
|
},
|
|
},
|
|
{
|
|
label: '失效时间',
|
|
field: 'expireTime',
|
|
isTable: true,
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: {width:'100%'},
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x',
|
|
}
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
},
|
|
{
|
|
label: '创建时间',
|
|
field: 'createTime',
|
|
isForm: false,
|
|
table: {
|
|
width: 180
|
|
},
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat : 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: {width:'100%'},
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x',
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '创建者',
|
|
field: 'creator',
|
|
table: {
|
|
width: 130
|
|
},
|
|
isForm: false,
|
|
isTable: true
|
|
},
|
|
{
|
|
label: '最后更新时间',
|
|
field: 'updateTime',
|
|
sort: 'custom',
|
|
isDetail: true,
|
|
isForm: false,
|
|
isTable: true,
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
table: {
|
|
width: 180
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: {width:'100%'},
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x',
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '最后更新者',
|
|
field: 'updater',
|
|
isDetail: true,
|
|
isForm: false,
|
|
isTable: true,
|
|
table: {
|
|
width: 150
|
|
}
|
|
},
|
|
{
|
|
label: '备注',
|
|
field: 'remark',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
},
|
|
{
|
|
label: '操作',
|
|
field: 'action',
|
|
isDetail: false,
|
|
isForm: false ,
|
|
table: {
|
|
width: 150,
|
|
fixed: 'right'
|
|
}
|
|
}
|
|
]))
|
|
|
|
|
|
/**
|
|
* @returns {Array} 生产退料申请主表
|
|
*/
|
|
export const ProductionscrapRequestMain = useCrudSchemas(
|
|
reactive<CrudSchema[]>([
|
|
{
|
|
label: '单据号',
|
|
field: 'number',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180,
|
|
fixed: 'left'
|
|
},
|
|
isForm: false,
|
|
isSearch: true
|
|
},
|
|
{
|
|
label: '状态',
|
|
field: 'status',
|
|
dictType: DICT_TYPE.REQUEST_STATUS,
|
|
dictClass: 'string',
|
|
isSearch: true,
|
|
isTable: true,
|
|
isForm: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
value: '1',
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: 'Q3通知单号',
|
|
field: 'q3Number',
|
|
sort: 'custom',
|
|
isSearch: false,
|
|
isDetail: true,
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true, // multiple: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择Q3通知单号', // 输入框占位文本
|
|
searchField: 'number', // 查询弹窗赋值字段
|
|
searchTitle: 'Q3通知单号', // 查询弹窗标题
|
|
searchAllSchemas: InspectionQ3Main.allSchemas, // 查询弹窗所需类
|
|
searchPage: InspectionQ3Api.getInspectionQ3MainPage, // 查询弹窗所需分页方法
|
|
searchCondition: [
|
|
{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},
|
|
{
|
|
key: 'status',
|
|
value: '0',
|
|
isMainValue: false
|
|
}
|
|
],
|
|
verificationParams: [
|
|
{
|
|
key: 'number',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true
|
|
}
|
|
] // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '报废原因',
|
|
field: 'lineScrapReason',
|
|
dictType: DICT_TYPE.LINE_SCRAP_REASON,
|
|
dictClass: 'string',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
filterable: true
|
|
}
|
|
},
|
|
tableForm: {
|
|
type: 'Select',
|
|
filterable: true
|
|
}
|
|
},
|
|
{
|
|
label: '成本中心代码',
|
|
field: 'costCenterCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
enterSearch: true,
|
|
isInpuFocusShow: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择成本中心代码',
|
|
searchField: 'costcentreCode',
|
|
searchTitle: '成本中心代码',
|
|
searchAllSchemas: QadCostcentre.allSchemas,
|
|
searchPage: QadCostcentreApi.getQadCostcentrePage,
|
|
verificationParams: [{
|
|
key: 'costcentreCode',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择成本中心代码', // 输入框占位文本
|
|
searchField: 'costcentreCode', // 查询弹窗赋值字段
|
|
searchTitle: '成本中心代码', // 查询弹窗标题
|
|
searchAllSchemas: QadCostcentre.allSchemas, // 查询弹窗所需类
|
|
searchPage: QadCostcentreApi.getQadCostcentrePage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}],
|
|
verificationParams: [{
|
|
key: 'costcentreCode',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '成本中心类型',
|
|
field: 'costCenterType',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isForm:true,
|
|
isTable:false,
|
|
isTableForm:false,
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
},
|
|
},
|
|
{
|
|
label: '原因代码',
|
|
field: 'reasonCodeRequisition',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
enterSearch: true,
|
|
isInpuFocusShow: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择成领用原因代码',
|
|
searchField: 'code',
|
|
searchTitle: '领用原因代码',
|
|
searchAllSchemas: SubjectAccount.allSchemas,
|
|
searchPage: SubjectAccountApi.getSubjectAccountPage,
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'costcentreType',
|
|
value: 'costCenterType',
|
|
message: '成本中心类型不能为空!',
|
|
isMainValue: true
|
|
}],
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择领用原因代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '领用原因代码', // 查询弹窗标题
|
|
searchAllSchemas: SubjectAccount.allSchemas, // 查询弹窗所需类
|
|
searchPage: SubjectAccountApi.getSubjectAccountPage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'costcentreType',
|
|
value: 'costCenterType',
|
|
message: '成本中心类型不能为空!',
|
|
isMainValue: true
|
|
}],
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '车间',
|
|
field: 'workshopCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isSearch: true,
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择车间代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '车间信息', // 查询弹窗标题
|
|
searchAllSchemas: Workshop.allSchemas, // 查询弹窗所需类
|
|
searchPage: WorkshopApi.getWorkshopPage, // 查询弹窗所需分页方法
|
|
searchCondition: [
|
|
{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}
|
|
],
|
|
verificationParams: [
|
|
{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true
|
|
}
|
|
] // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '生产线代码',
|
|
field: 'productionLineCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择生产线代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '生产线信息', // 查询弹窗标题
|
|
searchAllSchemas: Productionline.allSchemas, // 查询弹窗所需类
|
|
searchPage: ProductionlineApi.getProductionlinePage, // 查询弹窗所需分页方法
|
|
searchCondition: [
|
|
{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},
|
|
{
|
|
key: 'workshopCode',
|
|
value: 'workshopCode',
|
|
message: '请选择车间信息!', // 当前置条件为空时 弹出信息提示
|
|
isMainValue: true
|
|
}
|
|
],
|
|
verificationParams: [
|
|
{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true
|
|
}
|
|
] // 失去焦点校验参数
|
|
}
|
|
},
|
|
tableForm: {
|
|
isInpuFocusShow: true,
|
|
searchListPlaceholder: '请选择生产线代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '生产线信息', // 查询弹窗标题
|
|
searchAllSchemas: Productionline.allSchemas, // 查询弹窗所需类
|
|
searchPage: ProductionlineApi.getProductionlinePage, // 查询弹窗所需分页方法
|
|
searchCondition: [
|
|
{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},
|
|
{
|
|
key: 'workshopCode',
|
|
value: 'workshopCode',
|
|
message: '请选择车间信息!', // 当前置条件为空时 弹出信息提示
|
|
isMainValue: true
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
// HL-6202 还是子表数据,只是放在form中用来新增选择数据
|
|
label: '项目代码',
|
|
field: 'projectCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isDetail:false,
|
|
isTable:false,
|
|
isForm:true,
|
|
tableForm: {
|
|
enterSearch: true,
|
|
isInpuFocusShow: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择QAD项目信息',
|
|
searchField: 'projectCode',
|
|
searchTitle: '选择项目代码',
|
|
searchAllSchemas: QadProject.allSchemas,
|
|
searchPage: QadProjectApi.getQadProjectPage,
|
|
searchCondition: [
|
|
{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}
|
|
],
|
|
verificationParams: [{
|
|
key: 'projectCode',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择QAD项目信息', // 输入框占位文本
|
|
searchField: 'projectCode', // 查询弹窗赋值字段
|
|
searchTitle: '选择项目代码', // 查询弹窗标题
|
|
searchAllSchemas: QadProject.allSchemas, // 查询弹窗所需类
|
|
searchPage: QadProjectApi.getQadProjectPage, // 查询弹窗所需分页方法
|
|
searchCondition: [
|
|
{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}
|
|
],
|
|
verificationParams: [{
|
|
key: 'projectCode',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '申请时间',
|
|
field: 'requestTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
isTable: false,
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x'
|
|
}
|
|
},
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '截止时间',
|
|
field: 'dueTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
isForm:false,
|
|
isTableForm:false,
|
|
isTable: false,
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x'
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '从库区类型范围',
|
|
field: 'fromAreaTypes',
|
|
dictType: DICT_TYPE.AREA_TYPE,
|
|
dictClass: 'string',
|
|
isTable: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '到库区类型范围',
|
|
field: 'toAreaTypes',
|
|
dictType: DICT_TYPE.AREA_TYPE,
|
|
dictClass: 'string',
|
|
isSearch: true,
|
|
isTable: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '从库区代码范围',
|
|
field: 'fromAreaCodes',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '到库区代码范围',
|
|
field: 'toAreaCodes',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '从仓库代码',
|
|
field: 'fromWarehouseCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '到仓库代码',
|
|
field: 'toWarehouseCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '主备注',
|
|
field: 'mainRemark',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form:{
|
|
componentProps:{
|
|
maxlength:50,
|
|
showWordLimit:true,
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '业务类型',
|
|
field: 'businessType',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '部门',
|
|
field: 'departmentCode',
|
|
sort: 'custom',
|
|
isForm: false,
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
formatter: (_: Recordable, __: TableColumn, cellValue: number) => {
|
|
return userDeptArray.find((account) => account.id == cellValue)?.name
|
|
},
|
|
form: {
|
|
value: userDept.id,
|
|
component: 'Select',
|
|
api: () => userDeptArray,
|
|
componentProps: {
|
|
disabled: true,
|
|
optionsAlias: {
|
|
labelField: 'name',
|
|
valueField: 'id'
|
|
}
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '自动提交',
|
|
field: 'autoCommit',
|
|
dictType: DICT_TYPE.TRUE_FALSE,
|
|
dictClass: 'string',
|
|
isTable: false,
|
|
isForm: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'Switch',
|
|
value: requestsettingData.autoCommit,
|
|
componentProps: {
|
|
inactiveValue: 'FALSE',
|
|
activeValue: 'TRUE',
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '自动通过',
|
|
field: 'autoAgree',
|
|
dictType: DICT_TYPE.TRUE_FALSE,
|
|
dictClass: 'string',
|
|
isTable: false,
|
|
isForm: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'Switch',
|
|
value: requestsettingData.autoAgree,
|
|
componentProps: {
|
|
inactiveValue: 'FALSE',
|
|
activeValue: 'TRUE',
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '自动执行',
|
|
field: 'autoExecute',
|
|
dictType: DICT_TYPE.TRUE_FALSE,
|
|
dictClass: 'string',
|
|
isTable: false,
|
|
isForm: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'Switch',
|
|
value: requestsettingData.autoExecute,
|
|
componentProps: {
|
|
inactiveValue: 'FALSE',
|
|
activeValue: 'TRUE',
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '直接生成记录',
|
|
field: 'directCreateRecord',
|
|
dictType: DICT_TYPE.TRUE_FALSE,
|
|
dictClass: 'string',
|
|
isForm: false,
|
|
isTable: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'Switch',
|
|
value: requestsettingData.directCreateRecord,
|
|
componentProps: {
|
|
inactiveValue: 'FALSE',
|
|
activeValue: 'TRUE',
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '创建时间',
|
|
field: 'createTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x'
|
|
}
|
|
},
|
|
isTable: false,
|
|
isForm: false,
|
|
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')]
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '创建者',
|
|
field: 'creator',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '最后更新时间',
|
|
field: 'updateTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
isTable: false,
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: { width: '100%' },
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x'
|
|
}
|
|
},
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '最后更新者',
|
|
field: 'updater',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '操作',
|
|
field: 'action',
|
|
isDetail: false,
|
|
isForm: false,
|
|
table: {
|
|
width: 300,
|
|
fixed: 'right'
|
|
},
|
|
isTable: false
|
|
}
|
|
])
|
|
)
|
|
|
|
//表单校验
|
|
export const ProductionscrapRequestMainRules = reactive({
|
|
projectCode: [
|
|
{ required: false, message: '请输入项目代码', trigger: 'blur' }
|
|
],
|
|
departmentCode: [
|
|
{ required: true, message: '请输入部门', trigger: 'blur' }
|
|
],
|
|
remark: [
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' }
|
|
],
|
|
autoCommit: [
|
|
{ required: true, message: '请选择是否自动提交', trigger: 'change' }
|
|
],
|
|
autoAgree: [
|
|
{ required: true, message: '请选择是否自动通过', trigger: 'change' }
|
|
],
|
|
autoExecute: [
|
|
{ required: true, message: '请选择是否自动执行', trigger: 'change' }
|
|
],
|
|
directCreateRecord: [
|
|
{ required: true, message: '请选择是否跳过任务直接生成记录', trigger: 'change' }
|
|
],
|
|
workshopCode: [
|
|
{ required: true, message: '请选择车间', trigger: 'change' }
|
|
],
|
|
productionLineCode: [
|
|
{ required: false, message: '请选择生产线代码', trigger: 'change' }
|
|
],
|
|
lineScrapReason: [
|
|
{ required: true, message: '请选择报废原因', trigger: 'change' }
|
|
],
|
|
costCenterCode: [
|
|
{ required: true, message: '请选择成本中心代码', trigger: 'change' }
|
|
],
|
|
reasonCodeRequisition: [
|
|
{ required: true, message: '请选择原因代码', trigger: 'change' }
|
|
],
|
|
})
|
|
|
|
/**
|
|
* @returns {Array} 生产退料申请子表
|
|
*/
|
|
export const ProductionscrapRequestDetail = useCrudSchemas(reactive<CrudSchema[]>([
|
|
{
|
|
label: '生产线代码',
|
|
field: 'productionLineCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
hiddenInMain: true,
|
|
isTableForm: false,
|
|
isForm:false,
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择生产线代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '生产线信息', // 查询弹窗标题
|
|
searchAllSchemas: Productionline.allSchemas, // 查询弹窗所需类
|
|
searchPage: ProductionlineApi.getProductionlinePage, // 查询弹窗所需分页方法
|
|
searchCondition:[{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'workshopCode',
|
|
value: 'workshopCode',
|
|
message: '请选择车间信息!', // 当前置条件为空时 弹出信息提示
|
|
isMainValue: true
|
|
}]
|
|
}
|
|
},
|
|
tableForm:{
|
|
isInpuFocusShow: true,
|
|
searchListPlaceholder: '请选择生产线代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '生产线信息', // 查询弹窗标题
|
|
searchAllSchemas: Productionline.allSchemas, // 查询弹窗所需类
|
|
searchPage: ProductionlineApi.getProductionlinePage, // 查询弹窗所需分页方法
|
|
searchCondition:[{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'workshopCode',
|
|
value: 'workshopCode',
|
|
message: '请选择车间信息!', // 当前置条件为空时 弹出信息提示
|
|
isMainValue: true
|
|
}]
|
|
},
|
|
},
|
|
{
|
|
label: '工位代码',
|
|
field: 'workStationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择工位代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '工位信息', // 查询弹窗标题
|
|
searchAllSchemas: Workstation.allSchemas, // 查询弹窗所需类
|
|
searchPage: WorkstationApi.getWorkstationPage, // 查询弹窗所需分页方法
|
|
searchCondition:[{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'workshopCode',
|
|
value: 'workshopCode',
|
|
message: '请选择车间信息!',
|
|
isMainValue: true
|
|
},{
|
|
key: 'productionLineCode',
|
|
value: 'productionLineCode',
|
|
message: '请选择生产线信息!',
|
|
isMainValue: true,
|
|
isOptional:true, // isMainValue=true情况,添加参数可选可空的判断
|
|
}],
|
|
|
|
|
|
}
|
|
},
|
|
tableForm:{
|
|
multiple:true,
|
|
disabled:true,
|
|
// isInpuFocusShow: true,
|
|
searchListPlaceholder: '请选择工位代码', // 输入框占位文本
|
|
searchField: 'code', // 查询弹窗赋值字段
|
|
searchTitle: '工位信息', // 查询弹窗标题
|
|
searchAllSchemas: Workstation.allSchemas, // 查询弹窗所需类
|
|
searchPage: WorkstationApi.getWorkstationPage, // 查询弹窗所需分页方法
|
|
searchCondition:[{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'workshopCode',
|
|
value: 'workshopCode',
|
|
message: '请选择车间信息!',
|
|
isMainValue: true
|
|
},{
|
|
key: 'productionLineCode',
|
|
value: 'productionLineCode',
|
|
message: '请选择生产线信息!',
|
|
isMainValue: true,
|
|
isOptional:true, // isMainValue=true情况,添加参数可选可空的判断
|
|
|
|
}],
|
|
verificationPage: WorkstationApi.getWorkstationByCodes, // 校验数去焦点输入是否正确的方法
|
|
isShowTableFormSearch: true,
|
|
isRepeat: true,//是否可以重复添加该条数据
|
|
verificationParams: [{
|
|
key: 'code',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
},
|
|
},
|
|
// {
|
|
// label: '目标库位',
|
|
// field: 'toLocationCode',
|
|
// sort: 'custom',
|
|
// tableForm: {
|
|
// multiple: true,//多选
|
|
// isInpuFocusShow: true, // 开启查询弹窗
|
|
// searchListPlaceholder: '请选择库位代码', // 输入框占位文本
|
|
// searchField: 'code', // 查询弹窗赋值字段
|
|
// searchTitle: '库位基础信息', // 查询弹窗标题
|
|
// searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
|
|
// searchPage: LocationApi.selectBusinessTypeOutLocation, // 查询弹窗所需分页方法
|
|
// searchCondition: [{
|
|
// key: 'businessType',
|
|
// value: 'ProductionScrap', // 线边原料报废
|
|
// isMainValue: false
|
|
// },
|
|
// {
|
|
// key: 'isIn',
|
|
// value: 'in',
|
|
// isMainValue: false
|
|
// }
|
|
// ]
|
|
// },
|
|
// form: {
|
|
// // labelMessage: '信息提示说明!!!',
|
|
// componentProps: {
|
|
// isSearchList: true, // 开启查询弹窗
|
|
// multiple: true,//多选
|
|
// searchListPlaceholder: '请选择库位代码', // 输入框占位文本
|
|
// searchField: 'code', // 查询弹窗赋值字段
|
|
// searchTitle: '库位基础信息', // 查询弹窗标题
|
|
// searchAllSchemas: Location.allSchemas, // 查询弹窗所需类
|
|
// searchPage: LocationApi.selectBusinessTypeOutLocation, // 查询弹窗所需分页方法
|
|
// searchCondition: [{
|
|
// key: 'businessType',
|
|
// value: 'ReturnToHold', // 隔离退料
|
|
// isMainValue: false
|
|
// },
|
|
// {
|
|
// key: 'isIn',
|
|
// value: 'in',
|
|
// isMainValue: false
|
|
// }]
|
|
// }
|
|
// }
|
|
// },
|
|
{
|
|
label: '原料库位',
|
|
field: 'fromLocationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
},
|
|
isDetail:false,
|
|
isTable:false,
|
|
isTableForm: true,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '物料代码',
|
|
field: 'itemCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择物料代码', // 输入框占位文本
|
|
searchField: 'itemCode', // 查询弹窗赋值字段
|
|
searchTitle: '库存余额信息', // 查询弹窗标题
|
|
searchAllSchemas: BalanceCopy.allSchemas, // 查询弹窗所需类
|
|
searchPage: BalanceApi.getBalancePage, // 查询弹窗所需分页方法
|
|
searchCondition:[
|
|
{
|
|
key: 'locationCode',
|
|
value: 'fromLocationCode',
|
|
message: '请填写原料库位!',
|
|
isMainValue: true
|
|
},
|
|
{
|
|
key: 'inventoryStatus',
|
|
value: 'OK',
|
|
isMainValue: false
|
|
}]
|
|
}
|
|
},
|
|
tableForm:{
|
|
isInpuFocusShow: true,
|
|
searchListPlaceholder: '请选择物料代码', // 输入框占位文本
|
|
searchField: 'itemCode', // 查询弹窗赋值字段
|
|
searchTitle: '库存余额信息', // 查询弹窗标题
|
|
searchAllSchemas: BalanceCopy.allSchemas, // 查询弹窗所需类
|
|
searchPage: BalanceApi.getBalancePage, // 查询弹窗所需分页方法
|
|
searchCondition:[
|
|
{
|
|
key: 'locationCode',
|
|
value: 'fromLocationCode',
|
|
message: '请填写原料库位!',
|
|
isMainValue: true
|
|
},
|
|
{
|
|
key: 'inventoryStatus',
|
|
value: 'OK',
|
|
isMainValue: false
|
|
},{
|
|
key: 'businessType',
|
|
value: 'ProductionScrap', // 合格退料
|
|
isMainValue: false
|
|
}]
|
|
},
|
|
},
|
|
{
|
|
label: '物料名称',
|
|
field: 'itemName',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '物料描述1',
|
|
field: 'itemDesc1',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
hiddenInMain: true,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '物料描述2',
|
|
field: 'itemDesc2',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
hiddenInMain: true,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '批次',
|
|
field: 'batch',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '数量',
|
|
field: 'qty',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
form: {
|
|
component: 'InputNumber',
|
|
componentProps: {
|
|
min: 0,
|
|
precision: 2
|
|
}
|
|
},
|
|
tableForm: {
|
|
type: 'InputNumber',
|
|
min: 0,
|
|
precision: 2,
|
|
// maxField:'maxQty'
|
|
}
|
|
},
|
|
{
|
|
label: '计量单位',
|
|
field: 'uom',
|
|
dictType: DICT_TYPE.UOM,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 120
|
|
},
|
|
tableForm: {
|
|
type: 'Select',
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '单价',
|
|
field: 'singlePrice',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable:false,
|
|
form: {
|
|
component: 'InputNumber',
|
|
componentProps: {
|
|
disabled: true,
|
|
min: 0,
|
|
precision: 2,
|
|
},
|
|
},
|
|
tableForm: {
|
|
disabled: true,
|
|
type: 'InputNumber',
|
|
min: 0,
|
|
precision: 2,
|
|
}
|
|
},
|
|
{
|
|
label: '金额',
|
|
field: 'amount',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable:false,
|
|
form: {
|
|
component: 'InputNumber',
|
|
componentProps: {
|
|
disabled:true,
|
|
min: 0,
|
|
precision: 2,
|
|
}
|
|
},
|
|
tableForm: {
|
|
type: 'InputNumber',
|
|
disabled:true,
|
|
min: 0,
|
|
precision: 2,
|
|
},
|
|
},
|
|
{
|
|
label: '库存状态',
|
|
field: 'inventoryStatus',
|
|
dictType: DICT_TYPE.INVENTORY_STATUS,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
isTableForm: false,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
type: 'Select',
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '来源库位',
|
|
field: 'fromLocationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '从货主',
|
|
field: 'fromOwnerCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable:false,
|
|
hiddenInMain: true,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '到货主',
|
|
field: 'toOwnerCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable:false,
|
|
hiddenInMain: true,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
//HL-6202 还是子表数据
|
|
label: '项目代码',
|
|
field: 'projectCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm:false,
|
|
tableForm: {
|
|
enterSearch: true,
|
|
isInpuFocusShow: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择QAD项目信息',
|
|
searchField: 'projectCode',
|
|
searchTitle: '选择项目代码',
|
|
searchAllSchemas: QadProject.allSchemas,
|
|
searchPage: QadProjectApi.getQadProjectPage,
|
|
verificationParams: [{
|
|
key: 'projectCode',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
enterSearch: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择QAD项目信息', // 输入框占位文本
|
|
searchField: 'projectCode', // 查询弹窗赋值字段
|
|
searchTitle: '选择项目代码', // 查询弹窗标题
|
|
searchAllSchemas: QadProject.allSchemas, // 查询弹窗所需类
|
|
searchPage: QadProjectApi.getQadProjectPage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
}],
|
|
verificationParams: [{
|
|
key: 'projectCode',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '单据号',
|
|
field: 'number',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
hiddenInMain: true,
|
|
isTableForm: false,
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '包装规格',
|
|
field: 'packUnit',
|
|
sort: 'custom',
|
|
isSearch: false,
|
|
table: {
|
|
width: 120
|
|
},
|
|
isTable:false,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
tableForm: {
|
|
enterSearch:true,
|
|
isInpuFocusShow: true,
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择包装规格', // 输入框占位文本
|
|
searchField: 'packUnit', // 查询弹窗赋值字段
|
|
searchTitle: '物料包装信息', // 查询弹窗标题
|
|
searchAllSchemas: Itempackaging.allSchemas, // 查询弹窗所需类
|
|
searchPage: ItempackagingApi.getItempackagingPage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'itemCode',
|
|
value: 'itemCode',
|
|
message: '请先选择物料代码!',
|
|
isMainValue: true
|
|
}],
|
|
verificationParams: [{
|
|
key: 'packUnit',
|
|
action: '==',
|
|
value: '',
|
|
isMainValue: false,
|
|
isSearch: true,
|
|
isFormModel: true,
|
|
}], // 失去焦点校验参数
|
|
},
|
|
form: {
|
|
// labelMessage: '信息提示说明!!!',
|
|
componentProps: {
|
|
isSearchList: true, // 开启查询弹窗
|
|
searchListPlaceholder: '请选择包装规格', // 输入框占位文本
|
|
searchField: 'packUnit', // 查询弹窗赋值字段
|
|
searchTitle: '物料包装信息', // 查询弹窗标题
|
|
searchAllSchemas: Itempackaging.allSchemas, // 查询弹窗所需类
|
|
searchPage: ItempackagingApi.getItempackagingPage, // 查询弹窗所需分页方法
|
|
searchCondition: [{
|
|
key: 'available',
|
|
value: 'TRUE',
|
|
isMainValue: false
|
|
},{
|
|
key: 'itemCode',
|
|
value: 'itemCode',
|
|
message: '请先选择物料代码!', // 当前置条件为空时 弹出信息提示
|
|
isMainValue: true
|
|
}]
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '标包数量',
|
|
field: 'packQty',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 120
|
|
},
|
|
isTable:false,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
tableForm:{
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '包装号',
|
|
field: 'packingNumber',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable:false,
|
|
isTableForm: false,
|
|
isForm: false,
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '明细备注',
|
|
field: 'remark',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
},
|
|
{
|
|
label: '创建者',
|
|
field: 'creator',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '创建时间',
|
|
field: 'createTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: {width:'100%'},
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x',
|
|
}
|
|
},
|
|
isTableForm: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '最后更新时间',
|
|
field: 'updateTime',
|
|
formatter: dateFormatter,
|
|
detail: {
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss'
|
|
},
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
isTable:false,
|
|
form: {
|
|
component: 'DatePicker',
|
|
componentProps: {
|
|
style: {width:'100%'},
|
|
type: 'datetime',
|
|
dateFormat: 'YYYY-MM-DD HH:mm:ss',
|
|
valueFormat: 'x',
|
|
}
|
|
},
|
|
isTableForm: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '最后更新者',
|
|
field: 'updater',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTable:false,
|
|
isTableForm: false,
|
|
isForm: false
|
|
},
|
|
{
|
|
label: '操作',
|
|
field: 'action',
|
|
isDetail: false,
|
|
isForm: false ,
|
|
table: {
|
|
width: 250,
|
|
fixed: 'right'
|
|
},
|
|
isTableForm:false,
|
|
}
|
|
]))
|
|
|
|
//表单校验
|
|
export const ProductionscrapRequestDetailRules = reactive({
|
|
workStationCode: [
|
|
{ required: true, message: '请选择工位代码', trigger: 'change' }
|
|
],
|
|
productionLineCode: [
|
|
{ required: true, message: '请选择生产线代码', trigger: 'change' }
|
|
],
|
|
inventoryStatus: [
|
|
{ required: true, message: '请选择库存状态', trigger: 'change' }
|
|
],
|
|
itemCode: [
|
|
{ required: true, message: '请输入物料代码', trigger: 'blur' }
|
|
],
|
|
remark: [
|
|
{ max: 50, message: '不得超过50个字符', trigger: 'blur' }
|
|
],
|
|
// packUnit: [
|
|
// { required: true, message: '请选择包装规格', trigger: 'blur' }
|
|
// ]
|
|
})
|
|
|
|
/**
|
|
* @returns {Array} 生产退料申请子表创建标签
|
|
*/
|
|
export const ProductionscrapRequestDetailLabel = useCrudSchemas(reactive<CrudSchema[]>([
|
|
// {
|
|
// label: '标签生产线代码',
|
|
// field: 'productionLineCodePackage',
|
|
// sort: 'custom',
|
|
// table: {
|
|
// width: 150
|
|
// },
|
|
// tableForm:{
|
|
// disabled: true
|
|
// }
|
|
// },
|
|
{
|
|
label: '标签供应商代码',
|
|
field: 'supplierItemCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm:{
|
|
enterSearch:true,
|
|
isInpuFocusShow: true,
|
|
searchListPlaceholder: '请选择供应商代码', // 输入框占位文本
|
|
searchField: 'supplierCode', // 查询弹窗赋值字段
|
|
searchTitle: '供应商信息', // 查询弹窗标题
|
|
searchAllSchemas: Supplieritem.allSchemas, // 查询弹窗所需类
|
|
searchPage: SupplieritemApi.getSupplieritemPage, // 查询弹窗所需分页方法
|
|
searchCondition:[{
|
|
key: 'itemCode',
|
|
value: 'itemCode',
|
|
message: '请填写物料代码!',
|
|
isTableRowValue: true, //查询当前searchTable表中行数据的值
|
|
isMainValue: false
|
|
}]
|
|
}
|
|
},
|
|
{
|
|
label: '物料代码',
|
|
field: 'itemCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '批次',
|
|
field: 'batch',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true,
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '数量',
|
|
field: 'qty',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '计量单位',
|
|
field: 'uom',
|
|
dictType: DICT_TYPE.UOM,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '库存状态',
|
|
field: 'inventoryStatus',
|
|
dictType: DICT_TYPE.INVENTORY_STATUS,
|
|
dictClass: 'string',
|
|
isTable: true,
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
type: 'Select',
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '来源生产线代码',
|
|
field: 'productionLineCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '来源生产线代码',
|
|
field: 'productionLineCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '来源工位代码',
|
|
field: 'workStationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '来源库位代码',
|
|
field: 'fromLocationCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
tableForm: {
|
|
disabled: true
|
|
},
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
label: '物料名称',
|
|
field: 'itemName',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '物料描述1',
|
|
field: 'itemDesc1',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '物料描述2',
|
|
field: 'itemDesc2',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '项目代码',
|
|
field: 'projectCode',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150
|
|
},
|
|
isTableForm: false,
|
|
isForm: false,
|
|
},
|
|
{
|
|
label: '单据号',
|
|
field: 'number',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 180
|
|
},
|
|
isTableForm: false,
|
|
form: {
|
|
componentProps: {
|
|
disabled: true
|
|
}
|
|
}
|
|
},
|
|
]))
|
|
|
|
//表单校验
|
|
export const ProductionscrapRequestDetailLabelRules = reactive({
|
|
supplierItemCode: [
|
|
{ required: true, message: '请选择供应商', trigger: 'change' }
|
|
],
|
|
productionLineCodePackage: [
|
|
{ required: true, message: '请选择生产线', trigger: 'change' }
|
|
]
|
|
})
|
|
|
|
|
|
export const SupplierdeliverRequestPackage = useCrudSchemas(reactive<CrudSchema[]>([
|
|
{
|
|
label: '包装号',
|
|
field: 'number',
|
|
sort: 'custom',
|
|
isSearch: true,
|
|
table: {
|
|
width: 180,
|
|
fixed: 'left'
|
|
},
|
|
},
|
|
{
|
|
label: '物料代码',
|
|
field: 'itemCode',
|
|
sort: 'custom',
|
|
isSearch: true,
|
|
table: {
|
|
width: 150,
|
|
},
|
|
},
|
|
{
|
|
label: '批次',
|
|
field: 'batch',
|
|
sort: 'custom',
|
|
isSearch: true,
|
|
table: {
|
|
width: 150,
|
|
},
|
|
},
|
|
{
|
|
label: '数量',
|
|
field: 'qty',
|
|
sort: 'custom',
|
|
table: {
|
|
width: 150,
|
|
},
|
|
},
|
|
{
|
|
label: '计量单位',
|
|
field: 'uom',
|
|
sort: 'custom',
|
|
dictType: DICT_TYPE.UOM,
|
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
|
form: {
|
|
component: 'SelectV2'
|
|
},
|
|
table: {
|
|
width: 150,
|
|
},
|
|
},
|
|
|
|
]))
|
|
|
|
|