@titaui/pc 1.5.69-beta.4 → 1.5.69-beta.8
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/avatar/icon-avatar/index.js +1 -1
- package/lib/components/avatar/index.js +5 -1
- package/lib/components/avatar/num-avatar/index.css +12 -0
- package/lib/components/avatar/num-avatar/index.js +34 -0
- package/lib/components/button/default-button/index.css +49 -0
- package/lib/components/button/default-button/index.js +51 -0
- package/lib/components/button/index.js +8 -2
- package/lib/components/communication/CommunicationRecord.js +106 -162
- package/lib/components/communication/index.js +27 -24
- package/lib/components/dropdown-layer/index.js +15 -12
- package/lib/components/dynamic/components/condition-render/index.js +20 -0
- package/lib/components/dynamic/components/dynamic-search-input/index.css +6 -0
- package/lib/components/dynamic/components/dynamic-search-input/index.js +2 -1
- package/lib/components/dynamic/components/obj-status/index.css +22 -0
- package/lib/components/dynamic/components/obj-status/index.js +38 -0
- package/lib/components/dynamic/components/percent/index.css +21 -0
- package/lib/components/dynamic/components/percent/index.js +38 -0
- package/lib/components/dynamic/components/title/index.css +35 -0
- package/lib/components/dynamic/{dynamic-item/components/publish-content → components/title}/index.js +27 -31
- package/lib/components/dynamic/constant.js +19 -2
- package/lib/components/dynamic/dynamic-item/components/{dynamic-item-header → header}/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/components/{dynamic-item-header → header}/index.js +23 -16
- package/lib/components/dynamic/dynamic-item/components/icon/index.css +10 -0
- package/lib/components/dynamic/dynamic-item/components/icon/index.js +35 -0
- package/lib/components/dynamic/dynamic-item/{components/align → dynamic-align}/img/dynamic-align.svg +0 -0
- package/lib/components/dynamic/dynamic-item/{components/align → dynamic-align}/img/dynamic-relative.svg +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +95 -0
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +161 -0
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +51 -0
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.js +92 -0
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +48 -0
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +88 -0
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +94 -0
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +168 -0
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +85 -0
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +140 -0
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +95 -0
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +213 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project → dynamic-project}/constant.js +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-project}/img/project.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +91 -0
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +124 -0
- package/lib/components/dynamic/dynamic-item/{components/relative → dynamic-relative}/img/dynamic-relative.svg +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +95 -0
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +180 -0
- package/lib/components/dynamic/dynamic-item/dynamic-replay/index.css +134 -0
- package/lib/components/dynamic/dynamic-item/{components/replay → dynamic-replay}/index.js +73 -11
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +94 -0
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +137 -0
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +97 -0
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.js +205 -0
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +51 -0
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +92 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/constant.js +13 -3
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-cancel.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-delay.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-done.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-pause.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-progress.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-unaccept.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-unstart.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +111 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +162 -0
- package/lib/components/dynamic/dynamic-item/index.css +11 -2
- package/lib/components/dynamic/dynamic-item/index.js +125 -76
- package/lib/components/dynamic/dynamic-like-ranking/index.css +1 -0
- package/lib/components/dynamic/dynamic-like-ranking/index.js +65 -19
- package/lib/components/dynamic/dynamic-like-ranking/item.js +20 -38
- package/lib/components/dynamic/dynamic-liking/index.css +1 -0
- package/lib/components/dynamic/dynamic-liking/index.js +10 -4
- package/lib/components/dynamic/dynamic-liking/item.js +37 -12
- package/lib/components/dynamic/dynamic-list/index.js +9 -3
- package/lib/components/dynamic/dynamic-topping/index.js +1 -1
- package/lib/components/dynamic/dynamic-topping/item.js +2 -2
- package/lib/components/dynamic/dynamic.css +30 -0
- package/lib/components/dynamic/dynamic.js +61 -27
- package/lib/components/dynamic/quick-operation/index.js +14 -4
- package/lib/components/dynamic/request-api.js +13 -1
- package/lib/components/dynamic/util.js +16 -2
- package/lib/components/grid-page/image/{Assistant.svg → assistant.svg} +0 -0
- package/lib/components/grid-page/image/{Boss.svg → boss.svg} +0 -0
- package/lib/components/grid-page/image/{Default-background.png → default-background.png} +0 -0
- package/lib/components/grid-page/personal-info/index.js +4 -4
- package/lib/components/publish-dynamic-modal/publish-dynamic-modal.js +56 -23
- package/lib/components/publish-dynamic-modal/requist-api.js +17 -2
- package/lib/components/upvote/index.js +15 -10
- package/lib/components/user-selector/export-modules/field-tree-selector/index.css +4 -0
- package/lib/components/user-selector/export-modules/field-tree-selector/index.js +8 -6
- package/lib/pages/like-ranking/column.js +21 -8
- package/lib/pages/like-ranking/filter-buttons/department.js +46 -10
- package/lib/pages/like-ranking/filter-buttons/index.css +4 -8
- package/lib/pages/like-ranking/filter-buttons/index.js +12 -11
- package/lib/pages/like-ranking/filter-buttons/modular.js +51 -28
- package/lib/pages/like-ranking/filter-buttons/name.js +33 -6
- package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.css +17 -0
- package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.js +8 -2
- package/lib/pages/like-ranking/filter-buttons/timer.js +26 -46
- package/lib/pages/like-ranking/index.css +37 -2
- package/lib/pages/like-ranking/index.js +121 -21
- package/lib/pages/like-ranking/request-api.js +15 -0
- package/lib/utils/bs-global.js +19 -2
- package/lib/utils/format-time.js +110 -8
- package/lib/utils/tools.js +50 -25
- package/package.json +1 -1
- package/lib/components/dynamic/components/common-title/index.css +0 -106
- package/lib/components/dynamic/components/common-title/index.js +0 -129
- package/lib/components/dynamic/dynamic-item/components/align/index.css +0 -66
- package/lib/components/dynamic/dynamic-item/components/align/index.js +0 -109
- package/lib/components/dynamic/dynamic-item/components/assessment/index.css +0 -20
- package/lib/components/dynamic/dynamic-item/components/assessment/index.js +0 -48
- package/lib/components/dynamic/dynamic-item/components/common-dynamic/index.css +0 -34
- package/lib/components/dynamic/dynamic-item/components/common-dynamic/index.js +0 -153
- package/lib/components/dynamic/dynamic-item/components/create-o/index.css +0 -52
- package/lib/components/dynamic/dynamic-item/components/create-o/index.js +0 -104
- package/lib/components/dynamic/dynamic-item/components/dynamic-desc/index.css +0 -62
- package/lib/components/dynamic/dynamic-item/components/dynamic-desc/index.js +0 -257
- package/lib/components/dynamic/dynamic-item/components/publish-content/index.css +0 -22
- package/lib/components/dynamic/dynamic-item/components/relative/index.css +0 -66
- package/lib/components/dynamic/dynamic-item/components/relative/index.js +0 -124
- package/lib/components/dynamic/dynamic-item/components/replay/index.css +0 -93
- package/lib/components/dynamic/dynamic-item/components/report/index.css +0 -32
- package/lib/components/dynamic/dynamic-item/components/report/index.js +0 -82
- package/lib/components/dynamic/dynamic-item/components/task-project/index.css +0 -57
- package/lib/components/dynamic/dynamic-item/components/task-project/index.js +0 -87
- package/lib/components/dynamic/dynamic-item/components/task-project-icon/index.css +0 -20
- package/lib/components/dynamic/dynamic-item/components/task-project-icon/index.js +0 -40
- package/lib/components/dynamic/dynamic-topping/mock.js +0 -1
- package/lib/pages/like-ranking/tab-bar/index.css +0 -22
- package/lib/pages/like-ranking/tab-bar/index.js +0 -65
|
@@ -1,153 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
|
|
12
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
|
-
|
|
14
|
-
var _commonTitle = _interopRequireDefault(require("../../../components/common-title"));
|
|
15
|
-
|
|
16
|
-
var _dynamicLeftQuoto = _interopRequireDefault(require("../../../img/dynamic-left-quoto.svg"));
|
|
17
|
-
|
|
18
|
-
var _dynamicRightQuoto = _interopRequireDefault(require("../../../img/dynamic-right-quoto.svg"));
|
|
19
|
-
|
|
20
|
-
var _searchKeyHandle = _interopRequireDefault(require("../../../../search-key-handle"));
|
|
21
|
-
|
|
22
|
-
var _context = require("../../../context");
|
|
23
|
-
|
|
24
|
-
var _manager = _interopRequireDefault(require("../../../../drawer/manager"));
|
|
25
|
-
|
|
26
|
-
var _tools = require("../../../../..//utils/tools");
|
|
27
|
-
|
|
28
|
-
var _constant = require("../../../constant");
|
|
29
|
-
|
|
30
|
-
require("./index.css");
|
|
31
|
-
|
|
32
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
33
|
-
|
|
34
|
-
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); }
|
|
35
|
-
|
|
36
|
-
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; }
|
|
37
|
-
|
|
38
|
-
var prefix = "titaui-dynamic-common-dynamic";
|
|
39
|
-
|
|
40
|
-
var CommonDynamic = function CommonDynamic(_ref) {
|
|
41
|
-
var data = _ref.data;
|
|
42
|
-
var progress = data.progress,
|
|
43
|
-
progressDescription = data.progressDescription,
|
|
44
|
-
progressGrow = data.progressGrow,
|
|
45
|
-
riskLevel = data.riskLevel,
|
|
46
|
-
obj = data.obj,
|
|
47
|
-
rewardContent = data.rewardContent,
|
|
48
|
-
rewardTags = data.rewardTags;
|
|
49
|
-
|
|
50
|
-
var _useContext = (0, _react.useContext)(_context.SearchKeyContext),
|
|
51
|
-
searchKeyWord = _useContext.searchKeyWord;
|
|
52
|
-
|
|
53
|
-
var handleClickTitle = function handleClickTitle() {
|
|
54
|
-
if (!obj) {
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
var objType = obj.objType,
|
|
59
|
-
objId = obj.objId;
|
|
60
|
-
|
|
61
|
-
if (objType === _constant.EObjType.Kr) {
|
|
62
|
-
_manager["default"].open("krDetail", {
|
|
63
|
-
krId: objId
|
|
64
|
-
});
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
if (objType === _constant.EObjType.O) {
|
|
68
|
-
_manager["default"].open("okrDetail", {
|
|
69
|
-
okrId: objId
|
|
70
|
-
});
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
if (objType === _constant.EObjType.Task) {
|
|
74
|
-
window.Talent.app.vent.trigger("global-pull-screen", objId, "task");
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
if (objType === _constant.EObjType.Project) {
|
|
78
|
-
window.open(window.location.href.replace(location.hash, "#work?iTalentNavCode=tita-work&work_id=" + objId));
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
if (objType === _constant.EObjType.Assess) {
|
|
82
|
-
var assessId = data.url.split("assessId=")[1];
|
|
83
|
-
window.open(window.location.href.replace(location.hash, "#performance?reactRouterName=detail&formId=" + assessId));
|
|
84
|
-
}
|
|
85
|
-
};
|
|
86
|
-
|
|
87
|
-
var renderTitle = (0, _react.useMemo)(function () {
|
|
88
|
-
if (!obj) {
|
|
89
|
-
return;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
var objType = obj.objType,
|
|
93
|
-
objName = obj.objName;
|
|
94
|
-
|
|
95
|
-
if (objType === _constant.EObjType.Kr) {
|
|
96
|
-
return "KR:" + objName;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
if (objType === _constant.EObjType.O) {
|
|
100
|
-
return "O:" + objName;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
if (objType === _constant.EObjType.Task) {
|
|
104
|
-
return "任务:" + objName;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
if (objType === _constant.EObjType.Project) {
|
|
108
|
-
return "项目:" + objName;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
if (objType === _constant.EObjType.Assess) {
|
|
112
|
-
return "考核:" + objName;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
return "";
|
|
116
|
-
}, []);
|
|
117
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
118
|
-
className: prefix
|
|
119
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
120
|
-
className: prefix + "__title"
|
|
121
|
-
}, renderTitle && /*#__PURE__*/_react["default"].createElement(_commonTitle["default"], {
|
|
122
|
-
content: renderTitle,
|
|
123
|
-
showPercent: true,
|
|
124
|
-
percent: progress,
|
|
125
|
-
growPercent: progressGrow,
|
|
126
|
-
showStatusIcon: true,
|
|
127
|
-
oStatus: 1,
|
|
128
|
-
riskLevel: riskLevel,
|
|
129
|
-
onClickTitle: handleClickTitle
|
|
130
|
-
})), (progressDescription || rewardContent) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
131
|
-
className: prefix + "__description"
|
|
132
|
-
}, /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("img", {
|
|
133
|
-
className: (0, _classnames["default"])(prefix + "__description-quoto", prefix + "__description-quoto--left"),
|
|
134
|
-
src: _dynamicLeftQuoto["default"]
|
|
135
|
-
})), /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_searchKeyHandle["default"], {
|
|
136
|
-
str: progressDescription || rewardContent,
|
|
137
|
-
keyWord: searchKeyWord
|
|
138
|
-
}), /*#__PURE__*/_react["default"].createElement("img", {
|
|
139
|
-
className: (0, _classnames["default"])(prefix + "__description-quoto", prefix + "__description-quoto--right"),
|
|
140
|
-
src: _dynamicRightQuoto["default"]
|
|
141
|
-
}), rewardTags && rewardTags.length && rewardTags.map(function (reward) {
|
|
142
|
-
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
143
|
-
className: prefix + "__reward-tag",
|
|
144
|
-
style: {
|
|
145
|
-
background: (0, _tools.hexToRgba)(reward.color, 0.2),
|
|
146
|
-
color: reward.color
|
|
147
|
-
}
|
|
148
|
-
}, reward.tagName);
|
|
149
|
-
}))));
|
|
150
|
-
};
|
|
151
|
-
|
|
152
|
-
var _default = CommonDynamic;
|
|
153
|
-
exports["default"] = _default;
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
.titaui-dynamic-create-o {
|
|
2
|
-
font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.titaui-dynamic-create-o__infos-wrapper {
|
|
6
|
-
margin-top: 8px;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.titaui-dynamic-create-o__okr {
|
|
10
|
-
display: flex;
|
|
11
|
-
align-items: center;
|
|
12
|
-
font-size: 12px;
|
|
13
|
-
color: #89919f;
|
|
14
|
-
line-height: 18px;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.titaui-dynamic-create-o__okr-type-icon, .titaui-dynamic-create-o__okr-cycle-icon {
|
|
18
|
-
margin-right: 4px;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.titaui-dynamic-create-o__okr-cycle-icon {
|
|
22
|
-
margin-left: 20px;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
.titaui-dynamic-create-o__okr-krs {
|
|
26
|
-
margin-top: 4px;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
.titaui-dynamic-create-o__kr {
|
|
30
|
-
display: flex;
|
|
31
|
-
align-items: center;
|
|
32
|
-
margin-top: 8px;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.titaui-dynamic-create-o__kr-order {
|
|
36
|
-
font-size: 12px;
|
|
37
|
-
color: #2879ff;
|
|
38
|
-
line-height: 18px;
|
|
39
|
-
margin-right: 4px;
|
|
40
|
-
margin-top: 1px;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
.titaui-dynamic-create-o__kr-name {
|
|
44
|
-
font-size: 14px;
|
|
45
|
-
color: #3f4755;
|
|
46
|
-
line-height: 22px;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.titaui-dynamic-create-o__kr-name:hover {
|
|
50
|
-
color: #2879ff;
|
|
51
|
-
cursor: pointer;
|
|
52
|
-
}
|
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports["default"] = void 0;
|
|
7
|
-
|
|
8
|
-
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
|
|
10
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
11
|
-
|
|
12
|
-
var _commonTitle = _interopRequireDefault(require("../../../components/common-title"));
|
|
13
|
-
|
|
14
|
-
var _manager = _interopRequireDefault(require("../../../../drawer/manager"));
|
|
15
|
-
|
|
16
|
-
var _openData = require("../../../../../utils/open-data");
|
|
17
|
-
|
|
18
|
-
require("./index.css");
|
|
19
|
-
|
|
20
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
21
|
-
|
|
22
|
-
var prefix = "titaui-dynamic-create-o";
|
|
23
|
-
|
|
24
|
-
var CreateO = function CreateO(_ref) {
|
|
25
|
-
var data = _ref.data;
|
|
26
|
-
var okrId = data.okrId,
|
|
27
|
-
okrName = data.okrName,
|
|
28
|
-
krs = data.krs,
|
|
29
|
-
okrType = data.okrType,
|
|
30
|
-
cycleName = data.cycleName,
|
|
31
|
-
classify = data.classify;
|
|
32
|
-
|
|
33
|
-
var handleClickOTitle = function handleClickOTitle() {
|
|
34
|
-
_manager["default"].open("okrDetail", {
|
|
35
|
-
okrId: okrId
|
|
36
|
-
});
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
var handleClickKrTitle = function handleClickKrTitle(id) {
|
|
40
|
-
_manager["default"].open("krDetail", {
|
|
41
|
-
krId: id
|
|
42
|
-
});
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
var okrTypeMap = {
|
|
46
|
-
1: {
|
|
47
|
-
icon: "tu-icon-liebiao-geren",
|
|
48
|
-
text: "个人"
|
|
49
|
-
},
|
|
50
|
-
// 个人
|
|
51
|
-
2: {
|
|
52
|
-
icon: "tu-icon-liebiao-xiashu",
|
|
53
|
-
text: // @ts-ignore
|
|
54
|
-
"departmentId" == -1 ? "默认部门" : /*#__PURE__*/_react["default"].createElement(_openData.OpenDepartmentName, {
|
|
55
|
-
id: "departmentId",
|
|
56
|
-
name: "departmentName"
|
|
57
|
-
})
|
|
58
|
-
},
|
|
59
|
-
// 部门
|
|
60
|
-
3: {
|
|
61
|
-
icon: "tu-icon-gong_si",
|
|
62
|
-
text: "公司"
|
|
63
|
-
},
|
|
64
|
-
// 公司
|
|
65
|
-
4: {
|
|
66
|
-
icon: "tu-icon-liebiao-tuandui",
|
|
67
|
-
text: "groupName" || "团队"
|
|
68
|
-
} // 团队
|
|
69
|
-
|
|
70
|
-
};
|
|
71
|
-
var okrTypeInfo = okrTypeMap[okrType];
|
|
72
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
73
|
-
className: prefix
|
|
74
|
-
}, /*#__PURE__*/_react["default"].createElement(_commonTitle["default"], {
|
|
75
|
-
content: "O:" + okrName,
|
|
76
|
-
onClickTitle: handleClickOTitle,
|
|
77
|
-
showOClassify: true,
|
|
78
|
-
oClassify: classify
|
|
79
|
-
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
80
|
-
className: prefix + "__infos-wrapper"
|
|
81
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
82
|
-
className: prefix + "__okr"
|
|
83
|
-
}, /*#__PURE__*/_react["default"].createElement("i", {
|
|
84
|
-
className: (0, _classnames["default"])(okrTypeInfo.icon, prefix + "__okr-type-icon")
|
|
85
|
-
}), okrTypeInfo.text, /*#__PURE__*/_react["default"].createElement("i", {
|
|
86
|
-
className: (0, _classnames["default"])("tu-icon-deferred", prefix + "__okr-cycle-icon")
|
|
87
|
-
}), cycleName), krs && krs.length > 0 && /*#__PURE__*/_react["default"].createElement("div", {
|
|
88
|
-
className: prefix + "__okr-krs"
|
|
89
|
-
}, krs.map(function (kr, index) {
|
|
90
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
91
|
-
className: prefix + "__kr"
|
|
92
|
-
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
93
|
-
className: prefix + "__kr-order"
|
|
94
|
-
}, "KR", index + 1), /*#__PURE__*/_react["default"].createElement("span", {
|
|
95
|
-
className: prefix + "__kr-name",
|
|
96
|
-
onClick: function onClick() {
|
|
97
|
-
handleClickKrTitle(kr.krId);
|
|
98
|
-
}
|
|
99
|
-
}, kr.krName));
|
|
100
|
-
}))));
|
|
101
|
-
};
|
|
102
|
-
|
|
103
|
-
var _default = CreateO;
|
|
104
|
-
exports["default"] = _default;
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
.titaui-dynamic-desc__object-name {
|
|
2
|
-
font-size: 14px;
|
|
3
|
-
color: #2879ff;
|
|
4
|
-
line-height: 22px;
|
|
5
|
-
margin: 0 4px;
|
|
6
|
-
overflow: hidden;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.titaui-dynamic-desc__object-name:hover {
|
|
10
|
-
cursor: pointer;
|
|
11
|
-
color: #5c8eff;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.titaui-dynamic-desc__operate-desc {
|
|
15
|
-
font-size: 14px;
|
|
16
|
-
font-weight: 400;
|
|
17
|
-
color: #89919f;
|
|
18
|
-
line-height: 22px;
|
|
19
|
-
margin: 0 8px 0 4px;
|
|
20
|
-
overflow: hidden;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.titaui-dynamic-desc__operate-desc-wrapper {
|
|
24
|
-
display: flex;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.titaui-dynamic-desc-desc-operate-type {
|
|
28
|
-
display: inline-flex;
|
|
29
|
-
align-items: center;
|
|
30
|
-
justify-content: center;
|
|
31
|
-
width: 40px;
|
|
32
|
-
height: 18px;
|
|
33
|
-
min-width: 40px;
|
|
34
|
-
clip-path: polygon(0 100%, 100% 100%, 100% 0, 15% 0);
|
|
35
|
-
-webkit-clip-path: polygon(0 100%, 100% 100%, 100% 0, 15% 0);
|
|
36
|
-
border-radius: 14px 10px 10px 4px;
|
|
37
|
-
font-size: 12px;
|
|
38
|
-
color: #ffffff;
|
|
39
|
-
line-height: 18px;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.titaui-dynamic-desc__reward-img {
|
|
43
|
-
width: 25px;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.titaui-dynamic-desc__reward-user {
|
|
47
|
-
font-size: 14px;
|
|
48
|
-
font-weight: 600;
|
|
49
|
-
color: #3F4755;
|
|
50
|
-
line-height: 22px;
|
|
51
|
-
margin: 0 4px;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.titaui-dynamic-desc__reward-user:hover {
|
|
55
|
-
cursor: pointer;
|
|
56
|
-
color: #2879ff;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.titaui-dynamic-desc__reward-user--not-link:hover {
|
|
60
|
-
cursor: default !important;
|
|
61
|
-
color: #3f4755 !important;
|
|
62
|
-
}
|
|
@@ -1,257 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
|
|
12
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
|
-
|
|
14
|
-
var _constant = require("../../../constant");
|
|
15
|
-
|
|
16
|
-
var _manager = _interopRequireDefault(require("../../../../drawer/manager"));
|
|
17
|
-
|
|
18
|
-
var _searchKeyHandle = _interopRequireDefault(require("../../../../search-key-handle"));
|
|
19
|
-
|
|
20
|
-
var _context = require("../../../context");
|
|
21
|
-
|
|
22
|
-
var _tooltip = require("../../../../..//components/tooltip");
|
|
23
|
-
|
|
24
|
-
var _util = require("../../../util");
|
|
25
|
-
|
|
26
|
-
var _openData = require("../../../../../utils/open-data");
|
|
27
|
-
|
|
28
|
-
var _tools = require("../../../../../utils/tools");
|
|
29
|
-
|
|
30
|
-
var _dynamicReword = _interopRequireDefault(require("../../../img/dynamic-reword.svg"));
|
|
31
|
-
|
|
32
|
-
require("./index.css");
|
|
33
|
-
|
|
34
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
35
|
-
|
|
36
|
-
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); }
|
|
37
|
-
|
|
38
|
-
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; }
|
|
39
|
-
|
|
40
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
41
|
-
|
|
42
|
-
var prefix = "titaui-dynamic-desc";
|
|
43
|
-
|
|
44
|
-
var DynamicDesc = function DynamicDesc(_ref) {
|
|
45
|
-
var data = _ref.data;
|
|
46
|
-
|
|
47
|
-
var _useContext = (0, _react.useContext)(_context.SearchKeyContext),
|
|
48
|
-
searchKeyWord = _useContext.searchKeyWord;
|
|
49
|
-
|
|
50
|
-
var feedType = data.feedType,
|
|
51
|
-
parentObjType = data.parentObjType,
|
|
52
|
-
replayObjType = data.replayObjType,
|
|
53
|
-
relateObjType = data.relateObjType,
|
|
54
|
-
rewardUser = data.rewardUser,
|
|
55
|
-
obj = data.obj;
|
|
56
|
-
|
|
57
|
-
var _getFeedTypeAndTypeCo = (0, _util.getFeedTypeAndTypeColor)(feedType),
|
|
58
|
-
feedTypeText = _getFeedTypeAndTypeCo.feedTypeText,
|
|
59
|
-
feedTypeColor = _getFeedTypeAndTypeCo.feedTypeColor;
|
|
60
|
-
|
|
61
|
-
var handleClickTitle = function handleClickTitle(_ref2) {
|
|
62
|
-
var type = _ref2.type,
|
|
63
|
-
id = _ref2.id;
|
|
64
|
-
|
|
65
|
-
if (type === _constant.EObjType.Kr) {
|
|
66
|
-
_manager["default"].open("krDetail", {
|
|
67
|
-
krId: id
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
if (type === _constant.EObjType.O) {
|
|
72
|
-
_manager["default"].open("okrDetail", {
|
|
73
|
-
okrId: id
|
|
74
|
-
});
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
if (type === _constant.EObjType.Project) {
|
|
78
|
-
window.open(window.location.href.replace(location.hash, "#work?iTalentNavCode=tita-work&work_id=" + id));
|
|
79
|
-
}
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
var renderOperateDesc = function renderOperateDesc() {
|
|
83
|
-
if (feedType === _constant.EFeedType.O) {
|
|
84
|
-
return "负责了目标";
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
if (feedType === _constant.EFeedType.Project) {
|
|
88
|
-
return "负责了项目";
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
if (feedType === _constant.EFeedType.Kr) {
|
|
92
|
-
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
93
|
-
className: prefix + "__operate-desc-wrapper"
|
|
94
|
-
}, "\u8D1F\u8D23\u4E86", _constant.ObjTypeMapText[data.obj.objType], /*#__PURE__*/_react["default"].createElement("span", {
|
|
95
|
-
className: prefix + "__object-name",
|
|
96
|
-
onClick: function onClick() {
|
|
97
|
-
handleClickTitle({
|
|
98
|
-
type: data.obj.objType,
|
|
99
|
-
id: data.obj.objId
|
|
100
|
-
});
|
|
101
|
-
}
|
|
102
|
-
}, /*#__PURE__*/_react["default"].createElement(_tooltip.TooltipText, {
|
|
103
|
-
text: data.obj.objName,
|
|
104
|
-
isPercent: true
|
|
105
|
-
})), "\u4E0B\u5173\u952E\u6210\u679C");
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
if (feedType === _constant.EFeedType.Task) {
|
|
109
|
-
if (data.obj === null) {
|
|
110
|
-
return "负责了任务";
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
114
|
-
className: prefix + "__operate-desc-wrapper"
|
|
115
|
-
}, "\u8D1F\u8D23\u4E86", _constant.ObjTypeMapText[data.obj.objType], /*#__PURE__*/_react["default"].createElement("span", {
|
|
116
|
-
className: prefix + "__object-name",
|
|
117
|
-
onClick: function onClick() {
|
|
118
|
-
handleClickTitle({
|
|
119
|
-
type: data.obj.objType,
|
|
120
|
-
id: data.obj.objId
|
|
121
|
-
});
|
|
122
|
-
}
|
|
123
|
-
}, /*#__PURE__*/_react["default"].createElement(_tooltip.TooltipText, {
|
|
124
|
-
text: data.obj.objName,
|
|
125
|
-
isPercent: true
|
|
126
|
-
})), "\u4E0B\u4EFB\u52A1");
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
if (feedType === _constant.EFeedType.Assessment) {
|
|
130
|
-
return "的考核";
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
if (feedType === _constant.EFeedType.Report) {
|
|
134
|
-
return "的总结";
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
if (feedType === _constant.EFeedType.Reply) {
|
|
138
|
-
if (replayObjType === _constant.EObjType.O) {
|
|
139
|
-
return "的目标复盘";
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
if (replayObjType === _constant.EObjType.Kr) {
|
|
143
|
-
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
144
|
-
className: prefix + "__operate-desc-wrapper"
|
|
145
|
-
}, "\u5728\u76EE\u6807", /*#__PURE__*/_react["default"].createElement("span", {
|
|
146
|
-
className: prefix + "__object-name",
|
|
147
|
-
onClick: function onClick() {
|
|
148
|
-
handleClickTitle({
|
|
149
|
-
type: data.obj.objType,
|
|
150
|
-
id: data.obj.objId
|
|
151
|
-
});
|
|
152
|
-
}
|
|
153
|
-
}, /*#__PURE__*/_react["default"].createElement(_tooltip.TooltipText, {
|
|
154
|
-
text: data.obj.objName,
|
|
155
|
-
isPercent: true
|
|
156
|
-
})), "\u4E0B\u5173\u952E\u6210\u679C\u7684\u590D\u76D8");
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
if (feedType === _constant.EFeedType.Align) {
|
|
161
|
-
if (parentObjType === _constant.EObjType.Kr) {
|
|
162
|
-
return "对齐了关键成果";
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
if (parentObjType === _constant.EObjType.O) {
|
|
166
|
-
return "对齐了目标";
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
if (feedType === _constant.EFeedType.Relative) {
|
|
171
|
-
if (relateObjType === _constant.EObjType.Kr) {
|
|
172
|
-
return "关联了关键成果";
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
if (relateObjType === _constant.EObjType.O) {
|
|
176
|
-
return "关联了目标";
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
if (feedType === _constant.EFeedType.Progress) {
|
|
181
|
-
if (obj && obj.objType === _constant.EObjType.Kr) {
|
|
182
|
-
return /*#__PURE__*/_react["default"].createElement("span", null, "\u66F4\u65B0\u4E86\u76EE\u6807", /*#__PURE__*/_react["default"].createElement("span", {
|
|
183
|
-
className: prefix + "__object-name",
|
|
184
|
-
onClick: function onClick() {
|
|
185
|
-
handleClickTitle({
|
|
186
|
-
type: obj.objType,
|
|
187
|
-
id: obj.objId
|
|
188
|
-
});
|
|
189
|
-
}
|
|
190
|
-
}, /*#__PURE__*/_react["default"].createElement(_searchKeyHandle["default"], {
|
|
191
|
-
str: obj.objName,
|
|
192
|
-
keyWord: searchKeyWord
|
|
193
|
-
})), "\u4E0B\u5173\u952E\u6210\u679C\u8FDB\u5C55");
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
if (obj && obj.objType === _constant.EObjType.O) {
|
|
197
|
-
return "更新了目标进展";
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
if (obj && obj.objType === _constant.EObjType.Task) {
|
|
201
|
-
return "更新了任务进展";
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
if (obj && obj.objType === _constant.EObjType.Project) {
|
|
205
|
-
return "更新了项目进展";
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
return "";
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
if (feedType === _constant.EFeedType.Reword) {
|
|
212
|
-
var url = (0, _tools.getUrlForUserPage)({
|
|
213
|
-
userId: rewardUser.name,
|
|
214
|
-
userType: rewardUser.userType
|
|
215
|
-
});
|
|
216
|
-
|
|
217
|
-
var handleOpenUserPage = function handleOpenUserPage() {
|
|
218
|
-
window.open(url, '_blank');
|
|
219
|
-
};
|
|
220
|
-
|
|
221
|
-
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
222
|
-
className: prefix + '__reward'
|
|
223
|
-
}, "\u83B7\u5F97", /*#__PURE__*/_react["default"].createElement("span", {
|
|
224
|
-
className: (0, _classnames["default"])(prefix + '__reward-user', _defineProperty({}, prefix + '__reward-user--not-link', !url)),
|
|
225
|
-
onClick: handleOpenUserPage
|
|
226
|
-
}, /*#__PURE__*/_react["default"].createElement(_openData.OpenUserName, {
|
|
227
|
-
name: rewardUser.name,
|
|
228
|
-
id: rewardUser.userId
|
|
229
|
-
})), "\u6253\u8D4F");
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
if (feedType === _constant.EFeedType.Announcement) {
|
|
233
|
-
return '发布的公告';
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
if (feedType === _constant.EFeedType.Share) {
|
|
237
|
-
return '发布的分享';
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
return "";
|
|
241
|
-
};
|
|
242
|
-
|
|
243
|
-
return /*#__PURE__*/_react["default"].createElement(_react.Fragment, null, /*#__PURE__*/_react["default"].createElement("span", {
|
|
244
|
-
className: prefix + "__operate-desc"
|
|
245
|
-
}, renderOperateDesc()), feedType === _constant.EFeedType.Reword ? /*#__PURE__*/_react["default"].createElement("img", {
|
|
246
|
-
className: prefix + "__reward-img",
|
|
247
|
-
src: _dynamicReword["default"]
|
|
248
|
-
}) : /*#__PURE__*/_react["default"].createElement("span", {
|
|
249
|
-
className: prefix + "-desc-operate-type",
|
|
250
|
-
style: {
|
|
251
|
-
background: feedTypeColor
|
|
252
|
-
}
|
|
253
|
-
}, feedTypeText));
|
|
254
|
-
};
|
|
255
|
-
|
|
256
|
-
var _default = DynamicDesc;
|
|
257
|
-
exports["default"] = _default;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
.titaui-dynamic-publish-content__content {
|
|
2
|
-
font-size: 14px;
|
|
3
|
-
color: #3F4755;
|
|
4
|
-
line-height: 22px;
|
|
5
|
-
display: flex;
|
|
6
|
-
margin-bottom: 12px;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.titaui-dynamic-publish-content__content-quoto {
|
|
10
|
-
width: 12px;
|
|
11
|
-
height: 12px;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.titaui-dynamic-publish-content__content-quoto--left {
|
|
15
|
-
margin-right: 8px;
|
|
16
|
-
margin-top: -6px;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.titaui-dynamic-publish-content__content-quoto--right {
|
|
20
|
-
margin-left: 8px;
|
|
21
|
-
margin-top: 4px;
|
|
22
|
-
}
|