@titaui/pc 1.12.7-beta.4 → 1.12.9-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/change-okr-modal/Item.js +19 -18
- package/lib/components/change-okr-modal/styledComponents.js +9 -9
- package/lib/components/create-okr-modal/createSuccessCmp.js +47 -19
- package/lib/components/create-okr-modal/fields/index.css +14 -3
- package/lib/components/create-okr-modal/fields/o-new-name.js +31 -20
- package/lib/components/create-okr-modal/fields/okr-case.js +7 -5
- package/lib/components/create-okr-modal/fields/okr-parent.js +7 -5
- package/lib/components/create-okr-modal/index.js +215 -142
- package/lib/components/create-okr-modal/kr-items/index.css +23 -13
- package/lib/components/create-okr-modal/kr-items/krDatas.js +96 -76
- package/lib/components/create-okr-modal/kr-items/krItem.js +54 -57
- package/lib/components/create-okr-modal/style.js +5 -5
- package/lib/components/dynamic/components/title/index.js +1 -1
- package/lib/components/dynamic/dynamic-item/components/feed-operate/index.js +7 -7
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +7 -7
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +17 -17
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +3 -1
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +9 -9
- package/lib/components/dynamic/dynamic-item/dynamic-reply/index.js +3 -1
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +3 -1
- package/lib/components/dynamic/dynamic-item/index.js +4 -15
- package/lib/components/eReport/eReportLists/reportList.js +29 -30
- package/lib/components/eReport/eReportShare/style.js +1 -1
- package/lib/components/edit-kr-wight/EditKrWightModal.js +11 -9
- package/lib/components/menus/components/menu-tree/tree-node/index.css +0 -120
- package/lib/components/menus/components/menu-tree/tree-node/index.js +2 -22
- package/lib/components/menus/i18n.js +0 -8
- package/lib/components/menus/index.js +0 -6
- package/lib/components/nav-top/components/menu/index.js +4 -4
- package/lib/components/nav-top/components/user-message/components/inform/inform-item.js +1 -1
- package/lib/components/nav-top/components/user-message/components/todos/todo-item.js +3 -3
- package/lib/components/okr-detail/components/ao-nice/index.css +0 -1
- package/lib/components/okr-detail/components/header/edit-name.js +76 -39
- package/lib/components/okr-detail/components/header/index.css +122 -41
- package/lib/components/okr-detail/components/header/index.js +45 -48
- package/lib/components/{dynamic/dynamic-item/components/progress/components/okr-progress/index.js → okr-detail/components/header/o-classify.js} +84 -152
- package/lib/components/okr-detail/components/header/o-name.js +7 -5
- package/lib/components/okr-detail/components/o-progress-update/index.js +2 -2
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.js +3 -1
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/index.css +66 -4
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +174 -64
- package/lib/components/okr-detail/components/okr-tree/tree-node/o-child-node/index.js +9 -9
- package/lib/components/okr-detail/components/okr-tree/tree-node/o-parent-node/index.js +15 -13
- package/lib/components/okr-detail/components/tab-panel-content/index.css +1 -0
- package/lib/components/okr-detail/detail-header/index.js +11 -5
- package/lib/components/okr-detail/okr-list/create-kr-item/index.css +17 -0
- package/lib/components/okr-detail/okr-list/create-kr-item/index.js +75 -53
- package/lib/components/okr-detail/okr-list/index.css +9 -0
- package/lib/components/okr-detail/okr-list/index.js +25 -25
- package/lib/components/okr-detail/request-apis.js +73 -69
- package/lib/components/okr-detail/schedule/components/kr-progress/index.js +3 -1
- package/lib/components/okr-detail/schedule/components/o-progress/index.js +34 -32
- package/lib/components/okr-detail/schedule/components/sub-o-progress/index.js +3 -1
- package/lib/components/okr-flow/child-node/kr-node.js +3 -1
- package/lib/components/okr-flow/child-node/work-node.js +3 -1
- 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 +57 -14
- package/lib/components/okr-flow/export-modal/trans1.png +0 -0
- package/lib/components/okr-progress/components/kr-progress/index.js +5 -3
- package/lib/components/okr-progress/components/o-progress/index.js +3 -1
- package/lib/components/okr-progress/components/o-progress-update/index.js +2 -2
- package/lib/components/okr-progress/components/sub-o-progress/index.js +3 -1
- package/lib/components/okr-review/ReviewPop/components/ReviewBody/index.js +3 -3
- package/lib/components/okr-share/common-painter/openDataPainter.js +9 -6
- package/lib/components/okr-share/common-painter/utils.js +187 -36
- package/lib/components/okr-share/index.css +5 -4
- package/lib/components/okr-share/pink-card/card.js +3 -3
- package/lib/components/okr-share/pink-card/drawKrs.js +97 -18
- package/lib/components/okr-share/pink-card/index.js +20 -12
- package/lib/components/open-data-painter/index.js +6 -5
- package/lib/components/period-selector/components/button/style.js +1 -1
- package/lib/components/period-selector/index.css +1 -0
- package/lib/components/period-selector/index.js +7 -2
- package/lib/components/picker/components/picker-trigger/index.js +2 -47
- package/lib/components/picker/picker-panels.js +4 -45
- package/lib/components/picker/picker.js +3 -7
- package/lib/components/search-input/index.js +0 -5
- package/lib/components/search-key-handle/index.js +12 -10
- package/lib/components/select-layer/index.js +22 -8
- package/lib/components/task-relation-modal/helper.js +1 -56
- 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/okr-relation/tree/task-tree/index.css +2 -2
- package/lib/components/task-relation-modal/request-api.js +5 -2
- 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 +22 -3
- package/lib/components/task-relation-modal/tree-node/kr-node/index.js +4 -4
- package/lib/components/task-relation-modal/tree-node/o-node/index.js +8 -8
- package/lib/components/task-relation-modal/tree-node/work-node/index.js +11 -11
- package/lib/components/textarea/index.js +5 -7
- package/lib/components/tooltip/tooltip.js +9 -4
- package/lib/components/upload/components/uploadedPreview.js +17 -17
- package/lib/components/upload/index.js +23 -23
- 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 +2 -1
- package/lib/components/user-selector/export-modules/field-tree-selector/index.js +31 -17
- package/lib/components/user-selector/export-modules/multiple-user-selector--bak/index.css +1 -1
- package/lib/components/user-selector/searched-panel/index.js +4 -4
- package/lib/components/wechat-btn/index.css +5 -1
- package/lib/components-v1/userSelector/components/SingleMode.js +7 -5
- package/lib/index.js +0 -48
- package/lib/pages/home/components/data-list/table/columns/krName.js +3 -1
- package/lib/pages/home/components/data-list/table/columns/okrName.js +4 -2
- package/lib/pages/new-okr-list/header/index.js +15 -15
- package/lib/utils/bs-global.js +1 -1
- package/lib/utils/constant.js +2 -8
- package/lib/utils/helpers.js +11 -56
- package/lib/utils/hooks.js +5 -5
- package/lib/utils/open-data.js +216 -66
- package/lib/utils/tita-okr-cycle.js +3 -3
- package/package.json +2 -2
- package/lib/components/attachments-preview/index.css +0 -11
- package/lib/components/attachments-preview/index.js +0 -112
- package/lib/components/auto-save/img/failed.svg +0 -17
- package/lib/components/auto-save/img/success.svg +0 -16
- package/lib/components/auto-save/index.css +0 -39
- package/lib/components/auto-save/index.js +0 -78
- package/lib/components/auto-save/interface.js +0 -5
- package/lib/components/color-date-picker/index.css +0 -65
- package/lib/components/color-date-picker/index.js +0 -123
- package/lib/components/color-date-picker/interface.js +0 -14
- package/lib/components/dialog-upload/img/doc.svg +0 -1
- package/lib/components/dialog-upload/img/other.svg +0 -1
- package/lib/components/dialog-upload/img/pdf.svg +0 -1
- package/lib/components/dialog-upload/img/ppt.svg +0 -1
- package/lib/components/dialog-upload/img/radio.svg +0 -1
- package/lib/components/dialog-upload/img/video.svg +0 -1
- package/lib/components/dialog-upload/img/xls.svg +0 -1
- package/lib/components/dialog-upload/index.css +0 -77
- package/lib/components/dialog-upload/index.js +0 -332
- package/lib/components/dialog-upload/type.js +0 -35
- package/lib/components/dialog-upload/uploaded-preview.css +0 -77
- package/lib/components/dialog-upload/uploaded-preview.js +0 -132
- package/lib/components/dialog-upload/util.js +0 -131
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/encourage.js +0 -119
- 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 +0 -14
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/index.css +0 -68
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/index.js +0 -118
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/rate.js +0 -143
- 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/okr-progress/index.css +0 -170
- package/lib/components/dynamic/dynamic-item/components/okr-progress/index.js +0 -120
- package/lib/components/dynamic/dynamic-item/components/okr-progress/interface.js +0 -5
- package/lib/components/dynamic/dynamic-item/components/okr-progress/request-api.js +0 -10
- package/lib/components/dynamic/dynamic-item/components/okr-progress/utils.js +0 -10
- package/lib/components/dynamic/dynamic-item/components/progress/components/kr-progress/index.css +0 -8
- package/lib/components/dynamic/dynamic-item/components/progress/components/kr-progress/index.js +0 -26
- package/lib/components/dynamic/dynamic-item/components/progress/components/o-progress/index.css +0 -8
- package/lib/components/dynamic/dynamic-item/components/progress/components/o-progress/index.js +0 -26
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/index.css +0 -197
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/request-api.js +0 -20
- package/lib/components/dynamic/dynamic-item/components/progress/components/okr-progress/util.js +0 -134
- package/lib/components/dynamic/dynamic-item/components/progress/components/task-progress/index.css +0 -10
- package/lib/components/dynamic/dynamic-item/components/progress/components/task-progress/index.js +0 -60
- package/lib/components/dynamic/dynamic-item/components/progress/index.css +0 -25
- package/lib/components/dynamic/dynamic-item/components/progress/index.js +0 -71
- package/lib/components/dynamic/dynamic-item/components/progress/interface.js +0 -5
- package/lib/components/dynamic/dynamic-item/components/schedule/index.css +0 -31
- package/lib/components/dynamic/dynamic-item/components/schedule/index.js +0 -59
- package/lib/components/dynamic/dynamic-item/components/schedule/interface.js +0 -5
- 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 +0 -136
- package/lib/components/dynamic/dynamic-item/components/summary-header/index.js +0 -364
- package/lib/components/dynamic/dynamic-item/components/table-row-o-project/index.css +0 -24
- package/lib/components/dynamic/dynamic-item/components/table-row-o-project/index.js +0 -52
- package/lib/components/dynamic/dynamic-item/components/table-row-o-project/interface.js +0 -5
- package/lib/components/dynamic/dynamic-item/components/table-row-okr/index.css +0 -50
- package/lib/components/dynamic/dynamic-item/components/table-row-okr/index.js +0 -65
- package/lib/components/dynamic/dynamic-item/components/table-row-okr/interface.js +0 -5
- package/lib/components/dynamic/dynamic-item/components/task-progress/index.css +0 -201
- package/lib/components/dynamic/dynamic-item/components/task-progress/index.js +0 -95
- package/lib/components/dynamic/dynamic-item/components/task-progress/interface.js +0 -5
- package/lib/components/dynamic/dynamic-item/components/task-progress/utils.js +0 -10
- 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 +0 -32
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/evalute/index.js +0 -43
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/remind-user-view/index.css +0 -37
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/remind-user-view/index.js +0 -79
- 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 +0 -155
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/index.js +0 -155
- package/lib/components/import-modal/helper.js +0 -179
- package/lib/components/import-modal/image/loading.gif +0 -0
- package/lib/components/import-modal/import-okr-modal/index.css +0 -18
- package/lib/components/import-modal/import-okr-modal/index.js +0 -132
- package/lib/components/import-modal/import-task-modal/index.css +0 -18
- package/lib/components/import-modal/import-task-modal/index.js +0 -240
- package/lib/components/import-modal/import-task-modal/search-form.js +0 -135
- package/lib/components/import-modal/index.css +0 -30
- package/lib/components/import-modal/index.js +0 -20
- package/lib/components/import-modal/radio.js +0 -62
- package/lib/components/import-modal/request-api.js +0 -204
- package/lib/components/import-modal/search/category-select.js +0 -74
- package/lib/components/import-modal/search/okr-classify-select.js +0 -74
- package/lib/components/import-modal/search/okr-status-select.js +0 -74
- package/lib/components/import-modal/search/okr-type-select.js +0 -87
- package/lib/components/import-modal/search/principal.js +0 -135
- package/lib/components/import-modal/search/relation.js +0 -77
- package/lib/components/import-modal/search/search-dropdown/index.css +0 -50
- package/lib/components/import-modal/search/search-dropdown/index.js +0 -32
- package/lib/components/import-modal/search/task-relation.js +0 -83
- package/lib/components/import-modal/search/task-status-select.js +0 -87
- package/lib/components/import-modal/search/work-relation.js +0 -83
- package/lib/components/import-modal/search/work-status-select.js +0 -74
- package/lib/components/import-modal/tree/okr-tree/index.css +0 -61
- package/lib/components/import-modal/tree/okr-tree/index.js +0 -267
- package/lib/components/import-modal/tree/okr-tree/search-form.js +0 -161
- package/lib/components/import-modal/tree/task-work-tree/index.css +0 -123
- package/lib/components/import-modal/tree/task-work-tree/index.js +0 -187
- package/lib/components/import-modal/tree-node/index.css +0 -0
- package/lib/components/import-modal/tree-node/index.js +0 -51
- package/lib/components/import-modal/tree-node/kr-node/index.css +0 -58
- package/lib/components/import-modal/tree-node/kr-node/index.js +0 -108
- package/lib/components/import-modal/tree-node/milestone-node/index.css +0 -61
- package/lib/components/import-modal/tree-node/milestone-node/index.js +0 -118
- package/lib/components/import-modal/tree-node/o-node/index.css +0 -46
- package/lib/components/import-modal/tree-node/o-node/index.js +0 -138
- package/lib/components/import-modal/tree-node/work-node/index.css +0 -51
- package/lib/components/import-modal/tree-node/work-node/index.js +0 -108
- package/lib/components/menus/components/menu-tree/images/summary-menu/caidan-enjoy.svg +0 -14
- package/lib/components/menus/components/menu-tree/images/summary-menu/my-setup.svg +0 -18
- package/lib/components/menus/components/menu-tree/images/summary-menu/my-zongjie.svg +0 -15
- package/lib/components/menus/components/menu-tree/images/summary-menu/zongjie-s.svg +0 -15
- package/lib/components/menus/components/menu-tree/tree-node/subordinates.js +0 -74
- package/lib/components/menus/components/menu-tree/tree-node/summary-share.js +0 -74
- package/lib/components/menus/export-modules/summary-menus/depart-menus/helper.js +0 -56
- package/lib/components/menus/export-modules/summary-menus/depart-menus/index.css +0 -32
- package/lib/components/menus/export-modules/summary-menus/depart-menus/index.js +0 -201
- package/lib/components/menus/export-modules/summary-menus/index.css +0 -9
- package/lib/components/menus/export-modules/summary-menus/index.js +0 -134
- package/lib/components/menus/export-modules/summary-menus/menu-highlight.js +0 -76
- package/lib/components/menus/export-modules/summary-menus/menus.js +0 -199
- package/lib/components/menus/export-modules/summary-menus/summary-front-menus.js +0 -199
- package/lib/components/new-confidence/constant.js +0 -53
- package/lib/components/new-confidence/img/1.svg +0 -40
- package/lib/components/new-confidence/img/10.svg +0 -33
- package/lib/components/new-confidence/img/2.svg +0 -40
- package/lib/components/new-confidence/img/3.svg +0 -40
- package/lib/components/new-confidence/img/4.svg +0 -40
- package/lib/components/new-confidence/img/5.svg +0 -40
- package/lib/components/new-confidence/img/6.svg +0 -40
- package/lib/components/new-confidence/img/7.svg +0 -40
- package/lib/components/new-confidence/img/8.svg +0 -40
- package/lib/components/new-confidence/img/9.svg +0 -40
- package/lib/components/new-confidence/index.css +0 -62
- package/lib/components/new-confidence/index.js +0 -115
- package/lib/components/new-confidence/interface.js +0 -5
- package/lib/components/picker/components/panels/week-panel/index.css +0 -42
- package/lib/components/picker/components/panels/week-panel/index.js +0 -49
- package/lib/components/picker/components/panels/week-panel/utils.js +0 -45
- package/lib/components/picker/components/panels/week-panel/week-body.js +0 -79
- package/lib/components/picker/components/panels/week-panel/week-head.js +0 -80
- package/lib/components/rate/index.js +0 -50
- package/lib/components/regulation-setting-item/index.css +0 -33
- package/lib/components/regulation-setting-item/index.js +0 -37
- package/lib/components/rich-editor-at/components/index.css +0 -66
- package/lib/components/rich-editor-at/components/index.js +0 -188
- package/lib/components/rich-editor-at/index.css +0 -40
- package/lib/components/rich-editor-at/index.js +0 -108
- package/lib/components/rich-editor-upload/index.css +0 -11
- package/lib/components/rich-editor-upload/index.js +0 -84
- package/lib/utils/planDataJson.js +0 -11115
|
@@ -51,6 +51,8 @@ var defauleSelectNodes = {
|
|
|
51
51
|
|
|
52
52
|
var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
53
53
|
var multiple = props.multiple,
|
|
54
|
+
_props$disabled = props.disabled,
|
|
55
|
+
disabled = _props$disabled === void 0 ? false : _props$disabled,
|
|
54
56
|
trigger = props.trigger,
|
|
55
57
|
children = props.children,
|
|
56
58
|
_props$onOk = props.onOk,
|
|
@@ -59,15 +61,17 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
59
61
|
_props$onSelect = props.onSelect,
|
|
60
62
|
onSelect = _props$onSelect === void 0 ? function () {} : _props$onSelect,
|
|
61
63
|
_props$position = props.position,
|
|
62
|
-
position = _props$position === void 0 ?
|
|
64
|
+
position = _props$position === void 0 ? 'bottomRight' : _props$position,
|
|
63
65
|
_props$selectNodes = props.selectNodes,
|
|
64
66
|
selectNodes = _props$selectNodes === void 0 ? defauleSelectNodes : _props$selectNodes,
|
|
65
67
|
sourceFrom = props.sourceFrom,
|
|
66
68
|
departOnly = props.departOnly,
|
|
69
|
+
_props$departId = props.departId,
|
|
70
|
+
departId = _props$departId === void 0 ? "-1" : _props$departId,
|
|
67
71
|
_props$auth = props.auth,
|
|
68
72
|
auth = _props$auth === void 0 ? false : _props$auth,
|
|
69
73
|
_props$placeholder = props.placeholder,
|
|
70
|
-
placeholder = _props$placeholder === void 0 ? (0, _getLocale.getLocale)(
|
|
74
|
+
placeholder = _props$placeholder === void 0 ? (0, _getLocale.getLocale)('Mod_Pleaseselect') : _props$placeholder,
|
|
71
75
|
authType = props.authType,
|
|
72
76
|
getDepartRoot = props.getDepartRoot,
|
|
73
77
|
_props$destroyPopupOn = props.destroyPopupOnHide,
|
|
@@ -93,7 +97,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
93
97
|
_onPopupVisibleChange = props.onPopupVisibleChange,
|
|
94
98
|
popClass = props.popClass,
|
|
95
99
|
_props$searchWord = props.searchWord,
|
|
96
|
-
searchWord = _props$searchWord === void 0 ?
|
|
100
|
+
searchWord = _props$searchWord === void 0 ? '' : _props$searchWord,
|
|
97
101
|
_props$showSearchInpu = props.showSearchInput,
|
|
98
102
|
showSearchInput = _props$showSearchInpu === void 0 ? true : _props$showSearchInpu,
|
|
99
103
|
getPopupContainer = props.getPopupContainer,
|
|
@@ -112,7 +116,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
112
116
|
selected = _useState2[0],
|
|
113
117
|
setSelected = _useState2[1];
|
|
114
118
|
|
|
115
|
-
var _useState3 = (0, _react.useState)(
|
|
119
|
+
var _useState3 = (0, _react.useState)(''),
|
|
116
120
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
117
121
|
selectedText = _useState4[0],
|
|
118
122
|
setSelectedText = _useState4[1];
|
|
@@ -136,7 +140,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
136
140
|
var users = selectNodes.users;
|
|
137
141
|
(groups || []).forEach(function (data) {
|
|
138
142
|
selected.push({
|
|
139
|
-
nodeType:
|
|
143
|
+
nodeType: 'group',
|
|
140
144
|
id: data.id,
|
|
141
145
|
data: data
|
|
142
146
|
});
|
|
@@ -145,7 +149,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
145
149
|
});
|
|
146
150
|
(departments || []).forEach(function (data) {
|
|
147
151
|
selected.push({
|
|
148
|
-
nodeType:
|
|
152
|
+
nodeType: 'depart',
|
|
149
153
|
id: data.id,
|
|
150
154
|
data: data
|
|
151
155
|
});
|
|
@@ -157,7 +161,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
157
161
|
});
|
|
158
162
|
(users || []).forEach(function (data) {
|
|
159
163
|
selected.push({
|
|
160
|
-
nodeType:
|
|
164
|
+
nodeType: 'person',
|
|
161
165
|
id: "".concat(data.userId),
|
|
162
166
|
data: data
|
|
163
167
|
});
|
|
@@ -167,7 +171,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
167
171
|
name: data.name
|
|
168
172
|
}));
|
|
169
173
|
});
|
|
170
|
-
var text = texts.join(
|
|
174
|
+
var text = texts.join('、'); // if (!text) text = placeholder;
|
|
171
175
|
|
|
172
176
|
setSelectedText(text);
|
|
173
177
|
setJsxDomValues(jsxDomValues);
|
|
@@ -180,7 +184,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
180
184
|
|
|
181
185
|
(0, _react.useEffect)(function () {
|
|
182
186
|
if (getDepartRoot) {
|
|
183
|
-
(0, _requestApis.getTreeData)(
|
|
187
|
+
(0, _requestApis.getTreeData)('-1', {
|
|
184
188
|
departOnly: departOnly,
|
|
185
189
|
auth: auth,
|
|
186
190
|
isGetRoot: isGetRoot,
|
|
@@ -191,7 +195,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
191
195
|
for (var i = 0; i < departs.length; i++) {
|
|
192
196
|
var it = departs[i];
|
|
193
197
|
|
|
194
|
-
if (it.id ==
|
|
198
|
+
if (it.id == '-1') {
|
|
195
199
|
rootNode = it;
|
|
196
200
|
break;
|
|
197
201
|
}
|
|
@@ -225,7 +229,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
225
229
|
var jsxDomValues = [];
|
|
226
230
|
selectNodes.forEach(function (item) {
|
|
227
231
|
switch (item.nodeType) {
|
|
228
|
-
case
|
|
232
|
+
case 'person':
|
|
229
233
|
users.push(item.data);
|
|
230
234
|
texts.push(item.data.name);
|
|
231
235
|
jsxDomValues.push( /*#__PURE__*/_react["default"].createElement(_openData.OpenUserName, {
|
|
@@ -234,7 +238,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
234
238
|
}));
|
|
235
239
|
break;
|
|
236
240
|
|
|
237
|
-
case
|
|
241
|
+
case 'depart':
|
|
238
242
|
departments.push(item.data);
|
|
239
243
|
texts.push(item.data.name);
|
|
240
244
|
jsxDomValues.push( /*#__PURE__*/_react["default"].createElement(_openData.OpenDepartmentName, {
|
|
@@ -243,7 +247,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
243
247
|
}));
|
|
244
248
|
break;
|
|
245
249
|
|
|
246
|
-
case
|
|
250
|
+
case 'group':
|
|
247
251
|
groups.push(item.data);
|
|
248
252
|
texts.push(item.data.name);
|
|
249
253
|
jsxDomValues.push( /*#__PURE__*/_react["default"].createElement("span", null, item.data.name));
|
|
@@ -268,7 +272,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
268
272
|
onSelect(selectNodes, wechartOpts, e);
|
|
269
273
|
}
|
|
270
274
|
|
|
271
|
-
var text = texts.join(
|
|
275
|
+
var text = texts.join('、'); // if (!text) text = placeholder;
|
|
272
276
|
|
|
273
277
|
setSelectedText(text);
|
|
274
278
|
setJsxDomValues(jsxDomValues);
|
|
@@ -279,6 +283,10 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
279
283
|
onCancel && onCancel();
|
|
280
284
|
};
|
|
281
285
|
|
|
286
|
+
var onChangeVisible = function onChangeVisible() {
|
|
287
|
+
setVisible(!visible);
|
|
288
|
+
};
|
|
289
|
+
|
|
282
290
|
var popup = /*#__PURE__*/_react["default"].createElement(_selectorGenerater["default"], {
|
|
283
291
|
multiple: multiple,
|
|
284
292
|
onCancel: onCancelHandler,
|
|
@@ -288,11 +296,19 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
288
296
|
showSearchInput: showSearchInput
|
|
289
297
|
});
|
|
290
298
|
|
|
299
|
+
if (disabled) return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("span", {
|
|
300
|
+
className: "persel-selector-field"
|
|
301
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
302
|
+
className: "persel-selector-field__text"
|
|
303
|
+
}, (0, _openData.isWechat)() ? jsxDomValues : selectedText || /*#__PURE__*/_react["default"].createElement("span", {
|
|
304
|
+
className: "persel-selector-field__text-holder"
|
|
305
|
+
}, placeholder))));
|
|
291
306
|
return /*#__PURE__*/_react["default"].createElement(_context.CommonContext.Provider, {
|
|
292
307
|
value: {
|
|
293
308
|
sourceFrom: sourceFrom,
|
|
294
309
|
departOnly: departOnly,
|
|
295
310
|
auth: auth,
|
|
311
|
+
departId: departId,
|
|
296
312
|
authType: authType,
|
|
297
313
|
isGetRoot: isGetRoot,
|
|
298
314
|
disabledDepartSelect: disabledDepartSelect,
|
|
@@ -319,9 +335,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
319
335
|
}
|
|
320
336
|
}, children || trigger) : /*#__PURE__*/_react["default"].createElement("span", {
|
|
321
337
|
className: "persel-selector-field",
|
|
322
|
-
onClick:
|
|
323
|
-
return setVisible(!visible);
|
|
324
|
-
}
|
|
338
|
+
onClick: onChangeVisible
|
|
325
339
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
326
340
|
className: "persel-selector-field__text"
|
|
327
341
|
}, (0, _openData.isWechat)() ? jsxDomValues : selectedText || /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -139,21 +139,21 @@ function _default(props) {
|
|
|
139
139
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
140
140
|
className: "persel-searched"
|
|
141
141
|
}, loading && /*#__PURE__*/_react["default"].createElement(_loading["default"], null), !loading && /*#__PURE__*/_react["default"].createElement("div", null, searchedPanes.user && person && person.length ? /*#__PURE__*/_react["default"].createElement(_resultPart["default"], {
|
|
142
|
-
title: (0, _getLocale.getLocale)(
|
|
142
|
+
title: (0, _getLocale.getLocale)('Per_Ma_form_detail_Personnel'),
|
|
143
143
|
treeData: person,
|
|
144
144
|
onSelect: onNodeSelect,
|
|
145
145
|
selected: selected
|
|
146
146
|
}) : undefined, searchedPanes.depart && departs && departs.length ? /*#__PURE__*/_react["default"].createElement(_resultPart["default"], {
|
|
147
|
-
title: (0, _getLocale.getLocale)(
|
|
147
|
+
title: (0, _getLocale.getLocale)('Mod_Department'),
|
|
148
148
|
treeData: departs,
|
|
149
149
|
onSelect: onNodeSelect,
|
|
150
150
|
selected: selected
|
|
151
151
|
}) : undefined, searchedPanes.group && group && group.length ? /*#__PURE__*/_react["default"].createElement(_resultPart["default"], {
|
|
152
|
-
title: (0, _getLocale.getLocale)(
|
|
152
|
+
title: (0, _getLocale.getLocale)('Mod_Groups'),
|
|
153
153
|
treeData: group,
|
|
154
154
|
onSelect: onNodeSelect,
|
|
155
155
|
selected: selected
|
|
156
156
|
}) : undefined, itemCount == 0 && !noAuth && /*#__PURE__*/_react["default"].createElement(_empty["default"], null), itemCount == 0 && noAuth && /*#__PURE__*/_react["default"].createElement(_empty["default"], {
|
|
157
|
-
errorTip: (0, _getLocale.getLocale)(
|
|
157
|
+
errorTip: (0, _getLocale.getLocale)('Mod_Nopermissiondep')
|
|
158
158
|
})));
|
|
159
159
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
.titaui-wechat-btn {
|
|
2
|
+
margin: 0 8px;
|
|
2
3
|
font-size: 18px;
|
|
3
4
|
color: #a4acb9;
|
|
4
|
-
margin: 0 8px;
|
|
5
5
|
cursor: pointer;
|
|
6
6
|
}
|
|
7
7
|
|
|
@@ -9,6 +9,10 @@
|
|
|
9
9
|
color: #2879ff;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
+
.titaui-wechat-btn:not(:empty) {
|
|
13
|
+
margin: 0 8px;
|
|
14
|
+
}
|
|
15
|
+
|
|
12
16
|
.titaui-wechat-btn__chat {
|
|
13
17
|
color: #2879ff;
|
|
14
18
|
}
|
|
@@ -21,6 +21,8 @@ require("react-perfect-scrollbar/dist/css/styles.css");
|
|
|
21
21
|
|
|
22
22
|
var _openData = require("../../../utils/open-data");
|
|
23
23
|
|
|
24
|
+
var _getLocale = require("../../../utils/getLocale");
|
|
25
|
+
|
|
24
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
27
|
|
|
26
28
|
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); }
|
|
@@ -70,7 +72,7 @@ var SingleMode = /*#__PURE__*/function (_PureComponent) {
|
|
|
70
72
|
if (users[activeIndex]) {
|
|
71
73
|
_this.props.onSelect(users[activeIndex]);
|
|
72
74
|
|
|
73
|
-
document.removeEventListener(
|
|
75
|
+
document.removeEventListener('keydown', _this.handleKeyDown);
|
|
74
76
|
}
|
|
75
77
|
} else if (e.keyCode == 38) {
|
|
76
78
|
var index = activeIndex > 0 ? activeIndex - 1 : (users.length || 1) - 1;
|
|
@@ -109,7 +111,7 @@ var SingleMode = /*#__PURE__*/function (_PureComponent) {
|
|
|
109
111
|
};
|
|
110
112
|
|
|
111
113
|
_this.getSearchUsers = function () {
|
|
112
|
-
var url = (0, _openData.isPlatform)(
|
|
114
|
+
var url = (0, _openData.isPlatform)('wx') ? (0, _requestV.getApiUrl3)("staff/workwx/serarch?filter=".concat(_this.props.searchTxt)) : (0, _requestV.getApiUrl3)("staff/search?onlyMatchName=".concat(_this.props.onlySearchByName === true, "&filter=").concat(_this.props.searchTxt, "&pageNum=1&pageSize=999"));
|
|
113
115
|
(0, _requestV.taker)(url).then(function (res) {
|
|
114
116
|
if (res.Code == 1) {
|
|
115
117
|
var _users2 = [];
|
|
@@ -161,13 +163,13 @@ var SingleMode = /*#__PURE__*/function (_PureComponent) {
|
|
|
161
163
|
}
|
|
162
164
|
|
|
163
165
|
if (this.props.useKeyBoard !== false) {
|
|
164
|
-
document.addEventListener(
|
|
166
|
+
document.addEventListener('keydown', this.handleKeyDown);
|
|
165
167
|
}
|
|
166
168
|
}
|
|
167
169
|
}, {
|
|
168
170
|
key: "componentWillUnmount",
|
|
169
171
|
value: function componentWillUnmount() {
|
|
170
|
-
document.removeEventListener(
|
|
172
|
+
document.removeEventListener('keydown', this.handleKeyDown);
|
|
171
173
|
}
|
|
172
174
|
}, {
|
|
173
175
|
key: "componentDidUpdate",
|
|
@@ -192,7 +194,7 @@ var SingleMode = /*#__PURE__*/function (_PureComponent) {
|
|
|
192
194
|
return /*#__PURE__*/_react["default"].createElement(_style.SingleModeWrapper, null, /*#__PURE__*/_react["default"].createElement(_reactPerfectScrollbar["default"], null, !users.length && !pending ? /*#__PURE__*/_react["default"].createElement(_style.EmptyWrapper, null, /*#__PURE__*/_react["default"].createElement("img", {
|
|
193
195
|
src: require("../assets/emptyImg.png"),
|
|
194
196
|
width: "100px"
|
|
195
|
-
}), /*#__PURE__*/_react["default"].createElement(_style.ListEmptyText, null, getLocale(
|
|
197
|
+
}), /*#__PURE__*/_react["default"].createElement(_style.ListEmptyText, null, (0, _getLocale.getLocale)('Mod_ThereNothing'), "...")) : /*#__PURE__*/_react["default"].createElement(_style.SingleList, null, users.map(function (u, index) {
|
|
196
198
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
197
199
|
key: u.Id,
|
|
198
200
|
onMouseOver: function onMouseOver() {
|
package/lib/index.js
CHANGED
|
@@ -9,12 +9,6 @@ Object.defineProperty(exports, "Aha2021Page", {
|
|
|
9
9
|
return _aha["default"];
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
-
Object.defineProperty(exports, "AutoSave", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function get() {
|
|
15
|
-
return _autoSave["default"];
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
12
|
Object.defineProperty(exports, "Avatar", {
|
|
19
13
|
enumerable: true,
|
|
20
14
|
get: function get() {
|
|
@@ -51,12 +45,6 @@ Object.defineProperty(exports, "Checkbox", {
|
|
|
51
45
|
return _checkbox["default"];
|
|
52
46
|
}
|
|
53
47
|
});
|
|
54
|
-
Object.defineProperty(exports, "ColorDatePicker", {
|
|
55
|
-
enumerable: true,
|
|
56
|
-
get: function get() {
|
|
57
|
-
return _colorDatePicker["default"];
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
48
|
Object.defineProperty(exports, "Communication", {
|
|
61
49
|
enumerable: true,
|
|
62
50
|
get: function get() {
|
|
@@ -273,12 +261,6 @@ Object.defineProperty(exports, "NavTop", {
|
|
|
273
261
|
return _navTop["default"];
|
|
274
262
|
}
|
|
275
263
|
});
|
|
276
|
-
Object.defineProperty(exports, "NewConfidence", {
|
|
277
|
-
enumerable: true,
|
|
278
|
-
get: function get() {
|
|
279
|
-
return _newConfidence["default"];
|
|
280
|
-
}
|
|
281
|
-
});
|
|
282
264
|
Object.defineProperty(exports, "NewOkrListPage", {
|
|
283
265
|
enumerable: true,
|
|
284
266
|
get: function get() {
|
|
@@ -399,12 +381,6 @@ Object.defineProperty(exports, "PhotoCard", {
|
|
|
399
381
|
return _photoCard["default"];
|
|
400
382
|
}
|
|
401
383
|
});
|
|
402
|
-
Object.defineProperty(exports, "Picker", {
|
|
403
|
-
enumerable: true,
|
|
404
|
-
get: function get() {
|
|
405
|
-
return _picker["default"];
|
|
406
|
-
}
|
|
407
|
-
});
|
|
408
384
|
Object.defineProperty(exports, "PointDemo", {
|
|
409
385
|
enumerable: true,
|
|
410
386
|
get: function get() {
|
|
@@ -447,18 +423,6 @@ Object.defineProperty(exports, "RichEditor", {
|
|
|
447
423
|
return _richEditor["default"];
|
|
448
424
|
}
|
|
449
425
|
});
|
|
450
|
-
Object.defineProperty(exports, "RichEditorAt", {
|
|
451
|
-
enumerable: true,
|
|
452
|
-
get: function get() {
|
|
453
|
-
return _richEditorAt["default"];
|
|
454
|
-
}
|
|
455
|
-
});
|
|
456
|
-
Object.defineProperty(exports, "RichEditorUpload", {
|
|
457
|
-
enumerable: true,
|
|
458
|
-
get: function get() {
|
|
459
|
-
return _richEditorUpload["default"];
|
|
460
|
-
}
|
|
461
|
-
});
|
|
462
426
|
Object.defineProperty(exports, "ScrollContainer", {
|
|
463
427
|
enumerable: true,
|
|
464
428
|
get: function get() {
|
|
@@ -786,8 +750,6 @@ var _operationRecords = _interopRequireDefault(require("./components/operation-r
|
|
|
786
750
|
|
|
787
751
|
var _partNotice = _interopRequireDefault(require("./components/part-notice"));
|
|
788
752
|
|
|
789
|
-
var _picker = _interopRequireDefault(require("./components/picker"));
|
|
790
|
-
|
|
791
753
|
var _popup = _interopRequireDefault(require("./components/popup"));
|
|
792
754
|
|
|
793
755
|
var _progress = _interopRequireDefault(require("./components/progress"));
|
|
@@ -814,10 +776,6 @@ var _radio = _interopRequireDefault(require("./components/radio"));
|
|
|
814
776
|
|
|
815
777
|
var _richEditor = _interopRequireDefault(require("./components/rich-editor"));
|
|
816
778
|
|
|
817
|
-
var _richEditorUpload = _interopRequireDefault(require("./components/rich-editor-upload"));
|
|
818
|
-
|
|
819
|
-
var _richEditorAt = _interopRequireDefault(require("./components/rich-editor-at"));
|
|
820
|
-
|
|
821
779
|
var _request = _interopRequireDefault(require("./utils/request"));
|
|
822
780
|
|
|
823
781
|
var _searchDropdown = _interopRequireDefault(require("./components/search-dropdown"));
|
|
@@ -880,10 +838,4 @@ var _weeklyReport = _interopRequireDefault(require("./components/weekly-report")
|
|
|
880
838
|
|
|
881
839
|
var _wechatBtn = _interopRequireDefault(require("./components/wechat-btn"));
|
|
882
840
|
|
|
883
|
-
var _autoSave = _interopRequireDefault(require("./components/auto-save"));
|
|
884
|
-
|
|
885
|
-
var _newConfidence = _interopRequireDefault(require("./components/new-confidence"));
|
|
886
|
-
|
|
887
|
-
var _colorDatePicker = _interopRequireDefault(require("./components/color-date-picker"));
|
|
888
|
-
|
|
889
841
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -7,6 +7,8 @@ exports["default"] = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
|
|
10
|
+
var _openData = require("../../../../../../utils/open-data");
|
|
11
|
+
|
|
10
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
13
|
|
|
12
14
|
var preCls = "home-page-data-list-columns__krname";
|
|
@@ -19,7 +21,7 @@ function KrNameColumn(_ref) {
|
|
|
19
21
|
className: "".concat(preCls, "__tag")
|
|
20
22
|
}, "KR"), /*#__PURE__*/_react["default"].createElement("span", {
|
|
21
23
|
className: "".concat(preCls, "__name")
|
|
22
|
-
}, name));
|
|
24
|
+
}, (0, _openData.parseString)(name)));
|
|
23
25
|
}
|
|
24
26
|
|
|
25
27
|
var _default = KrNameColumn;
|
|
@@ -7,6 +7,8 @@ exports["default"] = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
|
|
10
|
+
var _openData = require("../../../../../../utils/open-data");
|
|
11
|
+
|
|
10
12
|
require("./index.css");
|
|
11
13
|
|
|
12
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -25,11 +27,11 @@ function OkrNameColumn(_ref) {
|
|
|
25
27
|
className: "".concat(preCls, "__tagO")
|
|
26
28
|
}, "O"), /*#__PURE__*/_react["default"].createElement("span", {
|
|
27
29
|
className: "".concat(preCls, "__contentO")
|
|
28
|
-
}, children)), type === "KR" && /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
30
|
+
}, (0, _openData.parseString)(children))), type === "KR" && /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
29
31
|
className: "".concat(preCls, "__tagKR")
|
|
30
32
|
}, "KR"), /*#__PURE__*/_react["default"].createElement("span", {
|
|
31
33
|
className: "".concat(preCls, "__contentKR")
|
|
32
|
-
}, children)));
|
|
34
|
+
}, (0, _openData.parseString)(children))));
|
|
33
35
|
}
|
|
34
36
|
|
|
35
37
|
var _default = OkrNameColumn;
|
|
@@ -124,45 +124,45 @@ function Header(props, ref) {
|
|
|
124
124
|
var rootNode = {
|
|
125
125
|
rootId: 0,
|
|
126
126
|
// @ts-ignore
|
|
127
|
-
rootName: window.BSGlobal.tenantInfo.Name ||
|
|
127
|
+
rootName: window.BSGlobal.tenantInfo.Name || ''
|
|
128
128
|
};
|
|
129
129
|
var level2Selected = {
|
|
130
130
|
id: 0,
|
|
131
131
|
// @ts-ignore
|
|
132
|
-
name: window.BSGlobal.tenantInfo.Name ||
|
|
132
|
+
name: window.BSGlobal.tenantInfo.Name || ''
|
|
133
133
|
};
|
|
134
|
-
var searchType =
|
|
134
|
+
var searchType = 'company';
|
|
135
135
|
|
|
136
136
|
if (departmentId && departmentId !== -1) {
|
|
137
137
|
rootNode.rootId = departmentId;
|
|
138
|
-
rootNode.rootName = departmentName ||
|
|
139
|
-
searchType =
|
|
138
|
+
rootNode.rootName = departmentName || '';
|
|
139
|
+
searchType = 'depart';
|
|
140
140
|
level2Selected.id = departmentId;
|
|
141
|
-
level2Selected.name = departmentName ||
|
|
141
|
+
level2Selected.name = departmentName || '';
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
if (toUserId) {
|
|
145
145
|
rootNode.rootId = toUserId;
|
|
146
|
-
rootNode.rootName = userInfo.name ||
|
|
147
|
-
searchType =
|
|
146
|
+
rootNode.rootName = userInfo.name || '';
|
|
147
|
+
searchType = 'user';
|
|
148
148
|
level2Selected.id = toUserId;
|
|
149
|
-
level2Selected.name = userInfo.name ||
|
|
149
|
+
level2Selected.name = userInfo.name || '';
|
|
150
150
|
}
|
|
151
151
|
|
|
152
152
|
if (parseInt(relation, 10) === 1) {
|
|
153
153
|
rootNode.rootId = (0, _bsGlobal.getUserInfo)().Id;
|
|
154
|
-
rootNode.rootName = (0, _bsGlobal.getUserInfo)().Name ||
|
|
155
|
-
searchType =
|
|
154
|
+
rootNode.rootName = (0, _bsGlobal.getUserInfo)().Name || '';
|
|
155
|
+
searchType = 'user';
|
|
156
156
|
level2Selected.id = (0, _bsGlobal.getUserInfo)().Id;
|
|
157
|
-
level2Selected.name = (0, _bsGlobal.getUserInfo)().Name ||
|
|
157
|
+
level2Selected.name = (0, _bsGlobal.getUserInfo)().Name || '';
|
|
158
158
|
}
|
|
159
159
|
|
|
160
160
|
var urlQuery = ["searchType=".concat(searchType), "period=".concat(JSON.stringify({
|
|
161
161
|
cycleType: cycleType,
|
|
162
162
|
annualNum: annualNum,
|
|
163
163
|
yqmNum: yqmNum
|
|
164
|
-
})), "rootNode=".concat(JSON.stringify(rootNode)), "level2Selected=".concat(JSON.stringify(level2Selected))].join(
|
|
165
|
-
var origin = window.location.href.split(
|
|
164
|
+
})), "rootNode=".concat(JSON.stringify(rootNode)), "level2Selected=".concat(JSON.stringify(level2Selected))].join('&');
|
|
165
|
+
var origin = window.location.href.split('#')[0];
|
|
166
166
|
window.location.href = "".concat(origin, "/#okr/map?").concat(urlQuery);
|
|
167
167
|
};
|
|
168
168
|
|
|
@@ -221,7 +221,7 @@ function Header(props, ref) {
|
|
|
221
221
|
className: "".concat(_precls.precls, "__header-item"),
|
|
222
222
|
onClick: gotoOkrMap
|
|
223
223
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"], {
|
|
224
|
-
overlay: (0, _getLocale.getLocale)(
|
|
224
|
+
overlay: (0, _getLocale.getLocale)('OKR_MyO_Text_Alignment'),
|
|
225
225
|
placement: "top"
|
|
226
226
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
227
227
|
className: "".concat(_precls.precls, "__header-icon")
|
package/lib/utils/bs-global.js
CHANGED
|
@@ -25,7 +25,7 @@ var getBSGlobal = function getBSGlobal(key) {
|
|
|
25
25
|
exports.getBSGlobal = getBSGlobal;
|
|
26
26
|
|
|
27
27
|
var getOkrAdvancedSetting = function getOkrAdvancedSetting() {
|
|
28
|
-
return window.BSGlobal
|
|
28
|
+
return window.BSGlobal.OkrAdvancedSetting;
|
|
29
29
|
}; // version 1 试用版
|
|
30
30
|
|
|
31
31
|
|
package/lib/utils/constant.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
6
|
+
exports.getMonth = void 0;
|
|
7
7
|
|
|
8
8
|
var _getLocale = require("./getLocale");
|
|
9
9
|
|
|
@@ -11,10 +11,4 @@ var getMonth = function getMonth() {
|
|
|
11
11
|
return [(0, _getLocale.getLocale)("Mod_Jan"), (0, _getLocale.getLocale)("Mod_Feb"), (0, _getLocale.getLocale)("Mod_Mar"), (0, _getLocale.getLocale)("Mod_Apr"), (0, _getLocale.getLocale)("Mod_May"), (0, _getLocale.getLocale)("Mod_Jun"), (0, _getLocale.getLocale)("Mod_Jul"), (0, _getLocale.getLocale)("Mod_Aug"), (0, _getLocale.getLocale)("Mod_Sept"), (0, _getLocale.getLocale)("Mod_Oct"), (0, _getLocale.getLocale)("Mod_Nov"), (0, _getLocale.getLocale)("Mod_Dec")];
|
|
12
12
|
};
|
|
13
13
|
|
|
14
|
-
exports.getMonth = getMonth;
|
|
15
|
-
|
|
16
|
-
var getWeek = function getWeek() {
|
|
17
|
-
return [(0, _getLocale.getLocale)("Mod_Sun"), (0, _getLocale.getLocale)("Mod_Mon"), (0, _getLocale.getLocale)("Mod_Tues"), (0, _getLocale.getLocale)("Mod_Wed"), (0, _getLocale.getLocale)("Mod_Thur"), (0, _getLocale.getLocale)("Mod_Fri"), (0, _getLocale.getLocale)("Mod_Sat")];
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
exports.getWeek = getWeek;
|
|
14
|
+
exports.getMonth = getMonth;
|
package/lib/utils/helpers.js
CHANGED
|
@@ -5,8 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.cssSupport = cssSupport;
|
|
7
7
|
exports.escapeHtml = escapeHtml;
|
|
8
|
-
exports.
|
|
9
|
-
exports.getPreAndNextMonthDate = exports.getLoginUserInfo = void 0;
|
|
8
|
+
exports.getLoginUserInfo = void 0;
|
|
10
9
|
exports.getTenantInfo = getTenantInfo;
|
|
11
10
|
exports.getUploadMaxSize = getUploadMaxSize;
|
|
12
11
|
exports.isTencentHr = exports.isLocal = exports.isFeishu = exports.isDingDing = void 0;
|
|
@@ -14,7 +13,7 @@ exports.isTencentHr = exports.isLocal = exports.isFeishu = exports.isDingDing =
|
|
|
14
13
|
var _bsGlobal = require("./bs-global");
|
|
15
14
|
|
|
16
15
|
function cssSupport(attr, value) {
|
|
17
|
-
var element = document.createElement(
|
|
16
|
+
var element = document.createElement("div");
|
|
18
17
|
|
|
19
18
|
if (attr in element.style) {
|
|
20
19
|
element.style[attr] = value;
|
|
@@ -25,7 +24,7 @@ function cssSupport(attr, value) {
|
|
|
25
24
|
}
|
|
26
25
|
|
|
27
26
|
function getUploadMaxSize() {
|
|
28
|
-
var info = (0, _bsGlobal.getBSGlobal)(
|
|
27
|
+
var info = (0, _bsGlobal.getBSGlobal)("tenantInfo");
|
|
29
28
|
if (info.Id === 352728) return 150;
|
|
30
29
|
var isDingDing = info.Source === 861;
|
|
31
30
|
var isDingZhi = window.dingZhiSize && window.dingZhiSize.indexOf(info.Id) !== -1;
|
|
@@ -34,15 +33,8 @@ function getUploadMaxSize() {
|
|
|
34
33
|
return 50;
|
|
35
34
|
}
|
|
36
35
|
|
|
37
|
-
function getApiUrl(url) {
|
|
38
|
-
var uid = (0, _bsGlobal.getUserInfo)().Id;
|
|
39
|
-
var tid = getTenantInfo().Id;
|
|
40
|
-
var apiServer = (0, _bsGlobal.getBSGlobal)('apiPath');
|
|
41
|
-
return apiServer + '/api/v1/' + tid + '/' + uid + '/' + url;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
36
|
function getTenantInfo() {
|
|
45
|
-
return (0, _bsGlobal.getBSGlobal)(
|
|
37
|
+
return (0, _bsGlobal.getBSGlobal)("tenantInfo");
|
|
46
38
|
}
|
|
47
39
|
|
|
48
40
|
var isDingDing = function isDingDing() {
|
|
@@ -71,11 +63,11 @@ exports.isTencentHr = isTencentHr;
|
|
|
71
63
|
|
|
72
64
|
function escapeHtml(str) {
|
|
73
65
|
var htmlEscapes = {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
66
|
+
"&": "&",
|
|
67
|
+
"<": "<",
|
|
68
|
+
">": ">",
|
|
69
|
+
""": "\"",
|
|
70
|
+
"'": "'"
|
|
79
71
|
};
|
|
80
72
|
return str.replace(/(&|<|>|"|')/g, function (s) {
|
|
81
73
|
return htmlEscapes[s];
|
|
@@ -83,44 +75,7 @@ function escapeHtml(str) {
|
|
|
83
75
|
}
|
|
84
76
|
|
|
85
77
|
var getLoginUserInfo = function getLoginUserInfo() {
|
|
86
|
-
return (0, _bsGlobal.getBSGlobal)(
|
|
87
|
-
};
|
|
88
|
-
|
|
89
|
-
exports.getLoginUserInfo = getLoginUserInfo;
|
|
90
|
-
|
|
91
|
-
var getPreAndNextMonthDate = function getPreAndNextMonthDate() {
|
|
92
|
-
var date = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : new Date();
|
|
93
|
-
var culPreDate = new Date(date);
|
|
94
|
-
var culNextDate = new Date(date);
|
|
95
|
-
var preDate = [];
|
|
96
|
-
var nextDate = []; // 获取前置天数
|
|
97
|
-
|
|
98
|
-
culPreDate.setDate(1);
|
|
99
|
-
var preRemainDays = culPreDate.getDay() === 0 ? 6 : culPreDate.getDay() - 1;
|
|
100
|
-
culPreDate.setDate(0);
|
|
101
|
-
|
|
102
|
-
while (preRemainDays > 0) {
|
|
103
|
-
// +1是因为上个月有5天到这个月,月末30号 则为 30-4, 30-3, 30-2, 30-1, 30-0五天
|
|
104
|
-
preDate.push(culPreDate.getDate() - preRemainDays + 1);
|
|
105
|
-
preRemainDays--;
|
|
106
|
-
} // 获取后置天数
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
culNextDate.setMonth(culNextDate.getMonth() + 1);
|
|
110
|
-
culNextDate.setDate(0);
|
|
111
|
-
var lastDateDay = Math.abs(culNextDate.getDay() - 7);
|
|
112
|
-
|
|
113
|
-
if (lastDateDay !== 7) {
|
|
114
|
-
while (lastDateDay >= 1) {
|
|
115
|
-
nextDate.unshift(lastDateDay);
|
|
116
|
-
lastDateDay--;
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
return {
|
|
121
|
-
preDate: preDate,
|
|
122
|
-
nextDate: nextDate
|
|
123
|
-
};
|
|
78
|
+
return (0, _bsGlobal.getBSGlobal)("loginUserInfo");
|
|
124
79
|
};
|
|
125
80
|
|
|
126
|
-
exports.
|
|
81
|
+
exports.getLoginUserInfo = getLoginUserInfo;
|