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.
421 lines
6.8 KiB
421 lines
6.8 KiB
1 year ago
|
import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
|
||
|
import { dateFormatter } from '@/utils/formatTime'
|
||
|
|
||
|
// 表单校验
|
||
|
export const PackageRules = reactive({
|
||
|
number: [required],
|
||
|
itemCode: [required],
|
||
|
itemName: [required],
|
||
|
})
|
||
1 year ago
|
export const Package2 = useCrudSchemas(reactive<CrudSchema[]>([
|
||
|
{
|
||
|
label: '包装号',
|
||
|
field: 'number',
|
||
|
sort: 'custom',
|
||
|
isSearch: true,
|
||
|
table: {
|
||
|
width: 150,
|
||
|
fixed: 'left'
|
||
|
},
|
||
|
},
|
||
|
]))
|
||
1 year ago
|
export const Package = useCrudSchemas(reactive<CrudSchema[]>([
|
||
|
{
|
||
|
label: '包装号',
|
||
|
field: 'number',
|
||
|
sort: 'custom',
|
||
|
isSearch: true,
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
fixed: 'left'
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '物料代码',
|
||
|
field: 'itemCode',
|
||
|
sort: 'custom',
|
||
|
isSearch: true,
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '物品名称',
|
||
|
field: 'itemName',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '物品描述1',
|
||
|
field: 'itemDesc1',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '物品描述2',
|
||
|
field: 'itemDesc2',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '批次',
|
||
|
field: 'batch',
|
||
|
sort: 'custom',
|
||
|
isSearch: true,
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '替代批次',
|
||
|
field: 'altBatch',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '生产日期',
|
||
|
field: 'produceDate',
|
||
|
sort: 'custom',
|
||
|
formatter: dateFormatter,
|
||
|
search: {
|
||
|
component: 'DatePicker',
|
||
|
componentProps: {
|
||
1 year ago
|
style: {width:'100%'},
|
||
1 year ago
|
valueFormat: 'YYYY-MM-DD HH:mm:ss',
|
||
|
type: 'daterange',
|
||
|
defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')]
|
||
|
}
|
||
|
},
|
||
|
form: {
|
||
|
component: 'DatePicker',
|
||
|
componentProps: {
|
||
|
type: 'datetime',
|
||
|
valueFormat: 'x'
|
||
|
}
|
||
|
},
|
||
1 year ago
|
table: {
|
||
|
width: 180,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '有效期(日)',
|
||
|
field: 'validityDays',
|
||
|
sort: 'custom',
|
||
|
form: {
|
||
|
component: 'InputNumber',
|
||
1 year ago
|
componentProps: {
|
||
|
min: 0
|
||
|
},
|
||
1 year ago
|
value: 0
|
||
|
},
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '失效日期',
|
||
|
field: 'expireDate',
|
||
|
sort: 'custom',
|
||
|
formatter: dateFormatter,
|
||
|
search: {
|
||
|
component: 'DatePicker',
|
||
|
componentProps: {
|
||
1 year ago
|
style: {width:'100%'},
|
||
1 year ago
|
valueFormat: 'YYYY-MM-DD HH:mm:ss',
|
||
|
type: 'daterange',
|
||
|
defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')]
|
||
|
}
|
||
|
},
|
||
|
form: {
|
||
|
component: 'DatePicker',
|
||
|
componentProps: {
|
||
|
type: 'datetime',
|
||
|
valueFormat: 'x'
|
||
|
}
|
||
|
},
|
||
1 year ago
|
table: {
|
||
|
width: 180,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '计量单位',
|
||
|
field: 'uom',
|
||
|
sort: 'custom',
|
||
|
dictType: DICT_TYPE.UOM,
|
||
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
||
|
form: {
|
||
|
component: 'SelectV2'
|
||
|
},
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '数量',
|
||
|
field: 'qty',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '替代计量单位',
|
||
|
field: 'altUom',
|
||
|
sort: 'custom',
|
||
|
dictType: DICT_TYPE.UOM,
|
||
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
||
|
form: {
|
||
|
component: 'SelectV2'
|
||
|
},
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '替代数量',
|
||
|
field: 'altQty',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '转换率',
|
||
|
field: 'convertRate',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '标包数量',
|
||
|
field: 'stdPackQty',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '标包单位',
|
||
|
field: 'stdPackUnit',
|
||
|
sort: 'custom',
|
||
|
dictType: DICT_TYPE.PACK_UNIT,
|
||
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
||
|
form: {
|
||
|
component: 'SelectV2'
|
||
|
},
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '仓库代码',
|
||
|
field: 'toWarehouseCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '月台代码',
|
||
|
field: 'toDockCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '库位代码',
|
||
|
field: 'toLocationCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '供应商代码',
|
||
|
field: 'supplierCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '供应商物品代码',
|
||
|
field: 'supplierItemCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '采购订单号',
|
||
|
field: 'poNumber',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '采购订单行',
|
||
|
field: 'poLine',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '采购计划单号',
|
||
|
field: 'rpNumber',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '发货单号',
|
||
|
field: 'asnNumber',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 182,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '生产订单号',
|
||
|
field: 'woNumber',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '生产订单行',
|
||
|
field: 'woLine',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '生产线代码',
|
||
|
field: 'productionLineCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '班组代码',
|
||
|
field: 'teamCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '班次代码',
|
||
|
field: 'shiftCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '客户代码',
|
||
|
field: 'customerCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '客户月台代码',
|
||
|
field: 'customerDockCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '客户物品代码',
|
||
|
field: 'customerItemCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '销售订单号',
|
||
|
field: 'soNumber',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '销售订单行',
|
||
|
field: 'soLine',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '质量等级',
|
||
|
field: 'eqLevel',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '货主代码',
|
||
|
field: 'ownerCode',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '重量',
|
||
|
field: 'weight',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '面积',
|
||
|
field: 'area',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
|
{
|
||
|
label: '体积',
|
||
|
field: 'volume',
|
||
|
sort: 'custom',
|
||
1 year ago
|
table: {
|
||
|
width: 150,
|
||
|
},
|
||
1 year ago
|
},
|
||
1 year ago
|
{
|
||
|
label: '操作',
|
||
|
field: 'action',
|
||
|
isForm: false,
|
||
|
table: {
|
||
|
width: 150,
|
||
|
fixed: 'right'
|
||
|
}
|
||
|
}
|
||
1 year ago
|
]))
|