Commit aa969d0b authored by XieZhiXiong's avatar XieZhiXiong

fix: 修复检索条件展示不对的问题

parent a3884c1b
......@@ -68,17 +68,6 @@ export const rectificationListSchema: ISchema = {
},
},
},
outerStatus: {
type: 'string',
enum: [],
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberRectification.common.columns.queryColumns.outState'})}`,
allowClear: true,
style: {
width: 160,
},
},
},
submit: {
'x-component': 'Submit',
'x-mega-props': {
......
......@@ -39,7 +39,7 @@ const List: React.FC<Iprops> = (props: Iprops) => {
<Card>
<CustomizeQueryList
columns={columns}
schema={querySchema}
schema={querySchema(true)}
fetchListData={handleFetch}
expressionScope={{
controllerBtns,
......
......@@ -56,7 +56,7 @@ const List: React.FC<Iprops> = (props: Iprops) => {
<Card>
<CustomizeQueryList
columns={columns}
schema={querySchema}
schema={querySchema(false)}
fetchListData={handleFetch}
effects={($, actions) => {
useStateFilterSearchLinkageEffect($, actions, 'name', FORM_FILTER_PATH,);
......
......@@ -77,77 +77,87 @@ export default confirmEditResultSchema
/**
* 会员考评页scheam
* @param visibleOuterStatus 是否可见外部状态
* @returns
*/
export const querySchema: ISchema = {
type: 'object',
properties: {
megaLayout: {
type: 'object',
'x-component': 'mega-layout',
properties: {
name: {
type: 'string',
'x-component': 'Search',
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberInspection.common.schema.add.searchMemberName'})}`,
align: 'flex-left',
tip: `${intl.formatMessage({ id: 'member.memberEvaluate.allQuery.schema.searchForMemberName'})}`,
},
export const querySchema: (visibleOuterStatus: boolean) => ISchema = (visibleOuterStatus) => {
const extraProperties = {
subject: {
type: 'string',
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberRectification.common.hooks.useGetDetailCommon.rectifyTopic'})}`,
allowClear: true,
style: {
width: 160,
},
[FORM_FILTER_PATH]: {
type: 'object',
'x-component': 'mega-layout',
'x-component-props': {
grid: true,
full: true,
autoRow: true,
columns: 6,
},
properties: {
subject: {
type: 'string',
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberRectification.common.hooks.useGetDetailCommon.rectifyTopic'})}`,
allowClear: true,
style: {
width: 160,
},
},
},
'[rectifyDayStart,rectifyDayEnd]': {
type: 'daterange',
'x-component-props': {
placeholder: [`${intl.formatMessage({ id: 'member.memberRectification.common.schema.index.rectifyBeginTime'})}`, `${intl.formatMessage({ id: 'member.memberRectification.tobeConfirmRectification.schema.rectifyCompleteTime'})}`],
allowClear: true,
style: {
width: 240,
},
},
},
outerStatus: {
type: 'string',
enum: [],
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberRectification.common.columns.queryColumns.outState'})}`,
allowClear: true,
style: {
width: 160,
},
},
},
},
'[rectifyDayStart,rectifyDayEnd]': {
type: 'daterange',
'x-component-props': {
placeholder: [`${intl.formatMessage({ id: 'member.memberRectification.common.schema.index.rectifyBeginTime'})}`, `${intl.formatMessage({ id: 'member.memberRectification.tobeConfirmRectification.schema.rectifyCompleteTime'})}`],
allowClear: true,
style: {
width: 240,
},
},
},
outerStatus: {
type: 'string',
enum: [],
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberRectification.common.columns.queryColumns.outState'})}`,
allowClear: true,
style: {
width: 160,
},
},
},
submit: {
'x-component': 'Submit',
'x-mega-props': {
span: 1,
},
'x-component-props': {
children: `${intl.formatMessage({ id: 'member.memberInspection.common.schema.add.query'})}`,
},
},
};
if (!visibleOuterStatus) {
delete extraProperties.outerStatus;
}
return {
type: 'object',
properties: {
megaLayout: {
type: 'object',
'x-component': 'mega-layout',
properties: {
name: {
type: 'string',
'x-component': 'Search',
'x-component-props': {
placeholder: `${intl.formatMessage({ id: 'member.memberInspection.common.schema.add.searchMemberName'})}`,
align: 'flex-left',
tip: `${intl.formatMessage({ id: 'member.memberEvaluate.allQuery.schema.searchForMemberName'})}`,
},
submit: {
'x-component': 'Submit',
'x-mega-props': {
span: 1,
},
'x-component-props': {
children: `${intl.formatMessage({ id: 'member.memberInspection.common.schema.add.query'})}`,
},
},
[FORM_FILTER_PATH]: {
type: 'object',
'x-component': 'mega-layout',
'x-component-props': {
grid: true,
full: true,
autoRow: true,
columns: 6,
},
properties: extraProperties,
},
},
},
},
},
}
};
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