Commit 8d4a7ace by 张珈源

feat(cgrk): 更新采购入库模块字段配置和界面组件

- 在CgrkModel模型中添加zdr、pch、ywzz字段并调整字段顺序
- 配置文件中增加制单人、批次号、业务组织字段的UI配置
- 列表表格中将库存组织、采购组织替换为制单人、批次号、业务组织列
- 更新供应商字段的maxlength属性配置
- 调整制单人字段为用户选择组件并修改相关属性
- 将批次号字段配置为自动编码规则组件
- 业务组织字段配置为下拉选择组件并设置数据源
- 禁用列表新增按钮功能并将编辑按钮添加到操作栏
- 扩展操作列宽度以适应更多按钮显示
- 实现编辑功能处理方法支持记录编辑操作
- 更新工作流权限配置中的字段类型和标识符映射
parent b1c622b8
...@@ -9,6 +9,12 @@ export interface MesWarehouseInPageParams extends BasicPageParams { ...@@ -9,6 +9,12 @@ export interface MesWarehouseInPageParams extends BasicPageParams {
ck: string; ck: string;
gys: string; gys: string;
zdr: string;
pch: string;
ywzz: string;
} }
/** /**
...@@ -27,11 +33,11 @@ export interface MesWarehouseInPageModel { ...@@ -27,11 +33,11 @@ export interface MesWarehouseInPageModel {
gys: string; gys: string;
kczz: string; zdr: string;
cgzz: string; pch: string;
zdr: string; ywzz: string;
bz: string; bz: string;
} }
...@@ -46,10 +52,6 @@ export interface MesWarehouseInModel { ...@@ -46,10 +52,6 @@ export interface MesWarehouseInModel {
djh: string; djh: string;
kczz: string;
cgzz: string;
djrq: string; djrq: string;
crklx: string; crklx: string;
...@@ -64,9 +66,9 @@ export interface MesWarehouseInModel { ...@@ -64,9 +66,9 @@ export interface MesWarehouseInModel {
bz: string; bz: string;
p3: string; ywzz: string;
p4: string; pch: string;
p5: string; p5: string;
......
...@@ -30,6 +30,38 @@ export const searchFormSchema: FormSchema[] = [ ...@@ -30,6 +30,38 @@ export const searchFormSchema: FormSchema[] = [
defaultValue: undefined, defaultValue: undefined,
component: 'Input', component: 'Input',
}, },
{
field: 'zdr',
label: '制单人',
defaultValue: undefined,
component: 'User',
componentProps: {
suffix: 'ant-design:setting-outlined',
placeholder: '请选择',
},
},
{
field: 'pch',
label: '批次号',
defaultValue: undefined,
component: 'Input',
},
{
field: 'ywzz',
label: '业务组织',
defaultValue: undefined,
component: 'XjrSelect',
componentProps: {
datasourceType: 'dic',
params: { itemId: '2015724355955159041' },
labelField: 'name',
valueField: 'value',
mode: 'multiple',
showSearch: true,
getPopupContainer: () => document.body,
},
},
]; ];
export const columns: BasicColumn[] = [ export const columns: BasicColumn[] = [
...@@ -100,41 +132,41 @@ export const columns: BasicColumn[] = [ ...@@ -100,41 +132,41 @@ export const columns: BasicColumn[] = [
{ {
resizable: true, resizable: true,
dataIndex: 'kczz', dataIndex: 'zdr',
title: '库存组织', title: '制单人',
componentType: 'input', componentType: 'user',
fixed: false, fixed: false,
sorter: true, sorter: true,
styleConfig: undefined, styleConfig: undefined,
listStyle: '', listStyle: undefined,
}, },
{ {
resizable: true, resizable: true,
dataIndex: 'cgzz', dataIndex: 'pch',
title: '采购组织', title: '批次号',
componentType: 'input', componentType: 'auto-code',
fixed: false, fixed: false,
sorter: true, sorter: true,
styleConfig: undefined, styleConfig: undefined,
listStyle: '', listStyle: undefined,
}, },
{ {
resizable: true, resizable: true,
dataIndex: 'zdr', dataIndex: 'ywzz',
title: '制单人', title: '业务组织',
componentType: 'input', componentType: 'select',
fixed: false, fixed: false,
sorter: true, sorter: true,
styleConfig: undefined, styleConfig: undefined,
listStyle: '', listStyle: undefined,
}, },
{ {
...@@ -383,7 +415,7 @@ export const formProps: FormProps = { ...@@ -383,7 +415,7 @@ export const formProps: FormProps = {
span: 8, span: 8,
list: [ list: [
{ {
key: '088c468398ab48bd996990978a6d54b7', key: 'cc1a975fc12c43a69b75687e1af784e5',
field: 'gys', field: 'gys',
label: '供应商', label: '供应商',
type: 'input', type: 'input',
...@@ -395,6 +427,7 @@ export const formProps: FormProps = { ...@@ -395,6 +427,7 @@ export const formProps: FormProps = {
span: 7, span: 7,
defaultValue: '', defaultValue: '',
placeholder: '请输入供应商', placeholder: '请输入供应商',
maxlength: null,
prefix: '', prefix: '',
suffix: '', suffix: '',
addonBefore: '', addonBefore: '',
...@@ -421,34 +454,27 @@ export const formProps: FormProps = { ...@@ -421,34 +454,27 @@ export const formProps: FormProps = {
span: 8, span: 8,
list: [ list: [
{ {
key: 'bed480e33d304f06b76cfffcc020f546', key: 'f6cab4a9e2894121b5a05dc6e1addf49',
field: 'zdr', field: 'zdr',
label: '制单人', label: '制单人',
type: 'input', type: 'user',
component: 'Input', component: 'User',
colProps: { span: 24 }, colProps: { span: 24 },
defaultValue: '', defaultValue: '',
componentProps: { componentProps: {
width: '100%',
span: 7, span: 7,
width: '100%',
defaultValue: '', defaultValue: '',
placeholder: '请输入制单人', placeholder: '请选择人员',
userType: 0,
prefix: '', prefix: '',
suffix: '', suffix: '',
addonBefore: '',
addonAfter: '',
disabled: false,
allowClear: false,
showLabel: true, showLabel: true,
disabled: false,
required: false, required: false,
rules: [], multiple: true,
events: {},
listStyle: '',
isSave: false,
isShow: true, isShow: true,
scan: false, events: {},
bordered: true,
isShowAi: false,
tooltipConfig: { visible: false, title: '提示文本' }, tooltipConfig: { visible: false, title: '提示文本' },
style: { width: '100%' }, style: { width: '100%' },
}, },
...@@ -459,34 +485,24 @@ export const formProps: FormProps = { ...@@ -459,34 +485,24 @@ export const formProps: FormProps = {
span: 8, span: 8,
list: [ list: [
{ {
key: 'fae35f38efc94386a6389b11c4ed164d', key: '8661293203314885bc02bb17bae70147',
field: 'kczz', field: 'pch',
label: '库存组织', label: '批次号',
type: 'input', type: 'auto-code',
component: 'Input', component: 'AutoCodeRule',
colProps: { span: 24 }, colProps: { span: 24 },
defaultValue: '',
componentProps: { componentProps: {
width: '100%', width: '100%',
span: 7, span: 7,
defaultValue: '', placeholder: '请输入批次号',
placeholder: '请输入库存组织',
prefix: '', prefix: '',
suffix: '', suffix: '',
addonBefore: '', addonBefore: '',
addonAfter: '', addonAfter: '',
disabled: false,
allowClear: false,
showLabel: true, showLabel: true,
autoCodeRule: 'cgrkpc',
required: false, required: false,
rules: [],
events: {},
listStyle: '',
isSave: false,
isShow: true, isShow: true,
scan: false,
bordered: true,
isShowAi: false,
tooltipConfig: { visible: false, title: '提示文本' }, tooltipConfig: { visible: false, title: '提示文本' },
style: { width: '100%' }, style: { width: '100%' },
}, },
...@@ -497,35 +513,43 @@ export const formProps: FormProps = { ...@@ -497,35 +513,43 @@ export const formProps: FormProps = {
span: 8, span: 8,
list: [ list: [
{ {
key: '1293af02768d4c2c897ee5964e5ba3f4', key: '55bfa8e7f6374af0a0be531657c966d9',
field: 'cgzz', field: 'ywzz',
label: '采购组织', label: '业务组织',
type: 'input', type: 'select',
component: 'Input', component: 'XjrSelect',
colProps: { span: 24 }, colProps: { span: 24 },
defaultValue: '',
componentProps: { componentProps: {
width: '100%', width: '100%',
span: 7, span: 7,
defaultValue: '', placeholder: '请选择下拉选择业务组织',
placeholder: '请输入采购组织',
prefix: '',
suffix: '',
addonBefore: '',
addonAfter: '',
disabled: false,
allowClear: false,
showLabel: true, showLabel: true,
showSearch: false,
isMultiple: false,
clearable: false,
disabled: false,
staticOptions: [
{ key: 1, label: 'Option 1', value: 'Option 1' },
{ key: 2, label: 'Option 2', value: 'Option 2' },
{ key: 3, label: 'Option 3', value: 'Option 3' },
],
defaultSelect: null,
datasourceType: 'dic',
params: { itemId: '2015724355955159041' },
labelField: 'name',
valueField: 'value',
apiConfig: {
path: 'CodeGeneration/selection',
method: 'GET',
apiId: '93d735dcb7364a0f8102188ec4d77ac7',
},
dicOptions: [],
required: false, required: false,
rules: [], rules: [],
events: {}, events: {},
listStyle: '',
isSave: false,
isShow: true, isShow: true,
scan: false,
bordered: true,
isShowAi: false,
tooltipConfig: { visible: false, title: '提示文本' }, tooltipConfig: { visible: false, title: '提示文本' },
itemId: '2015724355955159041',
style: { width: '100%' }, style: { width: '100%' },
}, },
}, },
...@@ -1014,7 +1038,7 @@ export const formProps: FormProps = { ...@@ -1014,7 +1038,7 @@ export const formProps: FormProps = {
isDeleteSelected: false, isDeleteSelected: false,
isListView: false, isListView: false,
viewList: [], viewList: [],
isShowAdd: true, isShowAdd: false,
isShowDelete: true, isShowDelete: true,
hasCheckedCol: false, hasCheckedCol: false,
events: {}, events: {},
......
...@@ -76,7 +76,7 @@ export const permissionList = [ ...@@ -76,7 +76,7 @@ export const permissionList = [
isSubTable: false, isSubTable: false,
showChildren: true, showChildren: true,
type: 'input', type: 'input',
key: '088c468398ab48bd996990978a6d54b7', key: 'cc1a975fc12c43a69b75687e1af784e5',
children: [], children: [],
options: {}, options: {},
defaultValue: '', defaultValue: '',
...@@ -92,8 +92,8 @@ export const permissionList = [ ...@@ -92,8 +92,8 @@ export const permissionList = [
fieldId: 'zdr', fieldId: 'zdr',
isSubTable: false, isSubTable: false,
showChildren: true, showChildren: true,
type: 'input', type: 'user',
key: 'bed480e33d304f06b76cfffcc020f546', key: 'f6cab4a9e2894121b5a05dc6e1addf49',
children: [], children: [],
options: {}, options: {},
defaultValue: '', defaultValue: '',
...@@ -101,19 +101,18 @@ export const permissionList = [ ...@@ -101,19 +101,18 @@ export const permissionList = [
{ {
required: false, required: false,
view: true, view: true,
edit: true, edit: false,
disabled: false, disabled: true,
isSaveTable: false, isSaveTable: false,
tableName: '', tableName: '',
fieldName: '库存组织', fieldName: '批次号',
fieldId: 'kczz', fieldId: 'pch',
isSubTable: false, isSubTable: false,
showChildren: true, showChildren: true,
type: 'input', type: 'auto-code',
key: 'fae35f38efc94386a6389b11c4ed164d', key: '8661293203314885bc02bb17bae70147',
children: [], children: [],
options: {}, options: {},
defaultValue: '',
}, },
{ {
required: false, required: false,
...@@ -122,15 +121,14 @@ export const permissionList = [ ...@@ -122,15 +121,14 @@ export const permissionList = [
disabled: false, disabled: false,
isSaveTable: false, isSaveTable: false,
tableName: '', tableName: '',
fieldName: '采购组织', fieldName: '业务组织',
fieldId: 'cgzz', fieldId: 'ywzz',
isSubTable: false, isSubTable: false,
showChildren: true, showChildren: true,
type: 'input', type: 'select',
key: '1293af02768d4c2c897ee5964e5ba3f4', key: '55bfa8e7f6374af0a0be531657c966d9',
children: [], children: [],
options: {}, options: {},
defaultValue: '',
}, },
{ {
required: false, required: false,
......
...@@ -140,9 +140,9 @@ ...@@ -140,9 +140,9 @@
//展示在列表内的按钮 //展示在列表内的按钮
const actionButtons = ref<string[]>(["view","delete"]); const actionButtons = ref<string[]>(["view","edit","delete"]);
const buttonConfigs = computed(()=>{ const buttonConfigs = computed(()=>{
const list = [{"buttonId":"2011687510413426688","name":"查看","code":"view","icon":"ant-design:eye-outlined","isDefault":true,"isUse":true},{"buttonId":"2011687510413426689","name":"新增","code":"add","icon":"ant-design:plus-outlined","isDefault":true,"isUse":true},{"name":"打印","code":"print","icon":"ant-design:printer-outlined","isDefault":true,"isUse":true},{"buttonId":"2011691871017484288","name":"快速导出","code":"export","icon":"ant-design:export-outlined","isDefault":true,"isUse":true},{"buttonId":"2011691871017484289","name":"提交","code":"commit","icon":"ant-design:arrow-up-outlined","isDefault":false,"isUse":true,"setting":[],"showType":"top","buttonType":"primary"},{"buttonId":"2011687510413426691","name":"删除","code":"delete","icon":"ant-design:delete-outlined","isDefault":true,"isUse":true}] const list = [{"buttonId":"2011687510413426688","name":"查看","code":"view","icon":"ant-design:eye-outlined","isDefault":true,"isUse":true},{"buttonId":"2011687510413426689","name":"新增","code":"add","icon":"ant-design:plus-outlined","isDefault":true,"isUse":true},{"buttonId":"2011687510413426690","name":"编辑","code":"edit","icon":"ant-design:form-outlined","isDefault":true,"isUse":true,"isEnableLock":true},{"buttonId":"2011729952881885184","name":"打印","code":"print","icon":"ant-design:printer-outlined","isDefault":true,"isUse":true},{"buttonId":"2011691871017484288","name":"快速导出","code":"export","icon":"ant-design:export-outlined","isDefault":true,"isUse":true},{"buttonId":"2011691871017484289","name":"提交","code":"commit","icon":"ant-design:arrow-up-outlined","isDefault":false,"isUse":true,"setting":[],"showType":"top","buttonType":"primary"},{"buttonId":"2011687510413426691","name":"删除","code":"delete","icon":"ant-design:delete-outlined","isDefault":true,"isUse":true}]
return filterButtonAuth(list); return filterButtonAuth(list);
}) })
...@@ -154,7 +154,7 @@ ...@@ -154,7 +154,7 @@
return buttonConfigs.value?.filter((x) => actionButtons.value.includes(x.code)); return buttonConfigs.value?.filter((x) => actionButtons.value.includes(x.code));
}); });
const btnEvent = {view : handleView,add : handleAdd,print : handlePrint,export : handleExport,delete : handleDelete,} const btnEvent = {view : handleView,add : handleAdd,edit : handleEdit,print : handlePrint,export : handleExport,delete : handleDelete,}
const { currentRoute } = useRouter(); const { currentRoute } = useRouter();
...@@ -211,7 +211,7 @@ ...@@ -211,7 +211,7 @@
striped: false, striped: false,
actionColumn: { actionColumn: {
width: 130, width: 195,
title: '操作', title: '操作',
dataIndex: 'action', dataIndex: 'action',
slots: { customRender: 'action' }, slots: { customRender: 'action' },
...@@ -242,6 +242,30 @@ ...@@ -242,6 +242,30 @@
} }
async function handleEdit(record: Recordable) {
let field = 'id';
try {
let hasIn = handleHasEnableLocke(buttonConfigs.value, 'edit');
if (hasIn) {
let res = await handleOpenFormEnableLockeData(
record[field],
formIdComputedRef.value,
);
if (res !== null) {
return;
}
}
let info = {
id: record[field],
isUpdate: true,
};
openModal(true, info);
} catch (error) {}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment