@titaui/pc 1.11.40-beta.6 → 1.11.42
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/name-avatar/index.css +0 -1
- package/lib/components/avatar/name-avatar/index.js +13 -22
- package/lib/components/button/rect-btn/index.css +11 -45
- package/lib/components/button/rect-btn/index.js +6 -12
- package/lib/components/change-okr-modal/index.js +1 -2
- package/lib/components/checkbox/index.css +3 -3
- package/lib/components/create-okr-modal/index.js +41 -45
- package/lib/components/create-okr-modal/request-api.js +1 -1
- package/lib/components/dialog-confirm/index.css +2 -2
- package/lib/components/drawer/headerAction.js +1 -5
- package/lib/components/drawer/headerDrop.js +4 -42
- package/lib/components/drawer/index.css +0 -33
- package/lib/components/drawer/index.js +3 -26
- package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/dynamic-footer.js +3 -3
- package/lib/components/dynamic/new-ui.css +4 -4
- package/lib/components/dynamic/online-broadcast/data.js +1 -13
- package/lib/components/e-priority/index.css +4 -4
- package/lib/components/e-priority/index.js +10 -2
- package/lib/components/nav-top/index.js +2 -6
- package/lib/components/okr-detail/base-info/other-infos/date-cycle/index.js +4 -20
- package/lib/components/okr-detail/base-info/other-infos/principal/index.js +1 -9
- package/lib/components/okr-detail/components/header/index.js +3 -10
- package/lib/components/okr-detail/components/header/o-name.js +3 -10
- package/lib/components/okr-detail/components/o-classify.js +1 -5
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +14 -13
- package/lib/components/okr-detail/detail-header/delete-confirm/delete-confirm.js +54 -111
- package/lib/components/okr-detail/detail-header/delete-confirm/style.js +38 -0
- package/lib/components/okr-detail/detail-header/index.css +0 -11
- package/lib/components/okr-detail/detail-header/index.js +234 -228
- package/lib/components/okr-detail/index.js +4 -21
- package/lib/components/okr-detail/okr-list/index.js +3 -8
- package/lib/components/okr-detail/request-apis.js +5 -11
- package/lib/components/okr-period-selector/index.js +5 -9
- package/lib/components/okr-period-selector/select-cycle.js +19 -23
- package/lib/components/operation-records/index.js +1 -1
- package/lib/components/operation-records/style.js +1 -1
- package/lib/components/task-relation-modal/request-api.js +1 -2
- package/lib/components/task-tree/task-item-node/constant.js +13 -1
- package/lib/components/toast/index.js +3 -5
- package/lib/index.js +0 -40
- package/lib/pages/new-okr-list/header/index.css +0 -45
- package/lib/pages/new-okr-list/header/index.js +29 -51
- package/lib/pages/new-okr-list/index.js +1 -3
- package/lib/pages/new-okr-list/list/index.js +2 -19
- package/lib/pages/new-okr-list/request-api.js +2 -8
- package/lib/pages/okr-map/unsupport-ie/index.js +5 -3
- package/lib/utils/format-time.js +1 -8
- package/lib/utils/open-data.js +1 -5
- package/package.json +1 -1
- package/lib/components/okr-detail/detail-header/constant.js +0 -53
- package/lib/components/okr-detail/detail-header/delete-confirm/index.css +0 -59
- package/lib/components/okr-detail/helper.js +0 -108
- package/lib/components/textarea/index.css +0 -142
- package/lib/components/textarea/index.js +0 -259
- package/lib/pages/new-okr-list/header/common.js +0 -52
- package/lib/pages/new-okr-list/header/operate-record.js +0 -129
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.workDelete = exports.updateVisibility = exports.updateTaskStatus = exports.updateTaskPrincipal = exports.updateTaskDate = exports.updateProgressDesc = exports.updateProgress = exports.updateParentId = exports.updateOkrVisibility = exports.updateOkrPrincipal = exports.updateOkrName = exports.updateOScore = exports.updateOCommitType = exports.updateOClassify = exports.updateKrProgressAndStatus = exports.updateKrPrincipal = exports.updateKrName = exports.updateKrDate = exports.updateConfidenceIndex = exports.updateClassify = exports.updateChildOkrWeight = exports.transferPrincipal = exports.start = exports.setTaskPriority = exports.saveODesc = exports.remindAction = exports.krChangeOrder = exports.getRelWorks = exports.getRelProgress = exports.getProgress = exports.getPraiseComments = exports.getOrg = exports.getOkrUsers = exports.getOkrDetail = exports.
|
|
6
|
+
exports.workDelete = exports.updateVisibility = exports.updateTaskStatus = exports.updateTaskPrincipal = exports.updateTaskDate = exports.updateProgressDesc = exports.updateProgress = exports.updateParentId = exports.updateOkrVisibility = exports.updateOkrPrincipal = exports.updateOkrName = exports.updateOScore = exports.updateOCommitType = exports.updateOClassify = exports.updateKrProgressAndStatus = exports.updateKrPrincipal = exports.updateKrName = exports.updateKrDate = exports.updateConfidenceIndex = exports.updateClassify = exports.updateChildOkrWeight = exports.transferPrincipal = exports.start = exports.setTaskPriority = exports.saveODesc = exports.remindAction = exports.krChangeOrder = exports.getRelWorks = exports.getRelProgress = exports.getProgress = exports.getPraiseComments = exports.getOrg = exports.getOkrUsers = exports.getOkrDetail = exports.getKrsByCondition = exports.getKrs = exports.getFeedById = exports.deleteUser = exports.deleteProgressDesc = exports.deleteKr = exports.createNewKr = exports.close = exports.cancelRel = exports.cancelPraise = exports.cancelParentOkr = exports.addUserRelation = exports.addUser = exports.addPraise = exports.addComment = void 0;
|
|
7
7
|
|
|
8
8
|
var _qs = _interopRequireDefault(require("qs"));
|
|
9
9
|
|
|
@@ -89,7 +89,7 @@ exports.updateConfidenceIndex = updateConfidenceIndex;
|
|
|
89
89
|
var updateOkrName = function updateOkrName(_ref4) {
|
|
90
90
|
var workId = _ref4.workId,
|
|
91
91
|
workName = _ref4.workName;
|
|
92
|
-
return (0, _request.rpost)("
|
|
92
|
+
return (0, _request.rpost)("v2")("work/name", {
|
|
93
93
|
workId: workId,
|
|
94
94
|
workName: workName
|
|
95
95
|
});
|
|
@@ -110,12 +110,6 @@ var getOkrDetail = function getOkrDetail(_ref5) {
|
|
|
110
110
|
|
|
111
111
|
exports.getOkrDetail = getOkrDetail;
|
|
112
112
|
|
|
113
|
-
var getOkrApprovalSettingInfo = function getOkrApprovalSettingInfo() {
|
|
114
|
-
return (0, _request.rget)("v1")("WorkManageSetting/GetOkrApproval");
|
|
115
|
-
};
|
|
116
|
-
|
|
117
|
-
exports.getOkrApprovalSettingInfo = getOkrApprovalSettingInfo;
|
|
118
|
-
|
|
119
113
|
var updateClassify = function updateClassify(_ref6) {
|
|
120
114
|
var okrId = _ref6.okrId,
|
|
121
115
|
okrClassify = _ref6.okrClassify;
|
|
@@ -413,7 +407,7 @@ var deleteUser = function deleteUser(delUserId, okrId, relation) {
|
|
|
413
407
|
exports.deleteUser = deleteUser;
|
|
414
408
|
|
|
415
409
|
var workDelete = function workDelete(data) {
|
|
416
|
-
return (0, _request.rdelete)("
|
|
410
|
+
return (0, _request.rdelete)("v2")("work/deleteV2?workId=".concat(data.workId), {
|
|
417
411
|
data: data
|
|
418
412
|
});
|
|
419
413
|
};
|
|
@@ -421,7 +415,7 @@ var workDelete = function workDelete(data) {
|
|
|
421
415
|
exports.workDelete = workDelete;
|
|
422
416
|
|
|
423
417
|
var start = function start(okrId) {
|
|
424
|
-
return (0, _request.rpost)("v1")("
|
|
418
|
+
return (0, _request.rpost)("v1")("Work/Start", {
|
|
425
419
|
work_id: okrId
|
|
426
420
|
}, {
|
|
427
421
|
headers: {
|
|
@@ -434,7 +428,7 @@ var start = function start(okrId) {
|
|
|
434
428
|
exports.start = start;
|
|
435
429
|
|
|
436
430
|
var close = function close(okrId) {
|
|
437
|
-
return (0, _request.rpost)("v1")("
|
|
431
|
+
return (0, _request.rpost)("v1")("Work/Close", {
|
|
438
432
|
work_id: okrId
|
|
439
433
|
}, {
|
|
440
434
|
headers: {
|
|
@@ -17,8 +17,6 @@ var _selectCycle = _interopRequireDefault(require("./select-cycle"));
|
|
|
17
17
|
|
|
18
18
|
var _requestApis = require("./request-apis");
|
|
19
19
|
|
|
20
|
-
var _getLocale = require("../../utils/getLocale");
|
|
21
|
-
|
|
22
20
|
require("./index.css");
|
|
23
21
|
|
|
24
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -70,14 +68,12 @@ function _default(props) {
|
|
|
70
68
|
}, []);
|
|
71
69
|
|
|
72
70
|
var handleChangeCyecle = function handleChangeCyecle(data) {
|
|
73
|
-
(0, _requestApis.updateOCyecle)(okrId, data).then(function (
|
|
74
|
-
|
|
75
|
-
|
|
71
|
+
(0, _requestApis.updateOCyecle)(okrId, data).then(function () {
|
|
72
|
+
_toast["default"].Success("修改成功", {
|
|
73
|
+
canClose: false
|
|
74
|
+
});
|
|
76
75
|
|
|
77
|
-
|
|
78
|
-
} else {
|
|
79
|
-
_toast["default"].Error(resp.Message);
|
|
80
|
-
}
|
|
76
|
+
setCycle(data);
|
|
81
77
|
});
|
|
82
78
|
};
|
|
83
79
|
|
|
@@ -49,7 +49,7 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
49
49
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
50
50
|
|
|
51
51
|
function _formatCycleData(periodParams, getCycleRange) {
|
|
52
|
-
if (!periodParams) return
|
|
52
|
+
if (!periodParams) return "";
|
|
53
53
|
var startDate = periodParams.startDate;
|
|
54
54
|
var endDate = periodParams.endDate;
|
|
55
55
|
|
|
@@ -58,7 +58,7 @@ function _formatCycleData(periodParams, getCycleRange) {
|
|
|
58
58
|
endDate = periodParams.endDate.slice(5);
|
|
59
59
|
}
|
|
60
60
|
|
|
61
|
-
return "".concat(_periodSelector["default"].formatPeriod(periodParams)).concat(getCycleRange ? ",".concat(startDate, "~").concat(endDate) :
|
|
61
|
+
return "".concat(_periodSelector["default"].formatPeriod(periodParams)).concat(getCycleRange ? ",".concat(startDate, "~").concat(endDate) : "");
|
|
62
62
|
}
|
|
63
63
|
|
|
64
64
|
function CreateCycle(_ref) {
|
|
@@ -94,21 +94,21 @@ function CreateCycle(_ref) {
|
|
|
94
94
|
setCycleSetting = _useState4[1];
|
|
95
95
|
|
|
96
96
|
(0, _react.useEffect)(function () {
|
|
97
|
-
var settings = localStorage.getItem(
|
|
97
|
+
var settings = localStorage.getItem("OKR_CYCLE_SETTING");
|
|
98
98
|
|
|
99
99
|
if (settings) {
|
|
100
100
|
setCycleSetting(JSON.parse(settings));
|
|
101
101
|
return;
|
|
102
102
|
}
|
|
103
103
|
|
|
104
|
-
var url = (0, _helper.getApiUrl)(
|
|
105
|
-
(0, _helper.taker)(url,
|
|
104
|
+
var url = (0, _helper.getApiUrl)("okr/cycleSetting");
|
|
105
|
+
(0, _helper.taker)(url, "GET").then(function (res) {
|
|
106
106
|
if (res.Code == 1) {
|
|
107
107
|
setCycleSetting(res.Data);
|
|
108
108
|
}
|
|
109
109
|
});
|
|
110
110
|
}, []);
|
|
111
|
-
var cycleWrapperRef = (0, _react.useRef)(document.createElement(
|
|
111
|
+
var cycleWrapperRef = (0, _react.useRef)(document.createElement("div"));
|
|
112
112
|
|
|
113
113
|
var onPeriodSelectorChangeHandler = function onPeriodSelectorChangeHandler(c) {
|
|
114
114
|
setSelfCycle(_objectSpread(_objectSpread({}, selfCycle), c));
|
|
@@ -148,13 +148,13 @@ function CreateCycle(_ref) {
|
|
|
148
148
|
},
|
|
149
149
|
ref: cycleWrapperRef,
|
|
150
150
|
style: {
|
|
151
|
-
backgroundColor:
|
|
152
|
-
boxShadow:
|
|
151
|
+
backgroundColor: "white",
|
|
152
|
+
boxShadow: "0px 4px 12px 0px rgb(127 145 180 / 20%)",
|
|
153
153
|
borderRadius: 4
|
|
154
154
|
}
|
|
155
155
|
}, /*#__PURE__*/_react["default"].createElement(_periodSelector["default"], {
|
|
156
156
|
style: {
|
|
157
|
-
width:
|
|
157
|
+
width: "100%"
|
|
158
158
|
},
|
|
159
159
|
selected: selfCycle,
|
|
160
160
|
showFullCycle: false,
|
|
@@ -176,9 +176,9 @@ function CreateCycle(_ref) {
|
|
|
176
176
|
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
177
177
|
className: "okr-detail-date-cycle__date-line",
|
|
178
178
|
style: {
|
|
179
|
-
borderBottom:
|
|
179
|
+
borderBottom: "1px solid #F0F2F5"
|
|
180
180
|
}
|
|
181
|
-
}, (0, _getLocale.getLocale)(
|
|
181
|
+
}, (0, _getLocale.getLocale)("Mod_StartDate"), "\uFF1A", /*#__PURE__*/_react["default"].createElement(_rangePickerPop["default"], {
|
|
182
182
|
format: "YYYY/MM/DD",
|
|
183
183
|
controlled: true,
|
|
184
184
|
onConfirm: onStartDateConfirmHandler,
|
|
@@ -193,7 +193,7 @@ function CreateCycle(_ref) {
|
|
|
193
193
|
className: "tu-icon-arrow-down okr-detail-date-cycle__select-time-down-icon"
|
|
194
194
|
})))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
195
195
|
className: "okr-detail-date-cycle__date-line"
|
|
196
|
-
}, (0, _getLocale.getLocale)(
|
|
196
|
+
}, (0, _getLocale.getLocale)("Mod_EndDate"), "\uFF1A", /*#__PURE__*/_react["default"].createElement(_rangePickerPop["default"], {
|
|
197
197
|
format: "YYYY/MM/DD",
|
|
198
198
|
controlled: true,
|
|
199
199
|
onConfirm: onEndDateCOnfirmHandler,
|
|
@@ -208,8 +208,8 @@ function CreateCycle(_ref) {
|
|
|
208
208
|
className: "tu-icon-arrow-down okr-detail-date-cycle__select-time-down-icon"
|
|
209
209
|
})))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
210
210
|
style: {
|
|
211
|
-
display:
|
|
212
|
-
justifyContent:
|
|
211
|
+
display: "flex",
|
|
212
|
+
justifyContent: "flex-end"
|
|
213
213
|
}
|
|
214
214
|
}, /*#__PURE__*/_react["default"].createElement(_titaUi.Button, {
|
|
215
215
|
size: "s",
|
|
@@ -217,15 +217,15 @@ function CreateCycle(_ref) {
|
|
|
217
217
|
marginRight: 12
|
|
218
218
|
},
|
|
219
219
|
onClick: onCancelClickHandler
|
|
220
|
-
}, (0, _getLocale.getLocale)(
|
|
220
|
+
}, (0, _getLocale.getLocale)("Mod_Cancel")), /*#__PURE__*/_react["default"].createElement(_titaUi.Button, {
|
|
221
221
|
size: "s",
|
|
222
222
|
type: "primary",
|
|
223
223
|
onClick: onSureClickHandler
|
|
224
|
-
}, (0, _getLocale.getLocale)(
|
|
224
|
+
}, (0, _getLocale.getLocale)("OKR_MyO_Butt_Determine"))));
|
|
225
225
|
} else {
|
|
226
|
-
return
|
|
226
|
+
return /*#__PURE__*/_react["default"].createElement(_periodSelector["default"], {
|
|
227
227
|
style: {
|
|
228
|
-
width:
|
|
228
|
+
width: "100%"
|
|
229
229
|
},
|
|
230
230
|
selected: cycle,
|
|
231
231
|
showFullCycle: false,
|
|
@@ -245,11 +245,7 @@ function CreateCycle(_ref) {
|
|
|
245
245
|
btnRef: btnRef,
|
|
246
246
|
clickCallback: function clickCallback() {},
|
|
247
247
|
text: _formatCycleData(cycle, getCycleRange)
|
|
248
|
-
}))
|
|
249
|
-
btnRef: btnRef,
|
|
250
|
-
clickCallback: function clickCallback() {},
|
|
251
|
-
text: _formatCycleData(cycle, getCycleRange)
|
|
252
|
-
});
|
|
248
|
+
}));
|
|
253
249
|
}
|
|
254
250
|
}
|
|
255
251
|
|
|
@@ -80,7 +80,7 @@ var OperationRecord = /*#__PURE__*/function (_PureComponent) {
|
|
|
80
80
|
|
|
81
81
|
_this.setState({
|
|
82
82
|
operationTrackList: newOperationTrackList,
|
|
83
|
-
operationTrackTotal:
|
|
83
|
+
operationTrackTotal: _mockData.OperationData.length
|
|
84
84
|
});
|
|
85
85
|
}
|
|
86
86
|
});
|
|
@@ -17,7 +17,7 @@ var OperationRecordWrapper = _styledComponents["default"].div(_templateObject ||
|
|
|
17
17
|
|
|
18
18
|
exports.OperationRecordWrapper = OperationRecordWrapper;
|
|
19
19
|
|
|
20
|
-
var OperationRecordTotal = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n margin-bottom:
|
|
20
|
+
var OperationRecordTotal = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n margin-bottom: 8px;\n font-size: 12px;\n color: #8f9ca6;\n display: inline-block;\n cursor: pointer;\n\n &:hover {\n color: #2879ff;\n }\n\n p {\n line-height: 17px;\n\n &::before {\n float: right;\n margin-left: 4px;\n }\n }\n"])));
|
|
21
21
|
|
|
22
22
|
exports.OperationRecordTotal = OperationRecordTotal;
|
|
23
23
|
|
|
@@ -15,8 +15,7 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
15
15
|
|
|
16
16
|
var okrSearch = function okrSearch(params) {
|
|
17
17
|
return (0, _request.rpost)("v1")("okr/search", _objectSpread(_objectSpread({}, params), {}, {
|
|
18
|
-
orderType: 1
|
|
19
|
-
includeCreateFailApprovalOkr: false
|
|
18
|
+
orderType: 1
|
|
20
19
|
})).then(function (res) {
|
|
21
20
|
return res.Data;
|
|
22
21
|
});
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.TASK_NDOE_TYPE = exports.EStatusStatus2ClassType = exports.EStatusClass2StatusTypeText = exports.EStatusClass2StatusType = void 0;
|
|
6
|
+
exports.getPriorityTextMapping = exports.TASK_NDOE_TYPE = exports.EStatusStatus2ClassType = exports.EStatusClass2StatusTypeText = exports.EStatusClass2StatusType = void 0;
|
|
7
7
|
|
|
8
8
|
var _getLocale = require("../../../utils/getLocale");
|
|
9
9
|
|
|
@@ -41,6 +41,18 @@ var EStatusClass2StatusTypeText = function EStatusClass2StatusTypeText() {
|
|
|
41
41
|
};
|
|
42
42
|
|
|
43
43
|
exports.EStatusClass2StatusTypeText = EStatusClass2StatusTypeText;
|
|
44
|
+
|
|
45
|
+
var getPriorityTextMapping = function getPriorityTextMapping() {
|
|
46
|
+
return {
|
|
47
|
+
1: "".concat((0, _getLocale.getLocale)("OKR_MyO_E_Priority"), "\uFF1A").concat((0, _getLocale.getLocale)("OKR_MyO_E_Butt_Highest")),
|
|
48
|
+
2: "".concat((0, _getLocale.getLocale)("OKR_MyO_E_Priority"), "\uFF1A").concat((0, _getLocale.getLocale)("OKR_MyO_E_Butt_High")),
|
|
49
|
+
3: "".concat((0, _getLocale.getLocale)("OKR_MyO_E_Priority"), "\uFF1A").concat((0, _getLocale.getLocale)("OKR_MyO_E_Butt_Middle")),
|
|
50
|
+
4: "".concat((0, _getLocale.getLocale)("OKR_MyO_E_Priority"), "\uFF1A").concat((0, _getLocale.getLocale)("OKR_MyO_E_Butt_Low")),
|
|
51
|
+
5: "".concat((0, _getLocale.getLocale)("OKR_MyO_E_Priority"), "\uFF1A").concat((0, _getLocale.getLocale)("OKR_MyO_E_Butt_Verylow"))
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
exports.getPriorityTextMapping = getPriorityTextMapping;
|
|
44
56
|
var TASK_NDOE_TYPE;
|
|
45
57
|
exports.TASK_NDOE_TYPE = TASK_NDOE_TYPE;
|
|
46
58
|
|
|
@@ -168,7 +168,6 @@ var Toast = /*#__PURE__*/function () {
|
|
|
168
168
|
var options,
|
|
169
169
|
key,
|
|
170
170
|
ins,
|
|
171
|
-
canClose,
|
|
172
171
|
_args3 = arguments;
|
|
173
172
|
return regeneratorRuntime.wrap(function _callee3$(_context3) {
|
|
174
173
|
while (1) {
|
|
@@ -181,15 +180,14 @@ var Toast = /*#__PURE__*/function () {
|
|
|
181
180
|
|
|
182
181
|
case 4:
|
|
183
182
|
ins = _context3.sent;
|
|
184
|
-
canClose = options.canClose !== undefined ? options.canClose : false;
|
|
185
183
|
ins.notice({
|
|
186
|
-
content: (0, _SuccessRender.RenderError)(msg, key, canClose, ins),
|
|
184
|
+
content: (0, _SuccessRender.RenderError)(msg, key, options.canClose, ins),
|
|
187
185
|
style: options.style,
|
|
188
|
-
duration: options.duration || canClose === false ? 3 : 3000,
|
|
186
|
+
duration: options.duration || options.canClose === false ? 3 : 3000,
|
|
189
187
|
key: key
|
|
190
188
|
});
|
|
191
189
|
|
|
192
|
-
case
|
|
190
|
+
case 6:
|
|
193
191
|
case "end":
|
|
194
192
|
return _context3.stop();
|
|
195
193
|
}
|
package/lib/index.js
CHANGED
|
@@ -51,12 +51,6 @@ Object.defineProperty(exports, "Communication", {
|
|
|
51
51
|
return _communication["default"];
|
|
52
52
|
}
|
|
53
53
|
});
|
|
54
|
-
Object.defineProperty(exports, "ConditionRender", {
|
|
55
|
-
enumerable: true,
|
|
56
|
-
get: function get() {
|
|
57
|
-
return _conditionRender["default"];
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
54
|
Object.defineProperty(exports, "Confidence", {
|
|
61
55
|
enumerable: true,
|
|
62
56
|
get: function get() {
|
|
@@ -69,12 +63,6 @@ Object.defineProperty(exports, "CreateOkrModal", {
|
|
|
69
63
|
return _createOkrModal["default"];
|
|
70
64
|
}
|
|
71
65
|
});
|
|
72
|
-
Object.defineProperty(exports, "DangerousHtml", {
|
|
73
|
-
enumerable: true,
|
|
74
|
-
get: function get() {
|
|
75
|
-
return _dangerousHtml["default"];
|
|
76
|
-
}
|
|
77
|
-
});
|
|
78
66
|
Object.defineProperty(exports, "DatePicker", {
|
|
79
67
|
enumerable: true,
|
|
80
68
|
get: function get() {
|
|
@@ -171,12 +159,6 @@ Object.defineProperty(exports, "Form", {
|
|
|
171
159
|
return _form["default"];
|
|
172
160
|
}
|
|
173
161
|
});
|
|
174
|
-
Object.defineProperty(exports, "FormatTime", {
|
|
175
|
-
enumerable: true,
|
|
176
|
-
get: function get() {
|
|
177
|
-
return _formatTime["default"];
|
|
178
|
-
}
|
|
179
|
-
});
|
|
180
162
|
Object.defineProperty(exports, "GridLayout", {
|
|
181
163
|
enumerable: true,
|
|
182
164
|
get: function get() {
|
|
@@ -393,12 +375,6 @@ Object.defineProperty(exports, "Progress", {
|
|
|
393
375
|
return _progress["default"];
|
|
394
376
|
}
|
|
395
377
|
});
|
|
396
|
-
Object.defineProperty(exports, "PublishDynamicModal", {
|
|
397
|
-
enumerable: true,
|
|
398
|
-
get: function get() {
|
|
399
|
-
return _publishDynamicModal["default"];
|
|
400
|
-
}
|
|
401
|
-
});
|
|
402
378
|
Object.defineProperty(exports, "Radio", {
|
|
403
379
|
enumerable: true,
|
|
404
380
|
get: function get() {
|
|
@@ -501,12 +477,6 @@ Object.defineProperty(exports, "TaskRelationModal", {
|
|
|
501
477
|
return _taskRelationModal["default"];
|
|
502
478
|
}
|
|
503
479
|
});
|
|
504
|
-
Object.defineProperty(exports, "Textarea", {
|
|
505
|
-
enumerable: true,
|
|
506
|
-
get: function get() {
|
|
507
|
-
return _textarea["default"];
|
|
508
|
-
}
|
|
509
|
-
});
|
|
510
480
|
Object.defineProperty(exports, "TitaChart", {
|
|
511
481
|
enumerable: true,
|
|
512
482
|
get: function get() {
|
|
@@ -632,8 +602,6 @@ var _button = _interopRequireDefault(require("./components/button"));
|
|
|
632
602
|
|
|
633
603
|
var _bookDemo = _interopRequireDefault(require("./components/book-demo"));
|
|
634
604
|
|
|
635
|
-
var _conditionRender = _interopRequireDefault(require("./components/condition-render"));
|
|
636
|
-
|
|
637
605
|
var _confidence = _interopRequireDefault(require("./components/confidence"));
|
|
638
606
|
|
|
639
607
|
var _communication = _interopRequireDefault(require("./components/communication"));
|
|
@@ -648,8 +616,6 @@ var _createOkrModal = _interopRequireDefault(require("./components/create-okr-mo
|
|
|
648
616
|
|
|
649
617
|
var _dialog = _interopRequireDefault(require("./components/dialog"));
|
|
650
618
|
|
|
651
|
-
var _dangerousHtml = _interopRequireDefault(require("./components/dangerous-html"));
|
|
652
|
-
|
|
653
619
|
var _datePicker = _interopRequireDefault(require("./components/date-picker"));
|
|
654
620
|
|
|
655
621
|
var _demoFree = _interopRequireDefault(require("./pages/demo-free"));
|
|
@@ -676,8 +642,6 @@ var _errorBoundary = _interopRequireDefault(require("./components/error-boundary
|
|
|
676
642
|
|
|
677
643
|
var _errorLevel = _interopRequireDefault(require("./utils/error-level"));
|
|
678
644
|
|
|
679
|
-
var _formatTime = _interopRequireDefault(require("./utils/format-time"));
|
|
680
|
-
|
|
681
645
|
var _fileList = _interopRequireDefault(require("./components/file-list"));
|
|
682
646
|
|
|
683
647
|
var _firework = _interopRequireDefault(require("./components/firework"));
|
|
@@ -750,8 +714,6 @@ var _periodSelector = _interopRequireDefault(require("./components/period-select
|
|
|
750
714
|
|
|
751
715
|
var _pagination = _interopRequireDefault(require("./components/pagination"));
|
|
752
716
|
|
|
753
|
-
var _publishDynamicModal = _interopRequireDefault(require("./components/publish-dynamic-modal"));
|
|
754
|
-
|
|
755
717
|
var _passwordInput = _interopRequireDefault(require("./components/password-input"));
|
|
756
718
|
|
|
757
719
|
var _photoCard = _interopRequireDefault(require("./components/photo-card"));
|
|
@@ -806,8 +768,6 @@ var _titaChart = _interopRequireDefault(require("./components/tita-chart"));
|
|
|
806
768
|
|
|
807
769
|
var _tooltip = _interopRequireDefault(require("./components/tooltip"));
|
|
808
770
|
|
|
809
|
-
var _textarea = _interopRequireDefault(require("./components/textarea"));
|
|
810
|
-
|
|
811
771
|
var _tooltipText = _interopRequireDefault(require("./components/tooltip/tooltip-text"));
|
|
812
772
|
|
|
813
773
|
var _userSelector = _interopRequireDefault(require("./components/user-selector"));
|
|
@@ -36,51 +36,6 @@
|
|
|
36
36
|
color: #2879ff;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
.tita-okr-list-v2__header-record {
|
|
40
|
-
display: flex;
|
|
41
|
-
box-sizing: border-box;
|
|
42
|
-
justify-content: center;
|
|
43
|
-
align-items: center;
|
|
44
|
-
transform: rotate(90deg);
|
|
45
|
-
background: #fff;
|
|
46
|
-
box-shadow: 0px 0px 8px 0px rgba(127, 145, 180, 0.1);
|
|
47
|
-
width: 36px;
|
|
48
|
-
height: 36px;
|
|
49
|
-
margin-left: 12px;
|
|
50
|
-
border-radius: 18px;
|
|
51
|
-
font-size: 20px;
|
|
52
|
-
cursor: pointer;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.tita-okr-list-v2__header-record-popup {
|
|
56
|
-
padding: 16px 12px;
|
|
57
|
-
box-sizing: border-box;
|
|
58
|
-
background: #ffffff;
|
|
59
|
-
box-shadow: 0px 4px 12px 0px rgba(127, 145, 180, 0.2);
|
|
60
|
-
border-radius: 12px;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.tita-okr-list-v2__header-record-item {
|
|
64
|
-
display: flex;
|
|
65
|
-
align-items: center;
|
|
66
|
-
padding: 5px 8px;
|
|
67
|
-
box-sizing: border-box;
|
|
68
|
-
font-size: 14px;
|
|
69
|
-
color: #3f4755;
|
|
70
|
-
line-height: 22px;
|
|
71
|
-
cursor: pointer;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.tita-okr-list-v2__header-record-item:hover {
|
|
75
|
-
color: #2879ff;
|
|
76
|
-
background: #f7f8fa;
|
|
77
|
-
border-radius: 8px;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.tita-okr-list-v2__header-record-item-content {
|
|
81
|
-
margin-left: 8px;
|
|
82
|
-
}
|
|
83
|
-
|
|
84
39
|
.tita-okr-list-v2__header-filter {
|
|
85
40
|
box-sizing: border-box;
|
|
86
41
|
height: 36px;
|
|
@@ -29,8 +29,6 @@ var _filter = _interopRequireDefault(require("./filter"));
|
|
|
29
29
|
|
|
30
30
|
var _comments = _interopRequireDefault(require("./comments"));
|
|
31
31
|
|
|
32
|
-
var _operateRecord = _interopRequireDefault(require("./operate-record"));
|
|
33
|
-
|
|
34
32
|
var _context = require("../context");
|
|
35
33
|
|
|
36
34
|
var _requestApi = require("../request-api");
|
|
@@ -67,7 +65,6 @@ function Header(props, ref) {
|
|
|
67
65
|
cycleType = _useContext.cycleType,
|
|
68
66
|
yqmNum = _useContext.yqmNum;
|
|
69
67
|
|
|
70
|
-
var relationShip = parseInt(relation, 10);
|
|
71
68
|
var onSearch = props.onSearch,
|
|
72
69
|
onFrontAddOKR = props.onFrontAddOKR;
|
|
73
70
|
|
|
@@ -87,26 +84,21 @@ function Header(props, ref) {
|
|
|
87
84
|
setUserInfo = _useState6[1];
|
|
88
85
|
|
|
89
86
|
(0, _react.useEffect)(function () {
|
|
90
|
-
if (toUserId !== undefined ||
|
|
87
|
+
if (toUserId !== undefined || relation == 1) {
|
|
91
88
|
var userId = toUserId;
|
|
92
|
-
if (
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
setUserInfo(res.Data);
|
|
97
|
-
});
|
|
98
|
-
}
|
|
89
|
+
if (relation == 1) userId = (0, _bsGlobal.getUserInfo)().Id;
|
|
90
|
+
userId && (0, _requestApi.getUserInfoById)(userId).then(function (res) {
|
|
91
|
+
setUserInfo(res.Data);
|
|
92
|
+
});
|
|
99
93
|
}
|
|
100
94
|
}, [toUserId, relation]);
|
|
101
95
|
(0, _react.useEffect)(function () {
|
|
102
96
|
setInit(true);
|
|
103
97
|
}, []);
|
|
104
98
|
(0, _react.useEffect)(function () {
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
});
|
|
109
|
-
}
|
|
99
|
+
init && onSearch({
|
|
100
|
+
onlyThisDept: onlyThisDept
|
|
101
|
+
});
|
|
110
102
|
}, [onlyThisDept]);
|
|
111
103
|
var createOkrRef = (0, _react.useRef)();
|
|
112
104
|
(0, _react.useImperativeHandle)(ref, function () {
|
|
@@ -124,56 +116,56 @@ function Header(props, ref) {
|
|
|
124
116
|
var rootNode = {
|
|
125
117
|
rootId: 0,
|
|
126
118
|
// @ts-ignore
|
|
127
|
-
rootName: window.BSGlobal.tenantInfo.Name ||
|
|
119
|
+
rootName: window.BSGlobal.tenantInfo.Name || ""
|
|
128
120
|
};
|
|
129
121
|
var level2Selected = {
|
|
130
122
|
id: 0,
|
|
131
123
|
// @ts-ignore
|
|
132
|
-
name: window.BSGlobal.tenantInfo.Name ||
|
|
124
|
+
name: window.BSGlobal.tenantInfo.Name || ""
|
|
133
125
|
};
|
|
134
|
-
var searchType =
|
|
126
|
+
var searchType = "company";
|
|
135
127
|
|
|
136
|
-
if (departmentId && departmentId
|
|
128
|
+
if (departmentId && departmentId != -1) {
|
|
137
129
|
rootNode.rootId = departmentId;
|
|
138
|
-
rootNode.rootName = departmentName ||
|
|
139
|
-
searchType =
|
|
130
|
+
rootNode.rootName = departmentName || "";
|
|
131
|
+
searchType = "depart";
|
|
140
132
|
level2Selected.id = departmentId;
|
|
141
|
-
level2Selected.name = departmentName ||
|
|
133
|
+
level2Selected.name = departmentName || "";
|
|
142
134
|
}
|
|
143
135
|
|
|
144
136
|
if (toUserId) {
|
|
145
137
|
rootNode.rootId = toUserId;
|
|
146
|
-
rootNode.rootName = userInfo.name ||
|
|
147
|
-
searchType =
|
|
138
|
+
rootNode.rootName = userInfo.name || "";
|
|
139
|
+
searchType = "user";
|
|
148
140
|
level2Selected.id = toUserId;
|
|
149
|
-
level2Selected.name = userInfo.name ||
|
|
141
|
+
level2Selected.name = userInfo.name || "";
|
|
150
142
|
}
|
|
151
143
|
|
|
152
|
-
if (
|
|
144
|
+
if (relation == 1) {
|
|
153
145
|
rootNode.rootId = (0, _bsGlobal.getUserInfo)().Id;
|
|
154
|
-
rootNode.rootName = (0, _bsGlobal.getUserInfo)().Name ||
|
|
155
|
-
searchType =
|
|
146
|
+
rootNode.rootName = (0, _bsGlobal.getUserInfo)().Name || "";
|
|
147
|
+
searchType = "user";
|
|
156
148
|
level2Selected.id = (0, _bsGlobal.getUserInfo)().Id;
|
|
157
|
-
level2Selected.name = (0, _bsGlobal.getUserInfo)().Name ||
|
|
149
|
+
level2Selected.name = (0, _bsGlobal.getUserInfo)().Name || "";
|
|
158
150
|
}
|
|
159
151
|
|
|
160
152
|
var urlQuery = ["searchType=".concat(searchType), "period=".concat(JSON.stringify({
|
|
161
153
|
cycleType: cycleType,
|
|
162
154
|
annualNum: annualNum,
|
|
163
155
|
yqmNum: yqmNum
|
|
164
|
-
})), "rootNode=".concat(JSON.stringify(rootNode)), "level2Selected=".concat(JSON.stringify(level2Selected))].join(
|
|
156
|
+
})), "rootNode=".concat(JSON.stringify(rootNode)), "level2Selected=".concat(JSON.stringify(level2Selected))].join("&");
|
|
165
157
|
var origin = window.location.href.split('#')[0];
|
|
166
158
|
window.location.href = "".concat(origin, "/#okr/map?").concat(urlQuery);
|
|
167
159
|
};
|
|
168
160
|
|
|
169
161
|
var getTitle = function getTitle() {
|
|
170
|
-
if (
|
|
162
|
+
if (relation == 1) {
|
|
171
163
|
return /*#__PURE__*/_react["default"].createElement(_userTitle["default"], {
|
|
172
164
|
toUserId: (0, _bsGlobal.getUserInfo)().Id
|
|
173
165
|
});
|
|
174
166
|
}
|
|
175
167
|
|
|
176
|
-
if (
|
|
168
|
+
if (relation == 2 || relation == 3) {
|
|
177
169
|
return /*#__PURE__*/_react["default"].createElement(_relationTitle["default"], {
|
|
178
170
|
relation: relation
|
|
179
171
|
});
|
|
@@ -205,11 +197,11 @@ function Header(props, ref) {
|
|
|
205
197
|
className: "".concat(_precls.precls, "__header-item")
|
|
206
198
|
}, getTitle())), /*#__PURE__*/_react["default"].createElement("div", {
|
|
207
199
|
className: "".concat(_precls.precls, "__header-right")
|
|
208
|
-
},
|
|
200
|
+
}, departmentId == 0 && /*#__PURE__*/_react["default"].createElement("div", {
|
|
209
201
|
className: "".concat(_precls.precls, "__header-item")
|
|
210
202
|
}, /*#__PURE__*/_react["default"].createElement(_keywordSearch["default"], {
|
|
211
203
|
onSearch: onSearch
|
|
212
|
-
})),
|
|
204
|
+
})), relation != 2 && relation != 3 &&
|
|
213
205
|
/*#__PURE__*/
|
|
214
206
|
// 我关注的 我参与的 没有创建按钮
|
|
215
207
|
_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -221,7 +213,7 @@ function Header(props, ref) {
|
|
|
221
213
|
className: "".concat(_precls.precls, "__header-item"),
|
|
222
214
|
onClick: gotoOkrMap
|
|
223
215
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"], {
|
|
224
|
-
overlay: (0, _getLocale.getLocale)(
|
|
216
|
+
overlay: (0, _getLocale.getLocale)("OKR_MyO_Text_Alignment"),
|
|
225
217
|
placement: "top"
|
|
226
218
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
227
219
|
className: "".concat(_precls.precls, "__header-icon")
|
|
@@ -229,24 +221,10 @@ function Header(props, ref) {
|
|
|
229
221
|
className: "tu-icon-yangshi-ditu"
|
|
230
222
|
}))))), /*#__PURE__*/_react["default"].createElement(_comments["default"], {
|
|
231
223
|
toUserId: toUserId,
|
|
232
|
-
relation:
|
|
224
|
+
relation: relation,
|
|
233
225
|
userInfo: userInfo
|
|
234
226
|
}), /*#__PURE__*/_react["default"].createElement(_filter["default"], {
|
|
235
227
|
onSearch: onSearch
|
|
236
|
-
}), Number(cycleType) !== -1 && /*#__PURE__*/_react["default"].createElement(_operateRecord["default"], {
|
|
237
|
-
toUserId: toUserId,
|
|
238
|
-
userInfo: userInfo,
|
|
239
|
-
relation: relationShip,
|
|
240
|
-
okrFeedParams: {
|
|
241
|
-
objId: departmentId === undefined ? Number(toUserId || (0, _bsGlobal.getUserInfo)().Id) : Number(departmentId),
|
|
242
|
-
// 人员或部门Id
|
|
243
|
-
objType: departmentId === undefined ? 1 : 2,
|
|
244
|
-
// 1:负责人,2:部门
|
|
245
|
-
cycleType: Number(cycleType),
|
|
246
|
-
// 目标周期:0-自定义,1-年度,2-季度,3-月度
|
|
247
|
-
yqmNum: Number(yqmNum),
|
|
248
|
-
annualNum: Number(annualNum)
|
|
249
|
-
}
|
|
250
228
|
})));
|
|
251
229
|
}
|
|
252
230
|
|
|
@@ -85,8 +85,7 @@ var NewOkrList = function NewOkrList(props) {
|
|
|
85
85
|
var OkrListCmp = props.OkrListCmp,
|
|
86
86
|
OkrCommunicationPush = props.OkrCommunicationPush,
|
|
87
87
|
Empty = props.Empty,
|
|
88
|
-
SetCycleModal = props.SetCycleModal
|
|
89
|
-
OkrOperateRecordDrawer = props.OkrOperateRecordDrawer;
|
|
88
|
+
SetCycleModal = props.SetCycleModal;
|
|
90
89
|
var useLocalStorage = new _localStorage.LocalStorage();
|
|
91
90
|
var formFieldValues = useLocalStorage.getItem("okr-filter-values") || {
|
|
92
91
|
targetType: "",
|
|
@@ -317,7 +316,6 @@ var NewOkrList = function NewOkrList(props) {
|
|
|
317
316
|
return /*#__PURE__*/_react["default"].createElement(_context.Context.Provider, {
|
|
318
317
|
value: _objectSpread({
|
|
319
318
|
OkrCommunicationPush: OkrCommunicationPush,
|
|
320
|
-
OkrOperateRecordDrawer: OkrOperateRecordDrawer,
|
|
321
319
|
relation: relation,
|
|
322
320
|
departmentName: departmentName,
|
|
323
321
|
departmentId: departmentId,
|