@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
|
@@ -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
|
|
|
@@ -62,6 +76,10 @@ 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,
|
|
@@ -80,13 +98,14 @@ 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", {
|
|
@@ -33,7 +33,7 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
33
33
|
|
|
34
34
|
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; }
|
|
35
35
|
|
|
36
|
-
var precls =
|
|
36
|
+
var precls = 'rel-kr-node';
|
|
37
37
|
|
|
38
38
|
function KrNode(props) {
|
|
39
39
|
var data = props.data,
|
|
@@ -49,7 +49,7 @@ function KrNode(props) {
|
|
|
49
49
|
removeSelected = _useContext.removeSelected;
|
|
50
50
|
|
|
51
51
|
var openKrDrawer = function openKrDrawer() {
|
|
52
|
-
_drawerManager["default"].open(
|
|
52
|
+
_drawerManager["default"].open('krDetail', {
|
|
53
53
|
krId: data.mileStoneId
|
|
54
54
|
}, {
|
|
55
55
|
zIndex: 1350
|
|
@@ -59,7 +59,7 @@ function KrNode(props) {
|
|
|
59
59
|
var onCheckHandler = function onCheckHandler(checked) {
|
|
60
60
|
if (checked) {
|
|
61
61
|
addSelected({
|
|
62
|
-
type:
|
|
62
|
+
type: 'kr',
|
|
63
63
|
workId: data.workId,
|
|
64
64
|
krId: data.mileStoneId,
|
|
65
65
|
id: data.feedId,
|
|
@@ -94,7 +94,7 @@ function KrNode(props) {
|
|
|
94
94
|
className: "".concat(precls, "__name-index")
|
|
95
95
|
}, "KR", krIndex), /*#__PURE__*/_react["default"].createElement("span", {
|
|
96
96
|
onClick: openKrDrawer
|
|
97
|
-
}, (0, _tools.htmlDecodeByHtmlRegExp)(data.mileStoneName))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
97
|
+
}, (0, _openData.parseString)((0, _tools.htmlDecodeByHtmlRegExp)(data.mileStoneName)))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
98
98
|
className: "".concat(precls, "__principle")
|
|
99
99
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"].Text, {
|
|
100
100
|
text: /*#__PURE__*/_react["default"].createElement(_openData.OpenUserName, {
|
|
@@ -47,7 +47,7 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
47
47
|
|
|
48
48
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
49
49
|
|
|
50
|
-
var precls =
|
|
50
|
+
var precls = 'rel-okr-node';
|
|
51
51
|
|
|
52
52
|
function ONode(props) {
|
|
53
53
|
var data = props.data,
|
|
@@ -68,14 +68,14 @@ function ONode(props) {
|
|
|
68
68
|
removeSelected = _useContext.removeSelected;
|
|
69
69
|
|
|
70
70
|
var okrTypeIcon = {
|
|
71
|
-
1:
|
|
72
|
-
2:
|
|
73
|
-
3:
|
|
74
|
-
4:
|
|
71
|
+
1: 'tu-icon-liebiao-geren',
|
|
72
|
+
2: 'tu-icon-liebiao-xiashu',
|
|
73
|
+
3: 'tu-icon-gong_si',
|
|
74
|
+
4: 'tu-icon-liebiao-tuandui'
|
|
75
75
|
};
|
|
76
76
|
|
|
77
77
|
var openOkrDrawer = function openOkrDrawer() {
|
|
78
|
-
_drawerManager["default"].open(
|
|
78
|
+
_drawerManager["default"].open('okrDetail', {
|
|
79
79
|
okrId: data.workId
|
|
80
80
|
}, {
|
|
81
81
|
zIndex: 1350
|
|
@@ -85,7 +85,7 @@ function ONode(props) {
|
|
|
85
85
|
var onCheckHandler = function onCheckHandler(checked) {
|
|
86
86
|
if (checked) {
|
|
87
87
|
addSelected({
|
|
88
|
-
type:
|
|
88
|
+
type: 'okr',
|
|
89
89
|
workId: data.workId,
|
|
90
90
|
krId: 0,
|
|
91
91
|
id: data.feedId,
|
|
@@ -119,7 +119,7 @@ function ONode(props) {
|
|
|
119
119
|
className: (0, _classnames["default"])(okrTypeIcon[data.okrType], "".concat(precls, "__okr-type-icon"))
|
|
120
120
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
121
121
|
onClick: openOkrDrawer
|
|
122
|
-
}, (0, _tools.htmlDecodeByHtmlRegExp)(data.workName))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
122
|
+
}, (0, _openData.parseString)((0, _tools.htmlDecodeByHtmlRegExp)(data.workName)))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
123
123
|
className: "".concat(precls, "__principle")
|
|
124
124
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"].Text, {
|
|
125
125
|
text: /*#__PURE__*/_react["default"].createElement(_openData.OpenUserName, {
|
|
@@ -43,7 +43,7 @@ function WorkNode(props) {
|
|
|
43
43
|
checked = _props$checked === void 0 ? false : _props$checked,
|
|
44
44
|
_props$disabled = props.disabled,
|
|
45
45
|
disabled = _props$disabled === void 0 ? false : _props$disabled;
|
|
46
|
-
var
|
|
46
|
+
var principalUser = data.principalUser;
|
|
47
47
|
|
|
48
48
|
var _useContext = (0, _react.useContext)(_context.Context),
|
|
49
49
|
multiple = _useContext.multiple,
|
|
@@ -58,13 +58,13 @@ function WorkNode(props) {
|
|
|
58
58
|
if (checked) {
|
|
59
59
|
addSelected({
|
|
60
60
|
type: "work",
|
|
61
|
-
workId: data.
|
|
61
|
+
workId: data.workId,
|
|
62
62
|
krId: 0,
|
|
63
|
-
id: data.
|
|
64
|
-
name: data.
|
|
63
|
+
id: data.workId,
|
|
64
|
+
name: data.workName
|
|
65
65
|
});
|
|
66
66
|
} else {
|
|
67
|
-
removeSelected(data.
|
|
67
|
+
removeSelected(data.workId);
|
|
68
68
|
}
|
|
69
69
|
};
|
|
70
70
|
|
|
@@ -87,7 +87,7 @@ function WorkNode(props) {
|
|
|
87
87
|
className: "".concat(precls, "__checkbox")
|
|
88
88
|
}, /*#__PURE__*/_react["default"].createElement(_radio["default"], {
|
|
89
89
|
onChange: onCheckHandler,
|
|
90
|
-
id: data.
|
|
90
|
+
id: data.workId,
|
|
91
91
|
checked: checked
|
|
92
92
|
})), /*#__PURE__*/_react["default"].createElement("span", {
|
|
93
93
|
className: "".concat(precls, "__name")
|
|
@@ -95,16 +95,16 @@ function WorkNode(props) {
|
|
|
95
95
|
className: (0, _classnames["default"])("tu-icon-project-s", "".concat(precls, "__name-icon"))
|
|
96
96
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
97
97
|
onClick: gotoWorkDetail
|
|
98
|
-
}, (0, _tools.htmlDecodeByHtmlRegExp)(data.
|
|
98
|
+
}, (0, _tools.htmlDecodeByHtmlRegExp)(data.workName))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
99
99
|
className: "".concat(precls, "__status")
|
|
100
|
-
}, statusMap[data.
|
|
100
|
+
}, statusMap[data.status]), /*#__PURE__*/_react["default"].createElement("span", {
|
|
101
101
|
className: "".concat(precls, "__principle")
|
|
102
102
|
}, /*#__PURE__*/_react["default"].createElement(_openData.OpenUserName, {
|
|
103
|
-
name:
|
|
104
|
-
id:
|
|
103
|
+
name: principalUser.name,
|
|
104
|
+
id: principalUser.userId
|
|
105
105
|
})), /*#__PURE__*/_react["default"].createElement("span", {
|
|
106
106
|
className: "".concat(precls, "__time")
|
|
107
|
-
}, (0, _helper.formatDateStr)(data.startDate), "-", (0, _helper.formatDateStr)(data.
|
|
107
|
+
}, (0, _helper.formatDateStr)(data.startDate), "-", (0, _helper.formatDateStr)(data.endDate)));
|
|
108
108
|
}
|
|
109
109
|
|
|
110
110
|
WorkNode.defaultProps = {
|
|
@@ -13,7 +13,7 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
13
13
|
|
|
14
14
|
require("./index.css");
|
|
15
15
|
|
|
16
|
-
var _excluded = ["disabled", "onFocus", "onBlur", "inputRef", "onChange", "className", "value", "placeholder", "maxLine", "
|
|
16
|
+
var _excluded = ["disabled", "onFocus", "onBlur", "inputRef", "onChange", "className", "value", "placeholder", "maxLine", "isShowApproval", "maxLength", "initValue", "onErrorChange", "validator", "onKeyDown"];
|
|
17
17
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
19
|
|
|
@@ -50,8 +50,7 @@ var Textarea = function Textarea(p) {
|
|
|
50
50
|
placeholder = p.placeholder,
|
|
51
51
|
_p$maxLine = p.maxLine,
|
|
52
52
|
maxLine = _p$maxLine === void 0 ? 4 : _p$maxLine,
|
|
53
|
-
|
|
54
|
-
changeEditStatus = p.changeEditStatus,
|
|
53
|
+
isShowApproval = p.isShowApproval,
|
|
55
54
|
maxLength = p.maxLength,
|
|
56
55
|
initValue = p.initValue,
|
|
57
56
|
onErrorChange = p.onErrorChange,
|
|
@@ -98,7 +97,7 @@ var Textarea = function Textarea(p) {
|
|
|
98
97
|
isTrue = _useState12[0],
|
|
99
98
|
setIsTrue = _useState12[1];
|
|
100
99
|
|
|
101
|
-
var _useState13 = (0, _react.useState)(
|
|
100
|
+
var _useState13 = (0, _react.useState)(1),
|
|
102
101
|
_useState14 = _slicedToArray(_useState13, 2),
|
|
103
102
|
textAreaRows = _useState14[0],
|
|
104
103
|
setTextAreaRows = _useState14[1];
|
|
@@ -193,7 +192,7 @@ var Textarea = function Textarea(p) {
|
|
|
193
192
|
}, [realValue]);
|
|
194
193
|
(0, _react.useEffect)(function () {
|
|
195
194
|
resetTextareaHeight();
|
|
196
|
-
}, [
|
|
195
|
+
}, [isShowApproval]);
|
|
197
196
|
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
198
197
|
className: "\n ".concat(prefixCls, "\n ").concat(areaError, "\n ").concat(disabled ? " disabled" : "", "\n "),
|
|
199
198
|
onFocus: function onFocus() {},
|
|
@@ -216,8 +215,7 @@ var Textarea = function Textarea(p) {
|
|
|
216
215
|
disabled: disabled,
|
|
217
216
|
ref: realInputRef,
|
|
218
217
|
value: realValue,
|
|
219
|
-
rows: textAreaRows
|
|
220
|
-
,
|
|
218
|
+
rows: textAreaRows,
|
|
221
219
|
placeholder: placeholder,
|
|
222
220
|
onScroll: handleShadowVisible,
|
|
223
221
|
onChange: function onChange(e) {
|
|
@@ -18,10 +18,15 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
18
18
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
19
|
|
|
20
20
|
function _default(props) {
|
|
21
|
-
var
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
var align = props.align,
|
|
22
|
+
placement = props.placement;
|
|
23
|
+
|
|
24
|
+
if (placement === "top" && !align) {
|
|
25
|
+
align = {
|
|
26
|
+
offset: [0, 5]
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
25
30
|
return /*#__PURE__*/_react["default"].createElement(_rcTooltip["default"], _extends({}, props, {
|
|
26
31
|
align: align,
|
|
27
32
|
transitionName: props.transitionName || "tita-common-fade"
|
|
@@ -84,7 +84,7 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
84
84
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
85
85
|
className: "tu-icon-canceled action-icon action-icon-delete",
|
|
86
86
|
onMouseDown: function onMouseDown() {
|
|
87
|
-
return onSubmit(index,
|
|
87
|
+
return onSubmit(index, 'cancel');
|
|
88
88
|
}
|
|
89
89
|
})));
|
|
90
90
|
}
|
|
@@ -94,24 +94,24 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
94
94
|
if (smallImageUrl && deleteable) {
|
|
95
95
|
// 是图片且能删除
|
|
96
96
|
return [/*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
97
|
-
content: (0, _getLocale.getLocale)(
|
|
97
|
+
content: (0, _getLocale.getLocale)('Mod_Preview'),
|
|
98
98
|
container: document.body
|
|
99
99
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
100
100
|
className: "upload-file-action-wrapper"
|
|
101
101
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
102
102
|
className: "tu-icon-yulan action-icon",
|
|
103
103
|
onMouseDown: function onMouseDown() {
|
|
104
|
-
return onSubmit(index,
|
|
104
|
+
return onSubmit(index, 'preview');
|
|
105
105
|
}
|
|
106
106
|
}))), /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
107
|
-
content: (0, _getLocale.getLocale)(
|
|
107
|
+
content: (0, _getLocale.getLocale)('Mod_Delete'),
|
|
108
108
|
container: document.body
|
|
109
109
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
110
110
|
className: "upload-file-action-wrapper"
|
|
111
111
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
112
112
|
className: "tu-icon-canceled action-icon delete",
|
|
113
113
|
onMouseDown: function onMouseDown() {
|
|
114
|
-
return onSubmit(index,
|
|
114
|
+
return onSubmit(index, 'delete');
|
|
115
115
|
}
|
|
116
116
|
})))];
|
|
117
117
|
}
|
|
@@ -119,14 +119,14 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
119
119
|
if (!smallImageUrl && deleteable) {
|
|
120
120
|
// 不是图片但能删除
|
|
121
121
|
return /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
122
|
-
content: (0, _getLocale.getLocale)(
|
|
122
|
+
content: (0, _getLocale.getLocale)('Mod_Delete'),
|
|
123
123
|
container: document.body
|
|
124
124
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
125
125
|
className: "upload-file-action-wrapper"
|
|
126
126
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
127
127
|
className: "tu-icon-canceled action-icon delete",
|
|
128
128
|
onMouseDown: function onMouseDown() {
|
|
129
|
-
return onSubmit(index,
|
|
129
|
+
return onSubmit(index, 'delete');
|
|
130
130
|
}
|
|
131
131
|
})));
|
|
132
132
|
}
|
|
@@ -134,14 +134,14 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
134
134
|
if (smallImageUrl && !deleteable) {
|
|
135
135
|
// 是图片不能删除
|
|
136
136
|
return /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
137
|
-
content: (0, _getLocale.getLocale)(
|
|
137
|
+
content: (0, _getLocale.getLocale)('Mod_Preview'),
|
|
138
138
|
container: document.body
|
|
139
139
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
140
140
|
className: "upload-file-action-wrapper"
|
|
141
141
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
142
142
|
className: "tu-icon-magnifier-circle action-icon",
|
|
143
143
|
onMouseDown: function onMouseDown() {
|
|
144
|
-
return onSubmit(index,
|
|
144
|
+
return onSubmit(index, 'preview');
|
|
145
145
|
}
|
|
146
146
|
})));
|
|
147
147
|
} // 不是图片也不能删除
|
|
@@ -152,14 +152,14 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
152
152
|
|
|
153
153
|
if (uploadStatus === 5) {
|
|
154
154
|
return /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
155
|
-
content: (0, _getLocale.getLocale)(
|
|
155
|
+
content: (0, _getLocale.getLocale)('Mod_Delete'),
|
|
156
156
|
container: document.body
|
|
157
157
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
158
158
|
className: "upload-file-action-wrapper"
|
|
159
159
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
160
160
|
className: "tu-icon-canceled action-icon delete",
|
|
161
161
|
onMouseDown: function onMouseDown() {
|
|
162
|
-
return onSubmit(index,
|
|
162
|
+
return onSubmit(index, 'delete');
|
|
163
163
|
}
|
|
164
164
|
})));
|
|
165
165
|
} // 4:上传失败
|
|
@@ -173,17 +173,17 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
173
173
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
174
174
|
className: "tu-icon-gengxin1 action-icon",
|
|
175
175
|
onMouseDown: function onMouseDown() {
|
|
176
|
-
return onSubmit(index,
|
|
176
|
+
return onSubmit(index, 'reupload');
|
|
177
177
|
}
|
|
178
178
|
}))), /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
179
|
-
content: (0, _getLocale.getLocale)(
|
|
179
|
+
content: (0, _getLocale.getLocale)('Mod_Delete'),
|
|
180
180
|
container: document.body
|
|
181
181
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
182
182
|
className: "upload-file-action-wrapper"
|
|
183
183
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
184
184
|
className: "tu-icon-canceled action-icon delete",
|
|
185
185
|
onMouseDown: function onMouseDown() {
|
|
186
|
-
return onSubmit(index,
|
|
186
|
+
return onSubmit(index, 'delete');
|
|
187
187
|
}
|
|
188
188
|
}))));
|
|
189
189
|
};
|
|
@@ -205,7 +205,7 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
205
205
|
uploadResultItem = _this$props.uploadResultItem,
|
|
206
206
|
index = _this$props.index;
|
|
207
207
|
return /*#__PURE__*/_react["default"].createElement(_style.PreviewContent, {
|
|
208
|
-
className: [
|
|
208
|
+
className: ['preview__content document-mouse-event-ignore', className].join(' ')
|
|
209
209
|
}, /*#__PURE__*/_react["default"].createElement(_style.PreviewImageWrapper, null, this.renderPreviewThumbnail()), /*#__PURE__*/_react["default"].createElement(_style.PreviewMessageWrapper, null, /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
210
210
|
content: uploadResultItem.FileName,
|
|
211
211
|
container: document.body
|
|
@@ -218,8 +218,8 @@ var UploadedPreview = /*#__PURE__*/function (_PureComponent) {
|
|
|
218
218
|
},
|
|
219
219
|
className: "upload-file--progress"
|
|
220
220
|
})) : /*#__PURE__*/_react["default"].createElement("div", {
|
|
221
|
-
className: uploadResultItem.uploadStatus === 3 || uploadResultItem.uploadStatus === 2 ?
|
|
222
|
-
}, uploadResultItem.uploadStatus === 3 || uploadResultItem.uploadStatus === 2 ? (0, _util.getFileSize)(uploadResultItem.FileSize) : uploadResultItem.Msg)))), /*#__PURE__*/_react["default"].createElement(_style.PreviewOptionsWrapper, null, this.dealPreviewOptions(uploadResultItem.uploadStatus, index, uploadResultItem.Deleteable, uploadResultItem.SmallImageUrl),
|
|
221
|
+
className: uploadResultItem.uploadStatus === 3 || uploadResultItem.uploadStatus === 2 ? 'upload-file-size' : 'upload-file-size upload-file-size--error'
|
|
222
|
+
}, uploadResultItem.uploadStatus === 3 || uploadResultItem.uploadStatus === 2 ? (0, _util.getFileSize)(uploadResultItem.FileSize) : uploadResultItem.Msg)))), /*#__PURE__*/_react["default"].createElement(_style.PreviewOptionsWrapper, null, this.dealPreviewOptions(uploadResultItem.uploadStatus, index, uploadResultItem.Deleteable, uploadResultItem.SmallImageUrl), ' '));
|
|
223
223
|
}
|
|
224
224
|
}]);
|
|
225
225
|
|
|
@@ -99,7 +99,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
99
99
|
|
|
100
100
|
if (fileInput) {
|
|
101
101
|
// @ts-ignore
|
|
102
|
-
fileInput.value =
|
|
102
|
+
fileInput.value = '';
|
|
103
103
|
}
|
|
104
104
|
};
|
|
105
105
|
|
|
@@ -161,7 +161,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
161
161
|
var uploadStartFile = null;
|
|
162
162
|
var timestamp = new Date().getTime(); // 给每个文件加一个时间戳
|
|
163
163
|
|
|
164
|
-
var uploadFileType = element.name.substring(element.name.lastIndexOf(
|
|
164
|
+
var uploadFileType = element.name.substring(element.name.lastIndexOf('.') + 1);
|
|
165
165
|
uploadStartFile = {
|
|
166
166
|
FileName: element.name,
|
|
167
167
|
FileType: (0, _type._dealAttachmentType)(uploadFileType).FileType,
|
|
@@ -173,17 +173,17 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
173
173
|
// 开始上传
|
|
174
174
|
IsSuccess: false,
|
|
175
175
|
uid: (0, _uuid["default"])(),
|
|
176
|
-
_smallImageUrl:
|
|
177
|
-
_bigImageUrl:
|
|
178
|
-
MediaType:
|
|
176
|
+
_smallImageUrl: '',
|
|
177
|
+
_bigImageUrl: '',
|
|
178
|
+
MediaType: '',
|
|
179
179
|
UserId: 0,
|
|
180
180
|
MaxDocCount: 0,
|
|
181
|
-
DfsPath:
|
|
182
|
-
ClientUrl:
|
|
183
|
-
SmallImageUrl:
|
|
184
|
-
BigImageUrl:
|
|
185
|
-
DownloadUrl:
|
|
186
|
-
Msg:
|
|
181
|
+
DfsPath: '',
|
|
182
|
+
ClientUrl: '',
|
|
183
|
+
SmallImageUrl: '',
|
|
184
|
+
BigImageUrl: '',
|
|
185
|
+
DownloadUrl: '',
|
|
186
|
+
Msg: '',
|
|
187
187
|
AllowUploadAttachmentSize: 50,
|
|
188
188
|
Deleteable: true,
|
|
189
189
|
requestXHR: new XMLHttpRequest() // 在这创建是为了取消用
|
|
@@ -202,7 +202,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
202
202
|
_this._dealUploadStart(uploadStartFiles); // 处理开始上传的文件
|
|
203
203
|
|
|
204
204
|
|
|
205
|
-
formData.append(
|
|
205
|
+
formData.append('file', element);
|
|
206
206
|
var url = action || (0, _requestV.getApiUrl)("Upload/PostFiles?format=json×tamp=".concat(timestamp));
|
|
207
207
|
|
|
208
208
|
_this._dealUploadXHRRequest(formData, url, uploadStartFile);
|
|
@@ -213,7 +213,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
213
213
|
if (uploadStartFile.FileSize > _this.props.fileSizeLimit * 1024 * 1024) {
|
|
214
214
|
setTimeout(function () {
|
|
215
215
|
_this._dealUploadSuccess(_objectSpread(_objectSpread({}, uploadStartFile), {
|
|
216
|
-
Msg:
|
|
216
|
+
Msg: '上传失败,文件过大',
|
|
217
217
|
IsImage: false,
|
|
218
218
|
uploadStatus: 5
|
|
219
219
|
}));
|
|
@@ -283,7 +283,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
283
283
|
item.uploadStatus = 4; // 上传失败
|
|
284
284
|
|
|
285
285
|
item.percentComplete = Math.round(evt.loaded * 100 / evt.total);
|
|
286
|
-
item.Msg =
|
|
286
|
+
item.Msg = '网络异常,请重新上传';
|
|
287
287
|
}
|
|
288
288
|
});
|
|
289
289
|
|
|
@@ -292,7 +292,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
292
292
|
});
|
|
293
293
|
};
|
|
294
294
|
|
|
295
|
-
xhr.open(
|
|
295
|
+
xhr.open('POST', url, true);
|
|
296
296
|
xhr.send(formData); // 开始上传,发送form数据
|
|
297
297
|
};
|
|
298
298
|
|
|
@@ -377,12 +377,12 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
377
377
|
onSubmit = _this$props2.onSubmit,
|
|
378
378
|
onDelete = _this$props2.onDelete;
|
|
379
379
|
|
|
380
|
-
if (options ===
|
|
380
|
+
if (options === 'cancel') {
|
|
381
381
|
var reUploadFileInfo = _this.state.uploadSuccessFiles[index];
|
|
382
382
|
reUploadFileInfo.requestXHR.abort();
|
|
383
383
|
}
|
|
384
384
|
|
|
385
|
-
if (options ===
|
|
385
|
+
if (options === 'delete' || options === 'cancel') {
|
|
386
386
|
var uploadResultFiles = _toConsumableArray(_this.state.uploadSuccessFiles);
|
|
387
387
|
|
|
388
388
|
var deleteFiles = uploadResultFiles[index];
|
|
@@ -398,11 +398,11 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
398
398
|
_this.setState({
|
|
399
399
|
uploadSuccessFiles: uploadResultFiles
|
|
400
400
|
});
|
|
401
|
-
} else if (options ===
|
|
401
|
+
} else if (options === 'preview') {
|
|
402
402
|
var imgIndex = _this.getImgIndex(index);
|
|
403
403
|
|
|
404
404
|
_this.refs.imgViewerRef.show(imgIndex);
|
|
405
|
-
} else if (options ===
|
|
405
|
+
} else if (options === 'reupload') {
|
|
406
406
|
var _reUploadFileInfo = _this.state.uploadSuccessFiles[index];
|
|
407
407
|
var reUploadFile = _this.state.selectFiles[_reUploadFileInfo.FileName];
|
|
408
408
|
|
|
@@ -493,7 +493,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
493
493
|
className = _this$props3.className,
|
|
494
494
|
style = _this$props3.style,
|
|
495
495
|
_this$props3$attachme = _this$props3.attachmentTipText,
|
|
496
|
-
attachmentTipText = _this$props3$attachme === void 0 ? (0, _getLocale.getLocale)(
|
|
496
|
+
attachmentTipText = _this$props3$attachme === void 0 ? (0, _getLocale.getLocale)('OKR_MyO_KRP_Draganddropu') : _this$props3$attachme;
|
|
497
497
|
var uploadSuccessFiles = this.state.uploadSuccessFiles;
|
|
498
498
|
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
|
|
499
499
|
container: document.body,
|
|
@@ -511,7 +511,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
511
511
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
512
512
|
ref: "uploader-trigger",
|
|
513
513
|
style: {
|
|
514
|
-
cursor:
|
|
514
|
+
cursor: 'pointer'
|
|
515
515
|
}
|
|
516
516
|
}, children), /*#__PURE__*/_react["default"].createElement("input", {
|
|
517
517
|
type: "file",
|
|
@@ -519,7 +519,7 @@ var Upload = /*#__PURE__*/function (_PureComponent) {
|
|
|
519
519
|
className: "upload_file_input",
|
|
520
520
|
multiple: this.props.multiple,
|
|
521
521
|
style: {
|
|
522
|
-
display:
|
|
522
|
+
display: 'none'
|
|
523
523
|
},
|
|
524
524
|
onChange: this.onFileInputChange
|
|
525
525
|
}))), this.renderUploadList(uploadSuccessFiles));
|
|
@@ -535,7 +535,7 @@ Upload.defaultProps = {
|
|
|
535
535
|
fileSizeLimit: 50,
|
|
536
536
|
filesTotal: 50,
|
|
537
537
|
multiple: true,
|
|
538
|
-
attachmentPreviewBox:
|
|
538
|
+
attachmentPreviewBox: 'MBlog__attachmentViewBox'
|
|
539
539
|
};
|
|
540
540
|
var _default = Upload;
|
|
541
541
|
exports["default"] = _default;
|
|
@@ -31,6 +31,8 @@ function _default(props) {
|
|
|
31
31
|
height = props.height;
|
|
32
32
|
|
|
33
33
|
var _useContext = (0, _react.useContext)(_context.CommonContext),
|
|
34
|
+
_useContext$departId = _useContext.departId,
|
|
35
|
+
departId = _useContext$departId === void 0 ? "-1" : _useContext$departId,
|
|
34
36
|
departOnly = _useContext.departOnly,
|
|
35
37
|
sourceFrom = _useContext.sourceFrom,
|
|
36
38
|
auth = _useContext.auth,
|
|
@@ -39,7 +41,7 @@ function _default(props) {
|
|
|
39
41
|
disabledDepartSelect = _useContext.disabledDepartSelect;
|
|
40
42
|
|
|
41
43
|
var onGetDepartTreeData = function onGetDepartTreeData() {
|
|
42
|
-
return (0, _requestApis.getTreeData)(
|
|
44
|
+
return (0, _requestApis.getTreeData)(departId, {
|
|
43
45
|
departOnly: departOnly,
|
|
44
46
|
auth: auth,
|
|
45
47
|
authType: authType,
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
.persel-selector-field {
|
|
2
2
|
display: inline-block;
|
|
3
|
+
max-width: 100%;
|
|
3
4
|
min-width: 120px;
|
|
4
5
|
height: 36px;
|
|
5
6
|
line-height: 36px;
|
|
6
7
|
background: #ffffff;
|
|
7
|
-
border-radius:
|
|
8
|
+
border-radius: 18px !important;
|
|
8
9
|
border: 1px solid #e9ecf0;
|
|
9
10
|
padding: 8px 12px;
|
|
10
11
|
box-sizing: border-box;
|