aldehyde 0.2.19 → 0.2.21
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.d.ts +50 -50
- package/lib/controls/action/index.d.ts.map +1 -1
- package/lib/controls/action/index.js +187 -187
- package/lib/controls/action/index.js.map +1 -1
- package/lib/controls/action/utils.d.ts +8 -8
- package/lib/controls/action/utils.js +109 -109
- package/lib/controls/auto-complete/index.d.ts +6 -6
- package/lib/controls/auto-complete/index.js +51 -51
- package/lib/controls/cascader/index.d.ts +22 -22
- package/lib/controls/cascader/index.d.ts.map +1 -1
- package/lib/controls/cascader/index.js +107 -106
- package/lib/controls/cascader/index.js.map +1 -1
- package/lib/controls/chemstruc/graph.d.ts +28 -28
- package/lib/controls/chemstruc/graph.d.ts.map +1 -1
- package/lib/controls/chemstruc/graph.js +120 -119
- package/lib/controls/chemstruc/graph.js.map +1 -1
- package/lib/controls/code-editor/sql-code-editor.d.ts +14 -14
- package/lib/controls/code-editor/sql-code-editor.js +52 -51
- package/lib/controls/code-editor/sql-code-editor.js.map +1 -1
- package/lib/controls/collapse-card/index.d.ts +19 -19
- package/lib/controls/collapse-card/index.d.ts.map +1 -1
- package/lib/controls/collapse-card/index.js +62 -62
- package/lib/controls/color-picker/index.d.ts +18 -18
- package/lib/controls/color-picker/index.d.ts.map +1 -1
- package/lib/controls/color-picker/index.js +59 -59
- package/lib/controls/counting-tag/index.d.ts +17 -17
- package/lib/controls/counting-tag/index.js +31 -30
- package/lib/controls/counting-tag/index.js.map +1 -1
- package/lib/controls/cquery/cquick-button.d.ts +23 -23
- package/lib/controls/cquery/cquick-button.d.ts.map +1 -1
- package/lib/controls/cquery/cquick-button.js +72 -72
- package/lib/controls/cquery/cquick-button.js.map +1 -1
- package/lib/controls/date-picker/index.d.ts +6 -6
- package/lib/controls/date-picker/index.js +83 -83
- package/lib/controls/entity-select/entity-select.d.ts +73 -73
- package/lib/controls/entity-select/entity-select.d.ts.map +1 -1
- package/lib/controls/entity-select/entity-select.js +427 -423
- package/lib/controls/entity-select/entity-select.js.map +1 -1
- package/lib/controls/entity-select/lab-tree-select.d.ts +24 -24
- package/lib/controls/entity-select/lab-tree-select.d.ts.map +1 -1
- package/lib/controls/entity-select/lab-tree-select.js +121 -120
- package/lib/controls/entity-select/lab-tree-select.js.map +1 -1
- package/lib/controls/entity-select/popover-entity-select.d.ts +19 -19
- package/lib/controls/entity-select/popover-entity-select.js +92 -91
- package/lib/controls/entity-select/popover-entity-select.js.map +1 -1
- package/lib/controls/entry-control.d.ts +12 -12
- package/lib/controls/entry-control.js +202 -202
- package/lib/controls/enum-badge/index.d.ts +6 -6
- package/lib/controls/enum-badge/index.js +13 -13
- package/lib/controls/enum-tag/index.d.ts +6 -6
- package/lib/controls/enum-tag/index.js +23 -23
- package/lib/controls/file-view/drawer-file-view.d.ts +21 -21
- package/lib/controls/file-view/drawer-file-view.d.ts.map +1 -1
- package/lib/controls/file-view/drawer-file-view.js +56 -55
- package/lib/controls/file-view/drawer-file-view.js.map +1 -1
- package/lib/controls/file-view/index.d.ts +27 -27
- package/lib/controls/file-view/index.d.ts.map +1 -1
- package/lib/controls/file-view/index.js +135 -134
- package/lib/controls/file-view/index.js.map +1 -1
- package/lib/controls/html-editor/draft.d.ts +21 -21
- package/lib/controls/html-editor/draft.d.ts.map +1 -1
- package/lib/controls/html-editor/draft.js +121 -121
- package/lib/controls/html-editor/draft.js.map +1 -1
- package/lib/controls/html-editor/tinymce.d.ts +12 -7
- package/lib/controls/html-editor/tinymce.d.ts.map +1 -1
- package/lib/controls/html-editor/tinymce.js +44 -43
- package/lib/controls/html-editor/tinymce.js.map +1 -1
- package/lib/controls/input-number/index.d.ts +6 -6
- package/lib/controls/input-number/index.js +68 -68
- package/lib/controls/input-range/index.d.ts +6 -6
- package/lib/controls/input-range/index.js +27 -27
- package/lib/controls/password-setter/index.d.ts +8 -7
- package/lib/controls/password-setter/index.d.ts.map +1 -1
- package/lib/controls/password-setter/index.js +50 -50
- package/lib/controls/progress/index.d.ts +6 -6
- package/lib/controls/progress/index.js +44 -44
- package/lib/controls/relation-existion/index.d.ts +19 -19
- package/lib/controls/relation-existion/index.d.ts.map +1 -1
- package/lib/controls/relation-existion/index.js +74 -74
- package/lib/controls/rfield/index.d.ts +28 -28
- package/lib/controls/rfield/index.d.ts.map +1 -1
- package/lib/controls/rfield/index.js +130 -130
- package/lib/controls/signature/index.d.ts +30 -30
- package/lib/controls/signature/index.d.ts.map +1 -1
- package/lib/controls/signature/index.js +129 -128
- package/lib/controls/signature/index.js.map +1 -1
- package/lib/controls/steps/index.d.ts +6 -6
- package/lib/controls/steps/index.js +41 -41
- package/lib/controls/text/ellipsis-text.d.ts +21 -21
- package/lib/controls/text/ellipsis-text.js +46 -45
- package/lib/controls/text/ellipsis-text.js.map +1 -1
- package/lib/controls/upload/index.d.ts +14 -14
- package/lib/controls/upload/index.js +99 -99
- package/lib/controls/view-control.d.ts +9 -9
- package/lib/controls/view-control.js +174 -174
- package/lib/custom-page/custom-page-router.d.ts +7 -22
- package/lib/custom-page/custom-page-router.d.ts.map +1 -1
- package/lib/custom-page/custom-page-router.js +66 -64
- package/lib/custom-page/custom-page-router.js.map +1 -1
- package/lib/custom-page/def-custom-page.d.ts +6 -5
- package/lib/custom-page/def-custom-page.d.ts.map +1 -1
- package/lib/custom-page/def-custom-page.js +13 -13
- package/lib/custom-page/dtmpl-custom-edit-modal-page.d.ts +42 -42
- package/lib/custom-page/dtmpl-custom-edit-modal-page.js +35 -34
- package/lib/custom-page/dtmpl-custom-edit-modal-page.js.map +1 -1
- package/lib/detail/button/cquery-button-bar.d.ts +15 -15
- package/lib/detail/button/cquery-button-bar.js +74 -74
- package/lib/detail/button/submit-button-bar.d.ts +18 -18
- package/lib/detail/button/submit-button-bar.d.ts.map +1 -1
- package/lib/detail/button/submit-button-bar.js +103 -104
- package/lib/detail/button/submit-button-bar.js.map +1 -1
- package/lib/detail/edit/dtmpl-edit.d.ts +47 -47
- package/lib/detail/edit/dtmpl-edit.d.ts.map +1 -1
- package/lib/detail/edit/dtmpl-edit.js +197 -196
- package/lib/detail/edit/dtmpl-edit.js.map +1 -1
- package/lib/detail/edit/fields-edit-card.d.ts +38 -38
- package/lib/detail/edit/fields-edit-card.js +64 -63
- package/lib/detail/edit/fields-edit-card.js.map +1 -1
- package/lib/detail/edit/modal-row-edit.d.ts +30 -30
- package/lib/detail/edit/modal-row-edit.js +56 -55
- package/lib/detail/edit/modal-row-edit.js.map +1 -1
- package/lib/detail/edit/post-result/index.d.ts +16 -16
- package/lib/detail/edit/post-result/index.js +27 -27
- package/lib/detail/edit/row-edit-card.d.ts +41 -41
- package/lib/detail/edit/row-edit-card.d.ts.map +1 -1
- package/lib/detail/edit/row-edit-card.js +84 -83
- package/lib/detail/edit/row-edit-card.js.map +1 -1
- package/lib/detail/edit/row-editor.d.ts +32 -32
- package/lib/detail/edit/row-editor.d.ts.map +1 -1
- package/lib/detail/edit/row-editor.js +56 -55
- package/lib/detail/edit/row-editor.js.map +1 -1
- package/lib/detail/rightbar/index.d.ts +19 -19
- package/lib/detail/rightbar/index.js +51 -50
- package/lib/detail/rightbar/index.js.map +1 -1
- package/lib/detail/view/act-dtmpl-view.d.ts +43 -43
- package/lib/detail/view/act-dtmpl-view.d.ts.map +1 -1
- package/lib/detail/view/act-dtmpl-view.js +96 -96
- package/lib/detail/view/act-dtmpl-view.js.map +1 -1
- package/lib/detail/view/dtmpl-view.d.ts +41 -41
- package/lib/detail/view/dtmpl-view.d.ts.map +1 -1
- package/lib/detail/view/dtmpl-view.js +115 -115
- package/lib/detail/view/dtmpl-view.js.map +1 -1
- package/lib/detail/view/field-view-group.d.ts +16 -16
- package/lib/detail/view/field-view-group.js +50 -50
- package/lib/detail/view/modal-dtmpl-view.d.ts +27 -27
- package/lib/detail/view/modal-dtmpl-view.d.ts.map +1 -1
- package/lib/detail/view/modal-dtmpl-view.js +32 -31
- package/lib/detail/view/modal-dtmpl-view.js.map +1 -1
- package/lib/detail/view/snapshot-timeline.d.ts +31 -31
- package/lib/detail/view/snapshot-timeline.d.ts.map +1 -1
- package/lib/detail/view/snapshot-timeline.js +89 -89
- package/lib/detail/view/snapshot-timeline.js.map +1 -1
- package/lib/exportor/export-frame.d.ts +49 -49
- package/lib/exportor/export-frame.d.ts.map +1 -1
- package/lib/exportor/export-frame.js +142 -141
- package/lib/exportor/export-frame.js.map +1 -1
- package/lib/exportor/index.d.ts +15 -15
- package/lib/exportor/index.js +43 -43
- package/lib/form/criteria-form.d.ts +19 -19
- package/lib/form/criteria-form.js +147 -147
- package/lib/form/dtmpl-form.d.ts +44 -44
- package/lib/form/dtmpl-form.d.ts.map +1 -1
- package/lib/form/dtmpl-form.js +204 -203
- package/lib/form/dtmpl-form.js.map +1 -1
- package/lib/form/field-group-form.d.ts +20 -20
- package/lib/form/field-group-form.js +57 -57
- package/lib/form/fields-form.d.ts +19 -19
- package/lib/form/fields-form.js +31 -31
- package/lib/form/form-Item-group.d.ts +29 -29
- package/lib/form/form-Item-group.d.ts.map +1 -1
- package/lib/form/form-Item-group.js +108 -107
- package/lib/form/form-Item-group.js.map +1 -1
- package/lib/icon/index.d.ts +10 -10
- package/lib/icon/index.js +21 -21
- package/lib/import/excel-import.d.ts +47 -47
- package/lib/import/excel-import.d.ts.map +1 -1
- package/lib/import/excel-import.js +234 -234
- package/lib/import/template-builder.d.ts +28 -20
- package/lib/import/template-builder.d.ts.map +1 -1
- package/lib/import/template-builder.js +425 -425
- package/lib/index.d.ts +41 -40
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +79 -78
- package/lib/index.js.map +1 -1
- package/lib/layout/MainPage.d.ts +4 -33
- package/lib/layout/MainPage.d.ts.map +1 -1
- package/lib/layout/MainPage.js +204 -204
- package/lib/layout/MainPage.js.map +1 -1
- package/lib/layout/footer/index.d.ts +6 -5
- package/lib/layout/footer/index.d.ts.map +1 -1
- package/lib/layout/footer/index.js +10 -10
- package/lib/layout/header/index.d.ts +14 -14
- package/lib/layout/header/index.js +35 -35
- package/lib/layout/menu/block.d.ts +16 -8
- package/lib/layout/menu/block.d.ts.map +1 -1
- package/lib/layout/menu/block.js +46 -47
- package/lib/layout/menu/block.js.map +1 -1
- package/lib/layout/menu/l2menu-message-bar.d.ts +23 -23
- package/lib/layout/menu/l2menu-message-bar.d.ts.map +1 -1
- package/lib/layout/menu/l2menu-message-bar.js +96 -96
- package/lib/layout/menu/l2menu-quick-bar.d.ts +29 -29
- package/lib/layout/menu/l2menu-quick-bar.d.ts.map +1 -1
- package/lib/layout/menu/l2menu-quick-bar.js +93 -93
- package/lib/layout/menu/menu-2layers.d.ts +13 -2
- package/lib/layout/menu/menu-2layers.d.ts.map +1 -1
- package/lib/layout/menu/menu-2layers.js +69 -70
- package/lib/layout/menu/menu-2layers.js.map +1 -1
- package/lib/layout/menu/menu-render.d.ts +8 -8
- package/lib/layout/menu/menu-render.js +74 -74
- package/lib/layout/menu/reset-password.d.ts +24 -24
- package/lib/layout/menu/reset-password.d.ts.map +1 -1
- package/lib/layout/menu/reset-password.js +113 -113
- package/lib/layout/menu/user-bar.d.ts +22 -22
- package/lib/layout/menu/user-bar.js +99 -99
- package/lib/layout/menu/userinfo-bar.d.ts +16 -16
- package/lib/layout/menu/userinfo-bar.d.ts.map +1 -1
- package/lib/layout/menu/userinfo-bar.js +43 -43
- package/lib/layout/sidebar/index.d.ts +11 -11
- package/lib/layout/sidebar/index.js +17 -17
- package/lib/login/context-setter.d.ts +23 -23
- package/lib/login/context-setter.d.ts.map +1 -1
- package/lib/login/context-setter.js +97 -97
- package/lib/login/context-setter.js.map +1 -1
- package/lib/login/login-context.d.ts +21 -10
- package/lib/login/login-context.d.ts.map +1 -1
- package/lib/login/login-context.js +126 -126
- package/lib/login/login.d.ts +2 -10
- package/lib/login/login.d.ts.map +1 -1
- package/lib/login/login.js +105 -101
- package/lib/login/login.js.map +1 -1
- package/lib/module/dtmpl-edit-card.d.ts +42 -42
- package/lib/module/dtmpl-edit-card.d.ts.map +1 -1
- package/lib/module/dtmpl-edit-card.js +162 -162
- package/lib/module/dtmpl-edit-card.js.map +1 -1
- package/lib/module/dtmpl-edit-drawer.d.ts +16 -16
- package/lib/module/dtmpl-edit-drawer.js +7 -7
- package/lib/module/dtmpl-edit-modal.d.ts +17 -17
- package/lib/module/dtmpl-edit-modal.js +7 -7
- package/lib/module/dtmpl-edit-page.d.ts +59 -59
- package/lib/module/dtmpl-edit-page.d.ts.map +1 -1
- package/lib/module/dtmpl-edit-page.js +191 -191
- package/lib/module/dtmpl-edit-page.js.map +1 -1
- package/lib/module/dtmpl-editor.d.ts +38 -38
- package/lib/module/dtmpl-editor.d.ts.map +1 -1
- package/lib/module/dtmpl-editor.js +146 -145
- package/lib/module/dtmpl-editor.js.map +1 -1
- package/lib/module/dtmpl-view-card.d.ts +18 -18
- package/lib/module/dtmpl-view-card.d.ts.map +1 -1
- package/lib/module/dtmpl-view-card.js +45 -45
- package/lib/module/dtmpl-view-drawer.d.ts +26 -26
- package/lib/module/dtmpl-view-drawer.js +39 -39
- package/lib/module/dtmpl-view-drawer.js.map +1 -1
- package/lib/module/dtmpl-view-modal.d.ts +27 -27
- package/lib/module/dtmpl-view-modal.js +35 -35
- package/lib/module/dtmpl-view-modal.js.map +1 -1
- package/lib/module/ltmpl-drawer.d.ts +28 -28
- package/lib/module/ltmpl-drawer.js +37 -36
- package/lib/module/ltmpl-drawer.js.map +1 -1
- package/lib/module/ltmpl-modal.d.ts +28 -28
- package/lib/module/ltmpl-modal.js +36 -35
- package/lib/module/ltmpl-modal.js.map +1 -1
- package/lib/module/ltmpl-table.d.ts +61 -56
- package/lib/module/ltmpl-table.d.ts.map +1 -1
- package/lib/module/ltmpl-table.js +217 -210
- package/lib/module/ltmpl-table.js.map +1 -1
- package/lib/routable/dtmpl-route.d.ts +9 -30
- package/lib/routable/dtmpl-route.d.ts.map +1 -1
- package/lib/routable/dtmpl-route.js +151 -154
- package/lib/routable/dtmpl-route.js.map +1 -1
- package/lib/routable/import-route.d.ts +5 -12
- package/lib/routable/import-route.d.ts.map +1 -1
- package/lib/routable/import-route.js +29 -28
- package/lib/routable/import-route.js.map +1 -1
- package/lib/routable/ltmpl-route.d.ts +10 -28
- package/lib/routable/ltmpl-route.d.ts.map +1 -1
- package/lib/routable/ltmpl-route.js +188 -169
- package/lib/routable/ltmpl-route.js.map +1 -1
- package/lib/routable/withroute.d.ts +3 -0
- package/lib/routable/withroute.d.ts.map +1 -0
- package/lib/routable/withroute.js +11 -0
- package/lib/routable/withroute.js.map +1 -0
- package/lib/table/act-table.d.ts +90 -89
- package/lib/table/act-table.d.ts.map +1 -1
- package/lib/table/act-table.js +529 -532
- package/lib/table/act-table.js.map +1 -1
- package/lib/table/column/column-selector.d.ts +24 -24
- package/lib/table/column/column-selector.js +59 -59
- package/lib/table/column/column-selector.js.map +1 -1
- package/lib/table/l2-act-table.d.ts +27 -22
- package/lib/table/l2-act-table.d.ts.map +1 -1
- package/lib/table/l2-act-table.js +86 -79
- package/lib/table/l2-act-table.js.map +1 -1
- package/lib/table/modal-select-table.d.ts +46 -41
- package/lib/table/modal-select-table.d.ts.map +1 -1
- package/lib/table/modal-select-table.js +215 -207
- package/lib/table/modal-select-table.js.map +1 -1
- package/lib/table/pagination.d.ts +16 -16
- package/lib/table/pagination.d.ts.map +1 -1
- package/lib/table/pagination.js +39 -39
- package/lib/table/pagination.js.map +1 -1
- package/lib/table/query-table.d.ts +73 -64
- package/lib/table/query-table.d.ts.map +1 -1
- package/lib/table/query-table.js +264 -256
- package/lib/table/query-table.js.map +1 -1
- package/lib/table/relation-table.d.ts +64 -64
- package/lib/table/relation-table.d.ts.map +1 -1
- package/lib/table/relation-table.js +425 -425
- package/lib/table/relation-table.js.map +1 -1
- package/lib/table/select-table.d.ts +45 -40
- package/lib/table/select-table.d.ts.map +1 -1
- package/lib/table/select-table.js +226 -220
- package/lib/table/select-table.js.map +1 -1
- package/lib/table/selected-rows-card.d.ts +15 -15
- package/lib/table/selected-rows-card.js +46 -46
- package/lib/table/stat/restat.d.ts +25 -25
- package/lib/table/stat/restat.d.ts.map +1 -1
- package/lib/table/stat/restat.js +60 -60
- package/lib/table/stat/restat.js.map +1 -1
- package/lib/table/table-util.d.ts +4 -4
- package/lib/table/table-util.js +25 -25
- package/lib/tmpl/control-type-supportor.d.ts +8 -8
- package/lib/tmpl/control-type-supportor.js +98 -98
- package/lib/tmpl/hc-data-source.d.ts +25 -25
- package/lib/tmpl/hc-data-source.js +331 -331
- package/lib/tmpl/hcservice-v3.d.ts +77 -76
- package/lib/tmpl/hcservice-v3.d.ts.map +1 -1
- package/lib/tmpl/hcservice-v3.js +803 -787
- package/lib/tmpl/hcservice-v3.js.map +1 -1
- package/lib/tmpl/interface.d.ts +272 -269
- package/lib/tmpl/interface.d.ts.map +1 -1
- package/lib/tmpl/interface.js +3 -3
- package/lib/tmpl/interface.js.map +1 -1
- package/lib/tmpl/superagent.d.ts +9 -9
- package/lib/tmpl/superagent.js +142 -142
- package/lib/tmpl/tmpl-config-analysis.d.ts +6 -6
- package/lib/tmpl/tmpl-config-analysis.js +106 -106
- package/lib/units/EncryptUtils.d.ts +6 -6
- package/lib/units/EncryptUtils.js +30 -29
- package/lib/units/EncryptUtils.js.map +1 -1
- package/lib/units/index.d.ts +80 -81
- package/lib/units/index.d.ts.map +1 -1
- package/lib/units/index.js +747 -742
- package/lib/units/index.js.map +1 -1
- package/lib/units/storage.d.ts +2 -2
- package/lib/units/storage.js +1 -1
- package/lib/welcome/HCWelcome.d.ts +17 -13
- package/lib/welcome/HCWelcome.d.ts.map +1 -1
- package/lib/welcome/HCWelcome.js +199 -198
- package/lib/welcome/HCWelcome.js.map +1 -1
- package/lib/welcome/quick-entrance.d.ts +19 -19
- package/lib/welcome/quick-entrance.d.ts.map +1 -1
- package/lib/welcome/quick-entrance.js +78 -78
- package/lib/welcome/workbench.d.ts +19 -19
- package/lib/welcome/workbench.d.ts.map +1 -1
- package/lib/welcome/workbench.js +77 -77
- package/package.json +10 -10
- package/src/aldehyde/controls/action/index.tsx +2 -3
- package/src/aldehyde/controls/cascader/index.tsx +1 -1
- package/src/aldehyde/controls/chemstruc/graph.tsx +2 -2
- package/src/aldehyde/controls/collapse-card/index.tsx +1 -1
- package/src/aldehyde/controls/color-picker/index.tsx +1 -1
- package/src/aldehyde/controls/cquery/cquick-button.tsx +1 -1
- package/src/aldehyde/controls/entity-select/entity-select.tsx +17 -20
- package/src/aldehyde/controls/entity-select/lab-tree-select.tsx +1 -1
- package/src/aldehyde/controls/file-view/drawer-file-view.tsx +1 -1
- package/src/aldehyde/controls/file-view/index.tsx +1 -1
- package/src/aldehyde/controls/html-editor/draft.tsx +2 -2
- package/src/aldehyde/controls/relation-existion/index.tsx +1 -1
- package/src/aldehyde/controls/rfield/index.tsx +4 -4
- package/src/aldehyde/controls/signature/index.tsx +3 -3
- package/src/aldehyde/custom-page/custom-page-router.tsx +18 -15
- package/src/aldehyde/detail/button/submit-button-bar.tsx +1 -2
- package/src/aldehyde/detail/edit/dtmpl-edit.tsx +11 -11
- package/src/aldehyde/detail/edit/row-edit-card.tsx +1 -1
- package/src/aldehyde/detail/edit/row-editor.tsx +1 -1
- package/src/aldehyde/detail/view/act-dtmpl-view.tsx +6 -6
- package/src/aldehyde/detail/view/dtmpl-view.tsx +4 -4
- package/src/aldehyde/detail/view/modal-dtmpl-view.tsx +0 -2
- package/src/aldehyde/detail/view/snapshot-timeline.tsx +2 -2
- package/src/aldehyde/exportor/export-frame.tsx +11 -11
- package/src/aldehyde/form/dtmpl-form.tsx +3 -3
- package/src/aldehyde/form/form-Item-group.tsx +1 -1
- package/src/aldehyde/import/excel-import.tsx +11 -11
- package/src/aldehyde/index.tsx +4 -2
- package/src/aldehyde/layout/MainPage.tsx +17 -19
- package/src/aldehyde/layout/menu/block.tsx +3 -3
- package/src/aldehyde/layout/menu/l2menu-message-bar.tsx +3 -3
- package/src/aldehyde/layout/menu/l2menu-quick-bar.tsx +4 -4
- package/src/aldehyde/layout/menu/menu-2layers.tsx +3 -4
- package/src/aldehyde/layout/menu/menu-render.tsx +1 -1
- package/src/aldehyde/layout/menu/reset-password.tsx +3 -3
- package/src/aldehyde/layout/menu/userinfo-bar.tsx +1 -1
- package/src/aldehyde/login/context-setter.tsx +3 -3
- package/src/aldehyde/login/login.js +9 -2
- package/src/aldehyde/module/dtmpl-edit-card.tsx +8 -8
- package/src/aldehyde/module/dtmpl-edit-page.tsx +8 -8
- package/src/aldehyde/module/dtmpl-editor.tsx +5 -5
- package/src/aldehyde/module/dtmpl-view-card.tsx +1 -1
- package/src/aldehyde/module/ltmpl-table.tsx +22 -11
- package/src/aldehyde/routable/dtmpl-route.tsx +32 -34
- package/src/aldehyde/routable/import-route.tsx +4 -3
- package/src/aldehyde/routable/ltmpl-route.tsx +100 -75
- package/src/aldehyde/routable/withroute.tsx +22 -0
- package/src/aldehyde/table/act-table.tsx +31 -32
- package/src/aldehyde/table/l2-act-table.tsx +15 -8
- package/src/aldehyde/table/modal-select-table.tsx +22 -12
- package/src/aldehyde/table/pagination.tsx +3 -4
- package/src/aldehyde/table/query-table.tsx +63 -51
- package/src/aldehyde/table/relation-table.tsx +9 -9
- package/src/aldehyde/table/select-table.tsx +22 -10
- package/src/aldehyde/table/stat/restat.tsx +2 -2
- package/src/aldehyde/tmpl/hcservice-v3.tsx +15 -0
- package/src/aldehyde/tmpl/interface.tsx +5 -1
- package/src/aldehyde/units/index.tsx +18 -13
- package/src/aldehyde/welcome/quick-entrance.tsx +1 -1
- package/src/aldehyde/welcome/workbench.tsx +1 -1
|
@@ -14,11 +14,11 @@ interface DtmplEditCardProps extends DtmplBaseProps {
|
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
interface DtmplEditCardState {
|
|
17
|
-
id
|
|
18
|
-
dtmplConfig
|
|
19
|
-
loading
|
|
20
|
-
serial
|
|
21
|
-
dtmplData
|
|
17
|
+
id?:string,
|
|
18
|
+
dtmplConfig?: DtmplConfig,
|
|
19
|
+
loading?: boolean;
|
|
20
|
+
serial?:number,
|
|
21
|
+
dtmplData?:DtmplData,
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
export default class DtmplEditCard extends React.PureComponent<DtmplEditCardProps, DtmplEditCardState> {
|
|
@@ -145,10 +145,10 @@ export default class DtmplEditCard extends React.PureComponent<DtmplEditCardProp
|
|
|
145
145
|
getFooter = () => {
|
|
146
146
|
const {dtmplData,serial}=this.state;
|
|
147
147
|
const footerButtons = [];
|
|
148
|
-
footerButtons.unshift(
|
|
149
|
-
<Button type={'primary'} >
|
|
148
|
+
footerButtons.unshift(
|
|
149
|
+
<Button onClick={() =>this.doSubmit()} type={'primary'} >
|
|
150
150
|
保 存
|
|
151
|
-
</Button
|
|
151
|
+
</Button>)
|
|
152
152
|
const {dtmplConfig} = this.state;
|
|
153
153
|
//处理action
|
|
154
154
|
if (dtmplConfig) {
|
|
@@ -20,11 +20,11 @@ interface ModalEditorProps extends DtmplBaseProps {
|
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
interface ModalEditorState {
|
|
23
|
-
id
|
|
24
|
-
dtmplConfig
|
|
25
|
-
loading
|
|
26
|
-
serial
|
|
27
|
-
dtmplData
|
|
23
|
+
id?:string,
|
|
24
|
+
dtmplConfig?: DtmplConfig,
|
|
25
|
+
loading?: boolean;
|
|
26
|
+
serial?:number,
|
|
27
|
+
dtmplData?:DtmplData,
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
export default class DtmplEditPage extends React.PureComponent<ModalEditorProps, ModalEditorState> {
|
|
@@ -167,10 +167,10 @@ export default class DtmplEditPage extends React.PureComponent<ModalEditorProps,
|
|
|
167
167
|
const {onCancel} = this.props
|
|
168
168
|
const {dtmplData,serial}=this.state;
|
|
169
169
|
const footerButtons = [];
|
|
170
|
-
footerButtons.unshift(
|
|
171
|
-
<Button type={'primary'} >
|
|
170
|
+
footerButtons.unshift(
|
|
171
|
+
<Button type={'primary'} onClick={() =>this.doSubmit()}>
|
|
172
172
|
保 存
|
|
173
|
-
</Button
|
|
173
|
+
</Button>)
|
|
174
174
|
const {dtmplConfig} = this.state;
|
|
175
175
|
//处理action
|
|
176
176
|
if (dtmplConfig) {
|
|
@@ -13,11 +13,11 @@ interface ModalEditorProps extends DtmplBaseProps {
|
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
interface ModalEditorState {
|
|
16
|
-
id
|
|
17
|
-
dtmplConfig
|
|
18
|
-
loading
|
|
19
|
-
serial
|
|
20
|
-
dtmplData
|
|
16
|
+
id?:string,
|
|
17
|
+
dtmplConfig?: DtmplConfig,
|
|
18
|
+
loading?: boolean;
|
|
19
|
+
serial?:number,
|
|
20
|
+
dtmplData?:DtmplData,
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
export default class DtmplEditPage extends React.PureComponent<ModalEditorProps, ModalEditorState> {
|
|
@@ -26,21 +26,25 @@ export interface LtmplTableProps {
|
|
|
26
26
|
};
|
|
27
27
|
|
|
28
28
|
export interface LtmplTableState {
|
|
29
|
-
ltmplConfigRes
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
29
|
+
ltmplConfigRes?: LtmplConfigRes;
|
|
30
|
+
pageNo?:number,
|
|
31
|
+
pageSize?:number,
|
|
32
|
+
criteriaData?: object;
|
|
33
|
+
showDtmplView?: boolean;
|
|
34
|
+
selectedCode?: string;
|
|
35
|
+
showDtmplEdit?: boolean;
|
|
36
|
+
showDraw?: boolean;
|
|
37
|
+
showDtmplCustomEdit?: boolean;
|
|
38
|
+
ractionId?: string,
|
|
39
|
+
collapse?: boolean,
|
|
38
40
|
};
|
|
39
41
|
|
|
40
42
|
class LtmplTable extends React.PureComponent<LtmplTableProps, LtmplTableState> {
|
|
41
43
|
|
|
42
44
|
state = {
|
|
43
45
|
ltmplConfigRes: undefined,
|
|
46
|
+
pageNo:undefined,
|
|
47
|
+
pageSize:undefined,
|
|
44
48
|
criteriaData: undefined,
|
|
45
49
|
showDtmplView: false,
|
|
46
50
|
showDtmplEdit: false,
|
|
@@ -179,6 +183,13 @@ class LtmplTable extends React.PureComponent<LtmplTableProps, LtmplTableState> {
|
|
|
179
183
|
});
|
|
180
184
|
}
|
|
181
185
|
|
|
186
|
+
onChangePage=(pageNo,pageSize)=>{
|
|
187
|
+
this.setState({
|
|
188
|
+
pageNo,pageSize
|
|
189
|
+
})
|
|
190
|
+
|
|
191
|
+
}
|
|
192
|
+
|
|
182
193
|
handleDtmplEdit = (code: string) => {
|
|
183
194
|
this.doSearch(this.state.criteriaData);
|
|
184
195
|
this.setState({
|
|
@@ -188,7 +199,7 @@ class LtmplTable extends React.PureComponent<LtmplTableProps, LtmplTableState> {
|
|
|
188
199
|
|
|
189
200
|
|
|
190
201
|
render() {
|
|
191
|
-
const {ltmplConfigRes, criteriaData, showDtmplView, selectedCode, showDtmplEdit, showDtmplCustomEdit, ractionId, showDraw, collapse} = this.state;
|
|
202
|
+
const {ltmplConfigRes, criteriaData,pageSize,pageNo, showDtmplView, selectedCode, showDtmplEdit, showDtmplCustomEdit, ractionId, showDraw, collapse} = this.state;
|
|
192
203
|
const {sourceId, mainCode, showView, doSearch, doRAction, funcMode, title, collapsible, initCollapse} = this.props;
|
|
193
204
|
|
|
194
205
|
if (!ltmplConfigRes) {
|
|
@@ -196,7 +207,7 @@ class LtmplTable extends React.PureComponent<LtmplTableProps, LtmplTableState> {
|
|
|
196
207
|
} else {
|
|
197
208
|
const {buttons,customEditPagePath} = ltmplConfigRes.ltmplConfig
|
|
198
209
|
return <>
|
|
199
|
-
<ActTable collapsible={collapsible} initCollapse={initCollapse && collapse} title={title}
|
|
210
|
+
<ActTable pageSize={pageSize} pageNo={pageNo} onChangePage={this.onChangePage} collapsible={collapsible} initCollapse={initCollapse && collapse} title={title}
|
|
200
211
|
funcMode={funcMode} mainCode={mainCode} showView={showView ? showView : this.showView}
|
|
201
212
|
doRAction={doRAction ? doRAction : this.doRAction}
|
|
202
213
|
doSearch={doSearch ? doSearch : this.doSearch} doEdit={this.doEdit} doCreate={this.doCreate}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
|
-
import {
|
|
2
|
+
import { Empty} from 'antd';
|
|
3
3
|
import {RouterCompProps} from '../tmpl/interface';
|
|
4
|
-
import Units from "../units";
|
|
5
4
|
import DtmplEdit from "../detail/edit/dtmpl-edit";
|
|
6
5
|
import ActDtmplView from '../detail/view/act-dtmpl-view';
|
|
7
6
|
import HcserviceV3 from "../tmpl/hcservice-v3";
|
|
7
|
+
import withRouter from "./withroute";
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
export interface DtmplRouteProps extends RouterCompProps {
|
|
@@ -12,8 +12,8 @@ export interface DtmplRouteProps extends RouterCompProps {
|
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
export interface DtmplRoutePropsStat {
|
|
15
|
-
codeSource
|
|
16
|
-
queriedCode
|
|
15
|
+
codeSource?:'new'|'listop'|'listop-new'|undefined,
|
|
16
|
+
queriedCode?:string,
|
|
17
17
|
};
|
|
18
18
|
|
|
19
19
|
class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsStat> {
|
|
@@ -27,8 +27,8 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
27
27
|
queriedCode:undefined,
|
|
28
28
|
}
|
|
29
29
|
async componentDidMount() {
|
|
30
|
-
const {
|
|
31
|
-
const {sourceId,} =
|
|
30
|
+
const {params}=this.props;
|
|
31
|
+
const {sourceId,} = params;
|
|
32
32
|
let codeSource:'new'|'listop'|'listop-new'|undefined=this.getCodeSource();
|
|
33
33
|
let queriedCode=undefined;
|
|
34
34
|
if(codeSource){
|
|
@@ -56,21 +56,21 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
56
56
|
return queriedCode;
|
|
57
57
|
}
|
|
58
58
|
getMenuId=()=>{
|
|
59
|
-
const {
|
|
59
|
+
const {searchParams} = this.props;
|
|
60
60
|
//console.log("this.props.match.params",this.props);
|
|
61
|
-
|
|
61
|
+
// var searchParams = new URLSearchParams( location.search);
|
|
62
62
|
let menuId = searchParams.get('menuId');
|
|
63
63
|
return menuId;
|
|
64
64
|
}
|
|
65
65
|
|
|
66
66
|
getCodeSource=()=>{
|
|
67
|
-
const {
|
|
68
|
-
|
|
69
|
-
|
|
67
|
+
const {params}=this.props;
|
|
68
|
+
// let params=Units.transQueryStrToParams(location.search);
|
|
69
|
+
// if('codeSource' in params){
|
|
70
70
|
return params['codeSource'];
|
|
71
|
-
}else{
|
|
72
|
-
|
|
73
|
-
}
|
|
71
|
+
// }else{
|
|
72
|
+
// return undefined;
|
|
73
|
+
// }
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
goBackToLtmpl=()=>{
|
|
@@ -83,11 +83,11 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
83
83
|
// url=url+`&mainCode=${mainCode}`;
|
|
84
84
|
// }
|
|
85
85
|
//this.props.history.push(url);
|
|
86
|
-
this.props.
|
|
86
|
+
this.props.navigate(-1);
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
goDtmpl=(code:string)=>{
|
|
90
|
-
const { sourceId,} = this.props.
|
|
90
|
+
const { sourceId,} = this.props.params;
|
|
91
91
|
const {basePath}=this.props;
|
|
92
92
|
let url=`${basePath}/${sourceId}/detail-edit?menuId=${this.getMenuId()}`;
|
|
93
93
|
if(code){
|
|
@@ -97,41 +97,39 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
97
97
|
if(mainCode){
|
|
98
98
|
url=url+`&mainCode=${mainCode}`;
|
|
99
99
|
}
|
|
100
|
-
this.props.
|
|
100
|
+
this.props.navigate(url);
|
|
101
101
|
}
|
|
102
102
|
|
|
103
103
|
getMainCode=()=>{
|
|
104
|
-
const {
|
|
105
|
-
|
|
106
|
-
let params=Units.transQueryStrToParams(location.search);
|
|
107
|
-
if('mainCode' in params){
|
|
104
|
+
const {params}=this.props;
|
|
105
|
+
//if('mainCode' in params){
|
|
108
106
|
return params['mainCode'];
|
|
109
|
-
}else{
|
|
110
|
-
|
|
111
|
-
}
|
|
107
|
+
// }else{
|
|
108
|
+
// return undefined;
|
|
109
|
+
// }
|
|
112
110
|
}
|
|
113
111
|
|
|
114
112
|
getCode= ()=>{
|
|
115
113
|
const {codeSource,queriedCode}=this.state;
|
|
116
|
-
const {
|
|
114
|
+
const {searchParams}=this.props;
|
|
117
115
|
//let code;
|
|
118
116
|
if(codeSource){
|
|
119
117
|
return queriedCode;
|
|
120
118
|
}else{
|
|
121
|
-
|
|
122
|
-
return
|
|
119
|
+
// let params=Units.transQueryStrToParams(location.search);
|
|
120
|
+
return searchParams.get('code');
|
|
123
121
|
}
|
|
124
122
|
}
|
|
125
123
|
|
|
126
124
|
getMode=()=>{
|
|
127
|
-
const {
|
|
128
|
-
|
|
129
|
-
return this.getCode()?
|
|
125
|
+
const {searchParams}=this.props;
|
|
126
|
+
// let params=Units.transQueryStrToParams(location.search);
|
|
127
|
+
return this.getCode()?searchParams.get('mode'):"add";
|
|
130
128
|
}
|
|
131
129
|
|
|
132
130
|
render() {
|
|
133
|
-
const {location,
|
|
134
|
-
const {sourceId,} =
|
|
131
|
+
const {location,params}=this.props;
|
|
132
|
+
const {sourceId,} = params;
|
|
135
133
|
const {codeSource}=this.state;
|
|
136
134
|
if(!location){
|
|
137
135
|
return <></>;
|
|
@@ -140,7 +138,7 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
140
138
|
if(code && code=='bad-code'){
|
|
141
139
|
return <Empty />
|
|
142
140
|
}
|
|
143
|
-
|
|
141
|
+
// let params=Units.transQueryStrToParams(location.search);
|
|
144
142
|
let versionId=params['versionId'];
|
|
145
143
|
if(location.pathname.endsWith("detail-view")){
|
|
146
144
|
return (
|
|
@@ -155,5 +153,5 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
155
153
|
}
|
|
156
154
|
}
|
|
157
155
|
|
|
158
|
-
export default DtmplRoute;
|
|
156
|
+
export default withRouter(DtmplRoute);
|
|
159
157
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import {RouterCompProps} from '../tmpl/interface';
|
|
3
3
|
import ExcelImport from '../import/excel-import'
|
|
4
|
+
import withRouter from "./withroute";
|
|
4
5
|
|
|
5
6
|
export interface ImportRouteProps extends RouterCompProps {
|
|
6
7
|
|
|
@@ -19,10 +20,10 @@ class ExcelImportRoute extends React.PureComponent<ImportRouteProps, ImportRoute
|
|
|
19
20
|
|
|
20
21
|
|
|
21
22
|
render() {
|
|
22
|
-
const {
|
|
23
|
-
const { sourceId} =
|
|
23
|
+
const { params, } = this.props;
|
|
24
|
+
const { sourceId} = params;
|
|
24
25
|
return <ExcelImport sourceId={sourceId}></ExcelImport>
|
|
25
26
|
}
|
|
26
27
|
}
|
|
27
|
-
export default ExcelImportRoute;
|
|
28
|
+
export default withRouter(ExcelImportRoute);
|
|
28
29
|
|
|
@@ -4,23 +4,25 @@ import Units from "../units";
|
|
|
4
4
|
import ActTable from '../table/act-table'
|
|
5
5
|
// import StatActTable from '../table/stat-act-table'
|
|
6
6
|
import HCDataSource from "../tmpl/hc-data-source";
|
|
7
|
-
|
|
7
|
+
import withRouter from "../routable/withroute";
|
|
8
8
|
export interface LtmplRouteProps extends RouterCompProps {
|
|
9
9
|
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export interface LtmplRouteState {
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
ltmplConfigRes?: LtmplConfigRes,
|
|
14
|
+
pageNo?: number,
|
|
15
|
+
pageSize?: number,
|
|
15
16
|
};
|
|
16
17
|
|
|
17
18
|
class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
18
|
-
static
|
|
19
|
-
basePath:"",
|
|
19
|
+
static defaultProps = {
|
|
20
|
+
basePath: "",
|
|
20
21
|
}
|
|
21
|
-
|
|
22
22
|
state = {
|
|
23
23
|
ltmplConfigRes: undefined,
|
|
24
|
+
pageNo: undefined,
|
|
25
|
+
pageSize: undefined,
|
|
24
26
|
}
|
|
25
27
|
|
|
26
28
|
async componentDidMount() {
|
|
@@ -28,36 +30,32 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
28
30
|
}
|
|
29
31
|
|
|
30
32
|
onRoute = (path) => {
|
|
31
|
-
this.props.
|
|
33
|
+
this.props.navigate(path);
|
|
32
34
|
}
|
|
33
35
|
|
|
34
|
-
getMenuId=()=>{
|
|
35
|
-
const {
|
|
36
|
-
//console.log("this.props.match.params",this.props);
|
|
37
|
-
var searchParams = new URLSearchParams( location.search);
|
|
36
|
+
getMenuId = () => {
|
|
37
|
+
const {searchParams} = this.props;
|
|
38
38
|
let menuId = searchParams.get('menuId');
|
|
39
39
|
return menuId;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
loadData = async () => {
|
|
43
|
-
const {
|
|
44
|
-
const {
|
|
45
|
-
let
|
|
46
|
-
//console.log('acttable location search:', this.props.location.search);
|
|
47
|
-
let ltmplConfigRes = await HCDataSource.requestLtmplConfig(sourceId);
|
|
43
|
+
const {params} = this.props;
|
|
44
|
+
const {sourceId} = params;
|
|
45
|
+
let ltmplConfigRes:LtmplConfigRes = await HCDataSource.requestLtmplConfig(sourceId);
|
|
48
46
|
this.setState({
|
|
49
|
-
ltmplConfigRes,
|
|
47
|
+
ltmplConfigRes:ltmplConfigRes,
|
|
50
48
|
})
|
|
51
49
|
}
|
|
52
50
|
|
|
53
51
|
async componentDidUpdate(prevProps) {
|
|
54
|
-
const {location} = this.props;
|
|
55
|
-
const {
|
|
56
|
-
let {
|
|
52
|
+
const {location,params} = this.props;
|
|
53
|
+
const {sourceId} = params;
|
|
54
|
+
let {sourceId: preSourceId} = prevProps.params;
|
|
57
55
|
let {location: preLocation} = prevProps;
|
|
58
56
|
|
|
59
|
-
if (
|
|
60
|
-
(
|
|
57
|
+
if (!sourceId ||
|
|
58
|
+
(!preSourceId && this.state.ltmplConfigRes)
|
|
61
59
|
|| (location.pathname == preLocation.pathname && location.search == preLocation.search)
|
|
62
60
|
) {
|
|
63
61
|
return;
|
|
@@ -65,26 +63,26 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
65
63
|
this.loadData();
|
|
66
64
|
}
|
|
67
65
|
|
|
68
|
-
showView = (code: string,toCustomPage:boolean=false) => {
|
|
69
|
-
const {basePath}=this.props;
|
|
70
|
-
const {
|
|
66
|
+
showView = (code: string, toCustomPage: boolean = false) => {
|
|
67
|
+
const {basePath} = this.props;
|
|
68
|
+
const {sourceId} = this.props.params;
|
|
71
69
|
const {ltmplConfigRes} = this.state;
|
|
72
70
|
let path = `${basePath}/${sourceId}/detail-view?code=${code}&menuId=${this.getMenuId()}`;
|
|
73
|
-
if(toCustomPage && ltmplConfigRes.ltmplConfig.customViewPagePath){
|
|
74
|
-
path
|
|
71
|
+
if (toCustomPage && ltmplConfigRes.ltmplConfig.customViewPagePath) {
|
|
72
|
+
path = `${basePath}${ltmplConfigRes.ltmplConfig.customViewPagePath}?menuId=${this.getMenuId()}&sourceId=${sourceId}`;
|
|
75
73
|
}
|
|
76
74
|
this.onRoute(path);
|
|
77
75
|
}
|
|
78
76
|
|
|
79
|
-
doEdit = (code: string,mode:AddOrUpdate,toCustomPage:boolean=false) => {
|
|
80
|
-
const {basePath}=this.props;
|
|
81
|
-
const {
|
|
77
|
+
doEdit = (code: string, mode: AddOrUpdate, toCustomPage: boolean = false) => {
|
|
78
|
+
const {basePath} = this.props;
|
|
79
|
+
const {sourceId} = this.props.params;
|
|
82
80
|
const {ltmplConfigRes} = this.state;
|
|
83
81
|
let mainCode = this.getMainCode();
|
|
84
82
|
|
|
85
83
|
let path = `${basePath}/${sourceId}/detail-edit?code=${code}&menuId=${this.getMenuId()}&mode=${mode}`;
|
|
86
|
-
if(toCustomPage && ltmplConfigRes.ltmplConfig.customEditPagePath){
|
|
87
|
-
path
|
|
84
|
+
if (toCustomPage && ltmplConfigRes.ltmplConfig.customEditPagePath) {
|
|
85
|
+
path = `${basePath}/page/${sourceId}${ltmplConfigRes.ltmplConfig.customEditPagePath}?code=${code}&menuId=${this.getMenuId()}`;
|
|
88
86
|
}
|
|
89
87
|
if (mainCode) {
|
|
90
88
|
path = path + `&mainCode=${mainCode}`;
|
|
@@ -93,24 +91,24 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
93
91
|
}
|
|
94
92
|
|
|
95
93
|
getMainCode = () => {
|
|
96
|
-
const {
|
|
97
|
-
let search = location.search;
|
|
94
|
+
const {searchParams} = this.props;
|
|
98
95
|
let mainCode = undefined;
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
96
|
+
// let criteriaData = Units.transQueryStrToParams(search);
|
|
97
|
+
let mcode=searchParams.get('mainCode');
|
|
98
|
+
if (mcode) {
|
|
99
|
+
// criteriaData = Units.transQueryStrToParams(search);
|
|
100
|
+
mainCode = mcode;
|
|
103
101
|
}
|
|
104
102
|
return mainCode;
|
|
105
103
|
}
|
|
106
104
|
|
|
107
|
-
doCreate = (toCustomPage:boolean=false) => {
|
|
108
|
-
const {basePath}=this.props;
|
|
109
|
-
const {
|
|
105
|
+
doCreate = (toCustomPage: boolean = false) => {
|
|
106
|
+
const {basePath} = this.props;
|
|
107
|
+
const {sourceId} = this.props.params;
|
|
110
108
|
const {ltmplConfigRes} = this.state;
|
|
111
109
|
let path = `${basePath}/${sourceId}/detail-edit?menuId=${this.getMenuId()}`;
|
|
112
|
-
if(toCustomPage && ltmplConfigRes.ltmplConfig.customEditPagePath){
|
|
113
|
-
path
|
|
110
|
+
if (toCustomPage && ltmplConfigRes.ltmplConfig.customEditPagePath) {
|
|
111
|
+
path = `${basePath}/page/${sourceId}${ltmplConfigRes.ltmplConfig.customEditPagePath}?menuId=${this.getMenuId()}`;
|
|
114
112
|
}
|
|
115
113
|
let mainCode = this.getMainCode();
|
|
116
114
|
if (mainCode) {
|
|
@@ -119,60 +117,87 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
119
117
|
this.onRoute(path);
|
|
120
118
|
}
|
|
121
119
|
|
|
122
|
-
doRAction = (ractionId:string,mainCode:String) => {
|
|
123
|
-
const {basePath}=this.props;
|
|
120
|
+
doRAction = (ractionId: string, mainCode: String) => {
|
|
121
|
+
const {basePath} = this.props;
|
|
124
122
|
let path = `${basePath}/${ractionId}/act-table?mainCode=${mainCode}&menuId=${this.getMenuId()}`;
|
|
125
123
|
this.onRoute(path);
|
|
126
124
|
}
|
|
127
125
|
|
|
128
126
|
doSearch = (params_) => {
|
|
129
|
-
const {basePath}=this.props;
|
|
130
|
-
const {
|
|
131
|
-
|
|
127
|
+
const {basePath} = this.props;
|
|
128
|
+
const {sourceId} = this.props.params;
|
|
129
|
+
let params = {...params_}
|
|
130
|
+
params['sourceId'] = sourceId;
|
|
131
|
+
const newfliter = Units.transQueryParamsToStr(params);
|
|
132
|
+
this.props.navigate(`${basePath}/${sourceId}/act-table?menuId=${this.getMenuId()}&${newfliter}`,{replace:true})
|
|
132
133
|
|
|
134
|
+
}
|
|
135
|
+
onChangeSearch = (params_) => {
|
|
133
136
|
let params = {...params_}
|
|
134
137
|
//追加过滤条件,hiddenColIds,innerQueryKey
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
+
const {location,searchParams} = this.props;
|
|
139
|
+
let mainCode = undefined;
|
|
140
|
+
let criteriaData=searchParams;
|
|
141
|
+
let mcode=searchParams.get("mainCode");
|
|
142
|
+
if (mcode) {
|
|
143
|
+
params['mainCode'] = mcode;
|
|
138
144
|
}
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
145
|
+
const {pageSize,pageNo} = this.state;
|
|
146
|
+
if(pageSize){
|
|
147
|
+
params['pageNo'] = pageNo;
|
|
148
|
+
}
|
|
149
|
+
if(pageNo){
|
|
150
|
+
params['pageSize'] = pageSize;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
this.doSearch(params);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
onChangePage = (pageNo: number, pageSize: number) => {
|
|
157
|
+
const {location} = this.props;
|
|
158
|
+
let search = location.search;
|
|
159
|
+
let mainCode = undefined;
|
|
160
|
+
let params = Units.transQueryStrToParams(search);
|
|
161
|
+
params['pageNo'] = pageNo;
|
|
162
|
+
params['pageSize'] = pageSize;
|
|
163
|
+
this.doSearch(params);
|
|
164
|
+
|
|
165
|
+
// this.setState({
|
|
166
|
+
// pageNo,
|
|
167
|
+
// pageSize
|
|
168
|
+
// })
|
|
150
169
|
}
|
|
151
170
|
|
|
152
171
|
|
|
153
172
|
render() {
|
|
154
173
|
const {ltmplConfigRes} = this.state;
|
|
155
|
-
const {location,
|
|
156
|
-
const {
|
|
157
|
-
let menuId = undefined;
|
|
174
|
+
const {location, params} = this.props;
|
|
175
|
+
const {sourceId} = params;
|
|
176
|
+
//let menuId = undefined;
|
|
158
177
|
let mainCode = undefined;
|
|
178
|
+
|
|
159
179
|
let search = location.search;
|
|
180
|
+
debugger
|
|
160
181
|
let criteriaData = Units.transQueryStrToParams(search);
|
|
161
|
-
if (search.indexOf('menuId') > 0) {
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
} else
|
|
165
|
-
|
|
166
|
-
}
|
|
182
|
+
// if (search.indexOf('menuId') > 0) {
|
|
183
|
+
// menuId = criteriaData['menuId'];
|
|
184
|
+
// criteriaData['menuId'] = undefined;
|
|
185
|
+
// } else {
|
|
186
|
+
// menuId = sourceId;
|
|
187
|
+
// }
|
|
188
|
+
let pageSize = criteriaData['pageSize'];
|
|
189
|
+
let pageNo = criteriaData['pageNo'];
|
|
190
|
+
|
|
167
191
|
if (search.indexOf('mainCode') > 0) {
|
|
168
|
-
criteriaData = Units.transQueryStrToParams(search);
|
|
192
|
+
//criteriaData = Units.transQueryStrToParams(search);
|
|
169
193
|
mainCode = criteriaData['mainCode'];
|
|
170
194
|
}
|
|
171
195
|
if (!ltmplConfigRes) {
|
|
172
196
|
return <></>;
|
|
173
197
|
} else {
|
|
174
|
-
return <ActTable
|
|
175
|
-
|
|
198
|
+
return <ActTable pageSize={pageSize} pageNo={pageNo} onChangePage={this.onChangePage}
|
|
199
|
+
menuId={this.getMenuId()} mainCode={mainCode} showView={this.showView}
|
|
200
|
+
doSearch={this.onChangeSearch} doEdit={this.doEdit} doCreate={this.doCreate}
|
|
176
201
|
sourceId={sourceId} criteriaData={criteriaData}
|
|
177
202
|
ltmplConfig={ltmplConfigRes.ltmplConfig}
|
|
178
203
|
doRAction={this.doRAction}
|
|
@@ -182,5 +207,5 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
182
207
|
}
|
|
183
208
|
}
|
|
184
209
|
|
|
185
|
-
export default LtmplRoute;
|
|
210
|
+
export default withRouter(LtmplRoute);
|
|
186
211
|
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import {useLocation, useNavigate, useParams,useSearchParams} from "react-router-dom";
|
|
3
|
+
|
|
4
|
+
const withRouter = Comp => props => {
|
|
5
|
+
const location = useLocation();
|
|
6
|
+
const navigate = useNavigate();
|
|
7
|
+
const params = useParams();
|
|
8
|
+
const [searchParams,setSearchParams]=useSearchParams();
|
|
9
|
+
return (
|
|
10
|
+
<Comp
|
|
11
|
+
{...props}
|
|
12
|
+
location={location}
|
|
13
|
+
navigate={navigate}
|
|
14
|
+
params={params}
|
|
15
|
+
searchParams={searchParams}
|
|
16
|
+
/>
|
|
17
|
+
);
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
export default withRouter;
|
|
22
|
+
|