@titaui/pc 1.12.14 → 1.12.17-beta.1
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/attachments-preview/index.css +11 -0
- package/lib/components/attachments-preview/index.js +112 -0
- package/lib/components/auto-save/img/failed.svg +17 -0
- package/lib/components/auto-save/img/success.svg +16 -0
- package/lib/components/auto-save/index.css +39 -0
- package/lib/components/auto-save/index.js +78 -0
- package/lib/components/auto-save/interface.js +5 -0
- package/lib/components/color-date-picker/index.css +72 -0
- package/lib/components/color-date-picker/index.js +129 -0
- package/lib/components/color-date-picker/interface.js +14 -0
- package/lib/components/communication/index.js +6 -0
- package/lib/components/dialog-confirm/index.css +1 -0
- package/lib/components/dialog-confirm/index.js +5 -3
- package/lib/components/dialog-upload/img/doc.svg +1 -0
- package/lib/components/dialog-upload/img/other.svg +1 -0
- package/lib/components/dialog-upload/img/pdf.svg +1 -0
- package/lib/components/dialog-upload/img/ppt.svg +1 -0
- package/lib/components/dialog-upload/img/radio.svg +1 -0
- package/lib/components/dialog-upload/img/video.svg +1 -0
- package/lib/components/dialog-upload/img/xls.svg +1 -0
- package/lib/components/dialog-upload/index.css +77 -0
- package/lib/components/dialog-upload/index.js +332 -0
- package/lib/components/dialog-upload/type.js +35 -0
- package/lib/components/dialog-upload/uploaded-preview.css +77 -0
- package/lib/components/dialog-upload/uploaded-preview.js +132 -0
- package/lib/components/dialog-upload/util.js +131 -0
- package/lib/components/drawer/index.css +14 -5
- package/lib/components/drawer/index.js +5 -2
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/api.js +27 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/encourage.js +119 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/APP-shoucang-m.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/ascore.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/curEfforts.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/curGood.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/curGreat.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/efforts.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/good.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/great.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/halfscore.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/loading.gif +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/score.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/img/top.svg +14 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/index.css +75 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/index.js +195 -0
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/rate.js +143 -0
- package/lib/components/dynamic/dynamic-item/components/header/img/evalute.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/header/img/fighting.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/header/img/happy.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/header/img/long-story.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/header/img/pressure.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/header/index.js +1 -5
- package/lib/components/dynamic/dynamic-item/components/okr-progress/constant.js +31 -0
- package/lib/components/dynamic/dynamic-item/components/okr-progress/index.css +171 -0
- package/lib/components/dynamic/dynamic-item/components/okr-progress/index.js +152 -0
- package/lib/components/dynamic/dynamic-item/components/okr-progress/interface.js +5 -0
- package/lib/components/dynamic/dynamic-item/components/okr-progress/request-api.js +10 -0
- package/lib/components/dynamic/dynamic-item/components/okr-progress/utils.js +10 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/kr-progress/index.css +8 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/kr-progress/index.js +26 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/o-progress/index.css +8 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/o-progress/index.js +26 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/index.css +197 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/index.js +222 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/request-api.js +20 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/util.js +134 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/task-progress/index.css +10 -0
- package/lib/components/dynamic/dynamic-item/components/progress/components/task-progress/index.js +60 -0
- package/lib/components/dynamic/dynamic-item/components/progress/index.css +25 -0
- package/lib/components/dynamic/dynamic-item/components/progress/index.js +71 -0
- package/lib/components/dynamic/dynamic-item/components/progress/interface.js +5 -0
- package/lib/components/dynamic/dynamic-item/components/schedule/index.css +35 -0
- package/lib/components/dynamic/dynamic-item/components/schedule/index.js +55 -0
- package/lib/components/dynamic/dynamic-item/components/schedule/interface.js +5 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/constant.js +45 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/img/evalute.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/img/fighting.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/img/happy.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/img/long-story.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/img/pressure.png +0 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/index.css +166 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/index.js +359 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/operate-record.js +49 -0
- package/lib/components/dynamic/dynamic-item/components/table-row-o-project/index.css +24 -0
- package/lib/components/dynamic/dynamic-item/components/table-row-o-project/index.js +52 -0
- package/lib/components/dynamic/dynamic-item/components/table-row-o-project/interface.js +5 -0
- package/lib/components/dynamic/dynamic-item/components/table-row-okr/index.css +50 -0
- package/lib/components/dynamic/dynamic-item/components/table-row-okr/index.js +65 -0
- package/lib/components/dynamic/dynamic-item/components/table-row-okr/interface.js +5 -0
- package/lib/components/dynamic/dynamic-item/components/task-progress/constant.js +16 -0
- package/lib/components/dynamic/dynamic-item/components/task-progress/index.css +201 -0
- package/lib/components/dynamic/dynamic-item/components/task-progress/index.js +170 -0
- package/lib/components/dynamic/dynamic-item/components/task-progress/interface.js +5 -0
- package/lib/components/dynamic/dynamic-item/components/task-progress/utils.js +27 -0
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +3 -2
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/come-on-big.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/come-on-small.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/evaluate-big.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/nice-big.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/nice-small.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/very-good-big.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/img/very-good-small.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/index.css +68 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/index.js +50 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/remind-user-view/index.css +43 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/remind-user-view/index.js +87 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/constant.js +45 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/img/evalute.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/img/fighting.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/img/happy.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/img/long-story.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/img/pressure.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/index.css +184 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/index.js +267 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/util.js +30 -0
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +3 -2
- package/lib/components/dynamic/dynamic-item/index.css +1 -0
- package/lib/components/dynamic/dynamic-item/index.js +27 -6
- package/lib/components/dynamic/dynamic-list/index.js +22 -5
- package/lib/components/form/form-fields/date/index.js +8 -7
- package/lib/components/help-card/image/liaojie1.svg +50 -0
- package/lib/components/help-card/index.css +4 -4
- package/lib/components/import-modal/helper.js +225 -0
- package/lib/components/import-modal/image/loading.gif +0 -0
- package/lib/components/import-modal/import-okr-modal/index.css +18 -0
- package/lib/components/import-modal/import-okr-modal/index.js +137 -0
- package/lib/components/import-modal/import-task-modal/index.css +18 -0
- package/lib/components/import-modal/import-task-modal/index.js +243 -0
- package/lib/components/import-modal/import-task-modal/search-form.js +141 -0
- package/lib/components/import-modal/index.css +30 -0
- package/lib/components/import-modal/index.js +20 -0
- package/lib/components/import-modal/radio.js +62 -0
- package/lib/components/import-modal/request-api.js +204 -0
- package/lib/components/import-modal/search/category-select.js +74 -0
- package/lib/components/import-modal/search/okr-classify-select.js +74 -0
- package/lib/components/import-modal/search/okr-status-select.js +74 -0
- package/lib/components/import-modal/search/okr-type-select.js +87 -0
- package/lib/components/import-modal/search/principal.js +135 -0
- package/lib/components/import-modal/search/relation.js +80 -0
- package/lib/components/import-modal/search/search-dropdown/index.css +50 -0
- package/lib/components/import-modal/search/search-dropdown/index.js +32 -0
- package/lib/components/import-modal/search/task-relation.js +80 -0
- package/lib/components/import-modal/search/task-status-select.js +87 -0
- package/lib/components/import-modal/search/work-relation.js +83 -0
- package/lib/components/import-modal/search/work-status-select.js +74 -0
- package/lib/components/import-modal/tree/okr-tree/index.css +61 -0
- package/lib/components/import-modal/tree/okr-tree/index.js +269 -0
- package/lib/components/import-modal/tree/okr-tree/search-form.js +169 -0
- package/lib/components/import-modal/tree/task-work-tree/index.css +124 -0
- package/lib/components/import-modal/tree/task-work-tree/index.js +190 -0
- package/lib/components/import-modal/tree-node/index.css +0 -0
- package/lib/components/import-modal/tree-node/index.js +51 -0
- package/lib/components/import-modal/tree-node/kr-node/index.css +65 -0
- package/lib/components/import-modal/tree-node/kr-node/index.js +112 -0
- package/lib/components/import-modal/tree-node/milestone-node/index.css +61 -0
- package/lib/components/import-modal/tree-node/milestone-node/index.js +118 -0
- package/lib/components/import-modal/tree-node/o-node/index.css +53 -0
- package/lib/components/import-modal/tree-node/o-node/index.js +142 -0
- package/lib/components/import-modal/tree-node/work-node/index.css +51 -0
- package/lib/components/import-modal/tree-node/work-node/index.js +108 -0
- package/lib/components/menus/components/menu-tree/images/summary-menu/caidan-enjoy.svg +14 -0
- package/lib/components/menus/components/menu-tree/images/summary-menu/my-setup.svg +18 -0
- package/lib/components/menus/components/menu-tree/images/summary-menu/my-zongjie.svg +15 -0
- package/lib/components/menus/components/menu-tree/images/summary-menu/zongjie-s.svg +15 -0
- package/lib/components/menus/components/menu-tree/tree-node/index.css +120 -0
- package/lib/components/menus/components/menu-tree/tree-node/index.js +22 -2
- package/lib/components/menus/components/menu-tree/tree-node/subordinates.js +78 -0
- package/lib/components/menus/components/menu-tree/tree-node/summary-share.js +78 -0
- package/lib/components/menus/export-modules/appraisal-menus/index.js +32 -14
- package/lib/components/menus/export-modules/appraisal-menus/menu-highlight.js +22 -6
- package/lib/components/menus/export-modules/appraisal-menus/menus.js +148 -47
- package/lib/components/menus/export-modules/interview-menus/constant.js +12 -12
- package/lib/components/menus/export-modules/okr-menus/index.js +6 -6
- package/lib/components/menus/export-modules/okr-menus/menus.js +64 -61
- package/lib/components/menus/export-modules/okr-menus/okr-front-menus.js +2 -2
- package/lib/components/menus/export-modules/summary-menus/depart-menus/helper.js +56 -0
- package/lib/components/menus/export-modules/summary-menus/depart-menus/index.css +32 -0
- package/lib/components/menus/export-modules/summary-menus/depart-menus/index.js +231 -0
- package/lib/components/menus/export-modules/summary-menus/index.css +9 -0
- package/lib/components/menus/export-modules/summary-menus/index.js +136 -0
- package/lib/components/menus/export-modules/summary-menus/menu-highlight.js +76 -0
- package/lib/components/menus/export-modules/summary-menus/menus.js +189 -0
- package/lib/components/menus/export-modules/summary-menus/request-api.js +17 -0
- package/lib/components/menus/export-modules/summary-menus/subordinate-menus/helper.js +28 -0
- package/lib/components/menus/export-modules/summary-menus/subordinate-menus/index.css +14 -0
- package/lib/components/menus/export-modules/summary-menus/subordinate-menus/index.js +201 -0
- package/lib/components/menus/export-modules/summary-menus/summary-front-menus.js +242 -0
- package/lib/components/menus/i18n.js +8 -0
- package/lib/components/menus/index.js +6 -0
- package/lib/components/menus/request-apis.js +8 -2
- package/lib/components/nav-top/components/app-center/images/chart.svg +22 -0
- package/lib/components/nav-top/components/app-center/images/file.svg +20 -0
- package/lib/components/nav-top/components/app-center/images/interview.svg +20 -0
- package/lib/components/nav-top/components/app-center/images/learning.svg +23 -0
- package/lib/components/nav-top/components/app-center/images/okr.svg +22 -0
- package/lib/components/nav-top/components/app-center/images/performance.svg +22 -0
- package/lib/components/nav-top/components/app-center/images/plan.svg +22 -0
- package/lib/components/nav-top/components/app-center/images/project.svg +23 -0
- package/lib/components/nav-top/components/app-center/images/summary.svg +23 -0
- package/lib/components/nav-top/components/app-center/images/yuyue.png +0 -0
- package/lib/components/nav-top/components/app-center/index.css +170 -0
- package/lib/components/nav-top/components/app-center/index.js +211 -0
- package/lib/components/nav-top/components/app-center/interface.js +19 -0
- package/lib/components/nav-top/components/menu/index.js +13 -13
- package/lib/components/nav-top/components/user-message/images/bell-1.svg +13 -0
- package/lib/components/nav-top/components/user-message/index.js +2 -2
- package/lib/components/nav-top/images/app-center.png +0 -0
- package/lib/components/nav-top/images/home.svg +16 -0
- package/lib/components/nav-top/index.css +61 -8
- package/lib/components/nav-top/index.js +74 -53
- package/lib/components/nav-top/utils.js +464 -1
- package/lib/components/new-confidence/constant.js +53 -0
- package/lib/components/new-confidence/img/1.svg +40 -0
- package/lib/components/new-confidence/img/10.svg +33 -0
- package/lib/components/new-confidence/img/2.svg +40 -0
- package/lib/components/new-confidence/img/3.svg +40 -0
- package/lib/components/new-confidence/img/4.svg +40 -0
- package/lib/components/new-confidence/img/5.svg +40 -0
- package/lib/components/new-confidence/img/6.svg +40 -0
- package/lib/components/new-confidence/img/7.svg +40 -0
- package/lib/components/new-confidence/img/8.svg +40 -0
- package/lib/components/new-confidence/img/9.svg +40 -0
- package/lib/components/new-confidence/index.css +62 -0
- package/lib/components/new-confidence/index.js +115 -0
- package/lib/components/new-confidence/interface.js +5 -0
- package/lib/components/okr-detail/components/header/o-avatar.js +12 -6
- package/lib/components/okr-flow/export-modal/color.png +0 -0
- package/lib/components/okr-flow/export-modal/index.css +28 -13
- package/lib/components/okr-flow/export-modal/index.js +82 -34
- package/lib/components/okr-flow/export-modal/trans1.png +0 -0
- package/lib/components/order-have-award/img/award.png +0 -0
- package/lib/components/order-have-award/index.css +5 -0
- package/lib/components/order-have-award/index.js +83 -0
- package/lib/components/order-have-award/interface.js +19 -0
- package/lib/components/period-selector/components/button/style.js +6 -6
- package/lib/components/period-selector/index.css +1 -0
- package/lib/components/period-selector/index.js +7 -2
- package/lib/components/picker/components/cross.svg +17 -0
- package/lib/components/picker/components/panels/date-panel/date-body.js +31 -19
- package/lib/components/picker/components/panels/date-panel/date-head.js +8 -8
- package/lib/components/picker/components/panels/date-panel/index.js +1 -1
- package/lib/components/picker/components/panels/month-panel/index.css +5 -0
- package/lib/components/picker/components/panels/month-panel/index.js +34 -4
- package/lib/components/picker/components/panels/month-panel/month-body.js +4 -5
- package/lib/components/picker/components/panels/month-panel/month-head.js +1 -1
- package/lib/components/picker/components/panels/week-panel/index.css +42 -0
- package/lib/components/picker/components/panels/week-panel/index.js +49 -0
- package/lib/components/picker/components/panels/week-panel/utils.js +124 -0
- package/lib/components/picker/components/panels/week-panel/week-body.js +71 -0
- package/lib/components/picker/components/panels/week-panel/week-head.js +80 -0
- package/lib/components/picker/components/panels/year-panel/index.css +5 -0
- package/lib/components/picker/components/panels/year-panel/index.js +34 -3
- package/lib/components/picker/components/panels/year-panel/year-body.js +10 -3
- package/lib/components/picker/components/picker-trigger/index.css +6 -1
- package/lib/components/picker/components/picker-trigger/index.js +16 -11
- package/lib/components/picker/context.js +17 -2
- package/lib/components/picker/index.css +29 -1
- package/lib/components/picker/index.js +3 -0
- package/lib/components/picker/picker-panels.js +98 -61
- package/lib/components/picker/picker.js +44 -30
- package/lib/components/picker/range-picker/components/picker-trigger/index.css +97 -0
- package/lib/components/picker/range-picker/components/picker-trigger/index.js +109 -0
- package/lib/components/picker/range-picker/components/placeholder/index.js +91 -0
- package/lib/components/picker/range-picker/components/select-input/index.js +72 -0
- package/lib/components/picker/range-picker/components/shortcuts/index.js +45 -0
- package/lib/components/picker/range-picker/index.css +158 -0
- package/lib/components/picker/range-picker/index.js +263 -0
- package/lib/components/picker/utils.js +168 -11
- package/lib/components/promise-confirm/index.css +0 -0
- package/lib/components/promise-confirm/index.js +117 -0
- package/lib/components/promise-confirm/interface.js +5 -0
- package/lib/components/rate/index.css +111 -0
- package/lib/components/rate/index.js +52 -0
- package/lib/components/regulation-setting-item/index.css +33 -0
- package/lib/components/regulation-setting-item/index.js +37 -0
- package/lib/components/rich-editor/schemas/list.js +0 -1
- package/lib/components/rich-editor-at/components/index.css +66 -0
- package/lib/components/rich-editor-at/components/index.js +189 -0
- package/lib/components/rich-editor-at/index.css +40 -0
- package/lib/components/rich-editor-at/index.js +113 -0
- package/lib/components/rich-editor-upload/index.css +11 -0
- package/lib/components/rich-editor-upload/index.js +87 -0
- package/lib/components/search-input/index.js +5 -0
- package/lib/components/select-layer/index.js +22 -8
- package/lib/components/select-tags/index.js +7 -1
- package/lib/components/task-relation-modal/helper.js +7 -62
- package/lib/components/task-relation-modal/okr-relation/relation-task-model/search-form.js +1 -4
- package/lib/components/task-relation-modal/okr-relation/request-api.js +2 -6
- package/lib/components/task-relation-modal/request-api.js +14 -11
- package/lib/components/task-relation-modal/tree/work-tree/index.js +27 -31
- package/lib/components/task-relation-modal/tree/work-tree/search-form.js +26 -7
- package/lib/components/task-relation-modal/tree-node/work-node/index.js +16 -16
- package/lib/components/textarea/index.js +7 -5
- package/lib/components/tooltip/tooltip.js +10 -5
- package/lib/components/user-selector/category-selector-panel/depart-tree.js +3 -1
- package/lib/components/user-selector/export-modules/field-tree-selector/index.css +11 -1
- package/lib/components/user-selector/export-modules/field-tree-selector/index.js +21 -3
- package/lib/components/user-selector/export-modules/multiple-user-selector--bak/index.css +4 -4
- package/lib/components/user-selector/request-apis.js +52 -22
- package/lib/components/user-selector/searched-panel/index.js +7 -1
- package/lib/components/write-summary-modal/index.css +79 -0
- package/lib/components/write-summary-modal/index.js +167 -0
- package/lib/components/write-summary-modal/interface.js +19 -0
- package/lib/components/write-summary-modal/request-api.js +18 -0
- package/lib/components/write-summary-modal/utils.js +31 -0
- package/lib/index.js +56 -0
- package/lib/pages/aha2021/index.css +7 -0
- package/lib/pages/aha2021/index.js +17 -11
- package/lib/pages/aha2021/new-menu-switcher/index.css +44 -0
- package/lib/pages/aha2021/new-menu-switcher/index.js +85 -0
- package/lib/pages/aha2021/new-menu-switcher/new-menu-bg.png +0 -0
- package/lib/pages/aha2021/request-api.js +15 -0
- package/lib/pages/okr-map/level2-search/user.js +1 -0
- package/lib/utils/bs-global.js +1 -1
- package/lib/utils/constant.js +14 -2
- package/lib/utils/helpers.js +56 -11
- package/lib/utils/planDataJson.js +1 -11115
- package/package.json +2 -1
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _attachmentsPreview = _interopRequireDefault(require("../attachments-preview"));
|
|
13
|
+
|
|
14
|
+
require("./index.css");
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
|
|
18
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
19
|
+
|
|
20
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
21
|
+
|
|
22
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
23
|
+
|
|
24
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
25
|
+
|
|
26
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
27
|
+
|
|
28
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
29
|
+
|
|
30
|
+
function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
31
|
+
|
|
32
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
33
|
+
|
|
34
|
+
var prefix = 'titaui-rich-editor-upload';
|
|
35
|
+
|
|
36
|
+
var RichEditorUpload = function RichEditorUpload(_ref) {
|
|
37
|
+
var _ref$files = _ref.files,
|
|
38
|
+
files = _ref$files === void 0 ? [] : _ref$files,
|
|
39
|
+
onChange = _ref.onChange,
|
|
40
|
+
_ref$editable = _ref.editable,
|
|
41
|
+
editable = _ref$editable === void 0 ? true : _ref$editable,
|
|
42
|
+
_ref$enableDelete = _ref.enableDelete,
|
|
43
|
+
enableDelete = _ref$enableDelete === void 0 ? true : _ref$enableDelete,
|
|
44
|
+
_ref$text = _ref.text,
|
|
45
|
+
text = _ref$text === void 0 ? '' : _ref$text;
|
|
46
|
+
|
|
47
|
+
var _useState = (0, _react.useState)(files),
|
|
48
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
49
|
+
attachments = _useState2[0],
|
|
50
|
+
setAttachments = _useState2[1];
|
|
51
|
+
|
|
52
|
+
var onFileChange = function onFileChange(files) {
|
|
53
|
+
setAttachments(files);
|
|
54
|
+
|
|
55
|
+
if (onChange) {
|
|
56
|
+
onChange(files);
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
var handleUploadFile = function handleUploadFile(files) {
|
|
61
|
+
setAttachments(attachments.concat(files));
|
|
62
|
+
|
|
63
|
+
if (onChange) {
|
|
64
|
+
onChange(attachments.concat(files));
|
|
65
|
+
}
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
(0, _react.useEffect)(function () {
|
|
69
|
+
setAttachments(files);
|
|
70
|
+
}, [files]);
|
|
71
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
72
|
+
className: prefix
|
|
73
|
+
}, text && /*#__PURE__*/_react["default"].createElement("div", {
|
|
74
|
+
className: "".concat(prefix, "__title")
|
|
75
|
+
}, text), /*#__PURE__*/_react["default"].createElement("div", {
|
|
76
|
+
className: "".concat(prefix, "__content")
|
|
77
|
+
}, /*#__PURE__*/_react["default"].createElement(_attachmentsPreview["default"], {
|
|
78
|
+
attachments: attachments,
|
|
79
|
+
enableDelete: enableDelete,
|
|
80
|
+
onChange: onFileChange,
|
|
81
|
+
onUploadFile: handleUploadFile,
|
|
82
|
+
enableUploadFile: editable
|
|
83
|
+
})));
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
var _default = RichEditorUpload;
|
|
87
|
+
exports["default"] = _default;
|
|
@@ -13,6 +13,8 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
13
13
|
|
|
14
14
|
var _popup = _interopRequireDefault(require("../popup"));
|
|
15
15
|
|
|
16
|
+
var _tooltip = _interopRequireDefault(require("../tooltip"));
|
|
17
|
+
|
|
16
18
|
var _getLocale = require("../../utils/getLocale");
|
|
17
19
|
|
|
18
20
|
require("./index.css");
|
|
@@ -42,7 +44,7 @@ var SelectLayer = function SelectLayer(props) {
|
|
|
42
44
|
onChangeSelect = props.onChangeSelect,
|
|
43
45
|
items = props.items,
|
|
44
46
|
_props$initText = props.initText,
|
|
45
|
-
initText = _props$initText === void 0 ? (0, _getLocale.getLocale)(
|
|
47
|
+
initText = _props$initText === void 0 ? (0, _getLocale.getLocale)('OKR_MyO_E_Temporarilynone') : _props$initText,
|
|
46
48
|
popupProps = props.popupProps,
|
|
47
49
|
renderPrefixIcon = props.renderPrefixIcon,
|
|
48
50
|
renderSuffixIcon = props.renderSuffixIcon,
|
|
@@ -82,13 +84,25 @@ var SelectLayer = function SelectLayer(props) {
|
|
|
82
84
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
83
85
|
className: "select-layout__layer-select-wrapper"
|
|
84
86
|
}, items.map(function (item, index) {
|
|
87
|
+
if (item.toolText) return /*#__PURE__*/_react["default"].createElement(_tooltip["default"], {
|
|
88
|
+
placement: "top",
|
|
89
|
+
overlay: item.toolText
|
|
90
|
+
}, /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
91
|
+
key: index,
|
|
92
|
+
onClick: function onClick(e) {
|
|
93
|
+
return handleSelectItem(item);
|
|
94
|
+
},
|
|
95
|
+
className: (0, _classnames["default"])('select-layout__layer-select-text', {
|
|
96
|
+
'select-layout__layer-select-text--active': selectItem && item.value === selectItem.value
|
|
97
|
+
})
|
|
98
|
+
}, item.label)));
|
|
85
99
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
86
100
|
key: index,
|
|
87
101
|
onClick: function onClick(e) {
|
|
88
102
|
return handleSelectItem(item);
|
|
89
103
|
},
|
|
90
|
-
className: (0, _classnames["default"])(
|
|
91
|
-
|
|
104
|
+
className: (0, _classnames["default"])('select-layout__layer-select-text', {
|
|
105
|
+
'select-layout__layer-select-text--active': selectItem && item.value === selectItem.value
|
|
92
106
|
})
|
|
93
107
|
}, item.label);
|
|
94
108
|
}));
|
|
@@ -113,9 +127,9 @@ var SelectLayer = function SelectLayer(props) {
|
|
|
113
127
|
}
|
|
114
128
|
|
|
115
129
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
116
|
-
className: (0, _classnames["default"])(
|
|
117
|
-
|
|
118
|
-
|
|
130
|
+
className: (0, _classnames["default"])('select-layout__layer-text', {
|
|
131
|
+
'select-layout__layer-text--focus': visible && canEdit,
|
|
132
|
+
'select-layout__layer-text--hidden-border': !canEdit
|
|
119
133
|
}),
|
|
120
134
|
onClick: handleClickText
|
|
121
135
|
}, renderPrefixIcon && /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -136,7 +150,7 @@ var SelectLayer = function SelectLayer(props) {
|
|
|
136
150
|
// @ts-ignore
|
|
137
151
|
_react["default"].createElement(_popup["default"], _extends({
|
|
138
152
|
popupVisible: visible,
|
|
139
|
-
action: [
|
|
153
|
+
action: ['click'],
|
|
140
154
|
destroyPopupOnHide: true,
|
|
141
155
|
popup: renderSelection,
|
|
142
156
|
mask: false,
|
|
@@ -144,7 +158,7 @@ var SelectLayer = function SelectLayer(props) {
|
|
|
144
158
|
return popupRef.current;
|
|
145
159
|
},
|
|
146
160
|
popupStyle: {
|
|
147
|
-
width:
|
|
161
|
+
width: '100%'
|
|
148
162
|
}
|
|
149
163
|
}, popupProps, {
|
|
150
164
|
onPopupVisibleChange: function onPopupVisibleChange(visible) {
|
|
@@ -19,7 +19,7 @@ var _getLocale = require("../../utils/getLocale");
|
|
|
19
19
|
|
|
20
20
|
require("./index.css");
|
|
21
21
|
|
|
22
|
-
var _excluded = ["selected", "data", "onChange", "style", "mode", "className", "placeholder", "name", "noBorder"];
|
|
22
|
+
var _excluded = ["selected", "controlValue", "data", "onChange", "style", "mode", "className", "placeholder", "name", "noBorder"];
|
|
23
23
|
|
|
24
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
25
|
|
|
@@ -52,6 +52,7 @@ var preCls = "titaui-select-tags";
|
|
|
52
52
|
var SelectTags = function SelectTags(_ref) {
|
|
53
53
|
var _ref$selected = _ref.selected,
|
|
54
54
|
selected = _ref$selected === void 0 ? [] : _ref$selected,
|
|
55
|
+
controlValue = _ref.controlValue,
|
|
55
56
|
_ref$data = _ref.data,
|
|
56
57
|
data = _ref$data === void 0 ? [] : _ref$data,
|
|
57
58
|
onChange = _ref.onChange,
|
|
@@ -78,6 +79,11 @@ var SelectTags = function SelectTags(_ref) {
|
|
|
78
79
|
setValue(value);
|
|
79
80
|
};
|
|
80
81
|
|
|
82
|
+
(0, _react.useEffect)(function () {
|
|
83
|
+
if (controlValue) {
|
|
84
|
+
setValue(selected);
|
|
85
|
+
}
|
|
86
|
+
}, [selected]);
|
|
81
87
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
82
88
|
className: preCls
|
|
83
89
|
}, /*#__PURE__*/_react["default"].createElement(_rcSelect["default"], _extends({
|
|
@@ -3,9 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.formatDateStr = void 0;
|
|
7
|
-
exports.formatPeriodPlanData = formatPeriodPlanData;
|
|
8
|
-
exports.lableTypeMap = exports.isOpenWorkManage = exports.isOpenOkrManage = exports.isOpenLabel = void 0;
|
|
6
|
+
exports.lableTypeMap = exports.isOpenWorkManage = exports.isOpenOkrManage = exports.isOpenLabel = exports.formatDateStr = void 0;
|
|
9
7
|
exports.momentDate = momentDate;
|
|
10
8
|
exports.workStatus = exports.timeFormat = exports.preCls = exports.okrStatus = void 0;
|
|
11
9
|
|
|
@@ -13,17 +11,15 @@ var _bsGlobal = require("../../utils/bs-global");
|
|
|
13
11
|
|
|
14
12
|
var _getLocale = require("../../utils/getLocale");
|
|
15
13
|
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
var preCls = "titaui-task-relation";
|
|
14
|
+
var preCls = 'titaui-task-relation';
|
|
19
15
|
exports.preCls = preCls;
|
|
20
|
-
var isOpenOkrManage = (0, _bsGlobal.getAppHead)(
|
|
16
|
+
var isOpenOkrManage = (0, _bsGlobal.getAppHead)('113'); // 开通OKR
|
|
21
17
|
|
|
22
18
|
exports.isOpenOkrManage = isOpenOkrManage;
|
|
23
|
-
var isOpenWorkManage = (0, _bsGlobal.getAppHead)(
|
|
19
|
+
var isOpenWorkManage = (0, _bsGlobal.getAppHead)('112'); // 开通项目
|
|
24
20
|
|
|
25
21
|
exports.isOpenWorkManage = isOpenWorkManage;
|
|
26
|
-
var TaskAdvancedSetting = (0, _bsGlobal.getBSGlobal)(
|
|
22
|
+
var TaskAdvancedSetting = (0, _bsGlobal.getBSGlobal)('TaskAdvancedSetting');
|
|
27
23
|
var isOpenLabel = TaskAdvancedSetting.TaskPlanSetting.TaskLabel; // 开启分类
|
|
28
24
|
|
|
29
25
|
exports.isOpenLabel = isOpenLabel;
|
|
@@ -115,8 +111,8 @@ exports.okrStatus = okrStatus;
|
|
|
115
111
|
|
|
116
112
|
var workStatus = function workStatus() {
|
|
117
113
|
return {
|
|
118
|
-
1: (0, _getLocale.getLocale)(
|
|
119
|
-
2: (0, _getLocale.getLocale)(
|
|
114
|
+
1: (0, _getLocale.getLocale)('Per_MyRe_text_Inprogress'),
|
|
115
|
+
2: (0, _getLocale.getLocale)('OKR_MyO_E_From_Completed')
|
|
120
116
|
};
|
|
121
117
|
};
|
|
122
118
|
|
|
@@ -125,55 +121,4 @@ exports.workStatus = workStatus;
|
|
|
125
121
|
function momentDate(date) {
|
|
126
122
|
var reg = new RegExp('年|月|日', 'g');
|
|
127
123
|
return date.replace(reg, '/').slice(0, -1);
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
function formatPeriodPlanData(period) {
|
|
131
|
-
var planData; // 获取选取年份的 dataJSON
|
|
132
|
-
|
|
133
|
-
var yearGroup = (0, _planDataJson.PlanDataJson)().find(function (p) {
|
|
134
|
-
return p.GroupName == period.annualNum + '';
|
|
135
|
-
}); // 年份下的 ‘年/季’ data
|
|
136
|
-
|
|
137
|
-
var seasonData = yearGroup ? yearGroup.PlanTableListModels.find(function (item) {
|
|
138
|
-
return item.TagName == (0, _getLocale.getLocale)('Tasks_Menu_Yearseason');
|
|
139
|
-
}) : null;
|
|
140
|
-
|
|
141
|
-
switch (period.cycleType) {
|
|
142
|
-
// case '-1': // 全部周期
|
|
143
|
-
// break;
|
|
144
|
-
case '0':
|
|
145
|
-
planData = {
|
|
146
|
-
StartDate: period.startDate,
|
|
147
|
-
EndDate: period.endDate
|
|
148
|
-
};
|
|
149
|
-
break;
|
|
150
|
-
|
|
151
|
-
case '1':
|
|
152
|
-
// 年度
|
|
153
|
-
planData = seasonData ? seasonData.PlanTableModels[0] : null;
|
|
154
|
-
break;
|
|
155
|
-
|
|
156
|
-
case '2':
|
|
157
|
-
planData = seasonData ? seasonData.PlanTableModels[period.yqmNum] : null; // 季度
|
|
158
|
-
|
|
159
|
-
break;
|
|
160
|
-
|
|
161
|
-
case '3':
|
|
162
|
-
// @ts-ignore
|
|
163
|
-
var monthData = yearGroup ? yearGroup.PlanTableListModels.find(function (p) {
|
|
164
|
-
return p.TagName == period.yqmNum + '月';
|
|
165
|
-
}) : null;
|
|
166
|
-
planData = monthData ? monthData.PlanTableModels[0] : null;
|
|
167
|
-
break;
|
|
168
|
-
|
|
169
|
-
default:
|
|
170
|
-
break;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
return {
|
|
174
|
-
endDate: planData ? period.cycleType == '0' ? planData.EndDate : momentDate(planData.EndDate || '') : '',
|
|
175
|
-
planTableId: planData && planData.PlanTableId,
|
|
176
|
-
planTableType: planData && planData.PlanTableType,
|
|
177
|
-
startDate: planData ? period.cycleType == '0' ? planData.StartDate : momentDate(planData.StartDate || '') : ''
|
|
178
|
-
};
|
|
179
124
|
}
|
|
@@ -21,8 +21,6 @@ var _taskStatusSelect = _interopRequireDefault(require("../../search/task-status
|
|
|
21
21
|
|
|
22
22
|
var _taskRelation = _interopRequireDefault(require("../../search/task-relation"));
|
|
23
23
|
|
|
24
|
-
var _helper = require("../../helper");
|
|
25
|
-
|
|
26
24
|
var _formatTime = require("../../../../utils/format-time");
|
|
27
25
|
|
|
28
26
|
var _getLocale = require("../../../../utils/getLocale");
|
|
@@ -85,12 +83,11 @@ function SearchForm(props) {
|
|
|
85
83
|
|
|
86
84
|
var dilagRef = (0, _react.useRef)(document.createElement('div'));
|
|
87
85
|
(0, _react.useEffect)(function () {
|
|
88
|
-
var planCycle = (0, _helper.formatPeriodPlanData)(cycle);
|
|
89
86
|
onChange(_objectSpread({
|
|
90
87
|
status: status,
|
|
91
88
|
keyWords: keyWords,
|
|
92
89
|
relation: relation
|
|
93
|
-
},
|
|
90
|
+
}, cycle));
|
|
94
91
|
}, [status, keyWords, cycle, relation]);
|
|
95
92
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
96
93
|
ref: dilagRef
|
|
@@ -32,10 +32,6 @@ var planTableTask = function planTableTask(params, pageNum, pageSize) {
|
|
|
32
32
|
keyWords = _params$keyWords === void 0 ? '' : _params$keyWords,
|
|
33
33
|
_params$status = params.status,
|
|
34
34
|
status = _params$status === void 0 ? 10 : _params$status,
|
|
35
|
-
_params$planTableId = params.planTableId,
|
|
36
|
-
planTableId = _params$planTableId === void 0 ? '' : _params$planTableId,
|
|
37
|
-
_params$planTableType = params.planTableType,
|
|
38
|
-
planTableType = _params$planTableType === void 0 ? '' : _params$planTableType,
|
|
39
35
|
_params$relation = params.relation,
|
|
40
36
|
relation = _params$relation === void 0 ? 0 : _params$relation;
|
|
41
37
|
|
|
@@ -54,8 +50,8 @@ var planTableTask = function planTableTask(params, pageNum, pageSize) {
|
|
|
54
50
|
EndDate: endDate,
|
|
55
51
|
startNum: pageNum,
|
|
56
52
|
count: pageSize,
|
|
57
|
-
planTableId: planTableId,
|
|
58
|
-
planTableType: planTableType,
|
|
53
|
+
// planTableId: planTableId,
|
|
54
|
+
// planTableType: planTableType,
|
|
59
55
|
fromLevel: 1,
|
|
60
56
|
toLevel: 1,
|
|
61
57
|
RelationType: relation,
|
|
@@ -16,7 +16,7 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
16
16
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17
17
|
|
|
18
18
|
var okrSearch = function okrSearch(params) {
|
|
19
|
-
return (0, _request.rpost)(
|
|
19
|
+
return (0, _request.rpost)('v1')('okr/search', _objectSpread(_objectSpread({}, params), {}, {
|
|
20
20
|
orderType: 1,
|
|
21
21
|
includeCreateFailApprovalOkr: false
|
|
22
22
|
})).then(function (res) {
|
|
@@ -32,9 +32,9 @@ var getCategory = function getCategory(params) {
|
|
|
32
32
|
_params$type = params.type,
|
|
33
33
|
type = _params$type === void 0 ? 0 : _params$type,
|
|
34
34
|
_params$keyWords = params.keyWords,
|
|
35
|
-
keyWords = _params$keyWords === void 0 ?
|
|
35
|
+
keyWords = _params$keyWords === void 0 ? '' : _params$keyWords;
|
|
36
36
|
var query = "pageSize=".concat(pageSize, "&pageNum=").concat(pageNum, "&type=").concat(type, "&keyWords=").concat(keyWords);
|
|
37
|
-
return (0, _request.rget)(
|
|
37
|
+
return (0, _request.rget)('v1')("lable/get?".concat(query)).then(function (res) {
|
|
38
38
|
return res.Data;
|
|
39
39
|
});
|
|
40
40
|
};
|
|
@@ -42,7 +42,7 @@ var getCategory = function getCategory(params) {
|
|
|
42
42
|
exports.getCategory = getCategory;
|
|
43
43
|
|
|
44
44
|
var getWorks = function getWorks(params) {
|
|
45
|
-
return (0, _request.rpost)(
|
|
45
|
+
return (0, _request.rpost)('v2')('Work/GetByConditions', _objectSpread(_objectSpread({}, params), {}, {
|
|
46
46
|
orderType: 1
|
|
47
47
|
})).then(function (res) {
|
|
48
48
|
return res.Data || {};
|
|
@@ -59,7 +59,7 @@ var updateLable = function updateLable(params) {
|
|
|
59
59
|
_params$mileStoneId = params.mileStoneId,
|
|
60
60
|
mileStoneId = _params$mileStoneId === void 0 ? 0 : _params$mileStoneId;
|
|
61
61
|
var url = "task/UpdateLable?task_id=".concat(task_id, "&lab_id=").concat(lab_id, "&lab_type=").concat(lab_type, "&mileStoneId=").concat(mileStoneId);
|
|
62
|
-
return (0, _request.rpost)(
|
|
62
|
+
return (0, _request.rpost)('v1')(url, _objectSpread({}, params)).then(function (res) {
|
|
63
63
|
return res;
|
|
64
64
|
});
|
|
65
65
|
}; // 关联其他
|
|
@@ -68,7 +68,7 @@ var updateLable = function updateLable(params) {
|
|
|
68
68
|
exports.updateLable = updateLable;
|
|
69
69
|
|
|
70
70
|
var relationWorks = function relationWorks(params) {
|
|
71
|
-
return (0, _request.rpost)(
|
|
71
|
+
return (0, _request.rpost)('v2')('task/relationWorkV2', _objectSpread({}, params)).then(function (res) {
|
|
72
72
|
return res;
|
|
73
73
|
});
|
|
74
74
|
};
|
|
@@ -76,7 +76,7 @@ var relationWorks = function relationWorks(params) {
|
|
|
76
76
|
exports.relationWorks = relationWorks;
|
|
77
77
|
|
|
78
78
|
var getUserById = function getUserById(userId) {
|
|
79
|
-
return (0, _request.rget)(
|
|
79
|
+
return (0, _request.rget)('v2')("user/GetById?touserid=".concat(userId)).then(function (res) {
|
|
80
80
|
return res.Data;
|
|
81
81
|
});
|
|
82
82
|
};
|
|
@@ -85,21 +85,24 @@ exports.getUserById = getUserById;
|
|
|
85
85
|
|
|
86
86
|
var workData = function workData(params, pageNum, pageSize) {
|
|
87
87
|
var _params$keyWords2 = params.keyWords,
|
|
88
|
-
keyWords = _params$keyWords2 === void 0 ?
|
|
88
|
+
keyWords = _params$keyWords2 === void 0 ? '' : _params$keyWords2,
|
|
89
89
|
_params$status = params.status,
|
|
90
90
|
status = _params$status === void 0 ? 0 : _params$status,
|
|
91
91
|
_params$relation = params.relation,
|
|
92
92
|
relation = _params$relation === void 0 ? 0 : _params$relation,
|
|
93
|
-
userIds = params.userIds
|
|
93
|
+
userIds = params.userIds,
|
|
94
|
+
_params$isGetMileston = params.isGetMilestone,
|
|
95
|
+
isGetMilestone = _params$isGetMileston === void 0 ? false : _params$isGetMileston;
|
|
94
96
|
var url = "work/list?toUserId=".concat(userIds || (0, _helpers.getLoginUserInfo)().Id);
|
|
95
|
-
return (0, _request.rpost)(
|
|
97
|
+
return (0, _request.rpost)('v1')(url, {
|
|
96
98
|
keyWords: keyWords,
|
|
97
99
|
orderType: 1,
|
|
98
100
|
pageNum: pageNum,
|
|
99
101
|
pageSize: pageSize,
|
|
100
102
|
relation: relation,
|
|
101
103
|
status: status,
|
|
102
|
-
userIds: userIds
|
|
104
|
+
userIds: userIds,
|
|
105
|
+
isGetMilestone: isGetMilestone
|
|
103
106
|
}).then(function (res) {
|
|
104
107
|
return res;
|
|
105
108
|
});
|
|
@@ -57,7 +57,7 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
57
57
|
|
|
58
58
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
59
59
|
|
|
60
|
-
var precls =
|
|
60
|
+
var precls = 'rel-work-tree';
|
|
61
61
|
|
|
62
62
|
function WorkTree() {
|
|
63
63
|
var _useContext = (0, _react.useContext)(_context2.Context),
|
|
@@ -105,7 +105,7 @@ function WorkTree() {
|
|
|
105
105
|
isScorll = _useState16[0],
|
|
106
106
|
setIsScorll = _useState16[1];
|
|
107
107
|
|
|
108
|
-
var contentRef = (0, _react.useRef)(document.createElement(
|
|
108
|
+
var contentRef = (0, _react.useRef)(document.createElement('div'));
|
|
109
109
|
var timer = null;
|
|
110
110
|
|
|
111
111
|
var setScorll = function setScorll(e) {
|
|
@@ -119,11 +119,11 @@ function WorkTree() {
|
|
|
119
119
|
|
|
120
120
|
(0, _react.useEffect)(function () {
|
|
121
121
|
if (contentRef.current) {
|
|
122
|
-
contentRef.current.addEventListener(
|
|
122
|
+
contentRef.current.addEventListener('scroll', setScorll, true);
|
|
123
123
|
}
|
|
124
124
|
|
|
125
125
|
return function () {
|
|
126
|
-
contentRef.current && contentRef.current.removeEventListener(
|
|
126
|
+
contentRef.current && contentRef.current.removeEventListener('scroll', setScorll, true);
|
|
127
127
|
};
|
|
128
128
|
}, [treeNodes]);
|
|
129
129
|
|
|
@@ -132,12 +132,12 @@ function WorkTree() {
|
|
|
132
132
|
var checked = !!selected.find(function (i) {
|
|
133
133
|
return i.id == "mileStoneId-".concat(item.mileStoneId);
|
|
134
134
|
});
|
|
135
|
-
item.workName = work.
|
|
135
|
+
item.workName = work.workName;
|
|
136
136
|
return {
|
|
137
137
|
key: "mileStoneId-".concat(item.mileStoneId),
|
|
138
|
-
nodeType:
|
|
138
|
+
nodeType: 'milestone',
|
|
139
139
|
data: item,
|
|
140
|
-
title:
|
|
140
|
+
title: '',
|
|
141
141
|
checked: checked,
|
|
142
142
|
index: key + 1,
|
|
143
143
|
disabled: !checked && selectedRoots.includes(item.workId)
|
|
@@ -147,47 +147,43 @@ function WorkTree() {
|
|
|
147
147
|
|
|
148
148
|
var transToTreeNode = function transToTreeNode(arr) {
|
|
149
149
|
return arr.map(function (item, _key) {
|
|
150
|
-
var _item$
|
|
151
|
-
|
|
150
|
+
var _item$workMileStones = item.workMileStones,
|
|
151
|
+
workMileStones = _item$workMileStones === void 0 ? [] : _item$workMileStones;
|
|
152
152
|
var checked = !!selected.find(function (i) {
|
|
153
|
-
return i.id == item.
|
|
153
|
+
return i.id == item.workId;
|
|
154
154
|
});
|
|
155
155
|
return {
|
|
156
|
-
key: item.
|
|
157
|
-
nodeType:
|
|
158
|
-
title:
|
|
159
|
-
children: formatKrNodes(
|
|
156
|
+
key: item.workId,
|
|
157
|
+
nodeType: 'work-node',
|
|
158
|
+
title: '',
|
|
159
|
+
children: formatKrNodes(workMileStones || [], item),
|
|
160
160
|
data: item,
|
|
161
161
|
checked: checked,
|
|
162
|
-
disabled: !checked && selectedRoots.includes(item.
|
|
162
|
+
disabled: !checked && selectedRoots.includes(item.workId)
|
|
163
163
|
};
|
|
164
164
|
});
|
|
165
165
|
};
|
|
166
166
|
|
|
167
167
|
var getTreeNodes = /*#__PURE__*/function () {
|
|
168
168
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
169
|
-
var
|
|
169
|
+
var res, _res$Data, _res$Data$works, works, _res$Data$total, total;
|
|
170
170
|
|
|
171
171
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
172
172
|
while (1) {
|
|
173
173
|
switch (_context.prev = _context.next) {
|
|
174
174
|
case 0:
|
|
175
175
|
_context.next = 2;
|
|
176
|
-
return (0, _requestApi.
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
}, query));
|
|
176
|
+
return (0, _requestApi.workData)(_objectSpread({
|
|
177
|
+
isGetMilestone: true
|
|
178
|
+
}, query), pageNum, pageSize);
|
|
180
179
|
|
|
181
180
|
case 2:
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
works = _yield$getWorks$works === void 0 ? [] : _yield$getWorks$works;
|
|
185
|
-
_yield$getWorks$total = _yield$getWorks.total;
|
|
186
|
-
total = _yield$getWorks$total === void 0 ? 0 : _yield$getWorks$total;
|
|
181
|
+
res = _context.sent;
|
|
182
|
+
_res$Data = res.Data, _res$Data$works = _res$Data.works, works = _res$Data$works === void 0 ? [] : _res$Data$works, _res$Data$total = _res$Data.total, total = _res$Data$total === void 0 ? 0 : _res$Data$total;
|
|
187
183
|
setWorks(works || []);
|
|
188
184
|
setTotal(total);
|
|
189
185
|
|
|
190
|
-
case
|
|
186
|
+
case 6:
|
|
191
187
|
case "end":
|
|
192
188
|
return _context.stop();
|
|
193
189
|
}
|
|
@@ -224,17 +220,17 @@ function WorkTree() {
|
|
|
224
220
|
onChange: onQueryChangeHandler
|
|
225
221
|
}), treeNodes.length == 0 && /*#__PURE__*/_react["default"].createElement("div", {
|
|
226
222
|
className: "".concat(precls, "__empty")
|
|
227
|
-
}, (0, _getLocale.getLocale)(
|
|
223
|
+
}, (0, _getLocale.getLocale)('Tasks_Tab_MyS_Noprojectilable')), treeNodes.length > 0 && /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
228
224
|
className: "".concat(precls, "__header")
|
|
229
225
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
230
226
|
className: "".concat(precls, "__header-obj")
|
|
231
|
-
}, (0, _getLocale.getLocale)(
|
|
227
|
+
}, (0, _getLocale.getLocale)('Pro_detail_AssociatedObject')), /*#__PURE__*/_react["default"].createElement("span", {
|
|
232
228
|
className: "".concat(precls, "__header-status")
|
|
233
|
-
}, (0, _getLocale.getLocale)(
|
|
229
|
+
}, (0, _getLocale.getLocale)('Mod_States')), /*#__PURE__*/_react["default"].createElement("span", {
|
|
234
230
|
className: "".concat(precls, "__header-principle")
|
|
235
|
-
}, (0, _getLocale.getLocale)(
|
|
231
|
+
}, (0, _getLocale.getLocale)('Mod_Owner')), /*#__PURE__*/_react["default"].createElement("span", {
|
|
236
232
|
className: "".concat(precls, "__header-time")
|
|
237
|
-
}, (0, _getLocale.getLocale)(
|
|
233
|
+
}, (0, _getLocale.getLocale)('Mod_Startendtime'))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
238
234
|
className: "".concat(precls, "__content"),
|
|
239
235
|
ref: contentRef
|
|
240
236
|
}, /*#__PURE__*/_react["default"].createElement(_tree["default"], {
|
|
@@ -17,10 +17,14 @@ var _okrStatusSelect = _interopRequireDefault(require("../../search/okr-status-s
|
|
|
17
17
|
|
|
18
18
|
var _principal = _interopRequireDefault(require("../../search/principal"));
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _helpers = require("../../../../utils/helpers");
|
|
21
|
+
|
|
22
|
+
var _workRelation = _interopRequireDefault(require("../../search/work-relation"));
|
|
21
23
|
|
|
22
24
|
require("./index.css");
|
|
23
25
|
|
|
26
|
+
var _loginUser$UserAvatar;
|
|
27
|
+
|
|
24
28
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
29
|
|
|
26
30
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -39,6 +43,16 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
39
43
|
|
|
40
44
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
41
45
|
|
|
46
|
+
var loginUser = (0, _helpers.getLoginUserInfo)();
|
|
47
|
+
var user = {
|
|
48
|
+
userId: loginUser.Id,
|
|
49
|
+
name: loginUser.Name,
|
|
50
|
+
avatar: {
|
|
51
|
+
original: loginUser === null || loginUser === void 0 ? void 0 : (_loginUser$UserAvatar = loginUser.UserAvatar) === null || _loginUser$UserAvatar === void 0 ? void 0 : _loginUser$UserAvatar.Original,
|
|
52
|
+
color: '#bc97eb'
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
|
|
42
56
|
function SearchForm(props) {
|
|
43
57
|
var onChange = props.onChange;
|
|
44
58
|
|
|
@@ -52,7 +66,7 @@ function SearchForm(props) {
|
|
|
52
66
|
users = _useState4[0],
|
|
53
67
|
setUsers = _useState4[1];
|
|
54
68
|
|
|
55
|
-
var _useState5 = (0, _react.useState)(
|
|
69
|
+
var _useState5 = (0, _react.useState)(''),
|
|
56
70
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
57
71
|
keyWords = _useState6[0],
|
|
58
72
|
setKeyWords = _useState6[1];
|
|
@@ -62,12 +76,16 @@ function SearchForm(props) {
|
|
|
62
76
|
relation = _useState8[0],
|
|
63
77
|
setRelation = _useState8[1];
|
|
64
78
|
|
|
79
|
+
var _useState9 = (0, _react.useState)([user]),
|
|
80
|
+
_useState10 = _slicedToArray(_useState9, 1),
|
|
81
|
+
initPerson = _useState10[0];
|
|
82
|
+
|
|
65
83
|
(0, _react.useEffect)(function () {
|
|
66
84
|
onChange({
|
|
67
85
|
status: okrStatus,
|
|
68
86
|
userIds: users.reduce(function (res, cur, index) {
|
|
69
|
-
return "".concat(res).concat(index == 0 ?
|
|
70
|
-
},
|
|
87
|
+
return "".concat(res).concat(index == 0 ? '' : ',').concat(cur.userId);
|
|
88
|
+
}, ''),
|
|
71
89
|
keyWords: keyWords,
|
|
72
90
|
relation: relation
|
|
73
91
|
});
|
|
@@ -80,20 +98,21 @@ function SearchForm(props) {
|
|
|
80
98
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
81
99
|
className: "rel-work-tree__search-item"
|
|
82
100
|
}, /*#__PURE__*/_react["default"].createElement(_principal["default"], {
|
|
101
|
+
multiple: false,
|
|
83
102
|
onChange: setUsers,
|
|
84
103
|
position: "bottomLeft",
|
|
85
|
-
initValue:
|
|
104
|
+
initValue: initPerson,
|
|
86
105
|
setRelation: setRelation
|
|
87
106
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
88
107
|
className: "rel-okr-tree__search-item"
|
|
89
|
-
}, /*#__PURE__*/_react["default"].createElement(
|
|
108
|
+
}, /*#__PURE__*/_react["default"].createElement(_workRelation["default"], {
|
|
90
109
|
onChange: setRelation,
|
|
91
110
|
initValue: relation
|
|
92
111
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
93
112
|
className: "rel-work-tree__search-item-keyword"
|
|
94
113
|
}, /*#__PURE__*/_react["default"].createElement(_searchInput["default"], {
|
|
95
114
|
onSearch: setKeyWords,
|
|
96
|
-
placeholder: (0, _getLocale.getLocale)(
|
|
115
|
+
placeholder: (0, _getLocale.getLocale)('Mod_Enterkeywords'),
|
|
97
116
|
style: {
|
|
98
117
|
height: 32,
|
|
99
118
|
width: 240
|