aldehyde 0.0.8 → 0.0.11
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/components/chart/antd/chart-utils.d.ts +7 -0
- package/lib/components/chart/antd/chart-utils.d.ts.map +1 -0
- package/lib/components/chart/antd/chart-utils.js +46 -0
- package/lib/components/chart/antd/chart-utils.js.map +1 -0
- package/lib/components/chart/antd/column-chart-sub.d.ts +7 -0
- package/lib/components/chart/antd/column-chart-sub.d.ts.map +1 -0
- package/lib/components/chart/antd/column-chart-sub.js +50 -0
- package/lib/components/chart/antd/column-chart-sub.js.map +1 -0
- package/lib/components/chart/antd/line-chart-sub.d.ts +7 -0
- package/lib/components/chart/antd/line-chart-sub.d.ts.map +1 -0
- package/lib/components/chart/antd/line-chart-sub.js +49 -0
- package/lib/components/chart/antd/line-chart-sub.js.map +1 -0
- package/lib/components/chart/antd/pie-chart-sub.d.ts +7 -0
- package/lib/components/chart/antd/pie-chart-sub.d.ts.map +1 -0
- package/lib/components/chart/antd/pie-chart-sub.js +37 -0
- package/lib/components/chart/antd/pie-chart-sub.js.map +1 -0
- package/lib/components/chart/antd/statview-d2-chart.d.ts +17 -0
- package/lib/components/chart/antd/statview-d2-chart.d.ts.map +1 -0
- package/lib/components/chart/antd/statview-d2-chart.js +108 -0
- package/lib/components/chart/antd/statview-d2-chart.js.map +1 -0
- package/lib/components/chart/statview-l2-chart.d.ts +23 -0
- package/lib/components/chart/statview-l2-chart.d.ts.map +1 -0
- package/lib/components/chart/statview-l2-chart.js +64 -0
- package/lib/components/chart/statview-l2-chart.js.map +1 -0
- package/lib/components/controls/action/index.css +9 -0
- package/lib/components/controls/action/index.d.ts +47 -0
- package/lib/components/controls/action/index.d.ts.map +1 -0
- package/lib/components/controls/action/index.js +165 -0
- package/lib/components/controls/action/index.js.map +1 -0
- package/lib/components/controls/action/utils.d.ts +9 -0
- package/lib/components/controls/action/utils.d.ts.map +1 -0
- package/lib/components/controls/action/utils.js +110 -0
- package/lib/components/controls/action/utils.js.map +1 -0
- package/lib/components/controls/auto-complete/index.d.ts +7 -0
- package/lib/components/controls/auto-complete/index.d.ts.map +1 -0
- package/lib/components/controls/auto-complete/index.js +53 -0
- package/lib/components/controls/auto-complete/index.js.map +1 -0
- package/lib/components/controls/chemstruc/graph.d.ts +31 -0
- package/lib/components/controls/chemstruc/graph.d.ts.map +1 -0
- package/lib/components/controls/chemstruc/graph.js +121 -0
- package/lib/components/controls/chemstruc/graph.js.map +1 -0
- package/lib/components/controls/chemstruc/index.css +28 -0
- package/lib/components/controls/collapse-card/index.css +9 -0
- package/lib/components/controls/collapse-card/index.d.ts +20 -0
- package/lib/components/controls/collapse-card/index.d.ts.map +1 -0
- package/lib/components/controls/collapse-card/index.js +63 -0
- package/lib/components/controls/collapse-card/index.js.map +1 -0
- package/lib/components/controls/color-picker/index.css +27 -0
- package/lib/components/controls/color-picker/index.d.ts +19 -0
- package/lib/components/controls/color-picker/index.d.ts.map +1 -0
- package/lib/components/controls/color-picker/index.js +61 -0
- package/lib/components/controls/color-picker/index.js.map +1 -0
- package/lib/components/controls/cquery/cquick-button.d.ts +20 -0
- package/lib/components/controls/cquery/cquick-button.d.ts.map +1 -0
- package/lib/components/controls/cquery/cquick-button.js +67 -0
- package/lib/components/controls/cquery/cquick-button.js.map +1 -0
- package/lib/components/controls/date-picker/index.d.ts +7 -0
- package/lib/components/controls/date-picker/index.d.ts.map +1 -0
- package/lib/components/controls/date-picker/index.js +91 -0
- package/lib/components/controls/date-picker/index.js.map +1 -0
- package/lib/components/controls/entity-select/entity-select.d.ts +53 -0
- package/lib/components/controls/entity-select/entity-select.d.ts.map +1 -0
- package/lib/components/controls/entity-select/entity-select.js +227 -0
- package/lib/components/controls/entity-select/entity-select.js.map +1 -0
- package/lib/components/controls/entity-select/index.css +6 -0
- package/lib/components/controls/entity-select/popover-entity-select.d.ts +20 -0
- package/lib/components/controls/entity-select/popover-entity-select.d.ts.map +1 -0
- package/lib/components/controls/entity-select/popover-entity-select.js +80 -0
- package/lib/components/controls/entity-select/popover-entity-select.js.map +1 -0
- package/lib/components/controls/entry-control.d.ts +11 -0
- package/lib/components/controls/entry-control.d.ts.map +1 -0
- package/lib/components/controls/entry-control.js +171 -0
- package/lib/components/controls/entry-control.js.map +1 -0
- package/lib/components/controls/enum-badge/index.d.ts +7 -0
- package/lib/components/controls/enum-badge/index.d.ts.map +1 -0
- package/lib/components/controls/enum-badge/index.js +14 -0
- package/lib/components/controls/enum-badge/index.js.map +1 -0
- package/lib/components/controls/enum-tag/index.d.ts +7 -0
- package/lib/components/controls/enum-tag/index.d.ts.map +1 -0
- package/lib/components/controls/enum-tag/index.js +18 -0
- package/lib/components/controls/enum-tag/index.js.map +1 -0
- package/lib/components/controls/file-view/drawer-file-view.d.ts +18 -0
- package/lib/components/controls/file-view/drawer-file-view.d.ts.map +1 -0
- package/lib/components/controls/file-view/drawer-file-view.js +51 -0
- package/lib/components/controls/file-view/drawer-file-view.js.map +1 -0
- package/lib/components/controls/file-view/index.d.ts +23 -0
- package/lib/components/controls/file-view/index.d.ts.map +1 -0
- package/lib/components/controls/file-view/index.js +130 -0
- package/lib/components/controls/file-view/index.js.map +1 -0
- package/lib/components/controls/html-editor/draft.d.ts +22 -0
- package/lib/components/controls/html-editor/draft.d.ts.map +1 -0
- package/lib/components/controls/html-editor/draft.js +122 -0
- package/lib/components/controls/html-editor/draft.js.map +1 -0
- package/lib/components/controls/input-number/index.d.ts +7 -0
- package/lib/components/controls/input-number/index.d.ts.map +1 -0
- package/lib/components/controls/input-number/index.js +67 -0
- package/lib/components/controls/input-number/index.js.map +1 -0
- package/lib/components/controls/input-range/index.d.ts +7 -0
- package/lib/components/controls/input-range/index.d.ts.map +1 -0
- package/lib/components/controls/input-range/index.js +28 -0
- package/lib/components/controls/input-range/index.js.map +1 -0
- package/lib/components/controls/password-setter/index.css +3 -0
- package/lib/components/controls/progress/index.d.ts +7 -0
- package/lib/components/controls/progress/index.d.ts.map +1 -0
- package/lib/components/controls/progress/index.js +45 -0
- package/lib/components/controls/progress/index.js.map +1 -0
- package/lib/components/controls/relation-existion/index.css +4 -0
- package/lib/components/controls/relation-existion/index.d.ts +20 -0
- package/lib/components/controls/relation-existion/index.d.ts.map +1 -0
- package/lib/components/controls/relation-existion/index.js +75 -0
- package/lib/components/controls/relation-existion/index.js.map +1 -0
- package/lib/components/controls/rfield/index.css +4 -0
- package/lib/components/controls/rfield/index.d.ts +29 -0
- package/lib/components/controls/rfield/index.d.ts.map +1 -0
- package/lib/components/controls/rfield/index.js +130 -0
- package/lib/components/controls/rfield/index.js.map +1 -0
- package/lib/components/controls/signature/index.d.ts +31 -0
- package/lib/components/controls/signature/index.d.ts.map +1 -0
- package/lib/components/controls/signature/index.js +129 -0
- package/lib/components/controls/signature/index.js.map +1 -0
- package/lib/components/controls/steps/index.d.ts +7 -0
- package/lib/components/controls/steps/index.d.ts.map +1 -0
- package/lib/components/controls/steps/index.js +42 -0
- package/lib/components/controls/steps/index.js.map +1 -0
- package/lib/components/controls/text/ellipsis-text.d.ts +22 -0
- package/lib/components/controls/text/ellipsis-text.d.ts.map +1 -0
- package/lib/components/controls/text/ellipsis-text.js +46 -0
- package/lib/components/controls/text/ellipsis-text.js.map +1 -0
- package/lib/components/controls/upload/index.d.ts +15 -0
- package/lib/components/controls/upload/index.d.ts.map +1 -0
- package/lib/components/controls/upload/index.js +100 -0
- package/lib/components/controls/upload/index.js.map +1 -0
- package/lib/components/controls/view-control.d.ts +10 -0
- package/lib/components/controls/view-control.d.ts.map +1 -0
- package/lib/components/controls/view-control.js +150 -0
- package/lib/components/controls/view-control.js.map +1 -0
- package/lib/components/detail/button/cquery-button-bar.d.ts +16 -0
- package/lib/components/detail/button/cquery-button-bar.d.ts.map +1 -0
- package/lib/components/detail/button/cquery-button-bar.js +75 -0
- package/lib/components/detail/button/cquery-button-bar.js.map +1 -0
- package/lib/components/detail/button/index.css +43 -0
- package/lib/components/detail/button/submit-button-bar.d.ts +19 -0
- package/lib/components/detail/button/submit-button-bar.d.ts.map +1 -0
- package/lib/components/detail/button/submit-button-bar.js +99 -0
- package/lib/components/detail/button/submit-button-bar.js.map +1 -0
- package/lib/components/detail/dtmpl.css +53 -0
- package/lib/components/detail/edit/dtmpl-edit.d.ts +48 -0
- package/lib/components/detail/edit/dtmpl-edit.d.ts.map +1 -0
- package/lib/components/detail/edit/dtmpl-edit.js +190 -0
- package/lib/components/detail/edit/dtmpl-edit.js.map +1 -0
- package/lib/components/detail/edit/fields-edit-card.d.ts +39 -0
- package/lib/components/detail/edit/fields-edit-card.d.ts.map +1 -0
- package/lib/components/detail/edit/fields-edit-card.js +64 -0
- package/lib/components/detail/edit/fields-edit-card.js.map +1 -0
- package/lib/components/detail/edit/modal-dtmpl-edit.d.ts +51 -0
- package/lib/components/detail/edit/modal-dtmpl-edit.d.ts.map +1 -0
- package/lib/components/detail/edit/modal-dtmpl-edit.js +168 -0
- package/lib/components/detail/edit/modal-dtmpl-edit.js.map +1 -0
- package/lib/components/detail/edit/modal-row-edit.d.ts +31 -0
- package/lib/components/detail/edit/modal-row-edit.d.ts.map +1 -0
- package/lib/components/detail/edit/modal-row-edit.js +56 -0
- package/lib/components/detail/edit/modal-row-edit.js.map +1 -0
- package/lib/components/detail/edit/post-result/index.d.ts +17 -0
- package/lib/components/detail/edit/post-result/index.d.ts.map +1 -0
- package/lib/components/detail/edit/post-result/index.js +28 -0
- package/lib/components/detail/edit/post-result/index.js.map +1 -0
- package/lib/components/detail/edit/row-edit-card.d.ts +42 -0
- package/lib/components/detail/edit/row-edit-card.d.ts.map +1 -0
- package/lib/components/detail/edit/row-edit-card.js +84 -0
- package/lib/components/detail/edit/row-edit-card.js.map +1 -0
- package/lib/components/detail/edit/row-editor.d.ts +31 -0
- package/lib/components/detail/edit/row-editor.d.ts.map +1 -0
- package/lib/components/detail/edit/row-editor.js +55 -0
- package/lib/components/detail/edit/row-editor.js.map +1 -0
- package/lib/components/detail/rightbar/index.css +35 -0
- package/lib/components/detail/rightbar/index.d.ts +20 -0
- package/lib/components/detail/rightbar/index.d.ts.map +1 -0
- package/lib/components/detail/rightbar/index.js +51 -0
- package/lib/components/detail/rightbar/index.js.map +1 -0
- package/lib/components/detail/view/act-dtmpl-view.d.ts +46 -0
- package/lib/components/detail/view/act-dtmpl-view.d.ts.map +1 -0
- package/lib/components/detail/view/act-dtmpl-view.js +110 -0
- package/lib/components/detail/view/act-dtmpl-view.js.map +1 -0
- package/lib/components/detail/view/dtmpl-view.d.ts +42 -0
- package/lib/components/detail/view/dtmpl-view.d.ts.map +1 -0
- package/lib/components/detail/view/dtmpl-view.js +111 -0
- package/lib/components/detail/view/dtmpl-view.js.map +1 -0
- package/lib/components/detail/view/field-view-group.d.ts +17 -0
- package/lib/components/detail/view/field-view-group.d.ts.map +1 -0
- package/lib/components/detail/view/field-view-group.js +51 -0
- package/lib/components/detail/view/field-view-group.js.map +1 -0
- package/lib/components/detail/view/modal-dtmpl-view.d.ts +27 -0
- package/lib/components/detail/view/modal-dtmpl-view.d.ts.map +1 -0
- package/lib/components/detail/view/modal-dtmpl-view.js +32 -0
- package/lib/components/detail/view/modal-dtmpl-view.js.map +1 -0
- package/lib/components/detail/view/snapshot-timeline.d.ts +32 -0
- package/lib/components/detail/view/snapshot-timeline.d.ts.map +1 -0
- package/lib/components/detail/view/snapshot-timeline.js +90 -0
- package/lib/components/detail/view/snapshot-timeline.js.map +1 -0
- package/lib/components/exportor/export-frame.css +3 -0
- package/lib/components/exportor/export-frame.d.ts +50 -0
- package/lib/components/exportor/export-frame.d.ts.map +1 -0
- package/lib/components/exportor/export-frame.js +140 -0
- package/lib/components/exportor/export-frame.js.map +1 -0
- package/lib/components/exportor/index.d.ts +16 -0
- package/lib/components/exportor/index.d.ts.map +1 -0
- package/lib/components/exportor/index.js +44 -0
- package/lib/components/exportor/index.js.map +1 -0
- package/lib/components/form/criteria-form.d.ts +19 -0
- package/lib/components/form/criteria-form.d.ts.map +1 -0
- package/lib/components/form/criteria-form.js +167 -0
- package/lib/components/form/criteria-form.js.map +1 -0
- package/lib/components/form/dtmpl-form.css +4 -0
- package/lib/components/form/dtmpl-form.d.ts +37 -0
- package/lib/components/form/dtmpl-form.d.ts.map +1 -0
- package/lib/components/form/dtmpl-form.js +213 -0
- package/lib/components/form/dtmpl-form.js.map +1 -0
- package/lib/components/form/field-group-form.d.ts +21 -0
- package/lib/components/form/field-group-form.d.ts.map +1 -0
- package/lib/components/form/field-group-form.js +58 -0
- package/lib/components/form/field-group-form.js.map +1 -0
- package/lib/components/form/fields-form.d.ts +20 -0
- package/lib/components/form/fields-form.d.ts.map +1 -0
- package/lib/components/form/fields-form.js +39 -0
- package/lib/components/form/fields-form.js.map +1 -0
- package/lib/components/form/form-Item-group.d.ts +22 -0
- package/lib/components/form/form-Item-group.d.ts.map +1 -0
- package/lib/components/form/form-Item-group.js +60 -0
- package/lib/components/form/form-Item-group.js.map +1 -0
- package/lib/components/form/index.css +13 -0
- package/lib/components/import/excel-import.d.ts +48 -0
- package/lib/components/import/excel-import.d.ts.map +1 -0
- package/lib/components/import/excel-import.js +234 -0
- package/lib/components/import/excel-import.js.map +1 -0
- package/lib/components/import/index.css +54 -0
- package/lib/components/import/template.css +51 -0
- package/lib/components/layout/MainPage.d.ts +32 -0
- package/lib/components/layout/MainPage.d.ts.map +1 -0
- package/lib/components/layout/MainPage.js +202 -0
- package/lib/components/layout/MainPage.js.map +1 -0
- package/lib/components/layout/footer/index.css +6 -0
- package/lib/components/layout/header/index.css +86 -0
- package/lib/components/layout/header/index.d.ts +16 -0
- package/lib/components/layout/header/index.d.ts.map +1 -0
- package/lib/components/layout/header/index.js +37 -0
- package/lib/components/layout/header/index.js.map +1 -0
- package/lib/components/layout/menu/block.d.ts +9 -0
- package/lib/components/layout/menu/block.d.ts.map +1 -0
- package/lib/components/layout/menu/block.js +48 -0
- package/lib/components/layout/menu/block.js.map +1 -0
- package/lib/components/layout/menu/l2menu-message-bar.d.ts +24 -0
- package/lib/components/layout/menu/l2menu-message-bar.d.ts.map +1 -0
- package/lib/components/layout/menu/l2menu-message-bar.js +97 -0
- package/lib/components/layout/menu/l2menu-message-bar.js.map +1 -0
- package/lib/components/layout/menu/l2menu-quick-bar.d.ts +30 -0
- package/lib/components/layout/menu/l2menu-quick-bar.d.ts.map +1 -0
- package/lib/components/layout/menu/l2menu-quick-bar.js +94 -0
- package/lib/components/layout/menu/l2menu-quick-bar.js.map +1 -0
- package/lib/components/layout/menu/menu-2layers.d.ts +9 -0
- package/lib/components/layout/menu/menu-2layers.d.ts.map +1 -0
- package/lib/components/layout/menu/menu-2layers.js +63 -0
- package/lib/components/layout/menu/menu-2layers.js.map +1 -0
- package/lib/components/layout/menu/menu-render.d.ts +8 -0
- package/lib/components/layout/menu/menu-render.d.ts.map +1 -0
- package/lib/components/layout/menu/menu-render.js +44 -0
- package/lib/components/layout/menu/menu-render.js.map +1 -0
- package/lib/components/layout/menu/reset-password.d.ts +25 -0
- package/lib/components/layout/menu/reset-password.d.ts.map +1 -0
- package/lib/components/layout/menu/reset-password.js +113 -0
- package/lib/components/layout/menu/reset-password.js.map +1 -0
- package/lib/components/layout/menu/user-bar.d.ts +19 -0
- package/lib/components/layout/menu/user-bar.d.ts.map +1 -0
- package/lib/components/layout/menu/user-bar.js +61 -0
- package/lib/components/layout/menu/user-bar.js.map +1 -0
- package/lib/components/layout/menu/userinfo-bar.d.ts +18 -0
- package/lib/components/layout/menu/userinfo-bar.d.ts.map +1 -0
- package/lib/components/layout/menu/userinfo-bar.js +50 -0
- package/lib/components/layout/menu/userinfo-bar.js.map +1 -0
- package/lib/components/layout/sidebar/index.css +26 -0
- package/lib/components/layout/sidebar/index.d.ts +12 -0
- package/lib/components/layout/sidebar/index.d.ts.map +1 -0
- package/lib/components/layout/sidebar/index.js +19 -0
- package/lib/components/layout/sidebar/index.js.map +1 -0
- package/lib/components/module/dtmpl-page.d.ts +19 -0
- package/lib/components/module/dtmpl-page.d.ts.map +1 -0
- package/lib/components/module/dtmpl-page.js +46 -0
- package/lib/components/module/dtmpl-page.js.map +1 -0
- package/lib/components/module/ltmpl-page.d.ts +34 -0
- package/lib/components/module/ltmpl-page.d.ts.map +1 -0
- package/lib/components/module/ltmpl-page.js +154 -0
- package/lib/components/module/ltmpl-page.js.map +1 -0
- package/lib/components/routable/dtmpl-route.d.ts +17 -0
- package/lib/components/routable/dtmpl-route.d.ts.map +1 -0
- package/lib/components/routable/dtmpl-route.js +77 -0
- package/lib/components/routable/dtmpl-route.js.map +1 -0
- package/lib/components/routable/import-route.d.ts +13 -0
- package/lib/components/routable/import-route.d.ts.map +1 -0
- package/lib/components/routable/import-route.js +29 -0
- package/lib/components/routable/import-route.js.map +1 -0
- package/lib/components/routable/ltmpl-route.d.ts +25 -0
- package/lib/components/routable/ltmpl-route.d.ts.map +1 -0
- package/lib/components/routable/ltmpl-route.js +145 -0
- package/lib/components/routable/ltmpl-route.js.map +1 -0
- package/lib/components/table/act-table.d.ts +76 -0
- package/lib/components/table/act-table.d.ts.map +1 -0
- package/lib/components/table/act-table.js +454 -0
- package/lib/components/table/act-table.js.map +1 -0
- package/lib/components/table/column/column-selector.d.ts +26 -0
- package/lib/components/table/column/column-selector.d.ts.map +1 -0
- package/lib/components/table/column/column-selector.js +59 -0
- package/lib/components/table/column/column-selector.js.map +1 -0
- package/lib/components/table/column/index.css +14 -0
- package/lib/components/table/index.css +45 -0
- package/lib/components/table/l2-act-table.d.ts +23 -0
- package/lib/components/table/l2-act-table.d.ts.map +1 -0
- package/lib/components/table/l2-act-table.js +80 -0
- package/lib/components/table/l2-act-table.js.map +1 -0
- package/lib/components/table/modal-select-table.d.ts +41 -0
- package/lib/components/table/modal-select-table.d.ts.map +1 -0
- package/lib/components/table/modal-select-table.js +208 -0
- package/lib/components/table/modal-select-table.js.map +1 -0
- package/lib/components/table/pagination.css +15 -0
- package/lib/components/table/pagination.d.ts +17 -0
- package/lib/components/table/pagination.d.ts.map +1 -0
- package/lib/components/table/pagination.js +40 -0
- package/lib/components/table/pagination.js.map +1 -0
- package/lib/components/table/query-table.d.ts +65 -0
- package/lib/components/table/query-table.d.ts.map +1 -0
- package/lib/components/table/query-table.js +257 -0
- package/lib/components/table/query-table.js.map +1 -0
- package/lib/components/table/relation-table.d.ts +61 -0
- package/lib/components/table/relation-table.d.ts.map +1 -0
- package/lib/components/table/relation-table.js +444 -0
- package/lib/components/table/relation-table.js.map +1 -0
- package/lib/components/table/select-table.d.ts +40 -0
- package/lib/components/table/select-table.d.ts.map +1 -0
- package/lib/components/table/select-table.js +223 -0
- package/lib/components/table/select-table.js.map +1 -0
- package/lib/components/table/selected-rows-card.d.ts +16 -0
- package/lib/components/table/selected-rows-card.d.ts.map +1 -0
- package/lib/components/table/selected-rows-card.js +47 -0
- package/lib/components/table/selected-rows-card.js.map +1 -0
- package/lib/components/table/stat/restat.d.ts +26 -0
- package/lib/components/table/stat/restat.d.ts.map +1 -0
- package/lib/components/table/stat/restat.js +61 -0
- package/lib/components/table/stat/restat.js.map +1 -0
- package/lib/components/table/table-util.d.ts +5 -0
- package/lib/components/table/table-util.d.ts.map +1 -0
- package/lib/components/table/table-util.js +30 -0
- package/lib/components/table/table-util.js.map +1 -0
- package/lib/components/tmpl/control-type-supportor.d.ts +9 -0
- package/lib/components/tmpl/control-type-supportor.d.ts.map +1 -0
- package/lib/components/tmpl/control-type-supportor.js +85 -0
- package/lib/components/tmpl/control-type-supportor.js.map +1 -0
- package/lib/components/tmpl/hc-data-source.d.ts +19 -0
- package/lib/components/tmpl/hc-data-source.d.ts.map +1 -0
- package/lib/components/tmpl/hc-data-source.js +230 -0
- package/lib/components/tmpl/hc-data-source.js.map +1 -0
- package/lib/components/tmpl/hcservice-v3.d.ts +53 -0
- package/lib/components/tmpl/hcservice-v3.d.ts.map +1 -0
- package/lib/components/tmpl/hcservice-v3.js +639 -0
- package/lib/components/tmpl/hcservice-v3.js.map +1 -0
- package/lib/components/tmpl/interface.d.ts +234 -0
- package/lib/components/tmpl/interface.d.ts.map +1 -0
- package/lib/components/tmpl/interface.js +4 -0
- package/lib/components/tmpl/interface.js.map +1 -0
- package/lib/components/tmpl/tmpl-config-analysis.d.ts +7 -0
- package/lib/components/tmpl/tmpl-config-analysis.d.ts.map +1 -0
- package/lib/components/tmpl/tmpl-config-analysis.js +106 -0
- package/lib/components/tmpl/tmpl-config-analysis.js.map +1 -0
- package/lib/components/units/index.d.ts +58 -0
- package/lib/components/units/index.d.ts.map +1 -0
- package/lib/components/units/index.js +525 -0
- package/lib/components/units/index.js.map +1 -0
- package/lib/components/welcome/index.css +13 -0
- package/lib/components/welcome/quick-entrance.d.ts +20 -0
- package/lib/components/welcome/quick-entrance.d.ts.map +1 -0
- package/lib/components/welcome/quick-entrance.js +79 -0
- package/lib/components/welcome/quick-entrance.js.map +1 -0
- package/lib/components/welcome/workbench.d.ts +20 -0
- package/lib/components/welcome/workbench.d.ts.map +1 -0
- package/lib/components/welcome/workbench.js +78 -0
- package/lib/components/welcome/workbench.js.map +1 -0
- package/lib/index.d.ts +4 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +4 -0
- package/lib/index.js.map +1 -0
- package/lib/style/common.css +79 -0
- package/lib/style/coverstyle.css +49 -0
- package/lib/style/transstyle.css +24 -0
- package/package.json +10 -7
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import React from 'react';
|
|
11
|
+
import { Card, Button, Upload, message, Progress, List, Checkbox, Row, Col, Popover, InputNumber } from 'antd';
|
|
12
|
+
import { ReloadOutlined, UploadOutlined, SettingOutlined } from '@ant-design/icons';
|
|
13
|
+
import Super from "../tmpl/superagent";
|
|
14
|
+
import Units from "../units";
|
|
15
|
+
import './index.css';
|
|
16
|
+
import HCDataSource from "../tmpl/hc-data-source";
|
|
17
|
+
const CheckboxGroup = Checkbox.Group;
|
|
18
|
+
const logLevelList = ['INFO', 'SUC', 'ERROR', 'WARN'];
|
|
19
|
+
let totalMSG = [];
|
|
20
|
+
;
|
|
21
|
+
;
|
|
22
|
+
export default class ExcelImport extends React.PureComponent {
|
|
23
|
+
constructor() {
|
|
24
|
+
super(...arguments);
|
|
25
|
+
this.state = {
|
|
26
|
+
maxMsgCount: 100,
|
|
27
|
+
inputMaxMsgCount: 100,
|
|
28
|
+
importStatus: 'waitingFile',
|
|
29
|
+
importFile: undefined,
|
|
30
|
+
logs: [],
|
|
31
|
+
percent: 0,
|
|
32
|
+
statusMsg: undefined,
|
|
33
|
+
logSetterVisible: false,
|
|
34
|
+
showLogLevelList: [...logLevelList],
|
|
35
|
+
logSerialId: undefined,
|
|
36
|
+
ltmplConfig: undefined,
|
|
37
|
+
};
|
|
38
|
+
this.timerId = undefined;
|
|
39
|
+
this.handleUpload = () => {
|
|
40
|
+
const { sourceId } = this.props;
|
|
41
|
+
const { importFile } = this.state;
|
|
42
|
+
const formData = new FormData();
|
|
43
|
+
formData.append('file', importFile);
|
|
44
|
+
formData.append('sourceId', sourceId.toString());
|
|
45
|
+
Super.super({
|
|
46
|
+
url: `/v3/ltmpl/importer`,
|
|
47
|
+
method: 'POST',
|
|
48
|
+
data: formData,
|
|
49
|
+
}, "formdata").then((res) => {
|
|
50
|
+
//console.log(res)
|
|
51
|
+
if (res.status === "success") {
|
|
52
|
+
this.setState({
|
|
53
|
+
importStatus: 'importing',
|
|
54
|
+
});
|
|
55
|
+
this.timerId = setInterval(() => this.handleStatus(res.importId), 500);
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
message.error('失败!');
|
|
59
|
+
this.setState({
|
|
60
|
+
importStatus: 'fail',
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
};
|
|
65
|
+
this.handleStopImport = () => {
|
|
66
|
+
this.setState({
|
|
67
|
+
importStatus: 'stop',
|
|
68
|
+
});
|
|
69
|
+
};
|
|
70
|
+
this.handleStatus = (importId) => {
|
|
71
|
+
const { maxMsgCount, importStatus } = this.state;
|
|
72
|
+
Super.super({
|
|
73
|
+
url: `/v3/importer/status`,
|
|
74
|
+
method: 'GET',
|
|
75
|
+
query: {
|
|
76
|
+
importId: importId,
|
|
77
|
+
msgIndex: 0,
|
|
78
|
+
maxMsgCount,
|
|
79
|
+
interrupted: importStatus == 'stop',
|
|
80
|
+
}
|
|
81
|
+
}, "", "none").then((res) => {
|
|
82
|
+
const MSG = [];
|
|
83
|
+
for (let item of res.messageSequence.messages) {
|
|
84
|
+
let color = "";
|
|
85
|
+
let logLevel = "";
|
|
86
|
+
let createTime = Units.formateDate(item.createTime);
|
|
87
|
+
if (item.type === "SUC") {
|
|
88
|
+
color = "green";
|
|
89
|
+
logLevel = '成功';
|
|
90
|
+
}
|
|
91
|
+
else if (item.type === "INFO") {
|
|
92
|
+
color = "black";
|
|
93
|
+
logLevel = '常规';
|
|
94
|
+
}
|
|
95
|
+
else if (item.type === "ERROR") {
|
|
96
|
+
color = "red";
|
|
97
|
+
logLevel = '错误';
|
|
98
|
+
}
|
|
99
|
+
else if (item.type === "WARN") {
|
|
100
|
+
color = "rgb(250, 225, 4)";
|
|
101
|
+
logLevel = '警告';
|
|
102
|
+
}
|
|
103
|
+
const msg = React.createElement("div", null,
|
|
104
|
+
React.createElement("p", null, createTime),
|
|
105
|
+
React.createElement("p", { style: { color: color } }, `【${logLevel}】` + item.text));
|
|
106
|
+
MSG.push({ level: item.type, msg });
|
|
107
|
+
}
|
|
108
|
+
this.setState({
|
|
109
|
+
statusMsg: res.message,
|
|
110
|
+
percent: Math.floor((res.current / res.totalCount) * 100),
|
|
111
|
+
logs: MSG,
|
|
112
|
+
});
|
|
113
|
+
if (res.completed === true) {
|
|
114
|
+
clearInterval(this.timerId);
|
|
115
|
+
message.success('导入完成!');
|
|
116
|
+
this.setState({
|
|
117
|
+
importStatus: 'success'
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
if (importStatus == 'stop') {
|
|
121
|
+
clearInterval(this.timerId);
|
|
122
|
+
}
|
|
123
|
+
});
|
|
124
|
+
};
|
|
125
|
+
this.onChangeShowLogLevelList = (showLogLevelList) => {
|
|
126
|
+
this.setState({
|
|
127
|
+
showLogLevelList,
|
|
128
|
+
});
|
|
129
|
+
};
|
|
130
|
+
this.fresh = () => {
|
|
131
|
+
// this.setState({
|
|
132
|
+
// fileList:[],
|
|
133
|
+
// uploading: false,
|
|
134
|
+
// statusMsg:"",
|
|
135
|
+
// begin:true,
|
|
136
|
+
// importAgain:"none",
|
|
137
|
+
// importbtn:"block",
|
|
138
|
+
// percent:0,
|
|
139
|
+
// messages:[]
|
|
140
|
+
// })
|
|
141
|
+
// message.success("刷新成功!")
|
|
142
|
+
};
|
|
143
|
+
this.handleLogSetter = () => {
|
|
144
|
+
const { inputMaxMsgCount } = this.state;
|
|
145
|
+
this.setState({
|
|
146
|
+
maxMsgCount: inputMaxMsgCount,
|
|
147
|
+
logSetterVisible: false,
|
|
148
|
+
});
|
|
149
|
+
message.success("设置成功!");
|
|
150
|
+
};
|
|
151
|
+
this.changeLogSetterVisible = visible => {
|
|
152
|
+
this.setState({ logSetterVisible: visible });
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
componentDidMount() {
|
|
156
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
157
|
+
const { sourceId } = this.props;
|
|
158
|
+
let ltmplConfigRes = yield HCDataSource.requestLtmplConfig(sourceId);
|
|
159
|
+
this.setState({
|
|
160
|
+
ltmplConfig: ltmplConfigRes.ltmplConfig,
|
|
161
|
+
});
|
|
162
|
+
});
|
|
163
|
+
}
|
|
164
|
+
componentWillUnmount() {
|
|
165
|
+
if (this.timerId) {
|
|
166
|
+
clearInterval(this.timerId);
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
render() {
|
|
170
|
+
const { ltmplConfig, importFile, maxMsgCount, percent, importStatus, showLogLevelList, logSetterVisible, logs } = this.state;
|
|
171
|
+
let showLogs = [];
|
|
172
|
+
for (let log of logs) {
|
|
173
|
+
if (showLogLevelList.includes(log.level)) {
|
|
174
|
+
showLogs.push(log.msg);
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
const props = {
|
|
178
|
+
accept: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,application/vnd.ms-excel,application/vnd.ms-excel",
|
|
179
|
+
onChange: () => {
|
|
180
|
+
},
|
|
181
|
+
onRemove: (file) => {
|
|
182
|
+
this.setState({
|
|
183
|
+
importFile: undefined,
|
|
184
|
+
importStatus: 'waitingFile',
|
|
185
|
+
percent: 0,
|
|
186
|
+
});
|
|
187
|
+
},
|
|
188
|
+
beforeUpload: (file) => {
|
|
189
|
+
this.setState({
|
|
190
|
+
percent: 0,
|
|
191
|
+
importFile: file,
|
|
192
|
+
importStatus: 'fileSelected',
|
|
193
|
+
});
|
|
194
|
+
return false;
|
|
195
|
+
},
|
|
196
|
+
fileList: importFile ? [importFile] : undefined,
|
|
197
|
+
};
|
|
198
|
+
const content = (React.createElement("div", null,
|
|
199
|
+
React.createElement("label", null, "\u65E5\u5FD7\u6D88\u606F\u6570\u4E0A\u9650\uFF1A"),
|
|
200
|
+
React.createElement(InputNumber, { defaultValue: maxMsgCount, onChange: (value) => this.setState({ inputMaxMsgCount: value }) }),
|
|
201
|
+
React.createElement(Button, { type: "primary", style: { marginLeft: '10px' }, onClick: this.handleLogSetter }, "\u786E\u5B9A")));
|
|
202
|
+
return (React.createElement("div", { className: "importData" },
|
|
203
|
+
React.createElement("h3", null,
|
|
204
|
+
'导入 -> ',
|
|
205
|
+
ltmplConfig ? ltmplConfig.title : "",
|
|
206
|
+
React.createElement("p", { className: "fr" },
|
|
207
|
+
React.createElement(Button, { className: "hoverbig", title: "\u5237\u65B0", onClick: this.fresh },
|
|
208
|
+
React.createElement(ReloadOutlined, null)))),
|
|
209
|
+
React.createElement(Row, null,
|
|
210
|
+
React.createElement(Col, { span: 14, offset: 5 },
|
|
211
|
+
React.createElement(Card, { style: { minWidth: 600 } },
|
|
212
|
+
React.createElement(Upload, Object.assign({}, props),
|
|
213
|
+
React.createElement(Button, null,
|
|
214
|
+
React.createElement(UploadOutlined, null),
|
|
215
|
+
"\u9009\u62E9\u5BFC\u5165\u6587\u4EF6")),
|
|
216
|
+
React.createElement(Progress, { percent: percent, size: "small", status: "active" }),
|
|
217
|
+
React.createElement("div", { className: "importBtns" },
|
|
218
|
+
React.createElement(Button, { type: "primary", onClick: this.handleUpload, disabled: !(['fileSelected', 'stop'].includes(importStatus)), loading: importStatus == 'importing' }, importStatus == 'importing' ? '正在导入' : importStatus == 'stop' ? '重新导入' : '开始导入'),
|
|
219
|
+
React.createElement(Button, { onClick: this.handleStopImport, disabled: importStatus != 'importing' }, '停止导入')),
|
|
220
|
+
React.createElement(List, { header: React.createElement("div", { className: "listHeader" },
|
|
221
|
+
React.createElement("h4", null, "\u5BFC\u5165\u65E5\u5FD7"),
|
|
222
|
+
React.createElement("div", { className: "checks" },
|
|
223
|
+
React.createElement(CheckboxGroup, { value: showLogLevelList, onChange: this.onChangeShowLogLevelList },
|
|
224
|
+
React.createElement(Checkbox, { value: "INFO", className: "infoColor" }, "\u5E38\u89C4"),
|
|
225
|
+
React.createElement(Checkbox, { value: "SUC", className: "sucColor" }, "\u6210\u529F"),
|
|
226
|
+
React.createElement(Checkbox, { value: "ERROR", className: "errorColor" }, "\u9519\u8BEF"),
|
|
227
|
+
React.createElement(Checkbox, { value: "WARN", className: "warnColor" }, "\u8B66\u544A")),
|
|
228
|
+
React.createElement("div", { className: "btns" },
|
|
229
|
+
React.createElement(Popover, { content: content, title: "\u65E5\u5FD7\u8BBE\u7F6E", trigger: "click", placement: "top", visible: logSetterVisible, overlayStyle: { width: 350 }, onVisibleChange: this.changeLogSetterVisible },
|
|
230
|
+
React.createElement(Button, { title: "\u65E5\u5FD7\u8BBE\u7F6E", type: "primary", size: "small" },
|
|
231
|
+
React.createElement(SettingOutlined, null)))))), footer: React.createElement("div", null, importStatus), bordered: true, dataSource: showLogs, renderItem: item => (React.createElement(List.Item, null, item)), className: "importList" }))))));
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
//# sourceMappingURL=excel-import.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"excel-import.js","sourceRoot":"","sources":["../../../src/components/import/excel-import.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAC,IAAI,EAAC,MAAM,EAAC,MAAM,EAAC,OAAO,EAAC,QAAQ,EAAC,IAAI,EAAC,QAAQ,EAAC,GAAG,EAAC,GAAG,EAAO,OAAO,EAAC,WAAW,EAAE,MAAM,MAAM,CAAA;AACzG,OAAO,EAAc,cAAc,EAAmB,cAAc,EAAc,eAAe,EAAC,MAAM,mBAAmB,CAAC;AAC5H,OAAO,KAAK,MAAM,oBAAoB,CAAA;AACtC,OAAO,KAAK,MAAM,UAAU,CAAA;AAC5B,OAAO,aAAa,CAAA;AAGpB,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAElD,MAAM,aAAa,GAAG,QAAQ,CAAC,KAAK,CAAC;AACrC,MAAM,YAAY,GAAc,CAAC,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;AACjE,IAAI,QAAQ,GAAC,EAAE,CAAA;AAMd,CAAC;AAcD,CAAC;AAEF,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,KAAK,CAAC,aAAgD;IAA/F;;QAEI,UAAK,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AAc;wCACxD,oBAAC,QAAQ,IAAC,KAAK,EAAC,OAAO,EAAE,SAAS,EAAC,YAAY,mBAAc;wCAC7D,oBAAC,QAAQ,IAAC,KAAK,EAAC,MAAM,EAAE,SAAS,EAAC,WAAW,mBAAc,CAC/C;oCAChB,6BAAK,SAAS,EAAC,MAAM;wCACjB,oBAAC,OAAO,IACJ,OAAO,EAAE,OAAO,EAChB,KAAK,EAAC,0BAAM,EACZ,OAAO,EAAC,OAAO,EACf,SAAS,EAAC,KAAK,EACf,OAAO,EAAE,gBAAgB,EACzB,YAAY,EAAE,EAAC,KAAK,EAAC,GAAG,EAAC,EACzB,eAAe,EAAE,IAAI,CAAC,sBAAsB;4CAE5C,oBAAC,MAAM,IAAC,KAAK,EAAC,0BAAM,EAAC,IAAI,EAAC,SAAS,EAAC,IAAI,EAAC,OAAO;gDAC5C,oBAAC,eAAe,OAAG,CACd,CACH,CACR,CACJ,CACJ,EAEV,MAAM,EAAE,iCAAM,YAAY,CAAO,EACjC,QAAQ,QACR,UAAU,EAAE,QAAQ,EACpB,UAAU,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC,oBAAC,IAAI,CAAC,IAAI,QAAE,IAAI,CAAa,CAAC,EACnD,SAAS,EAAC,YAAY,GACpB,CACH,CACL,CACJ,CACJ,CACT,CAAA;IACL,CAAC;CACJ"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
.importBtns button{
|
|
2
|
+
margin:15px 0 10px 0
|
|
3
|
+
}
|
|
4
|
+
.importList .ant-spin-container{
|
|
5
|
+
height:300px;
|
|
6
|
+
overflow: auto
|
|
7
|
+
}
|
|
8
|
+
.ant-list-item-content p{
|
|
9
|
+
margin-bottom: 0;
|
|
10
|
+
}
|
|
11
|
+
.listHeader h4{
|
|
12
|
+
display: inline;
|
|
13
|
+
}
|
|
14
|
+
.listHeader .checks{
|
|
15
|
+
float:right;
|
|
16
|
+
position: relative;
|
|
17
|
+
padding-right: 62px
|
|
18
|
+
}
|
|
19
|
+
.listHeader .btns{
|
|
20
|
+
position: absolute;
|
|
21
|
+
right:-22px;
|
|
22
|
+
top:0;
|
|
23
|
+
}
|
|
24
|
+
.infoColor{
|
|
25
|
+
color:black;
|
|
26
|
+
}
|
|
27
|
+
.infoColor .ant-checkbox-checked .ant-checkbox-inner{
|
|
28
|
+
background-color:black;
|
|
29
|
+
border-color: black;
|
|
30
|
+
}
|
|
31
|
+
.sucColor{
|
|
32
|
+
color:green;
|
|
33
|
+
}
|
|
34
|
+
.sucColor .ant-checkbox-checked .ant-checkbox-inner{
|
|
35
|
+
background-color:green;
|
|
36
|
+
border-color: green;
|
|
37
|
+
}
|
|
38
|
+
.errorColor{
|
|
39
|
+
color:red;
|
|
40
|
+
}
|
|
41
|
+
.errorColor .ant-checkbox-checked .ant-checkbox-inner{
|
|
42
|
+
background-color:red;
|
|
43
|
+
border-color: red;
|
|
44
|
+
}
|
|
45
|
+
.warnColor{
|
|
46
|
+
color:rgb(250, 225, 4);
|
|
47
|
+
}
|
|
48
|
+
.warnColor .ant-checkbox-checked .ant-checkbox-inner{
|
|
49
|
+
background-color:rgb(250, 225, 4);
|
|
50
|
+
border-color: rgb(250, 225, 4);
|
|
51
|
+
}
|
|
52
|
+
.importData h3{
|
|
53
|
+
font-size: 18px
|
|
54
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
.modelList {
|
|
2
|
+
margin-bottom:15px;
|
|
3
|
+
cursor: pointer;
|
|
4
|
+
width:200px;
|
|
5
|
+
}
|
|
6
|
+
.modelList:hover{
|
|
7
|
+
color:#1890ff
|
|
8
|
+
}
|
|
9
|
+
.modelList p{
|
|
10
|
+
margin-bottom: 4px;
|
|
11
|
+
line-height: 1.3;
|
|
12
|
+
}
|
|
13
|
+
.modelList p.tit{
|
|
14
|
+
font-weight: bold;
|
|
15
|
+
font-size: 15px
|
|
16
|
+
}
|
|
17
|
+
.modelList span{
|
|
18
|
+
display: inline-block;
|
|
19
|
+
width:40px;
|
|
20
|
+
height:40px;
|
|
21
|
+
border-radius: 50%;
|
|
22
|
+
line-height:45px;
|
|
23
|
+
text-align: center;
|
|
24
|
+
float: left;
|
|
25
|
+
margin-right:10px;
|
|
26
|
+
align-self: center;
|
|
27
|
+
background:#1890ff;
|
|
28
|
+
}
|
|
29
|
+
.modelList span.light{
|
|
30
|
+
background:red;
|
|
31
|
+
color:#fff;
|
|
32
|
+
}
|
|
33
|
+
.selectModal{
|
|
34
|
+
height:400px
|
|
35
|
+
}
|
|
36
|
+
.selectModal .table{
|
|
37
|
+
width:50%;
|
|
38
|
+
float: left;
|
|
39
|
+
overflow-y:auto;
|
|
40
|
+
max-height:300px;
|
|
41
|
+
}
|
|
42
|
+
.ant-collapse{
|
|
43
|
+
width:45%;
|
|
44
|
+
float: right;
|
|
45
|
+
}
|
|
46
|
+
.selectModal .ant-tag{
|
|
47
|
+
margin-bottom: 4px
|
|
48
|
+
}
|
|
49
|
+
.borderTag{
|
|
50
|
+
border:1px solid #ccc!important;
|
|
51
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { BlockMenu } from "../tmpl/interface";
|
|
3
|
+
interface MainPageProps {
|
|
4
|
+
children: any;
|
|
5
|
+
match?: any;
|
|
6
|
+
}
|
|
7
|
+
interface MainPageState {
|
|
8
|
+
collapsed: boolean;
|
|
9
|
+
currentL2MenuId: string;
|
|
10
|
+
blocks: BlockMenu[];
|
|
11
|
+
currentBlockId?: string;
|
|
12
|
+
isImporter: boolean;
|
|
13
|
+
}
|
|
14
|
+
declare class MainPage extends React.PureComponent<MainPageProps, MainPageState> {
|
|
15
|
+
scrollbarRef: React.RefObject<unknown>;
|
|
16
|
+
state: {
|
|
17
|
+
collapsed: boolean;
|
|
18
|
+
blocks: any[];
|
|
19
|
+
currentL2MenuId: any;
|
|
20
|
+
currentBlockId: any;
|
|
21
|
+
isImporter: boolean;
|
|
22
|
+
};
|
|
23
|
+
componentDidMount(): Promise<void>;
|
|
24
|
+
componentDidUpdate(prevProps: any, prevState: any): Promise<void>;
|
|
25
|
+
findBlockTitle: (blockId: string) => string;
|
|
26
|
+
findBlockIdOfL2Menu: (leMenuId: string) => string;
|
|
27
|
+
findCurrentBlock: () => BlockMenu;
|
|
28
|
+
toggle: () => void;
|
|
29
|
+
render(): JSX.Element;
|
|
30
|
+
}
|
|
31
|
+
export default MainPage;
|
|
32
|
+
//# sourceMappingURL=MainPage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MainPage.d.ts","sourceRoot":"","sources":["../../../src/components/layout/MainPage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,OAAO,EAAC,SAAS,EAAC,MAAM,mBAAmB,CAAC;AAU5C,UAAU,aAAa;IACnB,QAAQ,EAAE,GAAG,CAAC;IACd,KAAK,CAAC,EAAE,GAAG,CAAC;CACf;AAED,UAAU,aAAa;IACnB,SAAS,EAAE,OAAO,CAAC;IACnB,eAAe,EAAE,MAAM,CAAC;IACxB,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,UAAU,EAAC,OAAO,CAAC;CACtB;AAED,cAAM,QAAS,SAAQ,KAAK,CAAC,aAAa,CAAC,aAAa,EAAE,aAAa,CAAC;IACpE,YAAY,2BAAqB;IACjC,KAAK;;;;;;MAMJ;IAEK,iBAAiB;IA8BjB,kBAAkB,CAAC,SAAS,KAAA,EAAE,SAAS,KAAA;IAyC7C,cAAc,YAAa,MAAM,YAehC;IAED,mBAAmB,aAAc,MAAM,YAgBtC;IAED,gBAAgB,kBA4Bf;IAED,MAAM,aAIJ;IAEF,MAAM;CAiDT;AAED,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import React from 'react';
|
|
11
|
+
import { Layout } from 'antd';
|
|
12
|
+
import Footer from './footer';
|
|
13
|
+
import Header from './header';
|
|
14
|
+
import SideBar from './sidebar';
|
|
15
|
+
import HCDataSource from "../tmpl/hc-data-source";
|
|
16
|
+
import DocumentTitle from "react-document-title";
|
|
17
|
+
import Units from '../units';
|
|
18
|
+
import Scrollbars from 'react-custom-scrollbars';
|
|
19
|
+
const { Content, Sider } = Layout;
|
|
20
|
+
class MainPage extends React.PureComponent {
|
|
21
|
+
constructor() {
|
|
22
|
+
super(...arguments);
|
|
23
|
+
this.scrollbarRef = React.createRef();
|
|
24
|
+
this.state = {
|
|
25
|
+
collapsed: false,
|
|
26
|
+
blocks: [],
|
|
27
|
+
currentL2MenuId: undefined,
|
|
28
|
+
currentBlockId: undefined,
|
|
29
|
+
isImporter: false,
|
|
30
|
+
};
|
|
31
|
+
this.findBlockTitle = (blockId) => {
|
|
32
|
+
let blockTitle;
|
|
33
|
+
const { blocks } = this.state;
|
|
34
|
+
if (blockId) {
|
|
35
|
+
for (const block of blocks) {
|
|
36
|
+
if (block.id == blockId) {
|
|
37
|
+
blockTitle = block.title;
|
|
38
|
+
break;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
let title = blockTitle ? blockTitle + '-' : "";
|
|
43
|
+
let programName = Units.programName() ? Units.programName() : 'HYDROCARBON';
|
|
44
|
+
title = title + programName;
|
|
45
|
+
return title;
|
|
46
|
+
};
|
|
47
|
+
this.findBlockIdOfL2Menu = (leMenuId) => {
|
|
48
|
+
let blockId = undefined;
|
|
49
|
+
const { blocks } = this.state;
|
|
50
|
+
if (leMenuId) {
|
|
51
|
+
for (const block of blocks) {
|
|
52
|
+
for (const menul1 of block.l1Menus) {
|
|
53
|
+
for (const menul2 of menul1.l2Menus) {
|
|
54
|
+
if (menul2.id == leMenuId) {
|
|
55
|
+
blockId = block.id;
|
|
56
|
+
break;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
return blockId;
|
|
63
|
+
};
|
|
64
|
+
this.findCurrentBlock = () => {
|
|
65
|
+
const { blocks, currentL2MenuId, currentBlockId } = this.state;
|
|
66
|
+
let result = undefined;
|
|
67
|
+
if (currentL2MenuId) {
|
|
68
|
+
for (const block of blocks) {
|
|
69
|
+
for (const menul1 of block.l1Menus) {
|
|
70
|
+
for (const menul2 of menul1.l2Menus) {
|
|
71
|
+
if (menul2.id == currentL2MenuId) {
|
|
72
|
+
result = block;
|
|
73
|
+
break;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
if (currentBlockId && !result) {
|
|
80
|
+
for (const block of blocks) {
|
|
81
|
+
if (block.id === currentBlockId) {
|
|
82
|
+
result = block;
|
|
83
|
+
break;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
if (!result) {
|
|
88
|
+
result = blocks.at(0);
|
|
89
|
+
}
|
|
90
|
+
return result;
|
|
91
|
+
};
|
|
92
|
+
this.toggle = () => {
|
|
93
|
+
this.setState({
|
|
94
|
+
collapsed: !this.state.collapsed,
|
|
95
|
+
});
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
componentDidMount() {
|
|
99
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
100
|
+
var currentURL = new URL(window.location.href);
|
|
101
|
+
console.log('main page currentURL:', currentURL);
|
|
102
|
+
const search = window.location.href.split("?")[1];
|
|
103
|
+
var searchParams = new URLSearchParams('?' + search);
|
|
104
|
+
let blockId = searchParams.get('blockId');
|
|
105
|
+
let l2MenuId = searchParams.get('menuId');
|
|
106
|
+
//进一步找找l2MenuId
|
|
107
|
+
if (!l2MenuId) {
|
|
108
|
+
let sourcePart = currentURL.hash.match(/[\w]+\-[\d]+/);
|
|
109
|
+
if (sourcePart) {
|
|
110
|
+
let source = sourcePart[0].split('-');
|
|
111
|
+
if (source[0] === 'menu') {
|
|
112
|
+
l2MenuId = source[1];
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
let blockRes = yield HCDataSource.requestBlocks(l2MenuId ? l2MenuId : undefined, blockId ? blockId : undefined);
|
|
117
|
+
this.setState({
|
|
118
|
+
isImporter: currentURL.hash.indexOf('/importer') > 0,
|
|
119
|
+
blocks: blockRes.blocks,
|
|
120
|
+
currentL2MenuId: blockRes.l2MenuId,
|
|
121
|
+
currentBlockId: blockRes.blockId,
|
|
122
|
+
});
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
componentDidUpdate(prevProps, prevState) {
|
|
126
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
127
|
+
var currentURL = new URL(window.location.href);
|
|
128
|
+
const search = window.location.href.split("?")[1];
|
|
129
|
+
var searchParams = new URLSearchParams('?' + search);
|
|
130
|
+
let blockId = searchParams.get('blockId');
|
|
131
|
+
let l2MenuId = searchParams.get('menuId');
|
|
132
|
+
let isImporter_ = currentURL.hash.indexOf('/importer') > 0;
|
|
133
|
+
if (prevState.isImporter != isImporter_) {
|
|
134
|
+
this.setState({
|
|
135
|
+
isImporter: isImporter_,
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
//进一步找找l2MenuId
|
|
139
|
+
if (!l2MenuId) {
|
|
140
|
+
let sourcePart = currentURL.hash.match(/[\w]+\-[\d]+/);
|
|
141
|
+
if (sourcePart) {
|
|
142
|
+
let source = sourcePart[0].split('-');
|
|
143
|
+
if (source[0] === 'menu') {
|
|
144
|
+
l2MenuId = source[1];
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
const { currentL2MenuId, currentBlockId } = this.state;
|
|
149
|
+
if (l2MenuId && currentL2MenuId != l2MenuId) {
|
|
150
|
+
this.setState({
|
|
151
|
+
currentL2MenuId: l2MenuId,
|
|
152
|
+
});
|
|
153
|
+
}
|
|
154
|
+
if (!blockId) {
|
|
155
|
+
blockId = this.findBlockIdOfL2Menu(l2MenuId);
|
|
156
|
+
}
|
|
157
|
+
if (blockId && currentBlockId != blockId) {
|
|
158
|
+
this.setState({
|
|
159
|
+
currentBlockId: blockId,
|
|
160
|
+
});
|
|
161
|
+
}
|
|
162
|
+
});
|
|
163
|
+
}
|
|
164
|
+
render() {
|
|
165
|
+
var _a, _b;
|
|
166
|
+
const { match } = this.props;
|
|
167
|
+
const { collapsed, currentL2MenuId, currentBlockId, isImporter } = this.state;
|
|
168
|
+
//滚动条回到顶部
|
|
169
|
+
// document.body.scrollTop = document.documentElement.scrollTop = 0;
|
|
170
|
+
// @ts-ignore
|
|
171
|
+
// eslint-disable-next-line no-unused-expressions
|
|
172
|
+
(_b = (_a = this.scrollbarRef) === null || _a === void 0 ? void 0 : _a.current) === null || _b === void 0 ? void 0 : _b.scrollToTop();
|
|
173
|
+
return (React.createElement(Scrollbars, { ref: this.scrollbarRef, style: { height: 'calc(100vh)' }, autoHide: true, autoHideTimeout: 1000 },
|
|
174
|
+
React.createElement(DocumentTitle, { title: (isImporter ? '导入-' : "") + this.findBlockTitle(currentBlockId) },
|
|
175
|
+
React.createElement(Layout, null,
|
|
176
|
+
React.createElement(Sider, { style: {
|
|
177
|
+
overflow: 'auto',
|
|
178
|
+
height: '100vh',
|
|
179
|
+
position: 'fixed',
|
|
180
|
+
left: 0,
|
|
181
|
+
top: 0,
|
|
182
|
+
bottom: 0,
|
|
183
|
+
}, collapsed: collapsed },
|
|
184
|
+
React.createElement(SideBar, { blockMenu: this.findCurrentBlock(), currentL2MenuId: currentL2MenuId, collapsed: collapsed })),
|
|
185
|
+
React.createElement(Layout, { style: collapsed ? { background: '#fff', marginLeft: 80 } : {
|
|
186
|
+
background: '#fff',
|
|
187
|
+
marginLeft: 200
|
|
188
|
+
} },
|
|
189
|
+
React.createElement(Header, Object.assign({ toggle: this.toggle }, this.state)),
|
|
190
|
+
React.createElement(Content, { style: {
|
|
191
|
+
margin: '24px 16px 0',
|
|
192
|
+
overflow: 'initial',
|
|
193
|
+
minHeight: 'calc(100vh)',
|
|
194
|
+
minWidth: 760,
|
|
195
|
+
maxWidth: 1960,
|
|
196
|
+
paddingBottom: '8px',
|
|
197
|
+
} }, this.props.children),
|
|
198
|
+
React.createElement(Footer, null))))));
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
export default MainPage;
|
|
202
|
+
//# sourceMappingURL=MainPage.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MainPage.js","sourceRoot":"","sources":["../../../src/components/layout/MainPage.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAe,MAAM,EAAC,MAAM,MAAM,CAAA;AACzC,OAAO,MAAM,MAAM,UAAU,CAAC;AAE9B,OAAO,MAAM,MAAM,UAAU,CAAC;AAC9B,OAAO,OAAO,MAAM,WAAW,CAAC;AAChC,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAClD,OAAO,aAAa,MAAM,sBAAsB,CAAC;AACjD,OAAO,KAAK,MAAM,UAAU,CAAC;AAC7B,OAAO,UAAU,MAAM,yBAAyB,CAAC;AAEjD,MAAM,EAAC,OAAO,EAAE,KAAK,EAAC,GAAG,MAAM,CAAC;AAehC,MAAM,QAAS,SAAQ,KAAK,CAAC,aAA2C;IAAxE;;QACI,iBAAY,GAAG,KAAK,CAAC,SAAS,EAAE,CAAC;QACjC,UAAK,GAAG;YACJ,S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