Commit 82f47016 by 张恒

fix(scgl): 解决生产计划和生产任务编辑权限控制问题

- 在生产计划模块中添加状态检查,非草稿状态的任务无法编辑并显示提示
- 在生产任务模块中添加状态检查,非草稿状态的任务无法编辑并显示提示
- 集成Modal警告对话框用于用户状态提醒
- 保持原有编辑功能逻辑不变,仅增加前置状态验证
parent e81e3b06
......@@ -532,12 +532,15 @@ export const formProps: FormProps = {
style: { width: '100%' },
},
},
{
key: '427fc55accd744d0a6359faf80e45a1b',
field: 'sccx',
label: '产线',
type: 'associate-select',
component: 'AssociateSelect',
key: '21610208f2b8428e84de66979709d296',
field: 'sccj',
label: '车间',
type: 'select',
component: 'XjrSelect',
colProps: { span: 24 },
componentProps: {
width: '100%',
......@@ -545,34 +548,29 @@ export const formProps: FormProps = {
placeholder: '请选择',
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: '',
datasourceType: 'api',
labelField: 'label',
valueField: 'value',
apiConfig: {
path: '/scgl/scrw/getCxByCjbh',
path: '/scgl/scrw/getAllChejian',
method: 'GET',
apiId: 'ecbc0291292c49fca50468561b9770e8',
apiId: '59730efb7b4a4439a013cac04926e00e',
apiParams: [
{
key: '1',
title: 'Query Params',
tableInfo: [
{
name: 'cjid',
value:
'{"bindField":"sccj","fieldKey":"21610208f2b8428e84de66979709d296"}',
required: true,
defaultValue: '0',
bindType: 'data',
},
],
},
{ key: '1', title: 'Query Params', tableInfo: [] },
{ key: '2', title: 'Header', tableInfo: [] },
{ key: '3', title: 'Body' },
],
script:
"var sql='select cx.*,cx.id as value,cx.cxmc as label from mes_base_chanxian cx join mes_base_cj_cx rela on cx.id=rela.cxid where rela.delete_mark=0 and cx.delete_mark=0 and rela.cjid=#{cjid}'\r\nreturn db.select(sql)",
"var sql='select *,id as value,cjmc as label from mes_base_chejian where delete_mark=0'\r\nreturn db.select(sql)",
},
dicOptions: [],
required: false,
......@@ -693,11 +691,11 @@ export const formProps: FormProps = {
},
},
{
key: '21610208f2b8428e84de66979709d296',
field: 'sccj',
label: '车间',
type: 'select',
component: 'XjrSelect',
key: '427fc55accd744d0a6359faf80e45a1b',
field: 'sccx',
label: '产线',
type: 'associate-select',
component: 'AssociateSelect',
colProps: { span: 24 },
componentProps: {
width: '100%',
......@@ -705,29 +703,34 @@ export const formProps: FormProps = {
placeholder: '请选择',
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: '',
datasourceType: 'api',
labelField: 'label',
valueField: 'value',
apiConfig: {
path: '/scgl/scrw/getAllChejian',
path: '/scgl/scrw/getCxByCjbh',
method: 'GET',
apiId: '59730efb7b4a4439a013cac04926e00e',
apiId: 'ecbc0291292c49fca50468561b9770e8',
apiParams: [
{ key: '1', title: 'Query Params', tableInfo: [] },
{
key: '1',
title: 'Query Params',
tableInfo: [
{
name: 'cjid',
value:
'{"bindField":"sccj","fieldKey":"21610208f2b8428e84de66979709d296"}',
required: true,
defaultValue: '0',
bindType: 'data',
},
],
},
{ key: '2', title: 'Header', tableInfo: [] },
{ key: '3', title: 'Body' },
],
script:
"var sql='select *,id as value,cjmc as label from mes_base_chejian where delete_mark=0'\r\nreturn db.select(sql)",
"var sql='select cx.*,cx.id as value,cx.cxmc as label from mes_base_chanxian cx join mes_base_cj_cx rela on cx.id=rela.cxid where rela.delete_mark=0 and cx.delete_mark=0 and rela.cjid=#{cjid}'\r\nreturn db.select(sql)",
},
dicOptions: [],
required: false,
......
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