35 changed files with 4342 additions and 2980 deletions
@ -0,0 +1,58 @@ |
|||||
|
import request from '@/config/axios' |
||||
|
|
||||
|
export interface BarcodeVO { |
||||
|
id: number |
||||
|
code: string |
||||
|
name: string |
||||
|
description: string |
||||
|
order: number |
||||
|
length: number |
||||
|
prefixLenght: number |
||||
|
prefixChar: string |
||||
|
entityProperties: string |
||||
|
encyptMethod: string |
||||
|
masterId: number |
||||
|
trimEnd: string |
||||
|
isEncypt: string |
||||
|
} |
||||
|
|
||||
|
// 查询条码片段列表
|
||||
|
export const getBarcodePage = async (params) => { |
||||
|
if (params.isSearch) { |
||||
|
delete params.isSearch |
||||
|
const data = {...params} |
||||
|
return await request.post({ url: '/wms/barcode/senior', data }) |
||||
|
} else { |
||||
|
return await request.get({ url: `/wms/barcode/page`, params }) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 查询条码片段详情
|
||||
|
export const getBarcode = async (id: number) => { |
||||
|
return await request.get({ url: `/wms/barcode/get?id=` + id }) |
||||
|
} |
||||
|
|
||||
|
// 新增条码片段
|
||||
|
export const createBarcode = async (data: BarcodeVO) => { |
||||
|
return await request.post({ url: `/wms/barcode/create`, data }) |
||||
|
} |
||||
|
|
||||
|
// 修改条码片段
|
||||
|
export const updateBarcode = async (data: BarcodeVO) => { |
||||
|
return await request.put({ url: `/wms/barcode/update`, data }) |
||||
|
} |
||||
|
|
||||
|
// 删除条码片段
|
||||
|
export const deleteBarcode = async (id: number) => { |
||||
|
return await request.delete({ url: `/wms/barcode/delete?id=` + id }) |
||||
|
} |
||||
|
|
||||
|
// 导出条码片段 Excel
|
||||
|
export const exportBarcode = async (params) => { |
||||
|
return await request.download({ url: `/wms/barcode/export-excel`, params }) |
||||
|
} |
||||
|
|
||||
|
// 下载用户导入模板
|
||||
|
export const importTemplate = () => { |
||||
|
return request.download({ url: '/wms/barcode/get-import-template' }) |
||||
|
} |
@ -0,0 +1,59 @@ |
|||||
|
import request from '@/config/axios' |
||||
|
|
||||
|
export interface EnterpriseVO { |
||||
|
id: number |
||||
|
code: string |
||||
|
name: string |
||||
|
shortName: string |
||||
|
address: string |
||||
|
available: string |
||||
|
activeTime: Date |
||||
|
expireTime: Date |
||||
|
remark: string |
||||
|
deletionTime: Date |
||||
|
deleterId: string |
||||
|
extraProperties: string |
||||
|
concurrencyStamp: string |
||||
|
siteId: string |
||||
|
} |
||||
|
|
||||
|
// 查询企业列表
|
||||
|
export const getEnterprisePage = async (params) => { |
||||
|
if (params.isSearch) { |
||||
|
delete params.isSearch |
||||
|
const data = {...params} |
||||
|
return await request.post({ url: '/wms/enterprise/senior', data }) |
||||
|
} else { |
||||
|
return await request.get({ url: `/wms/enterprise/page`, params }) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 查询企业详情
|
||||
|
export const getEnterprise = async (id: number) => { |
||||
|
return await request.get({ url: `/wms/enterprise/get?id=` + id }) |
||||
|
} |
||||
|
|
||||
|
// 新增企业
|
||||
|
export const createEnterprise = async (data: EnterpriseVO) => { |
||||
|
return await request.post({ url: `/wms/enterprise/create`, data }) |
||||
|
} |
||||
|
|
||||
|
// 修改企业
|
||||
|
export const updateEnterprise = async (data: EnterpriseVO) => { |
||||
|
return await request.put({ url: `/wms/enterprise/update`, data }) |
||||
|
} |
||||
|
|
||||
|
// 删除企业
|
||||
|
export const deleteEnterprise = async (id: number) => { |
||||
|
return await request.delete({ url: `/wms/enterprise/delete?id=` + id }) |
||||
|
} |
||||
|
|
||||
|
// 导出企业 Excel
|
||||
|
export const exportEnterprise = async (params) => { |
||||
|
return await request.download({ url: `/wms/enterprise/export-excel`, params }) |
||||
|
} |
||||
|
|
||||
|
// 下载用户导入模板
|
||||
|
export const importTemplate = () => { |
||||
|
return request.download({ url: '/wms/enterprise/get-import-template' }) |
||||
|
} |
@ -0,0 +1,86 @@ |
|||||
|
import request from '@/config/axios' |
||||
|
|
||||
|
export interface PackageVO { |
||||
|
number: string |
||||
|
itemCode: string |
||||
|
itemName: string |
||||
|
itemDesc1: string |
||||
|
itemDesc2: string |
||||
|
batch: string |
||||
|
altBatch: string |
||||
|
produceDate: Date |
||||
|
validityDays: number |
||||
|
expireDate: Date |
||||
|
uom: string |
||||
|
qty: number |
||||
|
altUom: string |
||||
|
altQty: number |
||||
|
convertRate: number |
||||
|
stdPackQty: number |
||||
|
stdPackUnit: string |
||||
|
toWarehouseCode: string |
||||
|
toDockCode: string |
||||
|
toLocationCode: string |
||||
|
supplierCode: string |
||||
|
supplierItemCode: string |
||||
|
poNumber: string |
||||
|
poLine: string |
||||
|
rpNumber: string |
||||
|
asnNumber: string |
||||
|
woNumber: string |
||||
|
woLine: string |
||||
|
productionLineCode: string |
||||
|
teamCode: string |
||||
|
shiftCode: string |
||||
|
customerCode: string |
||||
|
customerDockCode: string |
||||
|
customerItemCode: string |
||||
|
soNumber: string |
||||
|
soLine: string |
||||
|
eqLevel: string |
||||
|
ownerCode: string |
||||
|
weight: string |
||||
|
area: string |
||||
|
volume: string |
||||
|
} |
||||
|
|
||||
|
// 查询包装列表
|
||||
|
export const getPackagePage = async (params) => { |
||||
|
if (params.isSearch) { |
||||
|
delete params.isSearch |
||||
|
const data = {...params} |
||||
|
return await request.post({ url: '/wms/package/senior', data }) |
||||
|
} else { |
||||
|
return await request.get({ url: `/wms/package/page`, params }) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 查询包装详情
|
||||
|
export const getPackage = async (id: number) => { |
||||
|
return await request.get({ url: `/wms/package/get?id=` + id }) |
||||
|
} |
||||
|
|
||||
|
// 新增包装
|
||||
|
export const createPackage = async (data: PackageVO) => { |
||||
|
return await request.post({ url: `/wms/package/create`, data }) |
||||
|
} |
||||
|
|
||||
|
// 修改包装
|
||||
|
export const updatePackage = async (data: PackageVO) => { |
||||
|
return await request.put({ url: `/wms/package/update`, data }) |
||||
|
} |
||||
|
|
||||
|
// 删除包装
|
||||
|
export const deletePackage = async (id: number) => { |
||||
|
return await request.delete({ url: `/wms/package/delete?id=` + id }) |
||||
|
} |
||||
|
|
||||
|
// 导出包装 Excel
|
||||
|
export const exportPackage = async (params) => { |
||||
|
return await request.download({ url: `/wms/package/export-excel`, params }) |
||||
|
} |
||||
|
|
||||
|
// 下载用户导入模板
|
||||
|
export const importTemplate = () => { |
||||
|
return request.download({ url: '/wms/package/get-import-template' }) |
||||
|
} |
@ -0,0 +1,129 @@ |
|||||
|
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' |
||||
|
import { dateFormatter } from '@/utils/formatTime' |
||||
|
|
||||
|
// 表单校验
|
||||
|
export const EnterpriseRules = reactive({ |
||||
|
code: [required], |
||||
|
shortName: [required], |
||||
|
available: [required], |
||||
|
}) |
||||
|
|
||||
|
export const Enterprise = useCrudSchemas(reactive<CrudSchema[]>([ |
||||
|
{ |
||||
|
label: '代码', |
||||
|
field: 'code', |
||||
|
sort: 'custom', |
||||
|
|
||||
|
}, |
||||
|
{ |
||||
|
label: '名称', |
||||
|
field: 'name', |
||||
|
sort: 'custom', |
||||
|
|
||||
|
}, |
||||
|
{ |
||||
|
label: '简称', |
||||
|
field: 'shortName', |
||||
|
sort: 'custom', |
||||
|
|
||||
|
}, |
||||
|
{ |
||||
|
label: '地址', |
||||
|
field: 'address', |
||||
|
sort: 'custom', |
||||
|
|
||||
|
}, |
||||
|
{ |
||||
|
label: '是否可用', |
||||
|
field: 'available', |
||||
|
sort: 'custom', |
||||
|
dictType: DICT_TYPE.TRUE_FALSE, |
||||
|
dictClass: 'string', |
||||
|
table: { |
||||
|
width: 120 |
||||
|
}, |
||||
|
form: { |
||||
|
component: 'Switch', |
||||
|
value: 'TRUE', |
||||
|
componentProps: { |
||||
|
inactiveValue: 'FALSE', |
||||
|
activeValue: 'TRUE' |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
{ |
||||
|
label: '生效时间', |
||||
|
field: 'activeTime', |
||||
|
sort: 'custom', |
||||
|
formatter: dateFormatter, |
||||
|
|
||||
|
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')] |
||||
|
} |
||||
|
}, |
||||
|
form: { |
||||
|
component: 'DatePicker', |
||||
|
componentProps: { |
||||
|
type: 'datetime', |
||||
|
valueFormat: 'x' |
||||
|
} |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '失效时间', |
||||
|
field: 'expireTime', |
||||
|
sort: 'custom', |
||||
|
formatter: dateFormatter, |
||||
|
|
||||
|
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')] |
||||
|
} |
||||
|
}, |
||||
|
form: { |
||||
|
component: 'DatePicker', |
||||
|
componentProps: { |
||||
|
type: 'datetime', |
||||
|
valueFormat: 'x' |
||||
|
} |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '备注', |
||||
|
field: 'remark', |
||||
|
sort: 'custom', |
||||
|
|
||||
|
}, |
||||
|
{ |
||||
|
label: '创建时间', |
||||
|
field: 'createTime', |
||||
|
sort: 'custom', |
||||
|
formatter: dateFormatter, |
||||
|
|
||||
|
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', |
||||
|
isForm: false, |
||||
|
table: { |
||||
|
width: 150, |
||||
|
fixed: 'right' |
||||
|
} |
||||
|
} |
||||
|
])) |
@ -0,0 +1,239 @@ |
|||||
|
<template> |
||||
|
<!-- <ContentWrap> |
||||
|
<Search :schema="Enterprise.allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> |
||||
|
</ContentWrap> --> |
||||
|
|
||||
|
<!-- 列表头部 --> |
||||
|
<TableHead |
||||
|
:HeadButttondata="HeadButttondata" |
||||
|
@button-base-click="buttonBaseClick" |
||||
|
:routeName="routeName" |
||||
|
@updataTableColumns="updataTableColumns" |
||||
|
@searchFormClick="searchFormClick" |
||||
|
:allSchemas="Enterprise.allSchemas" |
||||
|
/> |
||||
|
|
||||
|
<!-- 列表 --> |
||||
|
<ContentWrap> |
||||
|
<Table |
||||
|
:columns="tableColumns" |
||||
|
:data="tableObject.tableList" |
||||
|
:loading="tableObject.loading" |
||||
|
:pagination="{ |
||||
|
total: tableObject.total |
||||
|
}" |
||||
|
v-model:pageSize="tableObject.pageSize" |
||||
|
v-model:currentPage="tableObject.currentPage" |
||||
|
v-model:sort="tableObject.sort" |
||||
|
> |
||||
|
<template #code="{row}"> |
||||
|
<el-button type="primary" link @click="openDetail(row, '代码', row.code)"> |
||||
|
<span>{{ row.code }}</span> |
||||
|
</el-button> |
||||
|
</template> |
||||
|
<template #action="{ row }"> |
||||
|
<ButtonBase :Butttondata="butttondata" @button-base-click="buttonTableClick($event,row)" /> |
||||
|
</template> |
||||
|
</Table> |
||||
|
</ContentWrap> |
||||
|
|
||||
|
<!-- 表单弹窗:添加/修改 --> |
||||
|
<BasicForm |
||||
|
ref="basicFormRef" |
||||
|
@success="getList" |
||||
|
:rules="EnterpriseRules" |
||||
|
:formAllSchemas="Enterprise.allSchemas" |
||||
|
:searchTableParams="searchTableParams" |
||||
|
:apiUpdate="EnterpriseApi.updateEnterprise" |
||||
|
:apiCreate="EnterpriseApi.createEnterprise" |
||||
|
@searchTableSuccess="searchTableSuccess" |
||||
|
:isBusiness="false" |
||||
|
/> |
||||
|
|
||||
|
<!-- 详情 --> |
||||
|
<Detail ref="detailRef" :isBasic="true" :allSchemas="Enterprise.allSchemas" /> |
||||
|
|
||||
|
<!-- 导入 --> |
||||
|
<ImportForm ref="importFormRef" url="/wms/enterprise/import" :importTemplateData="importTemplateData" @success="importSuccess" /> |
||||
|
</template> |
||||
|
|
||||
|
<script setup lang="ts"> |
||||
|
import download from '@/utils/download' |
||||
|
import { Enterprise,EnterpriseRules } from './enterprise.data' |
||||
|
import * as EnterpriseApi from '@/api/wms/enterprise' |
||||
|
import * as defaultButtons from '@/utils/disposition/defaultButtons' |
||||
|
|
||||
|
defineOptions({ name: 'Enterprise' }) |
||||
|
|
||||
|
const message = useMessage() // 消息弹窗 |
||||
|
const { t } = useI18n() // 国际化 |
||||
|
|
||||
|
const route = useRoute() // 路由信息 |
||||
|
const routeName = ref() |
||||
|
routeName.value = route.name |
||||
|
const tableColumns = ref(Enterprise.allSchemas.tableColumns) |
||||
|
|
||||
|
// 字段设置 更新主列表字段 |
||||
|
const updataTableColumns = (val) => { |
||||
|
tableColumns.value = val |
||||
|
} |
||||
|
|
||||
|
// 查询列表页面参数设置 |
||||
|
const searchTableParams = ref([ |
||||
|
//{ |
||||
|
// formField: 'productItemCode', |
||||
|
// searchTableTitle: '物料信息', |
||||
|
// searchTableAllSchemas: Itembasic.allSchemas, |
||||
|
// searchTablePage: ItembasicApi.getItembasicPage |
||||
|
//} |
||||
|
]) |
||||
|
|
||||
|
// 查询页面返回 |
||||
|
const searchTableSuccess = (formField, searchField, val, basicFormRef, type, row ) => { |
||||
|
nextTick(() => { |
||||
|
const setV = {} |
||||
|
setV[formField] = val[0][searchField] |
||||
|
basicFormRef.setValues(setV) |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
const { tableObject, tableMethods } = useTable({ |
||||
|
getListApi: EnterpriseApi.getEnterprisePage // 分页接口 |
||||
|
}) |
||||
|
|
||||
|
// 获得表格的各种操作 |
||||
|
const { getList, setSearchParams } = tableMethods |
||||
|
|
||||
|
// 列表头部按钮 |
||||
|
const HeadButttondata = [ |
||||
|
defaultButtons.defaultAddBtn({hasPermi:'wms:enterprise:create'}), // 新增 |
||||
|
// defaultButtons.defaultImportBtn({hasPermi:'wms:enterprise:import'}), // 导入 |
||||
|
// defaultButtons.defaultExportBtn({hasPermi:'wms:enterprise:export'}), // 导出 |
||||
|
defaultButtons.defaultFreshBtn(null), // 刷新 |
||||
|
defaultButtons.defaultFilterBtn(null), // 筛选 |
||||
|
defaultButtons.defaultSetBtn(null), // 设置 |
||||
|
// { |
||||
|
// label: '自定义扩展按钮', |
||||
|
// name: 'zdy', |
||||
|
// hide: false, |
||||
|
// type: 'primary', |
||||
|
// icon: 'Select', |
||||
|
// color: '' |
||||
|
// }, |
||||
|
] |
||||
|
|
||||
|
// 头部按钮事件 |
||||
|
const buttonBaseClick = (val, item) => { |
||||
|
if (val == 'add') { // 新增 |
||||
|
openForm('create') |
||||
|
} else if (val == 'import') { // 导入 |
||||
|
handleImport() |
||||
|
} else if (val == 'export') { // 导出 |
||||
|
handleExport() |
||||
|
} else if (val == 'refresh') { // 刷新 |
||||
|
getList() |
||||
|
} else if (val == 'filtrate') { // 筛选 |
||||
|
} else { // 其他按钮 |
||||
|
console.log('其他按钮', item) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 根据状态返回该按钮是否显示 |
||||
|
const isShowMainButton = (row,val) => { |
||||
|
if (val.indexOf(row.status) > -1) { |
||||
|
return false |
||||
|
} else { |
||||
|
return true |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 列表-操作按钮 |
||||
|
const butttondata = [ |
||||
|
defaultButtons.mainListEditBtn({hasPermi:'wms:enterprise:update'}), // 编辑 |
||||
|
defaultButtons.mainListDeleteBtn({hasPermi:'wms:enterprise:delete'}), // 删除 |
||||
|
] |
||||
|
|
||||
|
|
||||
|
|
||||
|
// 列表-操作按钮事件 |
||||
|
const buttonTableClick = async (val, row) => { |
||||
|
if (val == 'edit') { // 编辑 |
||||
|
openForm('update', row) |
||||
|
} else if (val == 'delete') { // 删除 |
||||
|
handleDelete(row.id) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/** 添加/修改操作 */ |
||||
|
const basicFormRef = ref() |
||||
|
const openForm =async (type: string, row?: number) => { |
||||
|
basicFormRef.value.open(type, row) |
||||
|
} |
||||
|
|
||||
|
/** 详情操作 */ |
||||
|
const detailRef = ref() |
||||
|
const openDetail = (row: any, titleName: any, titleValue: any) => { |
||||
|
detailRef.value.openDetail(row, titleName, titleValue) |
||||
|
} |
||||
|
|
||||
|
/** 删除按钮操作 */ |
||||
|
const handleDelete = async (id: number) => { |
||||
|
try { |
||||
|
// 删除的二次确认 |
||||
|
await message.delConfirm() |
||||
|
// 发起删除 |
||||
|
await EnterpriseApi.deleteEnterprise(id) |
||||
|
message.success(t('common.delSuccess')) |
||||
|
// 刷新列表 |
||||
|
await getList() |
||||
|
} catch {} |
||||
|
} |
||||
|
|
||||
|
/** 导出按钮操作 */ |
||||
|
const exportLoading = ref(false) // 导出的加载中 |
||||
|
const handleExport = async () => { |
||||
|
try { |
||||
|
// 导出的二次确认 |
||||
|
await message.exportConfirm() |
||||
|
// 发起导出 |
||||
|
exportLoading.value = true |
||||
|
const data = await EnterpriseApi.exportEnterprise(setSearchParams) |
||||
|
download.excel(data, '企业.xls') |
||||
|
} catch { |
||||
|
} finally { |
||||
|
exportLoading.value = false |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/** 导入 */ |
||||
|
const importFormRef = ref() |
||||
|
const handleImport = () => { |
||||
|
importFormRef.value.open() |
||||
|
} |
||||
|
|
||||
|
// 导入附件弹窗所需的参数 |
||||
|
const importTemplateData = reactive({ |
||||
|
templateUrl: '', |
||||
|
templateTitle: '企业导入模版.xls' |
||||
|
}) |
||||
|
|
||||
|
// 导入成功之后 |
||||
|
const importSuccess = () => { |
||||
|
getList() |
||||
|
} |
||||
|
|
||||
|
// 筛选提交 |
||||
|
const searchFormClick = (searchData) => { |
||||
|
tableObject.params = { |
||||
|
isSearch: true, |
||||
|
filters: searchData.filters |
||||
|
} |
||||
|
getList() // 刷新当前列表 |
||||
|
} |
||||
|
|
||||
|
/** 初始化 **/ |
||||
|
onMounted(async () => { |
||||
|
getList() |
||||
|
importTemplateData.templateUrl = await EnterpriseApi.importTemplate() |
||||
|
}) |
||||
|
</script> |
@ -0,0 +1,109 @@ |
|||||
|
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' |
||||
|
|
||||
|
// 表单校验
|
||||
|
export const BarcodeRules = reactive({ |
||||
|
code: [required], |
||||
|
order: [required], |
||||
|
length: [required], |
||||
|
prefixLenght: [required], |
||||
|
entityProperties: [required], |
||||
|
trimEnd: [required], |
||||
|
isEncypt: [required], |
||||
|
}) |
||||
|
|
||||
|
export const Barcode = useCrudSchemas(reactive<CrudSchema[]>([ |
||||
|
{ |
||||
|
label: 'id', |
||||
|
field: 'id', |
||||
|
sort: 'custom', |
||||
|
isForm: false, |
||||
|
}, |
||||
|
{ |
||||
|
label: '代码', |
||||
|
field: 'code', |
||||
|
sort: 'custom', |
||||
|
isSearch: true, |
||||
|
}, |
||||
|
{ |
||||
|
label: '名称', |
||||
|
field: 'name', |
||||
|
sort: 'custom', |
||||
|
isSearch: true, |
||||
|
}, |
||||
|
{ |
||||
|
label: '描述', |
||||
|
field: 'description', |
||||
|
sort: 'custom', |
||||
|
isSearch: true, |
||||
|
}, |
||||
|
{ |
||||
|
label: '顺序', |
||||
|
field: 'order', |
||||
|
sort: 'custom', |
||||
|
form: { |
||||
|
component: 'InputNumber', |
||||
|
value: 0 |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '长度', |
||||
|
field: 'length', |
||||
|
sort: 'custom', |
||||
|
form: { |
||||
|
component: 'InputNumber', |
||||
|
value: 0 |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '前缀长度', |
||||
|
field: 'prefixLenght', |
||||
|
sort: 'custom', |
||||
|
form: { |
||||
|
component: 'InputNumber', |
||||
|
value: 0 |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '前缀字符', |
||||
|
field: 'prefixChar', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '实体属性', |
||||
|
field: 'entityProperties', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '加密方法', |
||||
|
field: 'encyptMethod', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '主表ID', |
||||
|
field: 'masterId', |
||||
|
sort: 'custom', |
||||
|
form: { |
||||
|
component: 'InputNumber', |
||||
|
value: 0 |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '截断尾部空格', |
||||
|
field: 'trimEnd', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '是否加密', |
||||
|
field: 'isEncypt', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '操作', |
||||
|
field: 'action', |
||||
|
isForm: false, |
||||
|
table: { |
||||
|
width: 150, |
||||
|
fixed: 'right' |
||||
|
} |
||||
|
} |
||||
|
])) |
@ -0,0 +1,244 @@ |
|||||
|
<template> |
||||
|
<ContentWrap> |
||||
|
<!-- 搜索工作栏 --> |
||||
|
<Search :schema="Barcode.allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> |
||||
|
</ContentWrap> |
||||
|
|
||||
|
<!-- 列表头部 --> |
||||
|
<TableHead |
||||
|
:HeadButttondata="HeadButttondata" |
||||
|
@button-base-click="buttonBaseClick" |
||||
|
:routeName="routeName" |
||||
|
@updataTableColumns="updataTableColumns" |
||||
|
@searchFormClick="searchFormClick" |
||||
|
:allSchemas="Barcode.allSchemas" |
||||
|
/> |
||||
|
|
||||
|
<!-- 列表 --> |
||||
|
<ContentWrap> |
||||
|
<Table |
||||
|
:columns="tableColumns" |
||||
|
:data="tableObject.tableList" |
||||
|
:loading="tableObject.loading" |
||||
|
:pagination="{ |
||||
|
total: tableObject.total |
||||
|
}" |
||||
|
v-model:pageSize="tableObject.pageSize" |
||||
|
v-model:currentPage="tableObject.currentPage" |
||||
|
v-model:sort="tableObject.sort" |
||||
|
> |
||||
|
<template #code="{row}"> |
||||
|
<el-button type="primary" link @click="openDetail(row, '代码', row.code)"> |
||||
|
<span>{{ row.code }}</span> |
||||
|
</el-button> |
||||
|
</template> |
||||
|
<template #action="{ row }"> |
||||
|
<ButtonBase :Butttondata="butttondata" @button-base-click="buttonTableClick($event,row)" /> |
||||
|
</template> |
||||
|
</Table> |
||||
|
</ContentWrap> |
||||
|
|
||||
|
<!-- 表单弹窗:添加/修改 --> |
||||
|
<BasicForm |
||||
|
ref="basicFormRef" |
||||
|
@success="getList" |
||||
|
:rules="BarcodeRules" |
||||
|
:formAllSchemas="Barcode.allSchemas" |
||||
|
:searchTableParams="searchTableParams" |
||||
|
:apiUpdate="BarcodeApi.updateBom" |
||||
|
:apiCreate="BarcodeApi.createBom" |
||||
|
@searchTableSuccess="searchTableSuccess" |
||||
|
:isBusiness="false" |
||||
|
/> |
||||
|
|
||||
|
<!-- 详情 --> |
||||
|
<Detail ref="detailRef" :isBasic="true" :allSchemas="Barcode.allSchemas" /> |
||||
|
|
||||
|
<!-- 导入 --> |
||||
|
<ImportForm ref="importFormRef" url="/wms/barcode/import" :importTemplateData="importTemplateData" @success="importSuccess" /> |
||||
|
</template> |
||||
|
|
||||
|
<script setup lang="ts"> |
||||
|
import download from '@/utils/download' |
||||
|
import { Barcode,BarcodeRules } from './barcode.data' |
||||
|
import * as BarcodeApi from '@/api/wms/barcode' |
||||
|
import * as defaultButtons from '@/utils/disposition/defaultButtons' |
||||
|
|
||||
|
defineOptions({ name: 'Barcode' }) |
||||
|
|
||||
|
const message = useMessage() // 消息弹窗 |
||||
|
const { t } = useI18n() // 国际化 |
||||
|
|
||||
|
const route = useRoute() // 路由信息 |
||||
|
const routeName = ref() |
||||
|
routeName.value = route.name |
||||
|
const tableColumns = ref(Barcode.allSchemas.tableColumns) |
||||
|
|
||||
|
// 字段设置 更新主列表字段 |
||||
|
const updataTableColumns = (val) => { |
||||
|
tableColumns.value = val |
||||
|
} |
||||
|
|
||||
|
// 查询列表页面参数设置 |
||||
|
const searchTableParams = ref([ |
||||
|
//{ |
||||
|
// formField: 'productItemCode', |
||||
|
// searchTableTitle: '物料信息', |
||||
|
// searchTableAllSchemas: Itembasic.allSchemas, |
||||
|
// searchTablePage: ItembasicApi.getItembasicPage |
||||
|
//} |
||||
|
]) |
||||
|
|
||||
|
// 查询页面返回 |
||||
|
const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => { |
||||
|
nextTick(() => { |
||||
|
const setV = {} |
||||
|
setV[formField] = val[0][searchField] |
||||
|
formRef.setValues(setV) |
||||
|
} |
||||
|
) |
||||
|
} |
||||
|
|
||||
|
const { tableObject, tableMethods } = useTable({ |
||||
|
getListApi: BarcodeApi.getBarcodePage // 分页接口 |
||||
|
}) |
||||
|
|
||||
|
// 获得表格的各种操作 |
||||
|
const { getList, setSearchParams } = tableMethods |
||||
|
|
||||
|
// 列表头部按钮 |
||||
|
const HeadButttondata = [ |
||||
|
defaultButtons.defaultAddBtn({hasPermi:'wms:barcode:create'}), // 新增 |
||||
|
// defaultButtons.defaultImportBtn({hasPermi:'wms:barcode:import'}), // 导入 |
||||
|
// defaultButtons.defaultExportBtn({hasPermi:'wms:barcode:export'}), // 导出 |
||||
|
defaultButtons.defaultFreshBtn(null), // 刷新 |
||||
|
// defaultButtons.defaultFilterBtn(null), // 筛选 |
||||
|
defaultButtons.defaultSetBtn(null), // 设置 |
||||
|
// { |
||||
|
// label: '自定义扩展按钮', |
||||
|
// name: 'zdy', |
||||
|
// hide: false, |
||||
|
// type: 'primary', |
||||
|
// icon: 'Select', |
||||
|
// color: '' |
||||
|
// }, |
||||
|
] |
||||
|
|
||||
|
// 头部按钮事件 |
||||
|
const buttonBaseClick = (val, item) => { |
||||
|
if (val == 'add') { // 新增 |
||||
|
openForm('create') |
||||
|
} else if (val == 'import') { // 导入 |
||||
|
handleImport() |
||||
|
} else if (val == 'export') { // 导出 |
||||
|
handleExport() |
||||
|
} else if (val == 'refresh') { // 刷新 |
||||
|
getList() |
||||
|
} else if (val == 'filtrate') { // 筛选 |
||||
|
} else { // 其他按钮 |
||||
|
console.log('其他按钮', item) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 根据状态返回该按钮是否显示 |
||||
|
const isShowMainButton = (row,val) => { |
||||
|
if (val.indexOf(row.status) > -1) { |
||||
|
return false |
||||
|
} else { |
||||
|
return true |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 列表-操作按钮 |
||||
|
const butttondata = (row) => { |
||||
|
return [ |
||||
|
defaultButtons.mainListEditBtn({hasPermi:'wms:barcode:update'}), // 编辑 |
||||
|
defaultButtons.mainListDeleteBtn({hasPermi:'wms:barcode:delete'}), // 删除 |
||||
|
] |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
// 列表-操作按钮事件 |
||||
|
const buttonTableClick = async (val, row) => { |
||||
|
if (val == 'edit') { // 编辑 |
||||
|
openForm('update', row) |
||||
|
} else if (val == 'delete') { // 删除 |
||||
|
handleDelete(row.id) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/** 添加/修改操作 */ |
||||
|
const formRef = ref() |
||||
|
const openForm =async (type: string, row?: number) => { |
||||
|
tableData.value = [] // 重置明细数据 |
||||
|
formRef.value.open(type, row) |
||||
|
} |
||||
|
|
||||
|
/** 详情操作 */ |
||||
|
const detailRef = ref() |
||||
|
const openDetail = (row: any, titleName: any, titleValue: any) => { |
||||
|
detailRef.value.openDetail(row, titleName, titleValue) |
||||
|
} |
||||
|
|
||||
|
/** 删除按钮操作 */ |
||||
|
const handleDelete = async (id: number) => { |
||||
|
try { |
||||
|
// 删除的二次确认 |
||||
|
await message.delConfirm() |
||||
|
// 发起删除 |
||||
|
await BarcodeApi.deleteBarcode(id) |
||||
|
message.success(t('common.delSuccess')) |
||||
|
// 刷新列表 |
||||
|
await getList() |
||||
|
} catch {} |
||||
|
} |
||||
|
|
||||
|
/** 导出按钮操作 */ |
||||
|
const exportLoading = ref(false) // 导出的加载中 |
||||
|
const handleExport = async () => { |
||||
|
try { |
||||
|
// 导出的二次确认 |
||||
|
await message.exportConfirm() |
||||
|
// 发起导出 |
||||
|
exportLoading.value = true |
||||
|
const data = await BarcodeApi.exportBarcode(setSearchParams) |
||||
|
download.excel(data, '条码片段.xls') |
||||
|
} catch { |
||||
|
} finally { |
||||
|
exportLoading.value = false |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/** 导入 */ |
||||
|
const importFormRef = ref() |
||||
|
const handleImport = () => { |
||||
|
importFormRef.value.open() |
||||
|
} |
||||
|
|
||||
|
// 导入附件弹窗所需的参数 |
||||
|
const importTemplateData = reactive({ |
||||
|
templateUrl: '', |
||||
|
templateTitle: '条码片段导入模版.xls' |
||||
|
}) |
||||
|
|
||||
|
// 导入成功之后 |
||||
|
const importSuccess = () => { |
||||
|
getList() |
||||
|
} |
||||
|
|
||||
|
// 筛选提交 |
||||
|
const searchFormClick = (searchData) => { |
||||
|
tableObject.params = { |
||||
|
isSearch: true, |
||||
|
filters: searchData.filters |
||||
|
} |
||||
|
getList() // 刷新当前列表 |
||||
|
} |
||||
|
|
||||
|
/** 初始化 **/ |
||||
|
onMounted(async () => { |
||||
|
getList() |
||||
|
importTemplateData.templateUrl = await BarcodeApi.importTemplate() |
||||
|
}) |
||||
|
</script> |
@ -0,0 +1,240 @@ |
|||||
|
<template> |
||||
|
<ContentWrap> |
||||
|
<!-- 搜索工作栏 --> |
||||
|
<Search :schema="Package.allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> |
||||
|
</ContentWrap> |
||||
|
|
||||
|
<!-- 列表头部 --> |
||||
|
<TableHead |
||||
|
:HeadButttondata="HeadButttondata" |
||||
|
@button-base-click="buttonBaseClick" |
||||
|
:routeName="routeName" |
||||
|
@updataTableColumns="updataTableColumns" |
||||
|
@searchFormClick="searchFormClick" |
||||
|
:allSchemas="Package.allSchemas" |
||||
|
/> |
||||
|
|
||||
|
<!-- 列表 --> |
||||
|
<ContentWrap> |
||||
|
<Table |
||||
|
:columns="tableColumns" |
||||
|
:data="tableObject.tableList" |
||||
|
:loading="tableObject.loading" |
||||
|
:pagination="{ |
||||
|
total: tableObject.total |
||||
|
}" |
||||
|
v-model:pageSize="tableObject.pageSize" |
||||
|
v-model:currentPage="tableObject.currentPage" |
||||
|
v-model:sort="tableObject.sort" |
||||
|
> |
||||
|
<template #number="{row}"> |
||||
|
<el-button type="primary" link @click="openDetail(row, '单据号', row.number)"> |
||||
|
<span>{{ row.number }}</span> |
||||
|
</el-button> |
||||
|
</template> |
||||
|
<template #action="{ row }"> |
||||
|
<ButtonBase :Butttondata="butttondata" @button-base-click="buttonTableClick($event,row)" /> |
||||
|
</template> |
||||
|
</Table> |
||||
|
</ContentWrap> |
||||
|
|
||||
|
<!-- 表单弹窗:添加/修改 --> |
||||
|
<BasicForm |
||||
|
ref="basicFormRef" |
||||
|
@success="getList" |
||||
|
:rules="PackageRules" |
||||
|
:formAllSchemas="Package.allSchemas" |
||||
|
:searchTableParams="searchTableParams" |
||||
|
:apiUpdate="PackageApi.updateBom" |
||||
|
:apiCreate="PackageApi.createBom" |
||||
|
@searchTableSuccess="searchTableSuccess" |
||||
|
:isBusiness="false" |
||||
|
/> |
||||
|
|
||||
|
<!-- 详情 --> |
||||
|
<Detail ref="detailRef" :isBasic="true" :allSchemas="Package.allSchemas" /> |
||||
|
|
||||
|
<!-- 导入 --> |
||||
|
<ImportForm ref="importFormRef" url="/wms/package/import" :importTemplateData="importTemplateData" @success="importSuccess" /> |
||||
|
</template> |
||||
|
|
||||
|
<script setup lang="ts"> |
||||
|
import download from '@/utils/download' |
||||
|
import { Package,PackageRules } from './package.data' |
||||
|
import * as PackageApi from '@/api/wms/package' |
||||
|
import * as defaultButtons from '@/utils/disposition/defaultButtons' |
||||
|
|
||||
|
defineOptions({ name: 'Package' }) |
||||
|
|
||||
|
const message = useMessage() // 消息弹窗 |
||||
|
const { t } = useI18n() // 国际化 |
||||
|
|
||||
|
const route = useRoute() // 路由信息 |
||||
|
const routeName = ref() |
||||
|
routeName.value = route.name |
||||
|
const tableColumns = ref(Package.allSchemas.tableColumns) |
||||
|
|
||||
|
// 字段设置 更新主列表字段 |
||||
|
const updataTableColumns = (val) => { |
||||
|
tableColumns.value = val |
||||
|
} |
||||
|
|
||||
|
// 查询列表页面参数设置 |
||||
|
const searchTableParams = ref([ |
||||
|
//{ |
||||
|
// formField: 'productItemCode', |
||||
|
// searchTableTitle: '物料信息', |
||||
|
// searchTableAllSchemas: Itembasic.allSchemas, |
||||
|
// searchTablePage: ItembasicApi.getItembasicPage |
||||
|
//} |
||||
|
]) |
||||
|
|
||||
|
// 查询页面返回 |
||||
|
const searchTableSuccess = (formField, searchField, val, basicFormRef, type, row ) => { |
||||
|
nextTick(() => { |
||||
|
const setV = {} |
||||
|
setV[formField] = val[0][searchField] |
||||
|
basicFormRef.setValues(setV) |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
const { tableObject, tableMethods } = useTable({ |
||||
|
getListApi: PackageApi.getPackagePage // 分页接口 |
||||
|
}) |
||||
|
|
||||
|
// 获得表格的各种操作 |
||||
|
const { getList, setSearchParams } = tableMethods |
||||
|
|
||||
|
// 列表头部按钮 |
||||
|
const HeadButttondata = [ |
||||
|
// defaultButtons.defaultAddBtn({hasPermi:'wms:package:create'}), // 新增 |
||||
|
// defaultButtons.defaultImportBtn({hasPermi:'wms:package:import'}), // 导入 |
||||
|
defaultButtons.defaultExportBtn({hasPermi:'wms:package:export'}), // 导出 |
||||
|
defaultButtons.defaultFreshBtn(null), // 刷新 |
||||
|
defaultButtons.defaultFilterBtn(null), // 筛选 |
||||
|
defaultButtons.defaultSetBtn(null), // 设置 |
||||
|
// { |
||||
|
// label: '自定义扩展按钮', |
||||
|
// name: 'zdy', |
||||
|
// hide: false, |
||||
|
// type: 'primary', |
||||
|
// icon: 'Select', |
||||
|
// color: '' |
||||
|
// }, |
||||
|
] |
||||
|
|
||||
|
// 头部按钮事件 |
||||
|
const buttonBaseClick = (val, item) => { |
||||
|
if (val == 'add') { // 新增 |
||||
|
openForm('create') |
||||
|
} else if (val == 'import') { // 导入 |
||||
|
handleImport() |
||||
|
} else if (val == 'export') { // 导出 |
||||
|
handleExport() |
||||
|
} else if (val == 'refresh') { // 刷新 |
||||
|
getList() |
||||
|
} else if (val == 'filtrate') { // 筛选 |
||||
|
} else { // 其他按钮 |
||||
|
console.log('其他按钮', item) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 根据状态返回该按钮是否显示 |
||||
|
const isShowMainButton = (row,val) => { |
||||
|
if (val.indexOf(row.status) > -1) { |
||||
|
return false |
||||
|
} else { |
||||
|
return true |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 列表-操作按钮 |
||||
|
const butttondata = (row) => { |
||||
|
return [ |
||||
|
defaultButtons.mainListEditBtn({hasPermi:'wms:package:update'}), // 编辑 |
||||
|
defaultButtons.mainListDeleteBtn({hasPermi:'wms:package:delete'}), // 删除 |
||||
|
] |
||||
|
} |
||||
|
|
||||
|
// 列表-操作按钮事件 |
||||
|
const buttonTableClick = async (val, row) => { |
||||
|
if (val == 'edit') { // 编辑 |
||||
|
openForm('update', row) |
||||
|
} else if (val == 'delete') { // 删除 |
||||
|
handleDelete(row.id) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/** 添加/修改操作 */ |
||||
|
const basicFormRef = ref() |
||||
|
const openForm =async (type: string, row?: number) => { |
||||
|
basicFormRef.value.open(type, row) |
||||
|
} |
||||
|
|
||||
|
/** 详情操作 */ |
||||
|
const detailRef = ref() |
||||
|
const openDetail = (row: any, titleName: any, titleValue: any) => { |
||||
|
detailRef.value.openDetail(row, titleName, titleValue) |
||||
|
} |
||||
|
|
||||
|
/** 删除按钮操作 */ |
||||
|
const handleDelete = async (id: number) => { |
||||
|
try { |
||||
|
// 删除的二次确认 |
||||
|
await message.delConfirm() |
||||
|
// 发起删除 |
||||
|
await PackageApi.deletePackage(id) |
||||
|
message.success(t('common.delSuccess')) |
||||
|
// 刷新列表 |
||||
|
await getList() |
||||
|
} catch {} |
||||
|
} |
||||
|
|
||||
|
/** 导出按钮操作 */ |
||||
|
const exportLoading = ref(false) // 导出的加载中 |
||||
|
const handleExport = async () => { |
||||
|
try { |
||||
|
// 导出的二次确认 |
||||
|
await message.exportConfirm() |
||||
|
// 发起导出 |
||||
|
exportLoading.value = true |
||||
|
const data = await PackageApi.exportPackage(setSearchParams) |
||||
|
download.excel(data, '包装.xls') |
||||
|
} catch { |
||||
|
} finally { |
||||
|
exportLoading.value = false |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/** 导入 */ |
||||
|
const importFormRef = ref() |
||||
|
const handleImport = () => { |
||||
|
importFormRef.value.open() |
||||
|
} |
||||
|
|
||||
|
// 导入附件弹窗所需的参数 |
||||
|
const importTemplateData = reactive({ |
||||
|
templateUrl: '', |
||||
|
templateTitle: '包装导入模版.xls' |
||||
|
}) |
||||
|
|
||||
|
// 导入成功之后 |
||||
|
const importSuccess = () => { |
||||
|
getList() |
||||
|
} |
||||
|
|
||||
|
// 筛选提交 |
||||
|
const searchFormClick = (searchData) => { |
||||
|
tableObject.params = { |
||||
|
isSearch: true, |
||||
|
filters: searchData.filters |
||||
|
} |
||||
|
getList() // 刷新当前列表 |
||||
|
} |
||||
|
|
||||
|
/** 初始化 **/ |
||||
|
onMounted(async () => { |
||||
|
getList() |
||||
|
importTemplateData.templateUrl = await PackageApi.importTemplate() |
||||
|
}) |
||||
|
</script> |
@ -0,0 +1,280 @@ |
|||||
|
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' |
||||
|
import { dateFormatter } from '@/utils/formatTime' |
||||
|
|
||||
|
// 表单校验
|
||||
|
export const PackageRules = reactive({ |
||||
|
number: [required], |
||||
|
itemCode: [required], |
||||
|
itemName: [required], |
||||
|
}) |
||||
|
|
||||
|
export const Package = useCrudSchemas(reactive<CrudSchema[]>([ |
||||
|
{ |
||||
|
label: '包装号', |
||||
|
field: 'number', |
||||
|
sort: 'custom', |
||||
|
isSearch: true, |
||||
|
}, |
||||
|
{ |
||||
|
label: '物料代码', |
||||
|
field: 'itemCode', |
||||
|
sort: 'custom', |
||||
|
isSearch: true, |
||||
|
}, |
||||
|
{ |
||||
|
label: '物品名称', |
||||
|
field: 'itemName', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '物品描述1', |
||||
|
field: 'itemDesc1', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '物品描述2', |
||||
|
field: 'itemDesc2', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '批次', |
||||
|
field: 'batch', |
||||
|
sort: 'custom', |
||||
|
isSearch: true, |
||||
|
}, |
||||
|
{ |
||||
|
label: '替代批次', |
||||
|
field: 'altBatch', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '生产日期', |
||||
|
field: 'produceDate', |
||||
|
sort: 'custom', |
||||
|
formatter: dateFormatter, |
||||
|
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')] |
||||
|
} |
||||
|
}, |
||||
|
form: { |
||||
|
component: 'DatePicker', |
||||
|
componentProps: { |
||||
|
type: 'datetime', |
||||
|
valueFormat: 'x' |
||||
|
} |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '有效期(日)', |
||||
|
field: 'validityDays', |
||||
|
sort: 'custom', |
||||
|
form: { |
||||
|
component: 'InputNumber', |
||||
|
value: 0 |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '失效日期', |
||||
|
field: 'expireDate', |
||||
|
sort: 'custom', |
||||
|
formatter: dateFormatter, |
||||
|
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')] |
||||
|
} |
||||
|
}, |
||||
|
form: { |
||||
|
component: 'DatePicker', |
||||
|
componentProps: { |
||||
|
type: 'datetime', |
||||
|
valueFormat: 'x' |
||||
|
} |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '计量单位', |
||||
|
field: 'uom', |
||||
|
sort: 'custom', |
||||
|
dictType: DICT_TYPE.UOM, |
||||
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
||||
|
form: { |
||||
|
component: 'SelectV2' |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '数量', |
||||
|
field: 'qty', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '替代计量单位', |
||||
|
field: 'altUom', |
||||
|
sort: 'custom', |
||||
|
dictType: DICT_TYPE.UOM, |
||||
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
||||
|
form: { |
||||
|
component: 'SelectV2' |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '替代数量', |
||||
|
field: 'altQty', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '转换率', |
||||
|
field: 'convertRate', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '标包数量', |
||||
|
field: 'stdPackQty', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '标包单位', |
||||
|
field: 'stdPackUnit', |
||||
|
sort: 'custom', |
||||
|
dictType: DICT_TYPE.PACK_UNIT, |
||||
|
dictClass: 'string', // 默认都是字符串类型其他暂不考虑
|
||||
|
form: { |
||||
|
component: 'SelectV2' |
||||
|
}, |
||||
|
}, |
||||
|
{ |
||||
|
label: '仓库代码', |
||||
|
field: 'toWarehouseCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '月台代码', |
||||
|
field: 'toDockCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '库位代码', |
||||
|
field: 'toLocationCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '供应商代码', |
||||
|
field: 'supplierCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '供应商物品代码', |
||||
|
field: 'supplierItemCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '采购订单号', |
||||
|
field: 'poNumber', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '采购订单行', |
||||
|
field: 'poLine', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '采购计划单号', |
||||
|
field: 'rpNumber', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '发货单号', |
||||
|
field: 'asnNumber', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '生产订单号', |
||||
|
field: 'woNumber', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '生产订单行', |
||||
|
field: 'woLine', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '生产线代码', |
||||
|
field: 'productionLineCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '班组代码', |
||||
|
field: 'teamCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '班次代码', |
||||
|
field: 'shiftCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '客户代码', |
||||
|
field: 'customerCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '客户月台代码', |
||||
|
field: 'customerDockCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '客户物品代码', |
||||
|
field: 'customerItemCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '销售订单号', |
||||
|
field: 'soNumber', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '销售订单行', |
||||
|
field: 'soLine', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '质量等级', |
||||
|
field: 'eqLevel', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '货主代码', |
||||
|
field: 'ownerCode', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '重量', |
||||
|
field: 'weight', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '面积', |
||||
|
field: 'area', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
{ |
||||
|
label: '体积', |
||||
|
field: 'volume', |
||||
|
sort: 'custom', |
||||
|
}, |
||||
|
// {
|
||||
|
// label: '操作',
|
||||
|
// field: 'action',
|
||||
|
// isForm: false,
|
||||
|
// table: {
|
||||
|
// width: 150,
|
||||
|
// fixed: 'right'
|
||||
|
// }
|
||||
|
// }
|
||||
|
])) |
Loading…
Reference in new issue