@titaui/pc 1.12.7-beta.1 → 1.12.7-beta.10
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/color-date-picker/index.css +65 -0
- package/lib/components/color-date-picker/index.js +123 -0
- package/lib/components/color-date-picker/interface.js +14 -0
- package/lib/components/dialog-upload/uploaded-preview.js +1 -1
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/encourage.js +7 -7
- package/lib/components/dynamic/dynamic-item/components/comments-dialog/index.js +23 -17
- package/lib/components/dynamic/dynamic-item/components/okr-progress/index.js +2 -1
- package/lib/components/dynamic/dynamic-item/components/summary-header/constant.js +45 -0
- package/lib/components/dynamic/dynamic-item/components/summary-header/index.js +47 -14
- package/lib/components/dynamic/dynamic-item/components/task-progress/index.js +2 -1
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/remind-user-view/index.js +2 -1
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/constant.js +45 -0
- package/lib/components/dynamic/dynamic-item/dynamic-new-report/index.js +40 -16
- package/lib/components/dynamic/dynamic-item/index.js +15 -5
- package/lib/components/import-modal/import-okr-modal/index.js +4 -1
- package/lib/components/menus/components/menu-tree/tree-node/subordinates.js +7 -3
- package/lib/components/menus/components/menu-tree/tree-node/summary-share.js +7 -3
- package/lib/components/menus/export-modules/summary-menus/depart-menus/index.js +59 -29
- package/lib/components/menus/export-modules/summary-menus/menus.js +56 -50
- package/lib/components/menus/request-apis.js +8 -2
- package/lib/components/new-confidence/index.js +5 -5
- package/lib/components/picker/components/panels/week-panel/utils.js +45 -0
- package/lib/components/picker/components/panels/week-panel/week-body.js +9 -56
- package/lib/components/picker/components/picker-trigger/index.js +2 -3
- package/lib/components/rate/index.js +0 -2
- package/lib/components/regulation-setting-item/index.css +33 -0
- package/lib/components/regulation-setting-item/index.js +37 -0
- package/lib/components/rich-editor-upload/index.js +3 -0
- package/lib/components/write-summary-modal/index.css +79 -0
- package/lib/components/write-summary-modal/index.js +151 -0
- package/lib/components/write-summary-modal/interface.js +19 -0
- package/lib/components/write-summary-modal/request-api.js +18 -0
- package/lib/components/write-summary-modal/utils.js +31 -0
- package/lib/index.js +16 -0
- package/lib/utils/constant.js +8 -2
- package/lib/utils/helpers.js +48 -11
- package/package.json +1 -1
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
.tita-ui-color-date-picker {
|
|
2
|
+
display: grid;
|
|
3
|
+
background: #ffffff;
|
|
4
|
+
text-align: center;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.tita-ui-color-date-picker__week-title {
|
|
8
|
+
font-size: 12px;
|
|
9
|
+
color: #89919f;
|
|
10
|
+
line-height: 18px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.tita-ui-color-date-picker__content {
|
|
14
|
+
display: flex;
|
|
15
|
+
align-items: center;
|
|
16
|
+
justify-content: center;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.tita-ui-color-date-picker__content-daily {
|
|
20
|
+
display: flex;
|
|
21
|
+
align-items: center;
|
|
22
|
+
justify-content: center;
|
|
23
|
+
cursor: pointer;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.tita-ui-color-date-picker__content-daily-text {
|
|
27
|
+
width: 24px;
|
|
28
|
+
height: 24px;
|
|
29
|
+
border-radius: 8px;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.tita-ui-color-date-picker__content-weekly {
|
|
33
|
+
height: 36px;
|
|
34
|
+
border-radius: 8px;
|
|
35
|
+
box-sizing: border-box;
|
|
36
|
+
display: flex;
|
|
37
|
+
align-items: center;
|
|
38
|
+
justify-content: center;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.tita-ui-color-date-picker__content-weekly-text {
|
|
42
|
+
color: #3f4755;
|
|
43
|
+
font-weight: 600;
|
|
44
|
+
font-size: 14px;
|
|
45
|
+
line-height: 18px;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.tita-ui-color-date-picker__content-weekly-desc {
|
|
49
|
+
color: #6f7886;
|
|
50
|
+
font-weight: 400;
|
|
51
|
+
font-size: 12px;
|
|
52
|
+
line-height: 18px;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.tita-ui-color-date-picker__content-month {
|
|
56
|
+
display: flex;
|
|
57
|
+
align-items: center;
|
|
58
|
+
justify-content: center;
|
|
59
|
+
border-radius: 8px;
|
|
60
|
+
height: 36px;
|
|
61
|
+
font-size: 14px;
|
|
62
|
+
font-weight: 600;
|
|
63
|
+
color: #3f4755;
|
|
64
|
+
line-height: 18px;
|
|
65
|
+
}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _interface = require("./interface");
|
|
13
|
+
|
|
14
|
+
var _constant = require("../../utils/constant");
|
|
15
|
+
|
|
16
|
+
require("./index.css");
|
|
17
|
+
|
|
18
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
19
|
+
|
|
20
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
21
|
+
|
|
22
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
23
|
+
|
|
24
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
25
|
+
|
|
26
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
27
|
+
|
|
28
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
29
|
+
|
|
30
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
31
|
+
|
|
32
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
33
|
+
|
|
34
|
+
var prefix = "tita-ui-color-date-picker";
|
|
35
|
+
|
|
36
|
+
var ColorDatePicker = function ColorDatePicker(_ref) {
|
|
37
|
+
var onItemClick = _ref.onItemClick,
|
|
38
|
+
_ref$data = _ref.data,
|
|
39
|
+
data = _ref$data === void 0 ? [] : _ref$data,
|
|
40
|
+
column = _ref.column,
|
|
41
|
+
_ref$type = _ref.type,
|
|
42
|
+
type = _ref$type === void 0 ? _interface.EReportType.Daily : _ref$type,
|
|
43
|
+
value = _ref.value,
|
|
44
|
+
_ref$rowGap = _ref.rowGap,
|
|
45
|
+
rowGap = _ref$rowGap === void 0 ? 0 : _ref$rowGap,
|
|
46
|
+
_ref$colGap = _ref.colGap,
|
|
47
|
+
colGap = _ref$colGap === void 0 ? 0 : _ref$colGap;
|
|
48
|
+
|
|
49
|
+
var handleItemClick = function handleItemClick(data) {
|
|
50
|
+
if (onItemClick) {
|
|
51
|
+
onItemClick(data);
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
var renderContent = (0, _react.useMemo)(function () {
|
|
56
|
+
var result = [];
|
|
57
|
+
|
|
58
|
+
if (type === _interface.EReportType.Daily) {
|
|
59
|
+
(0, _constant.getWeek)().forEach(function (item) {
|
|
60
|
+
result.push( /*#__PURE__*/_react["default"].createElement("div", {
|
|
61
|
+
className: "".concat(prefix, "__week-title")
|
|
62
|
+
}, item));
|
|
63
|
+
});
|
|
64
|
+
result.push.apply(result, _toConsumableArray(data.map(function (item) {
|
|
65
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
66
|
+
className: "".concat(prefix, "__content-daily"),
|
|
67
|
+
onClick: function onClick() {
|
|
68
|
+
return handleItemClick(item);
|
|
69
|
+
}
|
|
70
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
71
|
+
className: "".concat(prefix, "__content-daily-text"),
|
|
72
|
+
style: {
|
|
73
|
+
background: value === item.value ? item.selectedBgColor : item.bgColor,
|
|
74
|
+
color: value === item.value && item.bgColor ? "#ffffff" : item.color
|
|
75
|
+
}
|
|
76
|
+
}, item.text));
|
|
77
|
+
})));
|
|
78
|
+
} else if (type === _interface.EReportType.Weekly) {
|
|
79
|
+
result.push.apply(result, _toConsumableArray(data.map(function (item) {
|
|
80
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
81
|
+
className: "".concat(prefix, "__content-weekly"),
|
|
82
|
+
onClick: function onClick() {
|
|
83
|
+
return handleItemClick(item);
|
|
84
|
+
},
|
|
85
|
+
style: {
|
|
86
|
+
background: value === item.value ? item.selectedBgColor : item.bgColor,
|
|
87
|
+
color: value === item.value && item.bgColor ? "#ffffff" : item.color
|
|
88
|
+
}
|
|
89
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
90
|
+
className: "".concat(prefix, "__content-weekly-text")
|
|
91
|
+
}, item.text, /*#__PURE__*/_react["default"].createElement("span", {
|
|
92
|
+
className: "".concat(prefix, "__content-weekly-desc")
|
|
93
|
+
}, item.desc)));
|
|
94
|
+
})));
|
|
95
|
+
} else if (type === _interface.EReportType.Month) {
|
|
96
|
+
result.push.apply(result, _toConsumableArray(data.map(function (item) {
|
|
97
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
98
|
+
className: "".concat(prefix, "__content-month"),
|
|
99
|
+
onClick: function onClick() {
|
|
100
|
+
return handleItemClick(item);
|
|
101
|
+
},
|
|
102
|
+
style: {
|
|
103
|
+
background: value === item.value ? item.selectedBgColor : item.bgColor,
|
|
104
|
+
color: value === item.value && item.bgColor ? "#ffffff" : item.color
|
|
105
|
+
}
|
|
106
|
+
}, item.text);
|
|
107
|
+
})));
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
return result;
|
|
111
|
+
}, [column, data, type, value]);
|
|
112
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
113
|
+
className: prefix,
|
|
114
|
+
style: {
|
|
115
|
+
gridTemplateColumns: "repeat(".concat(column, ", 1fr)"),
|
|
116
|
+
rowGap: rowGap,
|
|
117
|
+
columnGap: colGap
|
|
118
|
+
}
|
|
119
|
+
}, renderContent);
|
|
120
|
+
};
|
|
121
|
+
|
|
122
|
+
var _default = ColorDatePicker;
|
|
123
|
+
exports["default"] = _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.EReportType = void 0;
|
|
7
|
+
var EReportType;
|
|
8
|
+
exports.EReportType = EReportType;
|
|
9
|
+
|
|
10
|
+
(function (EReportType) {
|
|
11
|
+
EReportType[EReportType["Daily"] = 8] = "Daily";
|
|
12
|
+
EReportType[EReportType["Weekly"] = 26] = "Weekly";
|
|
13
|
+
EReportType[EReportType["Month"] = 27] = "Month";
|
|
14
|
+
})(EReportType || (exports.EReportType = EReportType = {}));
|
|
@@ -36,7 +36,7 @@ var UploadedPreview = function UploadedPreview(_ref) {
|
|
|
36
36
|
// 上传中或不是图片文件时用默认icon
|
|
37
37
|
if (uploadResultItem.uploadStatus === 2 || !(0, _util.isImg)(uploadResultItem.MediaType)) {
|
|
38
38
|
return /*#__PURE__*/_react["default"].createElement("img", {
|
|
39
|
-
src: (0, _util.getFileTypeMapIcon)(uploadResultItem.MediaType),
|
|
39
|
+
src: (0, _util.getFileTypeMapIcon)(uploadResultItem.MediaType || uploadResultItem.FileType),
|
|
40
40
|
className: "upload-preview-img"
|
|
41
41
|
});
|
|
42
42
|
}
|
|
@@ -9,7 +9,7 @@ exports["default"] = void 0;
|
|
|
9
9
|
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _getLocale = require("../../../../../utils/getLocale");
|
|
13
13
|
|
|
14
14
|
var _efforts = _interopRequireDefault(require("./img/efforts.png"));
|
|
15
15
|
|
|
@@ -45,27 +45,27 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
|
45
45
|
|
|
46
46
|
var encourageTypes = {
|
|
47
47
|
'1': {
|
|
48
|
-
text: (0,
|
|
48
|
+
text: (0, _getLocale.getLocale)('Rep_NewS_Marvelous')
|
|
49
49
|
},
|
|
50
50
|
'2': {
|
|
51
|
-
text: (0,
|
|
51
|
+
text: (0, _getLocale.getLocale)('Rep_NewS_Welldone')
|
|
52
52
|
},
|
|
53
53
|
'3': {
|
|
54
|
-
text: (0,
|
|
54
|
+
text: (0, _getLocale.getLocale)('Rep_NewS_MakePerEffo')
|
|
55
55
|
}
|
|
56
56
|
};
|
|
57
57
|
var encourageList = [{
|
|
58
|
-
text: (0,
|
|
58
|
+
text: (0, _getLocale.getLocale)('Rep_NewS_Marvelous'),
|
|
59
59
|
icon: _great["default"],
|
|
60
60
|
curIcon: _curGreat["default"],
|
|
61
61
|
id: '1'
|
|
62
62
|
}, {
|
|
63
|
-
text: (0,
|
|
63
|
+
text: (0, _getLocale.getLocale)('Rep_NewS_Welldone'),
|
|
64
64
|
icon: _good["default"],
|
|
65
65
|
curIcon: _curGood["default"],
|
|
66
66
|
id: '2'
|
|
67
67
|
}, {
|
|
68
|
-
text: (0,
|
|
68
|
+
text: (0, _getLocale.getLocale)('Rep_NewS_MakePerEffo'),
|
|
69
69
|
icon: _efforts["default"],
|
|
70
70
|
curIcon: _curEfforts["default"],
|
|
71
71
|
id: '3'
|
|
@@ -9,16 +9,20 @@ exports["default"] = void 0;
|
|
|
9
9
|
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _dialog = _interopRequireDefault(require("../../../../dialog"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _form = _interopRequireDefault(require("../../../../form"));
|
|
15
|
+
|
|
16
|
+
var _textarea = _interopRequireDefault(require("../../../../textarea"));
|
|
17
|
+
|
|
18
|
+
var _regulationSettingItem = _interopRequireDefault(require("../../../../regulation-setting-item"));
|
|
19
|
+
|
|
20
|
+
var _getLocale = require("../../../../../utils/getLocale");
|
|
15
21
|
|
|
16
22
|
var _rate = _interopRequireDefault(require("./rate"));
|
|
17
23
|
|
|
18
24
|
var _encourage = _interopRequireDefault(require("./encourage"));
|
|
19
25
|
|
|
20
|
-
var _regulationSettingItem = _interopRequireDefault(require("../regulation-setting-item"));
|
|
21
|
-
|
|
22
26
|
require("./index.css");
|
|
23
27
|
|
|
24
28
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -39,13 +43,13 @@ 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
|
|
|
42
|
-
var precls =
|
|
46
|
+
var precls = "remind-dialog";
|
|
43
47
|
|
|
44
48
|
var RemindDialog = function RemindDialog(props) {
|
|
45
49
|
var visible = props.visible,
|
|
46
50
|
closeDialog = props.closeDialog;
|
|
47
51
|
|
|
48
|
-
var _useState = (0, _react.useState)(
|
|
52
|
+
var _useState = (0, _react.useState)(""),
|
|
49
53
|
_useState2 = _slicedToArray(_useState, 2),
|
|
50
54
|
comments = _useState2[0],
|
|
51
55
|
setComments = _useState2[1];
|
|
@@ -55,7 +59,7 @@ var RemindDialog = function RemindDialog(props) {
|
|
|
55
59
|
ratingScore = _useState4[0],
|
|
56
60
|
setRatingScore = _useState4[1];
|
|
57
61
|
|
|
58
|
-
var _useState5 = (0, _react.useState)(
|
|
62
|
+
var _useState5 = (0, _react.useState)(""),
|
|
59
63
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
60
64
|
encourageState = _useState6[0],
|
|
61
65
|
setEencourageState = _useState6[1];
|
|
@@ -66,40 +70,42 @@ var RemindDialog = function RemindDialog(props) {
|
|
|
66
70
|
setComments(e);
|
|
67
71
|
};
|
|
68
72
|
|
|
69
|
-
var onDailyValueChange = function onDailyValueChange() {};
|
|
70
|
-
|
|
71
73
|
var changeRate = function changeRate(v) {
|
|
72
74
|
setRatingScore(v);
|
|
75
|
+
setEencourageState("");
|
|
73
76
|
};
|
|
74
77
|
|
|
75
78
|
var changeEncourage = function changeEncourage(v) {
|
|
76
79
|
setEencourageState(v);
|
|
80
|
+
setRatingScore(0);
|
|
77
81
|
};
|
|
78
82
|
|
|
79
|
-
return /*#__PURE__*/_react["default"].createElement(
|
|
83
|
+
return /*#__PURE__*/_react["default"].createElement(_dialog["default"], {
|
|
80
84
|
visible: visible,
|
|
81
85
|
style: {
|
|
82
86
|
width: 538
|
|
83
87
|
},
|
|
84
88
|
onCancel: closeDialog,
|
|
85
89
|
onOk: closeDialog,
|
|
86
|
-
|
|
90
|
+
noFooterLine: true,
|
|
91
|
+
noHeadLine: true,
|
|
92
|
+
title: (0, _getLocale.getLocale)("Rep_NewS_Evaluation"),
|
|
87
93
|
onClose: closeDialog
|
|
88
94
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
89
95
|
className: "".concat(precls, "-content")
|
|
90
|
-
}, /*#__PURE__*/_react["default"].createElement(
|
|
91
|
-
label: (0,
|
|
96
|
+
}, /*#__PURE__*/_react["default"].createElement(_form["default"], null, /*#__PURE__*/_react["default"].createElement(_regulationSettingItem["default"], {
|
|
97
|
+
label: (0, _getLocale.getLocale)("Rep_NewS_OverallRating")
|
|
92
98
|
}, /*#__PURE__*/_react["default"].createElement(_rate["default"], {
|
|
93
99
|
ratingScore: ratingScore,
|
|
94
100
|
changeRate: changeRate
|
|
95
101
|
})), /*#__PURE__*/_react["default"].createElement(_regulationSettingItem["default"], {
|
|
96
|
-
label: (0,
|
|
102
|
+
label: (0, _getLocale.getLocale)("Rep_NewS_MedalEncour")
|
|
97
103
|
}, /*#__PURE__*/_react["default"].createElement(_encourage["default"], {
|
|
98
104
|
encourageState: encourageState,
|
|
99
105
|
changeEncourage: changeEncourage
|
|
100
106
|
})), /*#__PURE__*/_react["default"].createElement(_regulationSettingItem["default"], {
|
|
101
|
-
label: (0,
|
|
102
|
-
}, /*#__PURE__*/_react["default"].createElement(
|
|
107
|
+
label: (0, _getLocale.getLocale)("Per_Ass_New_Appr_detail_Com")
|
|
108
|
+
}, /*#__PURE__*/_react["default"].createElement(_textarea["default"], {
|
|
103
109
|
maxLine: 4,
|
|
104
110
|
line: 4,
|
|
105
111
|
value: comments,
|
|
@@ -107,7 +113,7 @@ var RemindDialog = function RemindDialog(props) {
|
|
|
107
113
|
return _onChange(e.target.value);
|
|
108
114
|
},
|
|
109
115
|
wrapperClass: "textarea",
|
|
110
|
-
placeholder: (0,
|
|
116
|
+
placeholder: (0, _getLocale.getLocale)("Rep_NewS_PleaEnteCom"),
|
|
111
117
|
inputRef: inputRef
|
|
112
118
|
})))));
|
|
113
119
|
};
|
|
@@ -34,7 +34,8 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
34
34
|
var prefix = "titaui-okr-progress";
|
|
35
35
|
|
|
36
36
|
var OkrProgress = function OkrProgress(_ref) {
|
|
37
|
-
var
|
|
37
|
+
var data = _ref.data,
|
|
38
|
+
_ref$type = _ref.type,
|
|
38
39
|
type = _ref$type === void 0 ? "day" : _ref$type;
|
|
39
40
|
var renderTitle = (0, _react.useMemo)(function () {
|
|
40
41
|
if (type === "day") {
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.Motion = exports.EEmotionType = void 0;
|
|
7
|
+
|
|
8
|
+
var _fighting = _interopRequireDefault(require("./img/fighting.png"));
|
|
9
|
+
|
|
10
|
+
var _happy = _interopRequireDefault(require("./img/happy.png"));
|
|
11
|
+
|
|
12
|
+
var _longStory = _interopRequireDefault(require("./img/long-story.png"));
|
|
13
|
+
|
|
14
|
+
var _pressure = _interopRequireDefault(require("./img/pressure.png"));
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
|
|
18
|
+
var EEmotionType;
|
|
19
|
+
exports.EEmotionType = EEmotionType;
|
|
20
|
+
|
|
21
|
+
(function (EEmotionType) {
|
|
22
|
+
EEmotionType[EEmotionType["Unset"] = 0] = "Unset";
|
|
23
|
+
EEmotionType[EEmotionType["Happy"] = 1] = "Happy";
|
|
24
|
+
EEmotionType[EEmotionType["Fighting"] = 2] = "Fighting";
|
|
25
|
+
EEmotionType[EEmotionType["HardToPutWords"] = 3] = "HardToPutWords";
|
|
26
|
+
EEmotionType[EEmotionType["Stressful"] = 4] = "Stressful";
|
|
27
|
+
})(EEmotionType || (exports.EEmotionType = EEmotionType = {}));
|
|
28
|
+
|
|
29
|
+
var Motion = [{
|
|
30
|
+
id: EEmotionType.Unset,
|
|
31
|
+
img: ""
|
|
32
|
+
}, {
|
|
33
|
+
id: EEmotionType.Happy,
|
|
34
|
+
img: _happy["default"]
|
|
35
|
+
}, {
|
|
36
|
+
id: EEmotionType.Fighting,
|
|
37
|
+
img: _fighting["default"]
|
|
38
|
+
}, {
|
|
39
|
+
id: EEmotionType.HardToPutWords,
|
|
40
|
+
img: _longStory["default"]
|
|
41
|
+
}, {
|
|
42
|
+
id: EEmotionType.Stressful,
|
|
43
|
+
img: _pressure["default"]
|
|
44
|
+
}];
|
|
45
|
+
exports.Motion = Motion;
|
|
@@ -27,13 +27,15 @@ var _conditionRender = _interopRequireDefault(require("../../../../condition-ren
|
|
|
27
27
|
|
|
28
28
|
var _tooltip = _interopRequireDefault(require("../../../../tooltip"));
|
|
29
29
|
|
|
30
|
+
var _commentsDialog = _interopRequireDefault(require("../comments-dialog"));
|
|
31
|
+
|
|
30
32
|
var _constant = require("../../../constant");
|
|
31
33
|
|
|
32
34
|
var _getLocale = require("../../../../../utils/getLocale");
|
|
33
35
|
|
|
34
|
-
var
|
|
36
|
+
var _constant2 = require("./constant");
|
|
35
37
|
|
|
36
|
-
var
|
|
38
|
+
var _evalute = _interopRequireDefault(require("./img/evalute.png"));
|
|
37
39
|
|
|
38
40
|
require("./index.css");
|
|
39
41
|
|
|
@@ -75,14 +77,16 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
75
77
|
desc = _ref$desc === void 0 ? "" : _ref$desc,
|
|
76
78
|
user = _ref.user,
|
|
77
79
|
_ref$suffixContent = _ref.suffixContent,
|
|
78
|
-
suffixContent = _ref$suffixContent === void 0 ? "" : _ref$suffixContent
|
|
80
|
+
suffixContent = _ref$suffixContent === void 0 ? "" : _ref$suffixContent,
|
|
81
|
+
dailyContent = _ref.dailyContent;
|
|
79
82
|
var createDate = data.createDate,
|
|
80
83
|
feedId = data.feedId,
|
|
81
84
|
_data$isTop = data.isTop,
|
|
82
85
|
isTop = _data$isTop === void 0 ? false : _data$isTop,
|
|
83
86
|
_data$isCollect = data.isCollect,
|
|
84
87
|
isCollect = _data$isCollect === void 0 ? false : _data$isCollect,
|
|
85
|
-
feedType = data.feedType
|
|
88
|
+
feedType = data.feedType,
|
|
89
|
+
canevaluate = data.canevaluate;
|
|
86
90
|
|
|
87
91
|
var _useState = (0, _react.useState)(isTop),
|
|
88
92
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -102,11 +106,17 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
102
106
|
var _useState7 = (0, _react.useState)(false),
|
|
103
107
|
_useState8 = _slicedToArray(_useState7, 2),
|
|
104
108
|
selectVisible = _useState8[0],
|
|
105
|
-
setSelectVisible = _useState8[1];
|
|
106
|
-
// userId: publishUser.id || publishUser.userId,
|
|
107
|
-
// userType: publishUser.userType || 2,
|
|
108
|
-
// });
|
|
109
|
+
setSelectVisible = _useState8[1];
|
|
109
110
|
|
|
111
|
+
var _useState9 = (0, _react.useState)(false),
|
|
112
|
+
_useState10 = _slicedToArray(_useState9, 2),
|
|
113
|
+
evaluateVisible = _useState10[0],
|
|
114
|
+
setEvaluateVisible = _useState10[1];
|
|
115
|
+
|
|
116
|
+
var _useState11 = (0, _react.useState)(""),
|
|
117
|
+
_useState12 = _slicedToArray(_useState11, 2),
|
|
118
|
+
mindImg = _useState12[0],
|
|
119
|
+
setMindImg = _useState12[1];
|
|
110
120
|
|
|
111
121
|
var url = "";
|
|
112
122
|
|
|
@@ -229,6 +239,14 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
229
239
|
window.open(url, "_blank");
|
|
230
240
|
};
|
|
231
241
|
|
|
242
|
+
var handleClickEvaluate = function handleClickEvaluate() {
|
|
243
|
+
setEvaluateVisible(true);
|
|
244
|
+
};
|
|
245
|
+
|
|
246
|
+
var handleCloseEvaluateDialog = function handleCloseEvaluateDialog() {
|
|
247
|
+
setEvaluateVisible(false);
|
|
248
|
+
};
|
|
249
|
+
|
|
232
250
|
var renderDialogConfirm = (0, _react.useMemo)(function () {
|
|
233
251
|
return /*#__PURE__*/_react["default"].createElement(_dialogConfirm["default"], {
|
|
234
252
|
visible: showDialogConfirm,
|
|
@@ -245,6 +263,17 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
245
263
|
onClick: enSureDeleteDynamic
|
|
246
264
|
}, (0, _getLocale.getLocale)("Mod_Delete")));
|
|
247
265
|
}, [showDialogConfirm]);
|
|
266
|
+
(0, _react.useEffect)(function () {
|
|
267
|
+
var mindData = dailyContent.filter(function (item) {
|
|
268
|
+
return item.title === "心情";
|
|
269
|
+
}); // 暂时用title
|
|
270
|
+
|
|
271
|
+
if (mindData[0].content !== "") {
|
|
272
|
+
setMindImg(_constant2.Motion.filter(function (item) {
|
|
273
|
+
return item.id === parseInt(mindData[0].content, 10);
|
|
274
|
+
})[0].img);
|
|
275
|
+
}
|
|
276
|
+
});
|
|
248
277
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
249
278
|
className: "".concat(prefix)
|
|
250
279
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -262,8 +291,8 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
262
291
|
textNum: 1,
|
|
263
292
|
fontSize: 18
|
|
264
293
|
}
|
|
265
|
-
}), /*#__PURE__*/_react["default"].createElement("img", {
|
|
266
|
-
src:
|
|
294
|
+
}), mindImg && /*#__PURE__*/_react["default"].createElement("img", {
|
|
295
|
+
src: mindImg,
|
|
267
296
|
className: "".concat(prefix, "-desc-mind")
|
|
268
297
|
})), /*#__PURE__*/_react["default"].createElement("span", {
|
|
269
298
|
className: "".concat(prefix, "-desc")
|
|
@@ -280,12 +309,13 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
280
309
|
name: user.name,
|
|
281
310
|
id: user.userId
|
|
282
311
|
})
|
|
283
|
-
})), desc, suffixContent), /*#__PURE__*/_react["default"].createElement("div", {
|
|
284
|
-
className: "".concat(prefix, "__evalute")
|
|
312
|
+
})), desc, suffixContent), canevaluate && /*#__PURE__*/_react["default"].createElement("div", {
|
|
313
|
+
className: "".concat(prefix, "__evalute"),
|
|
314
|
+
onClick: handleClickEvaluate
|
|
285
315
|
}, /*#__PURE__*/_react["default"].createElement("img", {
|
|
286
316
|
src: _evalute["default"],
|
|
287
317
|
className: "".concat(prefix, "__evalute-img")
|
|
288
|
-
}), (0, _getLocale.getLocale)(
|
|
318
|
+
}), (0, _getLocale.getLocale)("Per_MyRe_button_Toevaluate")), /*#__PURE__*/_react["default"].createElement("div", {
|
|
289
319
|
className: "".concat(prefix, "__more-operate")
|
|
290
320
|
}, /*#__PURE__*/_react["default"].createElement(_dropSelector["default"], {
|
|
291
321
|
popupPlacement: "bottomRight",
|
|
@@ -341,7 +371,10 @@ var DynamicItemHeader = function DynamicItemHeader(_ref) {
|
|
|
341
371
|
className: (0, _classnames["default"])("tu-icon-del", "".concat(prefix, "__more-operate-selection-icon"))
|
|
342
372
|
}), (0, _getLocale.getLocale)("Mod_Delete"))))))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
343
373
|
className: "".concat(prefix, "-desc-time")
|
|
344
|
-
}, createDate))), renderDialogConfirm
|
|
374
|
+
}, createDate))), renderDialogConfirm, /*#__PURE__*/_react["default"].createElement(_commentsDialog["default"], {
|
|
375
|
+
visible: evaluateVisible,
|
|
376
|
+
closeDialog: handleCloseEvaluateDialog
|
|
377
|
+
}));
|
|
345
378
|
};
|
|
346
379
|
|
|
347
380
|
var _default = DynamicItemHeader;
|
|
@@ -26,7 +26,8 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
26
26
|
var prefix = "titaui-dynamic-summary-task-progress";
|
|
27
27
|
|
|
28
28
|
var TaskProgress = function TaskProgress(_ref) {
|
|
29
|
-
var
|
|
29
|
+
var data = _ref.data,
|
|
30
|
+
_ref$type = _ref.type,
|
|
30
31
|
type = _ref$type === void 0 ? "day" : _ref$type;
|
|
31
32
|
var renderTitle = (0, _react.useMemo)(function () {
|
|
32
33
|
if (type === "day") {
|
package/lib/components/dynamic/dynamic-item/dynamic-new-report/components/remind-user-view/index.js
CHANGED
|
@@ -58,7 +58,8 @@ var userInfo = [{
|
|
|
58
58
|
avatar: _fighting["default"]
|
|
59
59
|
}];
|
|
60
60
|
|
|
61
|
-
var RemindUserView = function RemindUserView() {
|
|
61
|
+
var RemindUserView = function RemindUserView(props) {
|
|
62
|
+
var data = props.data;
|
|
62
63
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
63
64
|
className: preCls
|
|
64
65
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.Motion = exports.EEmotionType = void 0;
|
|
7
|
+
|
|
8
|
+
var _fighting = _interopRequireDefault(require("./img/fighting.png"));
|
|
9
|
+
|
|
10
|
+
var _happy = _interopRequireDefault(require("./img/happy.png"));
|
|
11
|
+
|
|
12
|
+
var _longStory = _interopRequireDefault(require("./img/long-story.png"));
|
|
13
|
+
|
|
14
|
+
var _pressure = _interopRequireDefault(require("./img/pressure.png"));
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
|
|
18
|
+
var EEmotionType;
|
|
19
|
+
exports.EEmotionType = EEmotionType;
|
|
20
|
+
|
|
21
|
+
(function (EEmotionType) {
|
|
22
|
+
EEmotionType[EEmotionType["Unset"] = 0] = "Unset";
|
|
23
|
+
EEmotionType[EEmotionType["Happy"] = 1] = "Happy";
|
|
24
|
+
EEmotionType[EEmotionType["Fighting"] = 2] = "Fighting";
|
|
25
|
+
EEmotionType[EEmotionType["HardToPutWords"] = 3] = "HardToPutWords";
|
|
26
|
+
EEmotionType[EEmotionType["Stressful"] = 4] = "Stressful";
|
|
27
|
+
})(EEmotionType || (exports.EEmotionType = EEmotionType = {}));
|
|
28
|
+
|
|
29
|
+
var Motion = [{
|
|
30
|
+
id: EEmotionType.Unset,
|
|
31
|
+
img: ""
|
|
32
|
+
}, {
|
|
33
|
+
id: EEmotionType.Happy,
|
|
34
|
+
img: _happy["default"]
|
|
35
|
+
}, {
|
|
36
|
+
id: EEmotionType.Fighting,
|
|
37
|
+
img: _fighting["default"]
|
|
38
|
+
}, {
|
|
39
|
+
id: EEmotionType.HardToPutWords,
|
|
40
|
+
img: _longStory["default"]
|
|
41
|
+
}, {
|
|
42
|
+
id: EEmotionType.Stressful,
|
|
43
|
+
img: _pressure["default"]
|
|
44
|
+
}];
|
|
45
|
+
exports.Motion = Motion;
|