From adc4b8e2ea9f334fc1998c42568367497b1599a7 Mon Sep 17 00:00:00 2001 From: cuiwenlong7 Date: Thu, 31 Mar 2022 23:00:12 +0800 Subject: [PATCH 1/5] =?UTF-8?q?feat:=20=E5=A2=9EloadPageList=E6=96=B9?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main.tsx | 4 ++++ src/steps/common.tsx | 2 ++ src/steps/form/index.tsx | 1 + src/steps/header/index.tsx | 2 ++ src/steps/table/index.tsx | 2 ++ src/util/operation.tsx | 5 +++++ 6 files changed, 16 insertions(+) diff --git a/src/main.tsx b/src/main.tsx index d580507..c8d852f 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -3,6 +3,7 @@ import marked from 'marked' import Step, { StepProps } from './steps/common' import StepComponents, { StepConfigs } from './steps' import { RichStringConfig } from './interface' +import { ISelectFieldOption } from './components/formFields/treeSelect' /** * 页面配置文件格式定义 @@ -46,6 +47,7 @@ export interface CCMSProps { loadPageURL: (pageID: any) => Promise loadPageFrameURL: (pageID: any) => Promise loadPageConfig: (pageID: any) => Promise + loadPageList: () => Promise> loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string) => void callback: (success: boolean) => void @@ -233,6 +235,7 @@ export default class CCMS extends React.Component { loadPageURL, loadPageFrameURL, loadPageConfig, + loadPageList, loadDomain, handlePageRedirect } = this.props @@ -275,6 +278,7 @@ export default class CCMS extends React.Component { loadPageURL, loadPageFrameURL, loadPageConfig, + loadPageList, loadDomain, handlePageRedirect } diff --git a/src/steps/common.tsx b/src/steps/common.tsx index 88da0fd..1641d1a 100644 --- a/src/steps/common.tsx +++ b/src/steps/common.tsx @@ -1,5 +1,6 @@ import React from 'react' import { CCMSConfig } from '../main' +import { ISelectFieldOption } from '../components/formFields/treeSelect' /** * 页面流转步骤基类配置定义 @@ -30,6 +31,7 @@ export interface StepProps { loadPageURL: (pageID: any) => Promise loadPageFrameURL: (pageID: any) => Promise loadPageConfig: (pageID: any) => Promise + loadPageList: () => Promise> baseRoute: string loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string) => void diff --git a/src/steps/form/index.tsx b/src/steps/form/index.tsx index 27debc8..ae0b0be 100644 --- a/src/steps/form/index.tsx +++ b/src/steps/form/index.tsx @@ -630,6 +630,7 @@ export default class FormStep extends Step { loadPageURL={this.props.loadPageURL} loadPageFrameURL={this.props.loadPageFrameURL} loadPageConfig={this.props.loadPageConfig} + loadPageList={this.props.loadPageList} baseRoute={this.props.baseRoute} loadDomain={this.props.loadDomain} handlePageRedirect={this.props.handlePageRedirect} diff --git a/src/steps/header/index.tsx b/src/steps/header/index.tsx index a7ec2d7..cbbfe82 100644 --- a/src/steps/header/index.tsx +++ b/src/steps/header/index.tsx @@ -235,6 +235,7 @@ export default class HeaderStep extends Step { loadPageURL={this.props.loadPageURL} loadPageFrameURL={this.props.loadPageFrameURL} loadPageConfig={this.props.loadPageConfig} + loadPageList={this.props.loadPageList} loadDomain={this.props.loadDomain} handlePageRedirect={this.props.handlePageRedirect} /> @@ -303,6 +304,7 @@ export default class HeaderStep extends Step { loadPageURL={this.props.loadPageURL} loadPageFrameURL={this.props.loadPageFrameURL} loadPageConfig={this.props.loadPageConfig} + loadPageList={this.props.loadPageList} baseRoute={this.props.baseRoute} loadDomain={this.props.loadDomain} handlePageRedirect={this.props.handlePageRedirect} diff --git a/src/steps/table/index.tsx b/src/steps/table/index.tsx index 8a751a0..765f26e 100644 --- a/src/steps/table/index.tsx +++ b/src/steps/table/index.tsx @@ -861,6 +861,7 @@ export default class TableStep extends Step { loadPageURL={this.props.loadPageURL} loadPageFrameURL={this.props.loadPageFrameURL} loadPageConfig={this.props.loadPageConfig} + loadPageList={this.props.loadPageList} loadDomain={this.props.loadDomain} handlePageRedirect={this.props.handlePageRedirect} onMount={() => { @@ -900,6 +901,7 @@ export default class TableStep extends Step { loadPageURL={this.props.loadPageURL} loadPageFrameURL={this.props.loadPageFrameURL} loadPageConfig={this.props.loadPageConfig} + loadPageList={this.props.loadPageList} loadDomain={this.props.loadDomain} handlePageRedirect={this.props.handlePageRedirect} onMount={() => { diff --git a/src/util/operation.tsx b/src/util/operation.tsx index 3f9f3b9..893f948 100644 --- a/src/util/operation.tsx +++ b/src/util/operation.tsx @@ -4,6 +4,7 @@ import { set } from "lodash"; import { ParamConfig } from "../interface"; import { CCMSConfig, CCMSProps } from "../main"; import { getParam } from "./value"; +import { ISelectFieldOption } from '../components/formFields/treeSelect' export type OperationConfig = CCMSOperationConfig @@ -56,6 +57,7 @@ interface OperationHelperProps { loadPageURL: (pageID: any) => Promise, loadPageFrameURL: (pageID: any) => Promise, loadPageConfig: (pageID: any) => Promise, + loadPageList: () => Promise>, baseRoute: string, loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string) => void @@ -96,6 +98,7 @@ export default class OperationHelper extends React.Component { @@ -152,6 +155,7 @@ export default class OperationHelper extends React.Component { @@ -180,6 +184,7 @@ export default class OperationHelper extends React.Component { -- Gitee From 717a257d9ec197eccd3cfad3875915aa4aaa524e Mon Sep 17 00:00:00 2001 From: cuiwenlong7 Date: Fri, 15 Apr 2022 10:53:34 +0800 Subject: [PATCH 2/5] =?UTF-8?q?feat:=20detail=E3=80=81=E8=A1=A8=E5=8D=95?= =?UTF-8?q?=E9=A1=B9=E5=A2=9E=E5=8A=A0loadPageList?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/detail/common.tsx | 2 ++ src/components/detail/group/index.tsx | 1 + src/components/detail/table/index.tsx | 2 ++ src/components/formFields/any/index.tsx | 3 +++ src/components/formFields/common.tsx | 2 ++ src/components/formFields/custom/index.tsx | 4 +++- src/components/formFields/form/index.tsx | 1 + src/components/formFields/group/index.tsx | 1 + src/components/formFields/importSubform/index.tsx | 1 + src/components/formFields/object/index.tsx | 1 + src/components/formFields/tabs/index.tsx | 1 + src/main.tsx | 4 ++-- src/steps/common.tsx | 4 ++-- src/steps/detail/index.tsx | 1 + src/steps/filter/index.tsx | 1 + src/steps/form/index.tsx | 1 + src/util/operation.tsx | 4 ++-- 17 files changed, 27 insertions(+), 7 deletions(-) diff --git a/src/components/detail/common.tsx b/src/components/detail/common.tsx index b4e514f..0a36f6c 100644 --- a/src/components/detail/common.tsx +++ b/src/components/detail/common.tsx @@ -4,6 +4,7 @@ import { ColumnsConfig, ParamConfig } from '../../interface' import { DetailFieldConfigs as getFieldConfigs } from './' import ParamHelper from '../../util/param' import { CCMSConfig } from '../../main' +import { TreeSelectFieldOption } from '../formFields/treeSelect' /** * 详情页表单项基类配置文件格式定义 @@ -93,6 +94,7 @@ export interface DetailFieldProps { baseRoute: string, loadDomain: (domain: string) => Promise loadPageConfig: (pageID: any) => Promise + loadPageList: () => Promise> handlePageRedirect: (path: string) => void checkPageAuth: (pageID: any) => Promise onUnmount: (reload?: boolean, data?: any) => Promise diff --git a/src/components/detail/group/index.tsx b/src/components/detail/group/index.tsx index 3858b55..c80378a 100644 --- a/src/components/detail/group/index.tsx +++ b/src/components/detail/group/index.tsx @@ -204,6 +204,7 @@ export default class GroupField extends DetailField Promise} loadPageFrameURL={this.props.loadPageFrameURL as (pageID: any) => Promise} loadPageConfig={this.props.loadPageConfig as (pageID: any) => Promise} + loadPageList={this.props.loadPageList} loadDomain={this.props.loadDomain} handlePageRedirect={this.props.handlePageRedirect} onMount={() => { diff --git a/src/components/formFields/any/index.tsx b/src/components/formFields/any/index.tsx index e93f34e..cfc7b75 100644 --- a/src/components/formFields/any/index.tsx +++ b/src/components/formFields/any/index.tsx @@ -97,6 +97,7 @@ export default class AnyField extends Field : ( type === 'number' ? {}} @@ -115,6 +116,7 @@ export default class AnyField extends Field : {}} form={this.props.form} @@ -132,6 +134,7 @@ export default class AnyField extends Field ) })} diff --git a/src/components/formFields/common.tsx b/src/components/formFields/common.tsx index cf36a02..84f5bc5 100644 --- a/src/components/formFields/common.tsx +++ b/src/components/formFields/common.tsx @@ -5,6 +5,7 @@ import { FieldConfigs as getFieldConfigs } from './' import ParamHelper from '../../util/param' import { ConditionConfig } from '../../util/condition' import { StatementConfig } from '../../util/statement' +import { TreeSelectFieldOption } from './treeSelect' /** * 表单项基类配置文件格式定义 @@ -95,6 +96,7 @@ export interface FieldProps { onValueListSort: (path: string, index: number, sortType: 'up' | 'down', validation: true | FieldError[], options?: { noPathCombination?: boolean }) => Promise baseRoute: string, loadDomain: (domain: string) => Promise + loadPageList: () => Promise> } /** diff --git a/src/components/formFields/custom/index.tsx b/src/components/formFields/custom/index.tsx index 492ef98..609bc7f 100644 --- a/src/components/formFields/custom/index.tsx +++ b/src/components/formFields/custom/index.tsx @@ -64,9 +64,10 @@ export default class CustomField extends Field imple onValueListSplice: this.props.onValueListSplice, base: this.props.baseRoute, loadDomain: this.props.loadDomain, + loadPageList: this.props.loadPageList, bindValidate: this.bindValidate, bindGet: this.bindGet - }); + }) } } } @@ -93,6 +94,7 @@ export default class CustomField extends Field imple onValueListSplice: this.props.onValueListSplice, base: this.props.baseRoute, loadDomain: this.props.loadDomain, + loadPageList: this.props.loadPageList, bindValidate: this.bindValidate, bindGet: this.bindGet } diff --git a/src/components/formFields/form/index.tsx b/src/components/formFields/form/index.tsx index 2c738f1..b92be82 100644 --- a/src/components/formFields/form/index.tsx +++ b/src/components/formFields/form/index.tsx @@ -540,6 +540,7 @@ export default class FormField extends Field await this.handleValueListSort(index, fieldIndex, path, _index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => await this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) }) diff --git a/src/components/formFields/group/index.tsx b/src/components/formFields/group/index.tsx index 7bec8a1..d633fd7 100644 --- a/src/components/formFields/group/index.tsx +++ b/src/components/formFields/group/index.tsx @@ -375,6 +375,7 @@ export default class GroupField extends Field this.handleValueListSort(formFieldIndex, path, index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => await this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) } diff --git a/src/components/formFields/importSubform/index.tsx b/src/components/formFields/importSubform/index.tsx index 5863faf..5a8c5dd 100644 --- a/src/components/formFields/importSubform/index.tsx +++ b/src/components/formFields/importSubform/index.tsx @@ -483,6 +483,7 @@ export default class ImportSubformField extends Field this.handleValueListSort(formFieldIndex, path, index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => await this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) } diff --git a/src/components/formFields/object/index.tsx b/src/components/formFields/object/index.tsx index e3ddba5..5d8287b 100644 --- a/src/components/formFields/object/index.tsx +++ b/src/components/formFields/object/index.tsx @@ -479,6 +479,7 @@ export default class ObjectField extends Field this.handleValueListSort(key, formFieldIndex, path, _index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) }) diff --git a/src/components/formFields/tabs/index.tsx b/src/components/formFields/tabs/index.tsx index 6525e9b..26fb9e3 100644 --- a/src/components/formFields/tabs/index.tsx +++ b/src/components/formFields/tabs/index.tsx @@ -439,6 +439,7 @@ export default class TabsField extends Field this.handleValueListSort(index, formFieldIndex, path, _index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => await this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) })} diff --git a/src/main.tsx b/src/main.tsx index 1da690a..98b3b1b 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -3,7 +3,7 @@ import marked from 'marked' import Step, { StepProps } from './steps/common' import StepComponents, { StepConfigs } from './steps' import { RichStringConfig } from './interface' -import { ISelectFieldOption } from './components/formFields/treeSelect' +import { TreeSelectFieldOption } from './components/formFields/treeSelect' /** * 页面配置文件格式定义 @@ -47,7 +47,7 @@ export interface CCMSProps { loadPageURL: (pageID: any) => Promise loadPageFrameURL: (pageID: any) => Promise loadPageConfig: (pageID: any) => Promise - loadPageList: () => Promise> + loadPageList: () => Promise> loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string, replaceHistory: boolean) => void callback: (success: boolean) => void diff --git a/src/steps/common.tsx b/src/steps/common.tsx index 8ed1a7b..9aab662 100644 --- a/src/steps/common.tsx +++ b/src/steps/common.tsx @@ -1,6 +1,6 @@ import React from 'react' import { CCMSConfig } from '../main' -import { ISelectFieldOption } from '../components/formFields/treeSelect' +import { TreeSelectFieldOption } from '../components/formFields/treeSelect' /** * 页面流转步骤基类配置定义 @@ -31,7 +31,7 @@ export interface StepProps { loadPageURL: (pageID: any) => Promise loadPageFrameURL: (pageID: any) => Promise loadPageConfig: (pageID: any) => Promise - loadPageList: () => Promise> + loadPageList: () => Promise> baseRoute: string loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string, replaceHistory: boolean) => void diff --git a/src/steps/detail/index.tsx b/src/steps/detail/index.tsx index 1e294d6..eec9fd1 100644 --- a/src/steps/detail/index.tsx +++ b/src/steps/detail/index.tsx @@ -384,6 +384,7 @@ export default class DetailStep extends Step { onUnmount={this.props.onUnmount} checkPageAuth={this.props.checkPageAuth} loadPageConfig={this.props.loadPageConfig} + loadPageList={this.props.loadPageList} loadPageURL={this.props.loadPageURL} loadPageFrameURL={this.props.loadPageFrameURL} handlePageRedirect={() => this.props.handlePageRedirect} diff --git a/src/steps/filter/index.tsx b/src/steps/filter/index.tsx index 8d828f6..75630ec 100644 --- a/src/steps/filter/index.tsx +++ b/src/steps/filter/index.tsx @@ -508,6 +508,7 @@ export default class FilterStep extends Step { onValueListSort={async (path, index, sortType, validation, options) => await this.handleValueListSort(formFieldIndex, path, index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => await this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) } diff --git a/src/steps/form/index.tsx b/src/steps/form/index.tsx index 421ed30..852a1d3 100644 --- a/src/steps/form/index.tsx +++ b/src/steps/form/index.tsx @@ -743,6 +743,7 @@ export default class FormStep extends Step { onValueListSort={async (path, index, sortType, validation, options) => await this.handleValueListSort(formFieldIndex, path, index, sortType, validation, options)} baseRoute={this.props.baseRoute} loadDomain={async (domain: string) => await this.props.loadDomain(domain)} + loadPageList={async () => await this.props.loadPageList()} /> ) } diff --git a/src/util/operation.tsx b/src/util/operation.tsx index 30216c8..2b5181b 100644 --- a/src/util/operation.tsx +++ b/src/util/operation.tsx @@ -4,7 +4,7 @@ import { set } from "lodash"; import { ParamConfig } from "../interface"; import { CCMSConfig, CCMSProps } from "../main"; import { getParam } from "./value"; -import { ISelectFieldOption } from '../components/formFields/treeSelect' +import { TreeSelectFieldOption } from '../components/formFields/treeSelect' export type OperationConfig = CCMSOperationConfig @@ -57,7 +57,7 @@ interface OperationHelperProps { loadPageURL: (pageID: any) => Promise, loadPageFrameURL: (pageID: any) => Promise, loadPageConfig: (pageID: any) => Promise, - loadPageList: () => Promise>, + loadPageList: () => Promise>, baseRoute: string, loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string, replaceHistory: boolean) => void -- Gitee From 16db0e5d878dbbef949e4fe68c27c456abae01ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B4=94=E6=96=87=E9=9A=86?= Date: Fri, 22 Apr 2022 23:18:51 +0800 Subject: [PATCH 3/5] =?UTF-8?q?fix:=20=E5=8E=BB=E9=99=A4=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/formFields/common.tsx | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/components/formFields/common.tsx b/src/components/formFields/common.tsx index 1b67ce3..225b8f1 100644 --- a/src/components/formFields/common.tsx +++ b/src/components/formFields/common.tsx @@ -192,10 +192,7 @@ export class Field extends React.Component< } shouldComponentUpdate (nextProps: FieldProps, nextState: S) { - // console.log('nextProps', nextProps, this.props, nextProps.value == this.props.value); - const dependentFieldsArr = this.dependentFields - // console.log('dependentFieldsArr',dependentFieldsArr); let dependentIsChange = false if (dependentFieldsArr && dependentFieldsArr.length) { for (let i = dependentFieldsArr.length; i >= 0; i--) { @@ -214,7 +211,6 @@ export class Field extends React.Component< * record也不比较,需要比较的话就在dependentFieldsArr取出record绝对路径 * */ if (!dependentIsChange && isEqual(this.state, nextState) && nextProps.value === this.props.value && this.props.config === nextProps.config) { - // console.log('no update' ); return false } return true -- Gitee From 4723a05ec9e8dbf77c36fc54f4995ca2d8fa7dea Mon Sep 17 00:00:00 2001 From: cuiwenlong7 Date: Sun, 24 Apr 2022 15:21:33 +0800 Subject: [PATCH 4/5] =?UTF-8?q?chore:=20=E4=BF=AE=E6=94=B9PageList?= =?UTF-8?q?=E5=AD=90=E9=A1=B9=E7=B1=BB=E5=9E=8B=E6=9D=A5=E6=BA=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/detail/common.tsx | 4 ++-- src/components/formFields/common.tsx | 4 ++-- src/main.tsx | 17 +++++++++++++++-- src/steps/common.tsx | 4 ++-- src/util/operation.tsx | 4 ++-- 5 files changed, 23 insertions(+), 10 deletions(-) diff --git a/src/components/detail/common.tsx b/src/components/detail/common.tsx index 889933c..6cae4e8 100644 --- a/src/components/detail/common.tsx +++ b/src/components/detail/common.tsx @@ -4,7 +4,7 @@ import { ColumnsConfig, ParamConfig } from '../../interface' import { DetailFieldConfigs as getFieldConfigs } from './' import ParamHelper from '../../util/param' import { CCMSConfig } from '../../main' -import { TreeSelectFieldOption } from '../formFields/treeSelect' +import { PageListItem } from '../../main' /** * 详情页表单项基类配置文件格式定义 @@ -94,7 +94,7 @@ export interface DetailFieldProps { baseRoute: string, loadDomain: (domain: string) => Promise loadPageConfig: (pageID: any) => Promise - loadPageList: () => Promise> + loadPageList: () => Promise> handlePageRedirect: (path: string) => void checkPageAuth: (pageID: any) => Promise onUnmount: (reload?: boolean, data?: any) => Promise diff --git a/src/components/formFields/common.tsx b/src/components/formFields/common.tsx index 225b8f1..eef2ebd 100644 --- a/src/components/formFields/common.tsx +++ b/src/components/formFields/common.tsx @@ -6,7 +6,7 @@ import ParamHelper from '../../util/param' import { updateCommonPrefixItem } from '../../util/value' import { ConditionConfig } from '../../util/condition' import { StatementConfig } from '../../util/statement' -import { TreeSelectFieldOption } from './treeSelect' +import { PageListItem } from '../../main' import { isEqual, get } from 'lodash' /** @@ -100,7 +100,7 @@ export interface FieldProps { onReportFields?: (field: string) => Promise // 向父组件上报依赖字段 1.3.0新增 step: { [field: string]: any } // 传递formValue loadDomain: (domain: string) => Promise - loadPageList: () => Promise> + loadPageList: () => Promise> } /** diff --git a/src/main.tsx b/src/main.tsx index 7bed1a1..2aadfb6 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -3,7 +3,6 @@ import marked from 'marked' import Step, { StepProps } from './steps/common' import StepComponents, { StepConfigs } from './steps' import { RichStringConfig } from './interface' -import { TreeSelectFieldOption } from './components/formFields/treeSelect' /** * 页面配置文件格式定义 @@ -47,7 +46,7 @@ export interface CCMSProps { loadPageURL: (pageID: any) => Promise loadPageFrameURL: (pageID: any) => Promise loadPageConfig: (pageID: any) => Promise - loadPageList: () => Promise> + loadPageList: () => Promise> loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string, replaceHistory: boolean) => void callback: (success: boolean) => void @@ -67,6 +66,20 @@ export interface CCMSState { data: any[] } +/** + * 页面列表项 + * - key: 此项必须设置(其值在整个树范围内唯一) + * - value: 默认根据此属性值进行筛选(其值在整个树范围内唯一) + * - title: 树节点显示的内容 + * - children: 子节点 + */ + export interface PageListItem { + key: string | number + value: string | number + title: string + children?: Array +} + /** * 页面组件 */ diff --git a/src/steps/common.tsx b/src/steps/common.tsx index fec990b..61244fa 100644 --- a/src/steps/common.tsx +++ b/src/steps/common.tsx @@ -1,6 +1,6 @@ import React from 'react' import { CCMSConfig } from '../main' -import { TreeSelectFieldOption } from '../components/formFields/treeSelect' +import { PageListItem } from '../main' /** * 页面流转步骤基类配置定义 @@ -31,7 +31,7 @@ export interface StepProps { loadPageURL: (pageID: any) => Promise loadPageFrameURL: (pageID: any) => Promise loadPageConfig: (pageID: any) => Promise - loadPageList: () => Promise> + loadPageList: () => Promise> baseRoute: string loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string, replaceHistory: boolean) => void diff --git a/src/util/operation.tsx b/src/util/operation.tsx index 14222c9..ef437eb 100644 --- a/src/util/operation.tsx +++ b/src/util/operation.tsx @@ -4,7 +4,7 @@ import { set } from '../util/produce' import { ParamConfig } from '../interface' import { CCMSConfig, CCMSProps } from '../main' import { getParam } from './value' -import { TreeSelectFieldOption } from '../components/formFields/treeSelect' +import { PageListItem } from '../main' export type OperationConfig = CCMSOperationConfig @@ -57,7 +57,7 @@ interface OperationHelperProps { loadPageURL: (pageID: any) => Promise, loadPageFrameURL: (pageID: any) => Promise, loadPageConfig: (pageID: any) => Promise, - loadPageList: () => Promise>, + loadPageList: () => Promise>, baseRoute: string, loadDomain: (domain: string) => Promise handlePageRedirect?: (path: string, replaceHistory: boolean) => void -- Gitee From 6d3befbd88c0dc79a2d5f319eb35de77a6b46e8e Mon Sep 17 00:00:00 2001 From: cuiwenlong7 Date: Sun, 24 Apr 2022 15:43:17 +0800 Subject: [PATCH 5/5] =?UTF-8?q?style:=20=E7=AE=80=E5=8C=96=E4=BB=A3?= =?UTF-8?q?=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/detail/common.tsx | 3 +-- src/steps/common.tsx | 3 +-- src/util/operation.tsx | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/components/detail/common.tsx b/src/components/detail/common.tsx index 6cae4e8..3c830fe 100644 --- a/src/components/detail/common.tsx +++ b/src/components/detail/common.tsx @@ -3,8 +3,7 @@ import { ColumnsConfig, ParamConfig } from '../../interface' import { DetailFieldConfigs as getFieldConfigs } from './' import ParamHelper from '../../util/param' -import { CCMSConfig } from '../../main' -import { PageListItem } from '../../main' +import { CCMSConfig, PageListItem } from '../../main' /** * 详情页表单项基类配置文件格式定义 diff --git a/src/steps/common.tsx b/src/steps/common.tsx index 61244fa..d7bb160 100644 --- a/src/steps/common.tsx +++ b/src/steps/common.tsx @@ -1,6 +1,5 @@ import React from 'react' -import { CCMSConfig } from '../main' -import { PageListItem } from '../main' +import { CCMSConfig, PageListItem } from '../main' /** * 页面流转步骤基类配置定义 diff --git a/src/util/operation.tsx b/src/util/operation.tsx index ef437eb..d7e7018 100644 --- a/src/util/operation.tsx +++ b/src/util/operation.tsx @@ -2,9 +2,8 @@ import React from 'react' import queryString from 'query-string' import { set } from '../util/produce' import { ParamConfig } from '../interface' -import { CCMSConfig, CCMSProps } from '../main' +import { CCMSConfig, CCMSProps, PageListItem } from '../main' import { getParam } from './value' -import { PageListItem } from '../main' export type OperationConfig = CCMSOperationConfig -- Gitee