aldehyde 0.2.160 → 0.2.163
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/controls/action/index.js +1 -1
- package/lib/controls/action/index.js.map +1 -1
- package/lib/controls/action/utils.d.ts +2 -2
- package/lib/controls/action/utils.d.ts.map +1 -1
- package/lib/controls/action/utils.js +5 -5
- package/lib/controls/action/utils.js.map +1 -1
- package/lib/controls/file-export/select-code-export.d.ts +13 -0
- package/lib/controls/file-export/select-code-export.d.ts.map +1 -0
- package/lib/controls/file-export/select-code-export.js +14 -0
- package/lib/controls/file-export/select-code-export.js.map +1 -0
- package/lib/controls/steps/index.d.ts.map +1 -1
- package/lib/controls/steps/index.js +4 -1
- package/lib/controls/steps/index.js.map +1 -1
- package/lib/detail/button/edit-button.d.ts +11 -0
- package/lib/detail/button/edit-button.d.ts.map +1 -0
- package/lib/detail/button/edit-button.js +29 -0
- package/lib/detail/button/edit-button.js.map +1 -0
- package/lib/detail/button/view-button.d.ts +11 -0
- package/lib/detail/button/view-button.d.ts.map +1 -0
- package/lib/detail/button/view-button.js +28 -0
- package/lib/detail/button/view-button.js.map +1 -0
- package/lib/detail/view/act-dtmpl-view.d.ts +3 -1
- package/lib/detail/view/act-dtmpl-view.d.ts.map +1 -1
- package/lib/detail/view/act-dtmpl-view.js +9 -3
- package/lib/detail/view/act-dtmpl-view.js.map +1 -1
- package/lib/{exportor → export}/export-frame.d.ts +4 -0
- package/lib/export/export-frame.d.ts.map +1 -0
- package/lib/{exportor → export}/export-frame.js +6 -4
- package/lib/export/export-frame.js.map +1 -0
- package/lib/export/select-code-export-frame.d.ts +49 -0
- package/lib/export/select-code-export-frame.d.ts.map +1 -0
- package/lib/export/select-code-export-frame.js +145 -0
- package/lib/export/select-code-export-frame.js.map +1 -0
- package/lib/form/criteria-form.d.ts.map +1 -1
- package/lib/form/criteria-form.js +26 -2
- package/lib/form/criteria-form.js.map +1 -1
- package/lib/hooks/useVarCssColor.d.ts +2 -0
- package/lib/hooks/useVarCssColor.d.ts.map +1 -0
- package/lib/hooks/useVarCssColor.js +7 -0
- package/lib/hooks/useVarCssColor.js.map +1 -0
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/layout/MainPage.d.ts.map +1 -1
- package/lib/layout/MainPage.js.map +1 -1
- package/lib/layout/menu/block.css +1 -1
- package/lib/layout/menu/block.d.ts.map +1 -1
- package/lib/layout/menu/block.js +1 -1
- package/lib/layout/menu/block.js.map +1 -1
- package/lib/layout2/components/userButton.d.ts +5 -0
- package/lib/layout2/components/userButton.d.ts.map +1 -0
- package/lib/layout2/components/userButton.js +133 -0
- package/lib/layout2/components/userButton.js.map +1 -0
- package/lib/layout2/css/header.css +38 -0
- package/lib/layout2/header.d.ts +12 -0
- package/lib/layout2/header.d.ts.map +1 -0
- package/lib/layout2/header.js +225 -0
- package/lib/layout2/header.js.map +1 -0
- package/lib/layout2/imgs/home.png +0 -0
- package/lib/layout2/main.d.ts +9 -0
- package/lib/layout2/main.d.ts.map +1 -0
- package/lib/layout2/main.js +14 -0
- package/lib/layout2/main.js.map +1 -0
- package/lib/layout2/page.d.ts +7 -0
- package/lib/layout2/page.d.ts.map +1 -0
- package/lib/layout2/page.js +120 -0
- package/lib/layout2/page.js.map +1 -0
- package/lib/layout2/sider.d.ts +10 -0
- package/lib/layout2/sider.d.ts.map +1 -0
- package/lib/layout2/sider.js +259 -0
- package/lib/layout2/sider.js.map +1 -0
- package/lib/layout2/type/layout.type.d.ts +10 -0
- package/lib/layout2/type/layout.type.d.ts.map +1 -0
- package/lib/layout2/type/layout.type.js +2 -0
- package/lib/layout2/type/layout.type.js.map +1 -0
- package/lib/layout2/util/menu.util.d.ts +28 -0
- package/lib/layout2/util/menu.util.d.ts.map +1 -0
- package/lib/layout2/util/menu.util.js +76 -0
- package/lib/layout2/util/menu.util.js.map +1 -0
- package/lib/login/login.d.ts.map +1 -1
- package/lib/login/login.js +3 -0
- package/lib/login/login.js.map +1 -1
- package/lib/login2/Login.d.ts +10 -0
- package/lib/login2/Login.d.ts.map +1 -0
- package/lib/login2/Login.js +71 -0
- package/lib/login2/Login.js.map +1 -0
- package/lib/login2/LoginPage.d.ts +4 -0
- package/lib/login2/LoginPage.d.ts.map +1 -0
- package/lib/login2/LoginPage.js +43 -0
- package/lib/login2/LoginPage.js.map +1 -0
- package/lib/login2/img/login-bg.png +0 -0
- package/lib/login2/index.d.ts +4 -0
- package/lib/login2/index.d.ts.map +1 -0
- package/lib/login2/index.js +4 -0
- package/lib/login2/index.js.map +1 -0
- package/lib/module/ltmpl-table.d.ts +6 -4
- package/lib/module/ltmpl-table.d.ts.map +1 -1
- package/lib/module/ltmpl-table.js +15 -11
- package/lib/module/ltmpl-table.js.map +1 -1
- package/lib/routable/dtmpl-route.d.ts +3 -2
- package/lib/routable/dtmpl-route.d.ts.map +1 -1
- package/lib/routable/dtmpl-route.js +20 -16
- package/lib/routable/dtmpl-route.js.map +1 -1
- package/lib/routable/import-route.d.ts +3 -2
- package/lib/routable/import-route.d.ts.map +1 -1
- package/lib/routable/import-route.js +10 -6
- package/lib/routable/import-route.js.map +1 -1
- package/lib/routable/ltmpl-route.d.ts +1 -0
- package/lib/routable/ltmpl-route.d.ts.map +1 -1
- package/lib/routable/ltmpl-route.js +24 -17
- package/lib/routable/ltmpl-route.js.map +1 -1
- package/lib/routable/ttmpl-route.d.ts +3 -2
- package/lib/routable/ttmpl-route.d.ts.map +1 -1
- package/lib/routable/ttmpl-route.js +13 -9
- package/lib/routable/ttmpl-route.js.map +1 -1
- package/lib/routable/withroute.d.ts +1 -1
- package/lib/routable/withroute.d.ts.map +1 -1
- package/lib/routable/withroute.js +3 -3
- package/lib/routable/withroute.js.map +1 -1
- package/lib/table/act-table.d.ts +7 -4
- package/lib/table/act-table.d.ts.map +1 -1
- package/lib/table/act-table.js +112 -88
- package/lib/table/act-table.js.map +1 -1
- package/lib/table/index.css +4 -4
- package/lib/table/query-table.d.ts.map +1 -1
- package/lib/table/query-table.js.map +1 -1
- package/lib/table/relation-table.d.ts +2 -2
- package/lib/table/relation-table.d.ts.map +1 -1
- package/lib/table/relation-table.js +5 -5
- package/lib/table/relation-table.js.map +1 -1
- package/lib/table/select-table.js +2 -2
- package/lib/table/select-table.js.map +1 -1
- package/lib/tmpl/hc-data-source.d.ts.map +1 -1
- package/lib/tmpl/hc-data-source.js +2 -3
- package/lib/tmpl/hc-data-source.js.map +1 -1
- package/lib/tmpl/hcservice-v3.d.ts +3 -2
- package/lib/tmpl/hcservice-v3.d.ts.map +1 -1
- package/lib/tmpl/hcservice-v3.js +11 -2
- package/lib/tmpl/hcservice-v3.js.map +1 -1
- package/lib/tmpl/interface.d.ts +46 -6
- package/lib/tmpl/interface.d.ts.map +1 -1
- package/lib/tree/tmpl-tree.d.ts.map +1 -1
- package/lib/tree/tmpl-tree.js +2 -1
- package/lib/tree/tmpl-tree.js.map +1 -1
- package/lib/welcome/HCWelcome.d.ts +1 -1
- package/lib/welcome/HCWelcome.d.ts.map +1 -1
- package/lib/welcome/HCWelcome.js +279 -175
- package/lib/welcome/HCWelcome.js.map +1 -1
- package/lib/welcome/img/welcome.png +0 -0
- package/package.json +1 -1
- package/src/aldehyde/controls/action/index.tsx +1 -1
- package/src/aldehyde/controls/action/utils.tsx +4 -5
- package/src/aldehyde/controls/file-export/select-code-export.tsx +40 -0
- package/src/aldehyde/controls/steps/index.tsx +6 -1
- package/src/aldehyde/detail/button/edit-button.tsx +62 -0
- package/src/aldehyde/detail/button/view-button.tsx +61 -0
- package/src/aldehyde/detail/view/act-dtmpl-view.tsx +14 -2
- package/src/aldehyde/{exportor → export}/export-frame.tsx +10 -6
- package/src/aldehyde/export/select-code-export-frame.tsx +218 -0
- package/src/aldehyde/form/criteria-form.tsx +35 -0
- package/src/aldehyde/hooks/useVarCssColor.ts +6 -0
- package/src/aldehyde/index.tsx +2 -2
- package/src/aldehyde/layout/MainPage.tsx +8 -6
- package/src/aldehyde/layout/menu/block.css +1 -1
- package/src/aldehyde/layout/menu/block.tsx +1 -0
- package/src/aldehyde/layout2/components/userButton.tsx +171 -0
- package/src/aldehyde/layout2/css/header.css +38 -0
- package/src/aldehyde/layout2/header.tsx +348 -0
- package/src/aldehyde/layout2/imgs/home.png +0 -0
- package/src/aldehyde/layout2/main.tsx +27 -0
- package/src/aldehyde/layout2/page.tsx +169 -0
- package/src/aldehyde/layout2/sider.tsx +357 -0
- package/src/aldehyde/layout2/type/layout.type.ts +10 -0
- package/src/aldehyde/layout2/util/menu.util.tsx +112 -0
- package/src/aldehyde/login/login.tsx +2 -0
- package/src/aldehyde/login2/Login.tsx +122 -0
- package/src/aldehyde/login2/LoginPage.tsx +59 -0
- package/src/aldehyde/login2/img/login-bg.png +0 -0
- package/src/aldehyde/login2/index.tsx +4 -0
- package/src/aldehyde/module/ltmpl-table.tsx +18 -13
- package/src/aldehyde/routable/dtmpl-route.tsx +141 -121
- package/src/aldehyde/routable/import-route.tsx +28 -23
- package/src/aldehyde/routable/ltmpl-route.tsx +86 -59
- package/src/aldehyde/routable/ttmpl-route.tsx +73 -55
- package/src/aldehyde/routable/withroute.tsx +21 -18
- package/src/aldehyde/table/act-table.tsx +93 -77
- package/src/aldehyde/table/index.css +4 -4
- package/src/aldehyde/table/query-table.tsx +1 -4
- package/src/aldehyde/table/relation-table.tsx +7 -7
- package/src/aldehyde/table/select-table.tsx +2 -2
- package/src/aldehyde/tmpl/hc-data-source.tsx +373 -352
- package/src/aldehyde/tmpl/hcservice-v3.tsx +33 -17
- package/src/aldehyde/tmpl/interface.tsx +53 -6
- package/src/aldehyde/tree/tmpl-tree.tsx +2 -1
- package/src/aldehyde/welcome/HCWelcome.js +294 -241
- package/src/aldehyde/welcome/img/welcome.png +0 -0
- package/lib/exportor/export-frame.d.ts.map +0 -1
- package/lib/exportor/export-frame.js.map +0 -1
- /package/lib/{exportor → export}/export-frame.css +0 -0
- /package/src/aldehyde/{exportor → export}/export-frame.css +0 -0
|
@@ -41,13 +41,13 @@ import {
|
|
|
41
41
|
ActTableViewModel,
|
|
42
42
|
AddOrUpdate,
|
|
43
43
|
BuiltInButtonName,
|
|
44
|
-
|
|
45
|
-
ColumnConfig,
|
|
44
|
+
ClassAddConfig,
|
|
45
|
+
ColumnConfig, DoEditParam,
|
|
46
46
|
DtmplData,
|
|
47
47
|
JumpConfig,
|
|
48
48
|
LtmplConfig,
|
|
49
49
|
QueryKey,
|
|
50
|
-
SelectedRow,
|
|
50
|
+
SelectedRow, ShowViewParam,
|
|
51
51
|
TmplBaseProps,
|
|
52
52
|
} from "../tmpl/interface";
|
|
53
53
|
import TableUnits from "./table-util";
|
|
@@ -58,7 +58,7 @@ import CriteriaForm from "./../form/criteria-form";
|
|
|
58
58
|
import ViewControl from "../controls/view-control";
|
|
59
59
|
import Units from "../units";
|
|
60
60
|
import ColumnSelector from "./column/column-selector";
|
|
61
|
-
import ExportFrame from "../
|
|
61
|
+
import ExportFrame, {ExportType} from "../export/export-frame";
|
|
62
62
|
import { SortableHandle } from "react-sortable-hoc";
|
|
63
63
|
import L2ActTable from "./l2-act-table";
|
|
64
64
|
|
|
@@ -70,6 +70,8 @@ import CollapseCard from "../controls/collapse-card";
|
|
|
70
70
|
import ToolTipBar from "../detail/tooltipbar";
|
|
71
71
|
import { LocaleContext } from "../locale/LocaleProvider";
|
|
72
72
|
import BlockMenuTreeDrawer from "../module/block-menu-tree-drawer";
|
|
73
|
+
import EditButton from "../detail/button/edit-button";
|
|
74
|
+
import ViewButton from "../detail/button/view-button";
|
|
73
75
|
|
|
74
76
|
const DragHandle = SortableHandle(() => (
|
|
75
77
|
<MenuOutlined style={{ cursor: "grab", color: "#999" }} />
|
|
@@ -87,10 +89,10 @@ interface ActTableProps extends TmplBaseProps {
|
|
|
87
89
|
onChangePage: (pageNo: number, pageSize: number) => void;
|
|
88
90
|
ltmplConfig: LtmplConfig;
|
|
89
91
|
menuId?: string;
|
|
90
|
-
showView?: (
|
|
92
|
+
showView?: (showVievParam:ShowViewParam) => void;
|
|
91
93
|
doCreate?: (addtmplId: string, toCustomPage: boolean) => void;
|
|
92
94
|
customCreatable?: boolean;
|
|
93
|
-
doEdit?: (
|
|
95
|
+
doEdit?: (doEditParam:DoEditParam) => void;
|
|
94
96
|
customEditable?: boolean;
|
|
95
97
|
doDelete?: (code: string) => void;
|
|
96
98
|
doSearch?: (params: object) => void;
|
|
@@ -357,7 +359,11 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
357
359
|
column["title"] = <>{translate("${操作}")}</>;
|
|
358
360
|
column["render"] = (text, record) => (
|
|
359
361
|
<Space size={[0, 4]} wrap>
|
|
360
|
-
{buttons.includes("detail") && showView
|
|
362
|
+
{buttons.includes("detail") && showView && (ActionUtils.isShow(
|
|
363
|
+
ltmplConfig.buttonViewAction?.preposes,
|
|
364
|
+
[record],
|
|
365
|
+
undefined
|
|
366
|
+
)) ? (
|
|
361
367
|
<Button
|
|
362
368
|
size="small"
|
|
363
369
|
type="primary"
|
|
@@ -367,34 +373,19 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
367
373
|
) : (
|
|
368
374
|
""
|
|
369
375
|
)}
|
|
370
|
-
{buttons.includes("customDetail") && showView
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
""
|
|
379
|
-
)}
|
|
376
|
+
{buttons.includes("customDetail") && showView &&
|
|
377
|
+
(ActionUtils.isShow(
|
|
378
|
+
ltmplConfig.buttonViewAction?.preposes,
|
|
379
|
+
[record],
|
|
380
|
+
undefined
|
|
381
|
+
)) ?
|
|
382
|
+
(<ViewButton showView={showView} data={record} ltmplConfig={ltmplConfig} ></ViewButton>) : (
|
|
383
|
+
"")}
|
|
380
384
|
{buttons.includes("dtmplEdit") &&
|
|
381
385
|
doEdit &&
|
|
382
|
-
!readOnly
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
ltmplConfig.buttonEditAction,
|
|
386
|
-
[record],
|
|
387
|
-
undefined
|
|
388
|
-
)) ? (
|
|
389
|
-
<Button
|
|
390
|
-
size="small"
|
|
391
|
-
type="dashed"
|
|
392
|
-
icon={<EditOutlined />}
|
|
393
|
-
onClick={() => doEdit(record.code, "update")}
|
|
394
|
-
></Button>
|
|
395
|
-
) : (
|
|
396
|
-
""
|
|
397
|
-
)}
|
|
386
|
+
!readOnly ?
|
|
387
|
+
(<EditButton doEdit={doEdit} data={record} ltmplConfig={ltmplConfig} ></EditButton>) : (
|
|
388
|
+
"")}
|
|
398
389
|
{builtInButtons?.includes("blockAuthMenuTree") && !readOnly ? (
|
|
399
390
|
<Button
|
|
400
391
|
size="small"
|
|
@@ -418,9 +409,8 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
418
409
|
{(buttons.includes("dtmplCustomEdit") || customEditable) &&
|
|
419
410
|
doEdit &&
|
|
420
411
|
!readOnly &&
|
|
421
|
-
(
|
|
422
|
-
|
|
423
|
-
ltmplConfig.buttonEditAction,
|
|
412
|
+
(ActionUtils.isShow(
|
|
413
|
+
ltmplConfig.buttonEditAction?.preposes,
|
|
424
414
|
[record],
|
|
425
415
|
undefined
|
|
426
416
|
)) ? (
|
|
@@ -428,7 +418,7 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
428
418
|
size="small"
|
|
429
419
|
type="dashed"
|
|
430
420
|
icon={<FormOutlined />}
|
|
431
|
-
onClick={() => doEdit(record.code, "update",
|
|
421
|
+
onClick={() => doEdit({code:record.code, mode:"update",toCustomPage:true})}
|
|
432
422
|
></Button>
|
|
433
423
|
) : (
|
|
434
424
|
""
|
|
@@ -451,7 +441,7 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
451
441
|
record.code
|
|
452
442
|
);
|
|
453
443
|
if (code) {
|
|
454
|
-
doEdit(code, "update", toCustomPage);
|
|
444
|
+
doEdit({code, mode:"update", toCustomPage});
|
|
455
445
|
}
|
|
456
446
|
}}
|
|
457
447
|
></Button>
|
|
@@ -531,9 +521,8 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
531
521
|
: ""}
|
|
532
522
|
{buttons.includes("singleDelete") &&
|
|
533
523
|
!readOnly &&
|
|
534
|
-
(
|
|
535
|
-
|
|
536
|
-
ltmplConfig.buttonDeleteAction,
|
|
524
|
+
(ActionUtils.isShow(
|
|
525
|
+
ltmplConfig.buttonDeleteAction?.preposes,
|
|
537
526
|
[record],
|
|
538
527
|
undefined
|
|
539
528
|
)) ? (
|
|
@@ -868,6 +857,61 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
868
857
|
this.doJump(jump, record);
|
|
869
858
|
};
|
|
870
859
|
|
|
860
|
+
|
|
861
|
+
renderExportButton=(title,type:ExportType,sourceId?:string)=>{
|
|
862
|
+
const {pageNo,pageSize,serverKey,ltmplConfig,readOnly}=this.props;
|
|
863
|
+
|
|
864
|
+
let buttons=ltmplConfig?.buttons;
|
|
865
|
+
|
|
866
|
+
const {queryKey,}=this.state;
|
|
867
|
+
const { translate } = this.context;
|
|
868
|
+
return <Popover
|
|
869
|
+
content={
|
|
870
|
+
<ExportFrame //导出组件
|
|
871
|
+
currentPage={{
|
|
872
|
+
pageNo: pageNo ? pageNo : 1,
|
|
873
|
+
pageSize: pageSize ? pageSize : ltmplConfig.defaultPageSize,
|
|
874
|
+
}}
|
|
875
|
+
type={type}
|
|
876
|
+
serverKey={serverKey}
|
|
877
|
+
queryKey={queryKey}
|
|
878
|
+
sourceId={sourceId}
|
|
879
|
+
title={translate("${" + ltmplConfig.title + "}" +"-"+ "${" +title + "}")}
|
|
880
|
+
/>
|
|
881
|
+
}
|
|
882
|
+
title={translate("${"+title+"}")}
|
|
883
|
+
placement="bottomRight"
|
|
884
|
+
trigger="click"
|
|
885
|
+
>
|
|
886
|
+
<Tooltip title={translate("${"+title+"}")}>
|
|
887
|
+
<Button
|
|
888
|
+
style={{
|
|
889
|
+
// display:
|
|
890
|
+
// buttons.includes("exportLtmplExcel") && !readOnly
|
|
891
|
+
// ? "inline"
|
|
892
|
+
// : "none",
|
|
893
|
+
marginLeft: "5px",
|
|
894
|
+
}} //为了点击到没有导出模块,使组件不致销毁,丢失导出数据
|
|
895
|
+
>
|
|
896
|
+
{type=="ltmpl-data-excel"? <DownloadOutlined />:title}
|
|
897
|
+
</Button>
|
|
898
|
+
</Tooltip>
|
|
899
|
+
</Popover>
|
|
900
|
+
}
|
|
901
|
+
|
|
902
|
+
renderFileExportButton=()=>{
|
|
903
|
+
const {ltmplConfig}=this.props;
|
|
904
|
+
let fileExports=ltmplConfig?.topFileExports;
|
|
905
|
+
if(fileExports){
|
|
906
|
+
return fileExports.map((fileExport) => {
|
|
907
|
+
return this.renderExportButton(fileExport.title,"ltmpl-data-filedata",fileExport.id);
|
|
908
|
+
});
|
|
909
|
+
}else{
|
|
910
|
+
return <></>
|
|
911
|
+
}
|
|
912
|
+
|
|
913
|
+
}
|
|
914
|
+
|
|
871
915
|
doSelectedJump = async (jump: JumpConfig) => {
|
|
872
916
|
const { selectedDatas } = this.state;
|
|
873
917
|
if (selectedDatas.length == 1) {
|
|
@@ -894,12 +938,12 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
894
938
|
});
|
|
895
939
|
};
|
|
896
940
|
|
|
897
|
-
getAddTmplButton = (
|
|
941
|
+
getAddTmplButton = (classAddConfigs: ClassAddConfig[]) => {
|
|
898
942
|
const { translate } = this.context;
|
|
899
|
-
if (
|
|
943
|
+
if (classAddConfigs && classAddConfigs.length < 1) {
|
|
900
944
|
return translate("${没有分类添加按钮}");
|
|
901
945
|
}
|
|
902
|
-
return
|
|
946
|
+
return classAddConfigs.map((config) => {
|
|
903
947
|
return (
|
|
904
948
|
<p>
|
|
905
949
|
<Button
|
|
@@ -951,12 +995,12 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
951
995
|
</Popover>
|
|
952
996
|
) : null}
|
|
953
997
|
{buttons.includes("dtmplAdd") && doCreate && !readOnly ? (
|
|
954
|
-
ltmplConfig.
|
|
955
|
-
ltmplConfig.
|
|
998
|
+
ltmplConfig.classAddConfigs &&
|
|
999
|
+
ltmplConfig.classAddConfigs.length > 0 ? (
|
|
956
1000
|
<Popover
|
|
957
1001
|
arrow={false}
|
|
958
1002
|
content={this.getAddTmplButton(
|
|
959
|
-
ltmplConfig.
|
|
1003
|
+
ltmplConfig.classAddConfigs
|
|
960
1004
|
)}
|
|
961
1005
|
placement="bottomRight"
|
|
962
1006
|
>
|
|
@@ -1001,39 +1045,11 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
1001
1045
|
""
|
|
1002
1046
|
)}
|
|
1003
1047
|
{buttons.includes("exportLtmplExcel") && !readOnly ? (
|
|
1004
|
-
|
|
1005
|
-
content={
|
|
1006
|
-
<ExportFrame //导出组件
|
|
1007
|
-
currentPage={{
|
|
1008
|
-
pageNo: pageNo ? pageNo : 1,
|
|
1009
|
-
pageSize: pageSize ? pageSize : ltmplConfig.defaultPageSize,
|
|
1010
|
-
}}
|
|
1011
|
-
serverKey={serverKey}
|
|
1012
|
-
queryKey={queryKey}
|
|
1013
|
-
title={translate("${" + ltmplConfig.title + "}")}
|
|
1014
|
-
/>
|
|
1015
|
-
}
|
|
1016
|
-
title={translate("${导出}")}
|
|
1017
|
-
placement="bottomRight"
|
|
1018
|
-
trigger="click"
|
|
1019
|
-
>
|
|
1020
|
-
<Tooltip title={translate("${导出}")}>
|
|
1021
|
-
<Button
|
|
1022
|
-
style={{
|
|
1023
|
-
display:
|
|
1024
|
-
buttons.includes("exportLtmplExcel") && !readOnly
|
|
1025
|
-
? "inline"
|
|
1026
|
-
: "none",
|
|
1027
|
-
marginLeft: "5px",
|
|
1028
|
-
}} //为了点击到没有导出模块,使组件不致销毁,丢失导出数据
|
|
1029
|
-
>
|
|
1030
|
-
<DownloadOutlined />
|
|
1031
|
-
</Button>
|
|
1032
|
-
</Tooltip>
|
|
1033
|
-
</Popover>
|
|
1048
|
+
this.renderExportButton("导出","ltmpl-data-excel")
|
|
1034
1049
|
) : (
|
|
1035
1050
|
""
|
|
1036
1051
|
)}
|
|
1052
|
+
{ this.renderFileExportButton()}
|
|
1037
1053
|
{buttons.includes("showChart") ? (
|
|
1038
1054
|
<Tooltip
|
|
1039
1055
|
title={
|
|
@@ -51,17 +51,17 @@
|
|
|
51
51
|
/*}*/
|
|
52
52
|
|
|
53
53
|
.ant-table-cell:has(.xiaoji) {
|
|
54
|
-
background-color:
|
|
54
|
+
background-color: var(--ant-control-item-bg-active-hover) !important;
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
.ant-table-cell:has(.zongji) {
|
|
58
|
-
background-color:
|
|
58
|
+
background-color: var(--color-4) !important;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
.xiaoji {
|
|
62
|
-
background-color:
|
|
62
|
+
background-color: var(--ant-control-item-bg-active-hover) !important;
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
.zongji {
|
|
66
|
-
background-color:
|
|
66
|
+
background-color: var(--color-4) !important;
|
|
67
67
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React
|
|
1
|
+
import React from "react";
|
|
2
2
|
import { Card, Collapse, Descriptions, List } from "antd";
|
|
3
3
|
import Table from "./control-table-x-axis-wrapper";
|
|
4
4
|
import "./index.css";
|
|
@@ -18,11 +18,8 @@ import { TableRowSelection } from "antd/lib/table/interface";
|
|
|
18
18
|
import { SortableContainer, SortableElement } from "react-sortable-hoc";
|
|
19
19
|
import { arrayMoveImmutable } from "array-move";
|
|
20
20
|
import ViewControl from "../controls/view-control";
|
|
21
|
-
import Scrollbars from "react-custom-scrollbars";
|
|
22
21
|
import { LocaleContext } from "../locale/LocaleProvider";
|
|
23
22
|
import { BigNumber } from "bignumber.js";
|
|
24
|
-
import Column from "antd/es/table/Column";
|
|
25
|
-
import { ColumnsType } from "antd/es/table";
|
|
26
23
|
import { init, merge, statistic } from "../utils/dsu";
|
|
27
24
|
|
|
28
25
|
const { Panel } = Collapse;
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
} from "@ant-design/icons";
|
|
22
22
|
import "./index.css";
|
|
23
23
|
import {
|
|
24
|
-
|
|
24
|
+
ClassAddConfig,
|
|
25
25
|
DtmplData,
|
|
26
26
|
FieldGroupConfig,
|
|
27
27
|
SelectedRow,
|
|
@@ -553,13 +553,13 @@ class RelationTable extends React.PureComponent<
|
|
|
553
553
|
});
|
|
554
554
|
};
|
|
555
555
|
|
|
556
|
-
getAddTmplButton = (
|
|
556
|
+
getAddTmplButton = (classAddConfigs: ClassAddConfig[]) => {
|
|
557
557
|
const { translate } = this.context;
|
|
558
558
|
|
|
559
|
-
if (
|
|
559
|
+
if (classAddConfigs && classAddConfigs.length < 1) {
|
|
560
560
|
return translate("${没有分类添加按钮}");
|
|
561
561
|
}
|
|
562
|
-
return
|
|
562
|
+
return classAddConfigs.map((config) => {
|
|
563
563
|
return (
|
|
564
564
|
<p>
|
|
565
565
|
<Button
|
|
@@ -604,12 +604,12 @@ class RelationTable extends React.PureComponent<
|
|
|
604
604
|
""
|
|
605
605
|
)}
|
|
606
606
|
{buttons.includes("dtmplAdd") ? (
|
|
607
|
-
fieldGroupConfig.
|
|
608
|
-
fieldGroupConfig.
|
|
607
|
+
fieldGroupConfig.classAddConfigs &&
|
|
608
|
+
fieldGroupConfig.classAddConfigs.length > 0 ? (
|
|
609
609
|
<Popover
|
|
610
610
|
arrow={false}
|
|
611
611
|
content={this.getAddTmplButton(
|
|
612
|
-
fieldGroupConfig.
|
|
612
|
+
fieldGroupConfig.classAddConfigs
|
|
613
613
|
)}
|
|
614
614
|
placement="bottomRight"
|
|
615
615
|
>
|
|
@@ -238,10 +238,10 @@ class SelectTable extends React.PureComponent<SelectTableProps, SelectTableStat>
|
|
|
238
238
|
return <>
|
|
239
239
|
</>
|
|
240
240
|
}
|
|
241
|
-
let {buttons, criterias, jumps, actions} = selectConfig
|
|
241
|
+
let {buttons, criterias, jumps, actions,fileExports} = selectConfig
|
|
242
242
|
let displayCriteriaCard: boolean = false;
|
|
243
243
|
if (buttons.includes('batchDelete') || (buttons.includes('query') && criterias && criterias.length > 0) ||
|
|
244
|
-
(actions && actions.length > 0) || (jumps && jumps.length > 0)) {
|
|
244
|
+
(actions && actions.length > 0) || (jumps && jumps.length > 0) || (fileExports && fileExports.length>0)) {
|
|
245
245
|
displayCriteriaCard = true;
|
|
246
246
|
}
|
|
247
247
|
return (
|