Browse Source

制品回收修改

master_hella_20240701
陈薪名 1 year ago
parent
commit
654e96cf23
  1. 5
      src/views/wms/productionManage/productredress/productredressJobMain/index.vue
  2. 4
      src/views/wms/productionManage/productredress/productredressJobMain/productredressJobMain.data.ts
  3. 133
      src/views/wms/productionManage/productredress/productredressRecordMain/index.vue
  4. 533
      src/views/wms/productionManage/productredress/productredressRecordMain/productredressRecordMain.data.ts
  5. 5
      src/views/wms/productionManage/productredress/productredressRequestMain/productredressRequestMain.data.ts

5
src/views/wms/productionManage/productredress/productredressJobMain/index.vue

@ -54,6 +54,7 @@
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { ProductredressJobMain,ProductredressJobMainRules,ProductredressJobDetail, ProductredressJobDetailRules } from './productredressJobMain.data' import { ProductredressJobMain,ProductredressJobMainRules,ProductredressJobDetail, ProductredressJobDetailRules } from './productredressJobMain.data'
import * as ProductredressJobMainApi from '@/api/wms/productredressJobMain' import * as ProductredressJobMainApi from '@/api/wms/productredressJobMain'
import * as ProductredressJobDetailApi from '@/api/wms/productredressJobDetail' import * as ProductredressJobDetailApi from '@/api/wms/productredressJobDetail'
@ -130,9 +131,13 @@ ProductredressJobDetail.allSchemas.tableFormColumns.forEach(item => {
tableFormKeys[item.field] = item.default ? item.default : '' tableFormKeys[item.field] = item.default ? item.default : ''
}) })
//
const { wsCache } = useCache()
/** 详情操作 */ /** 详情操作 */
const detailRef = ref() const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => { const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
detailRef.value.openDetail(row, titleName, titleValue, 'basicProductredressJobMain') detailRef.value.openDetail(row, titleName, titleValue, 'basicProductredressJobMain')
} }

4
src/views/wms/productionManage/productredress/productredressJobMain/productredressJobMain.data.ts

@ -540,6 +540,8 @@ export const ProductredressJobDetail = useCrudSchemas(reactive<CrudSchema[]>([
{ {
label: '计量单位', label: '计量单位',
field: 'uom', field: 'uom',
dictType: DICT_TYPE.UOM,
dictClass: 'string',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -572,6 +574,8 @@ export const ProductredressJobDetail = useCrudSchemas(reactive<CrudSchema[]>([
{ {
label: '库存状态', label: '库存状态',
field: 'inventoryStatus', field: 'inventoryStatus',
dictType: DICT_TYPE.INVENTORY_STATUS,
dictClass: 'string',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150

133
src/views/wms/productionManage/productredress/productredressRecordMain/index.vue

@ -27,9 +27,9 @@
v-model:currentPage="tableObject.currentPage" v-model:currentPage="tableObject.currentPage"
v-model:sort="tableObject.sort" v-model:sort="tableObject.sort"
> >
<template #code="{row}"> <template #number="{row}">
<el-button type="primary" link @click="openDetail(row, '代码', row.code)"> <el-button type="primary" link @click="openDetail(row, '代码', row.number)">
<span>{{ row.code }}</span> <span>{{ row.number }}</span>
</el-button> </el-button>
</template> </template>
<template #action="{ row }"> <template #action="{ row }">
@ -38,33 +38,25 @@
</Table> </Table>
</ContentWrap> </ContentWrap>
<!-- 表单弹窗添加/修改 -->
<BasicForm
ref="basicFormRef"
@success="formsSuccess"
:rules="ProductredressRecordMainRules"
:formAllSchemas="ProductredressRecordMain.allSchemas"
:apiUpdate="ProductredressRecordMainApi.updateProductredressRecordMain"
:apiCreate="ProductredressRecordMainApi.createProductredressRecordMain"
@searchTableSuccess="searchTableSuccess"
:isBusiness="false"
/>
<!-- 详情 --> <!-- 详情 -->
<Detail ref="detailRef" :isBasic="true" :allSchemas="ProductredressRecordMain.allSchemas" /> <Detail
ref="detailRef"
:isBasic="false"
:allSchemas="ProductredressRecordMain.allSchemas"
:detailAllSchemas="ProductredressRecordDetail.allSchemas"
:detailAllSchemasRules="ProductredressRecordDetailRules"
:apiPage="ProductredressRecordDetailApi.getProductredressRecordDetailPage"
/>
<!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/productredress-record-main/import" :importTemplateData="importTemplateData" @success="importSuccess" />
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import { ProductredressRecordMain,ProductredressRecordMainRules } from './productredressRecordMain.data' import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { ProductredressRecordMain,ProductredressRecordMainRules,ProductredressRecordDetail,ProductredressRecordDetailRules } from './productredressRecordMain.data'
import * as ProductredressRecordMainApi from '@/api/wms/productredressRecordMain' import * as ProductredressRecordMainApi from '@/api/wms/productredressRecordMain'
import * as ProductredressRecordDetailApi from '@/api/wms/productredressRecordDetail'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
import TableHead from '@/components/TableHead/src/TableHead.vue'
import ImportForm from '@/components/ImportForm/src/ImportForm.vue'
import Detail from '@/components/Detail/src/Detail.vue'
defineOptions({ name: 'ProductredressRecordMain' }) defineOptions({ name: 'ProductredressRecordMain' })
@ -76,15 +68,6 @@ const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref(ProductredressRecordMain.allSchemas.tableColumns) const tableColumns = ref(ProductredressRecordMain.allSchemas.tableColumns)
//
const searchTableSuccess = (formField, searchField, val, formRef) => {
nextTick(() => {
const setV = {}
setV[formField] = val[0][searchField]
formRef.setValues(setV)
})
}
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val
@ -99,29 +82,15 @@ const { getList, setSearchParams } = tableMethods
// //
const HeadButttondata = [ const HeadButttondata = [
defaultButtons.defaultAddBtn({hasPermi:'wms:productredressRecordMain:create'}), // defaultButtons.defaultExportBtn({hasPermi:'wms:productredress-record-main:export'}), //
defaultButtons.defaultImportBtn({hasPermi:'wms:productredressRecordMain:import'}), //
defaultButtons.defaultExportBtn({hasPermi:'wms:productredressRecordMain:export'}), //
defaultButtons.defaultFreshBtn(null), // defaultButtons.defaultFreshBtn(null), //
defaultButtons.defaultFilterBtn(null), // defaultButtons.defaultFilterBtn(null), //
defaultButtons.defaultSetBtn(null), // defaultButtons.defaultSetBtn(null), //
// {
// label: '',
// name: 'zdy',
// hide: false,
// type: 'primary',
// icon: 'Select',
// color: ''
// },
] ]
// //
const buttonBaseClick = (val, item) => { const buttonBaseClick = (val, item) => {
if (val == 'add') { // if (val == 'export') { //
openForm('create')
} else if (val == 'import') { //
handleImport()
} else if (val == 'export') { //
handleExport() handleExport()
} else if (val == 'refresh') { // } else if (val == 'refresh') { //
getList() getList()
@ -133,68 +102,22 @@ const buttonBaseClick = (val, item) => {
// - // -
const butttondata = [ const butttondata = [
defaultButtons.mainListEditBtn({hasPermi:'wms:productredressRecordMain:update'}), //
defaultButtons.mainListDeleteBtn({hasPermi:'wms:productredressRecordMain:delete'}), //
] ]
// - // -
const buttonTableClick = async (val, row) => { const buttonTableClick = async (val, row) => {
if (val == 'edit') { //
openForm('update', row)
} else if (val == 'delete') { //
handleDelete(row.id)
}
}
/** 添加/修改操作 */
const basicFormRef = ref()
const openForm = (type: string, row?: any) => {
basicFormRef.value.open(type, row)
}
// form
const formsSuccess = async (formType,data) => {
var isHave =ProductredressRecordMain.allSchemas.formSchema.some(function (item) {
return item.field === 'activeTime' || item.field === 'expireTime';
});
if(isHave){
if(data.activeTime && data.expireTime && data.activeTime >=data.expireTime){
message.error('失效时间要大于生效时间')
return;
}
}
if(data.activeTime==0)data.activeTime = null;
if(data.expireTime==0)data.expireTime = null;
if (formType === 'create') {
await ProductredressRecordMainApi.createProductredressRecordMain(data)
message.success(t('common.createSuccess'))
} else {
await ProductredressRecordMainApi.updateProductredressRecordMain(data)
message.success(t('common.updateSuccess'))
}
basicFormRef.value.dialogVisible = false
getList()
} }
//
const { wsCache } = useCache()
/** 详情操作 */ /** 详情操作 */
const detailRef = ref() const detailRef = ref()
const openDetail = (row: any, titleName: any, titleValue: any) => { const openDetail = (row: any, titleName: any, titleValue: any) => {
const departmentCode = wsCache.get(CACHE_KEY.DEPT).find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
detailRef.value.openDetail(row, titleName, titleValue, 'basicProductredressRecordMain') detailRef.value.openDetail(row, titleName, titleValue, 'basicProductredressRecordMain')
} }
/** 删除按钮操作 */
const handleDelete = async (id: number) => {
try {
//
await message.delConfirm()
//
await ProductredressRecordMainApi.deleteProductredressRecordMain(id)
message.success(t('common.delSuccess'))
//
await getList()
} catch {}
}
/** 导出按钮操作 */ /** 导出按钮操作 */
const exportLoading = ref(false) // const exportLoading = ref(false) //
const handleExport = async () => { const handleExport = async () => {
@ -211,21 +134,6 @@ const handleExport = async () => {
} }
} }
/** 导入 */
const importFormRef = ref()
const handleImport = () => {
importFormRef.value.open()
}
//
const importTemplateData = reactive({
templateUrl: '',
templateTitle: '制品回收记录主导入模版.xlsx'
})
//
const importSuccess = () => {
getList()
}
// //
const searchFormClick = (searchData) => { const searchFormClick = (searchData) => {
tableObject.params = { tableObject.params = {
@ -238,7 +146,6 @@ const searchFormClick = (searchData) => {
/** 初始化 **/ /** 初始化 **/
onMounted(async () => { onMounted(async () => {
getList() getList()
importTemplateData.templateUrl = await ProductredressRecordMainApi.importTemplate()
}) })
</script> </script>

533
src/views/wms/productionManage/productredress/productredressRecordMain/productredressRecordMain.data.ts

@ -1,213 +1,316 @@
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
import { dateFormatter } from '@/utils/formatTime' import { dateFormatter } from '@/utils/formatTime'
// 获取当前操作人的部门
import { TableColumn } from '@/types/table'
import { useUserStore } from '@/store/modules/user'
const userStore = useUserStore()
const userDept = userStore.userSelfInfo.dept
// id 转str 否则form回显匹配不到
userDept.id = userDept.id.toString()
const userDeptArray:any = [userDept]
// 表单校验 // 表单校验
export const ProductredressRecordMainRules = reactive({ export const ProductredressRecordMainRules = reactive({
}) })
export const ProductredressRecordMain = useCrudSchemas(reactive<CrudSchema[]>([ export const ProductredressRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
{ {
label: '申请单号', label: '单据号',
field: 'requestNumber', field: 'number',
sort: 'custom',
isSearch: true,
},
{
label: '任务单号',
field: 'jobNumber',
sort: 'custom',
},
{
label: '生产计划单号',
field: 'productionPlanNumber',
sort: 'custom', sort: 'custom',
table: {
width: 180,
fixed: 'left'
}, },
{ isForm: false,
label: '车间代码', isSearch: true,
field: 'workshopCode',
sort: 'custom',
}, },
{ {
label: '班组', label: '申请单号',
field: 'team', field: 'requestNumber',
sort: 'custom', sort: 'custom',
isSearch: true,
table: {
width: 180,
}, },
{
label: '班次',
field: 'shift',
sort: 'custom',
}, },
{ {
label: '明细', label: '任务单号',
field: 'details', field: 'jobNumber',
sort: 'custom', sort: 'custom',
}, table: {
width: 180,
},
},
// {
// label: '生产计划单号',
// field: 'productionPlanNumber',
// sort: 'custom',
// },
// {
// label: '车间代码',
// field: 'workshopCode',
// sort: 'custom',
// },
// {
// label: '班组',
// field: 'team',
// sort: 'custom',
// },
// {
// label: '班次',
// field: 'shift',
// sort: 'custom',
// },
// {
// label: '明细',
// field: 'details',
// sort: 'custom',
// },
{ {
label: '出库事务类型', label: '出库事务类型',
field: 'outTransactionType', field: 'outTransactionType',
sort: 'custom', sort: 'custom',
form: { isForm:false,
component: 'SelectV2' isTable:false
},
}, },
{ {
label: '入库事务类型', label: '入库事务类型',
field: 'inTransactionType', field: 'inTransactionType',
sort: 'custom', sort: 'custom',
form: { isForm:false,
component: 'SelectV2' isTable:false
},
}, },
{ {
label: '执行时间', label: '执行时间',
field: 'executeTime', field: 'executeTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: {
width: 180
},
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width: '100%'},
type: 'datetime', type: 'datetime',
valueFormat: 'x' dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
}, },
isForm: false
}, },
{ {
label: '生效日期', label: '生效日期',
field: 'activeDate', field: 'activeDate',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: {
width: 180
},
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width: '100%'},
type: 'datetime', type: 'datetime',
valueFormat: 'x' dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
}, },
isForm: false
}, },
{ {
label: '是否可用', label: '是否可用',
field: 'available', field: 'available',
sort: 'custom', sort: 'custom',
isForm:false,
isTable:false
}, },
{ {
label: '申请时间', label: '申请时间',
field: 'requestTime', field: 'requestTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: {
width: 180
},
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width: '100%'},
type: 'datetime', type: 'datetime',
valueFormat: 'x' dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
}, },
isForm: false
}, },
{ {
label: '截止时间', label: '截止时间',
field: 'dueTime', field: 'dueTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: {
width: 180
},
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width: '100%'},
type: 'datetime', type: 'datetime',
valueFormat: 'x' dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
}, },
isForm: false
}, },
{ {
label: '部门', label: '部门',
field: 'departmentCode', field: 'departmentCode',
sort: 'custom', sort: 'custom',
formatter: (_: Recordable, __: TableColumn, cellValue: number) => {
return userDeptArray.find((account) => account.id == cellValue)?.name
}, },
{ table: {
label: '接口类型', width: 150
field: 'interfaceType',
sort: 'custom',
form: {
component: 'SelectV2'
},
}, },
{ isForm:false,
label: '单据号', isTable:false,
field: 'number',
sort: 'custom',
}, },
{ {
label: '收货类型', label: '接口类型',
field: 'type', field: 'interfaceType',
sort: 'custom', sort: 'custom',
form: { table: {
component: 'SelectV2' width: 150
}, },
isForm:false,
isTable:false,
}, },
{ {
label: '业务类型', label: '业务类型',
field: 'businessType', field: 'businessType',
sort: 'custom', sort: 'custom',
form: { table: {
component: 'SelectV2' width: 150
}, },
isForm:false,
isTable:false,
}, },
{ {
label: '备注', label: '备注',
field: 'remark', field: 'remark',
sort: 'custom', sort: 'custom',
table: {
width: 150
}, },
{
label: '创建时间',
field: 'createTime',
sort: 'custom',
formatter: dateFormatter,
isForm:false, isForm:false,
}, isTable:false,
{
label: '创建者Id',
field: 'creator',
sort: 'custom',
isForm: false,
},
{
label: '代码',
field: 'code',
sort: 'custom',
}, },
{ {
label: '到仓库代码', label: '到仓库代码',
field: 'toWarehouseCode', field: 'toWarehouseCode',
sort: 'custom', sort: 'custom',
table: {
width: 150
},
isForm:false,
isTable:false,
}, },
{ {
label: '到库区类型范围', label: '到库区类型范围',
field: 'toAreaTypes', field: 'toAreaTypes',
sort: 'custom', sort: 'custom',
table: {
width: 150
},
isForm:false,
isTable:false,
}, },
{ {
label: '到库区代码范围', label: '到库区代码范围',
field: 'toAreaCodes', field: 'toAreaCodes',
sort: 'custom', sort: 'custom',
table: {
width: 150
},
isForm:false,
isTable:false,
}, },
{ {
label: '最后更新时间', label: '创建者',
field: 'updateTime', field: 'creator',
sort: 'custom', sort: 'custom',
formatter: dateFormatter,
isForm: false, isForm: false,
table: {
width: 150
},
}, },
{ {
label: '最后更新者用户名', label: '创建时间',
field: 'createTime',
sort: 'custom',
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',
}
},
isForm: false
},
{
label: '最后更新者',
field: 'updater', field: 'updater',
sort: 'custom', sort: 'custom',
isForm: false, isForm: false,
table: {
width: 150
},
}, },
{ {
label: '操作', label: '最后更新时间',
field: 'action', field: 'updateTime',
isForm: false, sort: 'custom',
formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: { table: {
width: 150, width: 180
fixed: 'right' },
form: {
component: 'DatePicker',
componentProps: {
style: {width: '100%'},
type: 'datetime',
dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
},
isForm: false
} }
])) ]))
@ -220,205 +323,237 @@ export const ProductredressRecordDetailRules = reactive({
export const ProductredressRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([ export const ProductredressRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([
{ {
label: 'id', label: '包装号',
field: 'id', field: 'packingNumber',
sort: 'custom', sort: 'custom',
table: {
width: 180
},
isForm: false, isForm: false,
}, },
{ {
label: '生产线代码', label: '批次',
field: 'productionlineCode', field: 'batch',
sort: 'custom', sort: 'custom',
isSearch: true, table: {
width: 150
},
isForm: false,
}, },
{ {
label: '工位代码', label: '物品代码',
field: 'workStationCode', field: 'itemCode',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
{ {
label: '工序代码', label: '物品名称',
field: 'processCode', field: 'itemName',
sort: 'custom', sort: 'custom',
table: {
width: 150
},
}, },
{ {
label: '包装号', label: '物品描述1',
field: 'packingNumber', field: 'itemDesc1',
sort: 'custom', sort: 'custom',
table: {
width: 150
},
}, },
{ {
label: '器具号', label: '物品描述2',
field: 'containerNumber', field: 'itemDesc2',
sort: 'custom', sort: 'custom',
table: {
width: 150
},
}, },
{ {
label: '批次', label: '项目代码',
field: 'batch', field: 'projectCode',
sort: 'custom', sort: 'custom',
isSearch: true, table: {
width: 150
},
},
{
label: '数量',
field: 'qty',
sort: 'custom',
table: {
width: 150
},
},
{
label: '计量单位',
field: 'uom',
dictType: DICT_TYPE.UOM,
dictClass: 'string',
sort: 'custom',
table: {
width: 150
},
}, },
{ {
label: '生产日期', label: '生产日期',
field: 'produceDate', field: 'produceDate',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: {
width: 180
},
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width: '100%'},
type: 'datetime', type: 'datetime',
valueFormat: 'x' dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
}, },
isForm: false
}, },
{ {
label: '过期日期', label: '过期日期',
field: 'expireDate', field: 'expireDate',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
table: {
width: 180
},
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width: '100%'},
type: 'datetime', type: 'datetime',
valueFormat: 'x' dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
}, },
}, isForm: false
{
label: '库存状态',
field: 'inventoryStatus',
sort: 'custom',
form: {
component: 'Radio'
},
},
{
label: '到库位代码',
field: 'toLocationCode',
sort: 'custom',
},
{
label: '到库位组代码',
field: 'toLocationGroupCode',
sort: 'custom',
},
{
label: '到库区代码',
field: 'toAreaCode',
sort: 'custom',
},
{
label: '到货主代码',
field: 'toOwnerCode',
sort: 'custom',
},
{
label: '订单号',
field: 'woNumber',
sort: 'custom',
},
{
label: '订单行',
field: 'woLine',
sort: 'custom',
}, },
{ {
label: '包装数量', label: '包装数量',
field: 'packQty', field: 'packQty',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
{ {
label: '包装规格', label: '包装规格',
field: 'packUnit', field: 'packUnit',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
{ {
label: 'BOM版本', label: 'BOM版本',
field: 'bomVersion', field: 'bomVersion',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
{ {
label: '明细', label: '库存状态',
field: 'backFlushDetails', field: 'inventoryStatus',
sort: 'custom', sort: 'custom',
dictType: DICT_TYPE.INVENTORY_STATUS,
dictClass: 'string',
table: {
width: 150
}
}, },
{ {
label: '主表ID', label: '到库位代码',
field: 'masterId', field: 'toLocationCode',
sort: 'custom', sort: 'custom',
form: { table: {
component: 'InputNumber', width: 150
value: 0 }
},
}, },
{ {
label: '单据号', label: '到库位组代码',
field: 'number', field: 'toLocationGroupCode',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
{ {
label: '物品代码', label: '到库区代码',
field: 'itemCode', field: 'toAreaCode',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
// {
// label: '到货主代码',
// field: 'toOwnerCode',
// sort: 'custom',
// table: {
// width: 150
// }
// },
{ {
label: '备注', label: '备注',
field: 'remark', field: 'remark',
sort: 'custom', sort: 'custom',
table: {
width: 150
}
}, },
{ {
label: '创建时间', label: '创建者',
field: 'createTime',
sort: 'custom',
formatter: dateFormatter,
isForm: false,
},
{
label: '创建者Id',
field: 'creator', field: 'creator',
sort: 'custom', sort: 'custom',
isForm: false, isForm: false,
table: {
width: 150
}, },
{
label: '地点ID',
field: 'siteId',
sort: 'custom',
},
{
label: '物品名称',
field: 'itemName',
sort: 'custom',
}, },
{ {
label: '物品描述1', label: '创建时间',
field: 'itemDesc1', field: 'createTime',
sort: 'custom',
},
{
label: '物品描述2',
field: 'itemDesc2',
sort: 'custom', sort: 'custom',
formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
}, },
{ table: {
label: '项目代码', width: 180
field: 'projectCode',
sort: 'custom',
}, },
{ form: {
label: '数量', component: 'DatePicker',
field: 'qty', componentProps: {
sort: 'custom', style: {width: '100%'},
type: 'datetime',
dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
}
}, },
{ isForm: false
label: '计量单位',
field: 'uom',
sort: 'custom',
}, },
{ {
label: '接口类型', label: '最后更新者',
field: 'interfaceType', field: 'updater',
sort: 'custom', sort: 'custom',
form: { isForm: false,
component: 'SelectV2' table: {
width: 150
}, },
}, },
{ {
@ -426,21 +561,21 @@ export const ProductredressRecordDetail = useCrudSchemas(reactive<CrudSchema[]>(
field: 'updateTime', field: 'updateTime',
sort: 'custom', sort: 'custom',
formatter: dateFormatter, formatter: dateFormatter,
isForm: false, detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
}, },
{
label: '最后更新者用户名',
field: 'updater',
sort: 'custom',
isForm: false,
},
{
label: '操作',
field: 'action',
isForm: false,
table: { table: {
width: 150, width: 180
fixed: 'right' },
form: {
component: 'DatePicker',
componentProps: {
style: {width: '100%'},
type: 'datetime',
dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
} }
},
isForm: false
} }
])) ]))

5
src/views/wms/productionManage/productredress/productredressRequestMain/productredressRequestMain.data.ts

@ -112,6 +112,7 @@ export const ProductredressRequestMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'toWarehouseCode', field: 'toWarehouseCode',
sort: 'custom', sort: 'custom',
isForm:false, isForm:false,
isTable:false,
table: { table: {
width: 150 width: 150
}, },
@ -121,6 +122,7 @@ export const ProductredressRequestMain = useCrudSchemas(reactive<CrudSchema[]>([
field: 'departmentCode', field: 'departmentCode',
sort: 'custom', sort: 'custom',
isForm:false, isForm:false,
isTable:false,
table: { table: {
width: 150 width: 150
}, },
@ -172,6 +174,7 @@ export const ProductredressRequestMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '备注', label: '备注',
field: 'remark', field: 'remark',
sort: 'custom', sort: 'custom',
isTable:false,
}, },
{ {
label: '到库区类型范围', label: '到库区类型范围',
@ -410,6 +413,8 @@ export const ProductredressRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
{ {
label: '计量单位', label: '计量单位',
field: 'uom', field: 'uom',
dictType: DICT_TYPE.UOM,
dictClass: 'string',
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150

Loading…
Cancel
Save