Commit 730f6cac by 张珈源

feat(ckgl): 更新库存盘点组件数据源配置

- 将选择框数据源从字典类型改为API类型
- 配置新的API接口getStoreLocation获取库位信息
- 更新SQL查询脚本获取库位表有效数据
- 移除按钮配置中的modal空属性
- 添加defaultSelect空配置到下拉选择框
- 统一label字段为label,value字段为value
parent 8eedcd03
......@@ -8,9 +8,20 @@ export const searchFormSchema: FormSchema[] = [
defaultValue: undefined,
component: 'XjrSelect',
componentProps: {
datasourceType: 'dic',
params: { itemId: '2010539474382962690' },
labelField: 'name',
datasourceType: 'api',
apiConfig: {
path: '/getStoreLocation',
method: 'GET',
apiId: 'd55f1866db284ecd8b038a3956b9c5b7',
apiParams: [
{ key: '1', title: 'Query Params', tableInfo: [] },
{ key: '2', title: 'Header', tableInfo: [] },
{ key: '3', title: 'Body' },
],
script:
'var sql="select id as value,name as label from mes_storage_location where delete_mark = 0 ";\r\nreturn db.select(sql);',
},
labelField: 'label',
valueField: 'value',
mode: 'multiple',
showSearch: true,
......@@ -238,7 +249,6 @@ export const formProps: FormProps = {
isShow: true,
margin: '10px',
events: { click: "formActionType.showMessage('开始盘点')" },
modal: null,
type: 1,
event: [],
tooltipConfig: { visible: false, title: '提示文本' },
......@@ -282,7 +292,6 @@ export const formProps: FormProps = {
isShow: true,
margin: '10px',
events: { click: "formActionType.showMessage('确认盘点')" },
modal: null,
type: 1,
event: [],
tooltipConfig: { visible: false, title: '提示文本' },
......@@ -326,7 +335,6 @@ export const formProps: FormProps = {
isShow: true,
margin: '10px',
events: { click: "formActionType.showMessage('取消盘点')" },
modal: null,
type: 1,
event: [],
tooltipConfig: { visible: false, title: '提示文本' },
......@@ -383,14 +391,21 @@ export const formProps: FormProps = {
{ key: 2, label: 'Option 2', value: 'Option 2' },
{ key: 3, label: 'Option 3', value: 'Option 3' },
],
datasourceType: 'dic',
params: { itemId: '2010539474382962690' },
labelField: 'name',
datasourceType: 'api',
params: null,
labelField: 'label',
valueField: 'value',
apiConfig: {
path: 'CodeGeneration/selection',
path: '/getStoreLocation',
method: 'GET',
apiId: '93d735dcb7364a0f8102188ec4d77ac7',
apiId: 'd55f1866db284ecd8b038a3956b9c5b7',
apiParams: [
{ key: '1', title: 'Query Params', tableInfo: [] },
{ key: '2', title: 'Header', tableInfo: [] },
{ key: '3', title: 'Body' },
],
script:
'var sql="select id as value,name as label from mes_storage_location where delete_mark = 0 ";\r\nreturn db.select(sql);',
},
dicOptions: [],
required: true,
......@@ -399,6 +414,7 @@ export const formProps: FormProps = {
isShow: true,
tooltipConfig: { visible: false, title: '提示文本' },
itemId: '2010539474382962690',
defaultSelect: null,
style: { width: '100%' },
},
},
......@@ -714,14 +730,21 @@ export const formProps: FormProps = {
{ key: 2, label: 'Option 2', value: 'Option 2' },
{ key: 3, label: 'Option 3', value: 'Option 3' },
],
datasourceType: 'dic',
params: { itemId: '2010539474382962690' },
labelField: 'name',
datasourceType: 'api',
params: null,
labelField: 'label',
valueField: 'value',
apiConfig: {
path: 'CodeGeneration/selection',
path: '/getStoreLocation',
method: 'GET',
apiId: '93d735dcb7364a0f8102188ec4d77ac7',
apiId: 'd55f1866db284ecd8b038a3956b9c5b7',
apiParams: [
{ key: '1', title: 'Query Params', tableInfo: [] },
{ key: '2', title: 'Header', tableInfo: [] },
{ key: '3', title: 'Body' },
],
script:
'var sql="select id as value,name as label from mes_storage_location where delete_mark = 0 ";\r\nreturn db.select(sql);',
},
dicOptions: [],
required: false,
......@@ -730,6 +753,7 @@ export const formProps: FormProps = {
isShow: true,
tooltipConfig: { visible: false, title: '提示文本' },
itemId: '2010539474382962690',
defaultSelect: null,
listStyle: "return 'border: 0'",
},
},
......@@ -843,7 +867,6 @@ export const formButtons = [
isShow: true,
index: 2,
type: 1,
modal: null,
},
{
key: 'cancel',
......@@ -854,7 +877,6 @@ export const formButtons = [
isShow: true,
index: 1,
type: 1,
modal: null,
},
{
key: 'reset',
......@@ -865,6 +887,5 @@ export const formButtons = [
isShow: true,
index: 0,
type: 1,
modal: null,
},
];
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