Commit 7ec95129 by 张珈源

feat(ckgl): 更新采购到货页面配置和按钮功能

- 修改物料编码和物料名称字段类型从value改为form
- 更新按钮配置添加新增功能按钮
- 添加handleAdd事件处理函数
- 优化按钮事件映射配置
- 调整代码格式和缩进
- 更新按钮权限过滤逻辑
parent 4fc271ac
...@@ -132,7 +132,7 @@ ...@@ -132,7 +132,7 @@
//展示在列表内的按钮 //展示在列表内的按钮
const actionButtons = ref<string[]>(["view","edit","create"]); const actionButtons = ref<string[]>(["view","edit","create"]);
const buttonConfigs = computed(()=>{ const buttonConfigs = computed(()=>{
const list = [{"buttonId":"2009445983314264064","name":"查看","code":"view","icon":"ant-design:eye-outlined","isDefault":true,"isUse":true},{"buttonId":"2009445983314264066","name":"编辑","code":"edit","icon":"ant-design:form-outlined","isDefault":true,"isUse":true,"isEnableLock":true},{"buttonId":"2009478676487966720","name":"同步","code":"get","icon":"ant-design:arrow-down-outlined","isDefault":false,"isUse":true,"setting":[],"showType":"top","buttonType":"primary"},{"buttonId":"2012037219988561920","name":"生成入库单","code":"create","icon":"ant-design:download-outlined","isDefault":false,"isUse":true,"setting":[],"showType":"inline","buttonType":"primary"}] const list = [{"buttonId":"2009445983314264064","name":"查看","code":"view","icon":"ant-design:eye-outlined","isDefault":true,"isUse":true},{"buttonId":"2009445983314264065","name":"新增","code":"add","icon":"ant-design:plus-outlined","isDefault":true,"isUse":true},{"buttonId":"2009445983314264066","name":"编辑","code":"edit","icon":"ant-design:form-outlined","isDefault":true,"isUse":true,"isEnableLock":true},{"buttonId":"2009478676487966720","name":"同步","code":"get","icon":"ant-design:arrow-down-outlined","isDefault":false,"isUse":true,"setting":[],"showType":"top","buttonType":"primary"},{"buttonId":"2012037219988561920","name":"生成入库单","code":"create","icon":"ant-design:download-outlined","isDefault":false,"isUse":true,"setting":[],"showType":"inline","buttonType":"primary"}]
return filterButtonAuth(list); return filterButtonAuth(list);
}) })
...@@ -144,7 +144,7 @@ ...@@ -144,7 +144,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,edit : handleEdit,create : handleCreate} const btnEvent = {view : handleView,edit : handleEdit,create : handleCreate,add : handleAdd}
const { currentRoute } = useRouter(); const { currentRoute } = useRouter();
...@@ -224,6 +224,13 @@ ...@@ -224,6 +224,13 @@
} }
function handleAdd() {
openModal(true, { isUpdate: false, });
}
async function handleEdit(record: Recordable) { async function handleEdit(record: Recordable) {
let field = 'id'; let field = 'id';
......
...@@ -732,24 +732,18 @@ export const formProps: FormProps = { ...@@ -732,24 +732,18 @@ export const formProps: FormProps = {
innerParams: [ innerParams: [
{ {
name: '物料编码', name: '物料编码',
type: 'value', type: 'form',
value: '', value:
apiConfig: { '{"key":"1efb753a8bb24b81bb9834ce244e301c","table":"mes_warehouse_prepare_info","field":"wlbh"}',
path: 'CodeGeneration/selection', apiConfig: '',
method: 'GET',
apiId: '93d735dcb7364a0f8102188ec4d77ac7',
},
component: '{"table":"table_17482","field":"wu_liao_bian_ma5244"}', component: '{"table":"table_17482","field":"wu_liao_bian_ma5244"}',
}, },
{ {
name: '物料名称', name: '物料名称',
type: 'value', type: 'form',
value: '', value:
apiConfig: { '{"key":"e91cc7cef4cb47e78a87362aa77bb084","table":"mes_warehouse_prepare_info","field":"wlmc"}',
path: 'CodeGeneration/selection', apiConfig: '',
method: 'GET',
apiId: '93d735dcb7364a0f8102188ec4d77ac7',
},
component: '{"table":"table_17482","field":"wu_liao_ming_chen9124"}', component: '{"table":"table_17482","field":"wu_liao_ming_chen9124"}',
}, },
], ],
......
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