@titaui/pc 1.5.69-beta.5 → 1.5.69-beta.9
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/communication/CommunicationRecord.js +106 -162
- package/lib/components/communication/index.js +27 -24
- 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/{components/common-dynamic → dynamic-reward}/index.js +91 -37
- 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.js +65 -19
- package/lib/components/dynamic/dynamic-like-ranking/item.js +20 -38
- 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 +1 -1
- package/lib/components/dynamic/dynamic.js +49 -15
- package/lib/components/dynamic/request-api.js +13 -1
- package/lib/components/dynamic/util.js +16 -2
- package/lib/components/grid-page/personal-info/index.js +4 -4
- package/lib/pages/like-ranking/column.js +18 -5
- package/lib/pages/like-ranking/filter-buttons/department.js +19 -12
- package/lib/pages/like-ranking/filter-buttons/index.js +8 -23
- package/lib/pages/like-ranking/filter-buttons/modular.js +27 -25
- package/lib/pages/like-ranking/filter-buttons/name.js +6 -8
- 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 +10 -11
- package/lib/pages/like-ranking/index.css +14 -2
- package/lib/pages/like-ranking/index.js +64 -89
- package/lib/utils/bs-global.js +2 -1
- package/lib/utils/format-time.js +35 -2
- 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 -110
- 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/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
|
@@ -34,7 +34,7 @@ var IconAvatar = function IconAvatar(_ref) {
|
|
|
34
34
|
className: "tita-icon-avatar"
|
|
35
35
|
}, /*#__PURE__*/_react["default"].createElement(_default2["default"], _extends({
|
|
36
36
|
userId: userId,
|
|
37
|
-
src: avatar.HasAvatar ? avatar.medium :
|
|
37
|
+
src: avatar.HasAvatar || avatar.hasAvatar ? avatar.medium : "",
|
|
38
38
|
color: avatar.color,
|
|
39
39
|
name: name
|
|
40
40
|
}, restProps)), /*#__PURE__*/_react["default"].createElement("img", {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports["default"] = exports.IconAvatar = exports.NameAvatar = exports.DefaultAvatar = exports.TextAvatar = void 0;
|
|
6
|
+
exports["default"] = exports.NumAvatar = exports.IconAvatar = exports.NameAvatar = exports.DefaultAvatar = exports.TextAvatar = void 0;
|
|
7
7
|
|
|
8
8
|
var _default2 = _interopRequireDefault(require("./default"));
|
|
9
9
|
|
|
@@ -13,6 +13,8 @@ var _nameAvatar = _interopRequireDefault(require("./name-avatar"));
|
|
|
13
13
|
|
|
14
14
|
var _iconAvatar = _interopRequireDefault(require("./icon-avatar"));
|
|
15
15
|
|
|
16
|
+
var _numAvatar = _interopRequireDefault(require("./num-avatar"));
|
|
17
|
+
|
|
16
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
19
|
|
|
18
20
|
var TextAvatar = _textAvatar["default"];
|
|
@@ -23,5 +25,7 @@ var NameAvatar = _nameAvatar["default"];
|
|
|
23
25
|
exports.NameAvatar = NameAvatar;
|
|
24
26
|
var IconAvatar = _iconAvatar["default"];
|
|
25
27
|
exports.IconAvatar = IconAvatar;
|
|
28
|
+
var NumAvatar = _numAvatar["default"];
|
|
29
|
+
exports.NumAvatar = NumAvatar;
|
|
26
30
|
var _default = _default2["default"];
|
|
27
31
|
exports["default"] = _default;
|
|
@@ -0,0 +1,34 @@
|
|
|
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 _bsGlobal = require("../../../utils/bs-global");
|
|
11
|
+
|
|
12
|
+
require("./index.css");
|
|
13
|
+
|
|
14
|
+
var _excluded = ["num"];
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
|
|
18
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
|
+
|
|
20
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
21
|
+
|
|
22
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
23
|
+
|
|
24
|
+
var IconAvatar = function IconAvatar(_ref) {
|
|
25
|
+
var num = _ref.num,
|
|
26
|
+
restProps = _objectWithoutProperties(_ref, _excluded);
|
|
27
|
+
|
|
28
|
+
return /*#__PURE__*/_react["default"].createElement("div", _extends({
|
|
29
|
+
className: "tita-num-avatar"
|
|
30
|
+
}, restProps), (0, _bsGlobal.formatNum)(num));
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
var _default = IconAvatar;
|
|
34
|
+
exports["default"] = _default;
|
|
@@ -19,12 +19,12 @@ var _ConfirmPop = _interopRequireDefault(require("../delete-confirm-pop/ConfirmP
|
|
|
19
19
|
|
|
20
20
|
var _ConvertUserName = _interopRequireDefault(require("./ConvertUserName"));
|
|
21
21
|
|
|
22
|
-
var _requestV = require("../../utils/request-v1");
|
|
23
|
-
|
|
24
22
|
var _openData = require("../../utils/open-data");
|
|
25
23
|
|
|
26
24
|
var _fileList = _interopRequireDefault(require("../file-list"));
|
|
27
25
|
|
|
26
|
+
var _tools = require("../../utils/tools");
|
|
27
|
+
|
|
28
28
|
require("./index.css");
|
|
29
29
|
|
|
30
30
|
var _style = require("./style");
|
|
@@ -35,167 +35,111 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
35
35
|
|
|
36
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
37
|
|
|
38
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
39
|
-
|
|
40
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
41
|
-
|
|
42
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
43
|
-
|
|
44
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
45
|
-
|
|
46
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
47
|
-
|
|
48
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
49
|
-
|
|
50
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
51
|
-
|
|
52
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
53
|
-
|
|
54
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
55
|
-
|
|
56
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
57
|
-
|
|
58
38
|
var prefix = "titaui-communication";
|
|
59
39
|
|
|
60
|
-
var CommunicationRecord =
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
if (res.Code == 1) {
|
|
76
|
-
_this.setState({
|
|
77
|
-
replyedContent: res.Data.content
|
|
78
|
-
});
|
|
79
|
-
}
|
|
40
|
+
var CommunicationRecord = function CommunicationRecord(_ref) {
|
|
41
|
+
var communicationTrack = _ref.communicationTrack,
|
|
42
|
+
_ref$confirmPopAlign = _ref.confirmPopAlign,
|
|
43
|
+
confirmPopAlign = _ref$confirmPopAlign === void 0 ? "top right" : _ref$confirmPopAlign,
|
|
44
|
+
highLightKeyWord = _ref.highLightKeyWord,
|
|
45
|
+
index = _ref.index,
|
|
46
|
+
onCommunicationRecordChange = _ref.onCommunicationRecordChange,
|
|
47
|
+
className = _ref.className,
|
|
48
|
+
praiseStatus = _ref.praiseStatus;
|
|
49
|
+
var contentRef = (0, _react.useRef)();
|
|
50
|
+
(0, _react.useEffect)(function () {
|
|
51
|
+
if (highLightKeyWord) {
|
|
52
|
+
(0, _tools.highLightWord)({
|
|
53
|
+
parentDom: contentRef.current,
|
|
54
|
+
keyWord: highLightKeyWord
|
|
80
55
|
});
|
|
81
|
-
};
|
|
82
|
-
|
|
83
|
-
_this.state = {
|
|
84
|
-
replyedContent: ""
|
|
85
|
-
};
|
|
86
|
-
return _this;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
_createClass(CommunicationRecord, [{
|
|
90
|
-
key: "componentWillMount",
|
|
91
|
-
value: function componentWillMount() {
|
|
92
|
-
var parentCommentId = this.props.communicationTrack.parentCommentId;
|
|
93
|
-
|
|
94
|
-
if (parentCommentId) {
|
|
95
|
-
this.getCommentGetByIds(parentCommentId);
|
|
96
|
-
}
|
|
97
|
-
} // 获取被回复人发布的沟通内容:“的话”上的tips信息
|
|
98
|
-
|
|
99
|
-
}, {
|
|
100
|
-
key: "render",
|
|
101
|
-
value: function render() {
|
|
102
|
-
var _this$props = this.props,
|
|
103
|
-
communicationTrack = _this$props.communicationTrack,
|
|
104
|
-
index = _this$props.index,
|
|
105
|
-
onCommunicationRecordChange = _this$props.onCommunicationRecordChange,
|
|
106
|
-
className = _this$props.className,
|
|
107
|
-
confirmPopAlign = _this$props.confirmPopAlign,
|
|
108
|
-
praiseStatus = _this$props.praiseStatus;
|
|
109
|
-
return /*#__PURE__*/_react["default"].createElement(_style.CommunicationItem, {
|
|
110
|
-
className: className
|
|
111
|
-
}, /*#__PURE__*/_react["default"].createElement(_avatar["default"], {
|
|
112
|
-
size: _avatar["default"].size(7),
|
|
113
|
-
name: communicationTrack.publishUser.name,
|
|
114
|
-
src: communicationTrack.publishUser.avatar.small,
|
|
115
|
-
color: communicationTrack.publishUser.avatar.color,
|
|
116
|
-
userId: communicationTrack.publishUser.userId
|
|
117
|
-
}), /*#__PURE__*/_react["default"].createElement(_style.CommunicationDetail, null, /*#__PURE__*/_react["default"].createElement("p", {
|
|
118
|
-
style: {
|
|
119
|
-
color: "#3a4247",
|
|
120
|
-
wordBreak: "break-all"
|
|
121
|
-
}
|
|
122
|
-
}, communicationTrack.commentType != 2 ? /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_ConvertUserName["default"], {
|
|
123
|
-
userName: communicationTrack.publishUser.name,
|
|
124
|
-
userId: communicationTrack.publishUser.userId
|
|
125
|
-
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
126
|
-
className: prefix + "__communication-colon"
|
|
127
|
-
}, "\uFF1A")) : /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_ConvertUserName["default"], {
|
|
128
|
-
userName: communicationTrack.publishUser.name,
|
|
129
|
-
userId: communicationTrack.publishUser.userId
|
|
130
|
-
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
131
|
-
className: prefix + "__communication-text"
|
|
132
|
-
}, "\u56DE\u590D"), /*#__PURE__*/_react["default"].createElement(_ConvertUserName["default"], {
|
|
133
|
-
userName: communicationTrack.parentUser.name,
|
|
134
|
-
userId: communicationTrack.parentUser.userId
|
|
135
|
-
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
136
|
-
className: prefix + "__communication-colon"
|
|
137
|
-
}, "\uFF1A"), /*#__PURE__*/_react["default"].createElement(_Portals["default"], null, /*#__PURE__*/_react["default"].createElement(_reactTooltip["default"], {
|
|
138
|
-
html: true,
|
|
139
|
-
className: "tt-react-tooltip",
|
|
140
|
-
place: "top",
|
|
141
|
-
type: "dark",
|
|
142
|
-
effect: "solid"
|
|
143
|
-
}))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
144
|
-
className: prefix + "__communication-content"
|
|
145
|
-
}, (0, _openData.parseTag)(communicationTrack.content))), communicationTrack.attachments && /*#__PURE__*/_react["default"].createElement("div", {
|
|
146
|
-
className: prefix + "__communication-attachments"
|
|
147
|
-
}, /*#__PURE__*/_react["default"].createElement(_fileList["default"], {
|
|
148
|
-
data: communicationTrack.attachments
|
|
149
|
-
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
150
|
-
className: prefix + '__communication-bottom'
|
|
151
|
-
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
152
|
-
className: prefix + "__communication-time"
|
|
153
|
-
}, communicationTrack.createDate), /*#__PURE__*/_react["default"].createElement(_style.CommunicationActionbar, {
|
|
154
|
-
className: "communication__actionbar"
|
|
155
|
-
}, /*#__PURE__*/_react["default"].createElement(_style.ActionbarList, null, /*#__PURE__*/_react["default"].createElement(_style.ActionbarItem, {
|
|
156
|
-
onMouseDown: function onMouseDown(event) {
|
|
157
|
-
praiseStatus != 2 && onCommunicationRecordChange(event, "reply", index);
|
|
158
|
-
}
|
|
159
|
-
}, "\u56DE\u590D"), /*#__PURE__*/_react["default"].createElement(_style.ActionbarItem, {
|
|
160
|
-
onMouseDown: function onMouseDown(event) {
|
|
161
|
-
praiseStatus != 2 && onCommunicationRecordChange(event, "praise", index);
|
|
162
|
-
}
|
|
163
|
-
}, communicationTrack.isPraise ? "已赞" : "点赞"), communicationTrack.praiseTotal > 0 &&
|
|
164
|
-
/*#__PURE__*/
|
|
165
|
-
// <ToolTip title='点击查看点赞记录'>
|
|
166
|
-
_react["default"].createElement(_style.CommunicationPraiseTotal, {
|
|
167
|
-
className: "communication__praise__total",
|
|
168
|
-
onMouseDown: function onMouseDown(event) {
|
|
169
|
-
onCommunicationRecordChange(event, "showPraiseRecord", index);
|
|
170
|
-
event.stopPropagation();
|
|
171
|
-
event.nativeEvent.stopImmediatePropagation();
|
|
172
|
-
},
|
|
173
|
-
onClick: function onClick(event) {
|
|
174
|
-
event.stopPropagation();
|
|
175
|
-
event.nativeEvent.stopImmediatePropagation();
|
|
176
|
-
},
|
|
177
|
-
"data-for": "praise-record",
|
|
178
|
-
"data-tip": !!communicationTrack.praiseTotal ? "点击查看点赞记录" : ""
|
|
179
|
-
}, communicationTrack.praiseTotal) // </ToolTip>
|
|
180
|
-
, communicationTrack.isEdit && /*#__PURE__*/_react["default"].createElement(_ConfirmPop["default"], {
|
|
181
|
-
align: confirmPopAlign,
|
|
182
|
-
onSubmit: function onSubmit(event) {
|
|
183
|
-
return onCommunicationRecordChange(event, "delete", index);
|
|
184
|
-
}
|
|
185
|
-
}, /*#__PURE__*/_react["default"].createElement(_style.ActionbarItem, null, "\u5220\u9664")))))), /*#__PURE__*/_react["default"].createElement(_reactTooltip["default"], {
|
|
186
|
-
id: "praise-record",
|
|
187
|
-
className: "tt-react-tooltip",
|
|
188
|
-
place: "top",
|
|
189
|
-
type: "dark",
|
|
190
|
-
effect: "solid"
|
|
191
|
-
}));
|
|
192
56
|
}
|
|
193
|
-
}]);
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
57
|
+
}, [highLightKeyWord]);
|
|
58
|
+
return /*#__PURE__*/_react["default"].createElement(_style.CommunicationItem, {
|
|
59
|
+
className: className
|
|
60
|
+
}, /*#__PURE__*/_react["default"].createElement(_avatar["default"], {
|
|
61
|
+
size: _avatar["default"].size(7),
|
|
62
|
+
name: communicationTrack.publishUser.name,
|
|
63
|
+
src: communicationTrack.publishUser.avatar.small,
|
|
64
|
+
color: communicationTrack.publishUser.avatar.color,
|
|
65
|
+
userId: communicationTrack.publishUser.userId
|
|
66
|
+
}), /*#__PURE__*/_react["default"].createElement(_style.CommunicationDetail, null, /*#__PURE__*/_react["default"].createElement("p", {
|
|
67
|
+
style: {
|
|
68
|
+
color: "#3a4247",
|
|
69
|
+
wordBreak: "break-all"
|
|
70
|
+
}
|
|
71
|
+
}, communicationTrack.commentType != 2 ? /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_ConvertUserName["default"], {
|
|
72
|
+
userName: communicationTrack.publishUser.name,
|
|
73
|
+
userId: communicationTrack.publishUser.userId
|
|
74
|
+
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
75
|
+
className: prefix + "__communication-colon"
|
|
76
|
+
}, "\uFF1A")) : /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_ConvertUserName["default"], {
|
|
77
|
+
userName: communicationTrack.publishUser.name,
|
|
78
|
+
userId: communicationTrack.publishUser.userId
|
|
79
|
+
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
80
|
+
className: prefix + "__communication-text"
|
|
81
|
+
}, "\u56DE\u590D"), /*#__PURE__*/_react["default"].createElement(_ConvertUserName["default"], {
|
|
82
|
+
userName: communicationTrack.parentUser.name,
|
|
83
|
+
userId: communicationTrack.parentUser.userId
|
|
84
|
+
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
85
|
+
className: prefix + "__communication-colon"
|
|
86
|
+
}, "\uFF1A"), /*#__PURE__*/_react["default"].createElement(_Portals["default"], null, /*#__PURE__*/_react["default"].createElement(_reactTooltip["default"], {
|
|
87
|
+
html: true,
|
|
88
|
+
className: "tt-react-tooltip",
|
|
89
|
+
place: "top",
|
|
90
|
+
type: "dark",
|
|
91
|
+
effect: "solid"
|
|
92
|
+
}))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
93
|
+
className: prefix + "__communication-content",
|
|
94
|
+
ref: contentRef
|
|
95
|
+
}, (0, _openData.parseTag)(communicationTrack.content))), communicationTrack.attachments && /*#__PURE__*/_react["default"].createElement("div", {
|
|
96
|
+
className: prefix + "__communication-attachments"
|
|
97
|
+
}, /*#__PURE__*/_react["default"].createElement(_fileList["default"], {
|
|
98
|
+
data: communicationTrack.attachments
|
|
99
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
100
|
+
className: prefix + "__communication-bottom"
|
|
101
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
102
|
+
className: prefix + "__communication-time"
|
|
103
|
+
}, communicationTrack.createDate), /*#__PURE__*/_react["default"].createElement(_style.CommunicationActionbar, {
|
|
104
|
+
className: "communication__actionbar"
|
|
105
|
+
}, /*#__PURE__*/_react["default"].createElement(_style.ActionbarList, null, /*#__PURE__*/_react["default"].createElement(_style.ActionbarItem, {
|
|
106
|
+
onMouseDown: function onMouseDown(event) {
|
|
107
|
+
praiseStatus != 2 && onCommunicationRecordChange(event, "reply", index);
|
|
108
|
+
}
|
|
109
|
+
}, "\u56DE\u590D"), /*#__PURE__*/_react["default"].createElement(_style.ActionbarItem, {
|
|
110
|
+
onMouseDown: function onMouseDown(event) {
|
|
111
|
+
praiseStatus != 2 && onCommunicationRecordChange(event, "praise", index);
|
|
112
|
+
}
|
|
113
|
+
}, communicationTrack.isPraise ? "已赞" : "点赞"), communicationTrack.praiseTotal > 0 &&
|
|
114
|
+
/*#__PURE__*/
|
|
115
|
+
// <ToolTip title='点击查看点赞记录'>
|
|
116
|
+
_react["default"].createElement(_style.CommunicationPraiseTotal, {
|
|
117
|
+
className: "communication__praise__total",
|
|
118
|
+
onMouseDown: function onMouseDown(event) {
|
|
119
|
+
onCommunicationRecordChange(event, "showPraiseRecord", index);
|
|
120
|
+
event.stopPropagation();
|
|
121
|
+
event.nativeEvent.stopImmediatePropagation();
|
|
122
|
+
},
|
|
123
|
+
onClick: function onClick(event) {
|
|
124
|
+
event.stopPropagation();
|
|
125
|
+
event.nativeEvent.stopImmediatePropagation();
|
|
126
|
+
},
|
|
127
|
+
"data-for": "praise-record",
|
|
128
|
+
"data-tip": !!communicationTrack.praiseTotal ? "点击查看点赞记录" : ""
|
|
129
|
+
}, communicationTrack.praiseTotal) // </ToolTip>
|
|
130
|
+
, communicationTrack.isEdit && /*#__PURE__*/_react["default"].createElement(_ConfirmPop["default"], {
|
|
131
|
+
align: confirmPopAlign,
|
|
132
|
+
onSubmit: function onSubmit(event) {
|
|
133
|
+
return onCommunicationRecordChange(event, "delete", index);
|
|
134
|
+
}
|
|
135
|
+
}, /*#__PURE__*/_react["default"].createElement(_style.ActionbarItem, null, "\u5220\u9664")))))), /*#__PURE__*/_react["default"].createElement(_reactTooltip["default"], {
|
|
136
|
+
id: "praise-record",
|
|
137
|
+
className: "tt-react-tooltip",
|
|
138
|
+
place: "top",
|
|
139
|
+
type: "dark",
|
|
140
|
+
effect: "solid"
|
|
141
|
+
}));
|
|
142
|
+
};
|
|
143
|
+
|
|
144
|
+
var _default = CommunicationRecord;
|
|
145
|
+
exports["default"] = _default;
|
|
@@ -83,14 +83,14 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
83
83
|
okrFeedParams = _this$props.okrFeedParams;
|
|
84
84
|
var isShowAllCommunicationRecord = _this.state.isShowAllCommunicationRecord;
|
|
85
85
|
var url = commentType == 1 ? isShowAllCommunicationRecord ? (0, _requestV.getApiUrl2)("comment/Get?feed_id=".concat(feedId, "&comment_type=0")) : (0, _requestV.getApiUrl2)("user/feed/GetById?feed_id=".concat(feedId, "&comment_count=").concat(commentCount)) : (0, _requestV.getApiUrl)("okr/cycle/getFeed?objId=".concat(okrFeedParams && okrFeedParams.objId, "&objType=").concat(okrFeedParams && okrFeedParams.objType, "&cycleType=").concat(okrFeedParams && okrFeedParams.cycleType, "&yqmNum=").concat(okrFeedParams && okrFeedParams.yqmNum, "&annualNum=").concat(okrFeedParams && okrFeedParams.annualNum, "&commentCount=").concat(commentCount));
|
|
86
|
-
(0, _requestV.taker)(url,
|
|
86
|
+
(0, _requestV.taker)(url, "GET").then(function (res) {
|
|
87
87
|
if (res.Code === 1) {
|
|
88
88
|
var data = res.Data && (res.Data.feedComments || res.Data);
|
|
89
89
|
|
|
90
90
|
_this.setState({
|
|
91
91
|
communicationTrackList: data.comments ? data.comments : [],
|
|
92
92
|
communicationTrackTotal: data.total,
|
|
93
|
-
okrCommentFeedId: commentType == 2 ? res.Data.feedId :
|
|
93
|
+
okrCommentFeedId: commentType == 2 ? res.Data.feedId : ""
|
|
94
94
|
});
|
|
95
95
|
} else {
|
|
96
96
|
_this.setState({
|
|
@@ -130,15 +130,15 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
130
130
|
|
|
131
131
|
var communicationTrackList = _toConsumableArray(_this.state.communicationTrackList);
|
|
132
132
|
|
|
133
|
-
if (actionType ===
|
|
133
|
+
if (actionType === "delete") {
|
|
134
134
|
// 删除
|
|
135
135
|
var url = (0, _requestV.getApiUrl2)("comment/Delete?comment_id=".concat(communicationTrackList[index].commentId, "&feed_id=").concat(feedId || _this.state.okrCommentFeedId));
|
|
136
|
-
(0, _requestV.taker)(url,
|
|
136
|
+
(0, _requestV.taker)(url, "DELETE").then(function (res) {
|
|
137
137
|
if (res.Code === 1) {
|
|
138
138
|
isShowAllCommunicationRecord ? _this.getFeedInfo(feedId, communicationTrackTotal - 1) : _this.getFeedInfo(feedId, commentCount);
|
|
139
139
|
}
|
|
140
140
|
});
|
|
141
|
-
} else if (actionType ===
|
|
141
|
+
} else if (actionType === "reply") {
|
|
142
142
|
// 沟通里的回复
|
|
143
143
|
if (_this.props.useCustomMblog && _this.props.onComment) {
|
|
144
144
|
_this.props.onComment({
|
|
@@ -163,7 +163,7 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
163
163
|
replyUserId: communicationTrackList[index].publishUser.userId,
|
|
164
164
|
replyUserCommentId: communicationTrackList[index].commentId
|
|
165
165
|
});
|
|
166
|
-
} else if (actionType ===
|
|
166
|
+
} else if (actionType === "praise") {
|
|
167
167
|
// 沟通里的点赞
|
|
168
168
|
var isPraise = communicationTrackList[index].isPraise;
|
|
169
169
|
isPraise = !isPraise;
|
|
@@ -174,7 +174,7 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
174
174
|
|
|
175
175
|
var _url = isPraise ? (0, _requestV.getApiUrl)("praise/add?objId=".concat(communicationTrackList[index].commentId, "&objType=19&praiseType=1")) : (0, _requestV.getApiUrl)("praise/cancel?objId=".concat(communicationTrackList[index].commentId, "&objType=19"));
|
|
176
176
|
|
|
177
|
-
(0, _requestV.taker)(_url,
|
|
177
|
+
(0, _requestV.taker)(_url, "POST").then(function (res) {
|
|
178
178
|
if (res.Code === 1) {
|
|
179
179
|
var praiseTotal = communicationTrackList[index].praiseTotal;
|
|
180
180
|
communicationTrackList[index].isPraise = isPraise;
|
|
@@ -190,7 +190,7 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
190
190
|
});
|
|
191
191
|
}
|
|
192
192
|
});
|
|
193
|
-
} else if (actionType ===
|
|
193
|
+
} else if (actionType === "showPraiseRecord") {
|
|
194
194
|
// 显示点赞记录
|
|
195
195
|
_this.setState({
|
|
196
196
|
isShowPraiseRecordPop: true,
|
|
@@ -225,7 +225,7 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
225
225
|
communicationTrackTotal = _this$state3.communicationTrackTotal,
|
|
226
226
|
isShowAllCommunicationRecord = _this$state3.isShowAllCommunicationRecord;
|
|
227
227
|
|
|
228
|
-
if (submitType ===
|
|
228
|
+
if (submitType === "submit") {
|
|
229
229
|
// 发送
|
|
230
230
|
sentData.FeedId = feedId;
|
|
231
231
|
sentData.CommentId = 0;
|
|
@@ -240,8 +240,8 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
240
240
|
submitStatus: 2
|
|
241
241
|
});
|
|
242
242
|
|
|
243
|
-
var url = commentType == 1 ? (0, _requestV.getApiUrl2)(
|
|
244
|
-
(0, _requestV.taker)(url,
|
|
243
|
+
var url = commentType == 1 ? (0, _requestV.getApiUrl2)("comment/Add") : (0, _requestV.getApiUrl)("okr/cycle/addComment?objId=".concat(okrFeedParams && okrFeedParams.objId, "&objType=").concat(okrFeedParams && okrFeedParams.objType, "&cycleType=").concat(okrFeedParams && okrFeedParams.cycleType, "&yqmNum=").concat(okrFeedParams && okrFeedParams.yqmNum, "&annualNum=").concat(okrFeedParams && okrFeedParams.annualNum));
|
|
244
|
+
(0, _requestV.taker)(url, "POST", sentData).then(function (res) {
|
|
245
245
|
if (res.Code === 1) {
|
|
246
246
|
isShowAllCommunicationRecord ? _this.getFeedInfo(feedId, communicationTrackTotal + 1) : _this.getFeedInfo(feedId, commentCount);
|
|
247
247
|
|
|
@@ -277,17 +277,17 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
277
277
|
isShowAllCommunicationRecord: false,
|
|
278
278
|
// 是否显示所有记录
|
|
279
279
|
// 回复
|
|
280
|
-
replyUser:
|
|
281
|
-
replyUserId:
|
|
282
|
-
replyUserCommentId:
|
|
280
|
+
replyUser: "",
|
|
281
|
+
replyUserId: "",
|
|
282
|
+
replyUserCommentId: "0",
|
|
283
283
|
isShowReplyToUser: false,
|
|
284
284
|
// 是否显示回复谁
|
|
285
285
|
submitStatus: 0,
|
|
286
286
|
praiseStatus: 0,
|
|
287
287
|
// 点赞记录
|
|
288
|
-
praiseObjId:
|
|
288
|
+
praiseObjId: "",
|
|
289
289
|
isShowPraiseRecordPop: false,
|
|
290
|
-
okrCommentFeedId:
|
|
290
|
+
okrCommentFeedId: ""
|
|
291
291
|
};
|
|
292
292
|
return _this;
|
|
293
293
|
}
|
|
@@ -347,16 +347,18 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
347
347
|
showAtAll = _this$props8.showAtAll,
|
|
348
348
|
useCustomMblog = _this$props8.useCustomMblog,
|
|
349
349
|
_this$props8$submitTe = _this$props8.submitText,
|
|
350
|
-
submitText = _this$props8$submitTe === void 0 ?
|
|
350
|
+
submitText = _this$props8$submitTe === void 0 ? "回复" : _this$props8$submitTe,
|
|
351
|
+
_this$props8$highLigh = _this$props8.highLightKeyWord,
|
|
352
|
+
highLightKeyWord = _this$props8$highLigh === void 0 ? '' : _this$props8$highLigh;
|
|
351
353
|
return /*#__PURE__*/_react["default"].createElement(_style.CommunicationWrapper, {
|
|
352
354
|
className: "communcation-wrapper ".concat(className)
|
|
353
355
|
}, /*#__PURE__*/_react["default"].createElement("div", null, communicationTrackTotal > 0 && /*#__PURE__*/_react["default"].createElement(_style.CommunicationRecordTotal, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
354
|
-
className: prefix +
|
|
356
|
+
className: prefix + "__communication-total",
|
|
355
357
|
onMouseDown: function onMouseDown() {
|
|
356
358
|
return _this2.handlerSwitchShowRecord();
|
|
357
359
|
}
|
|
358
360
|
}, "\u5168\u90E8\u6C9F\u901A\xA0", /*#__PURE__*/_react["default"].createElement("span", null, communicationTrackTotal), /*#__PURE__*/_react["default"].createElement("i", {
|
|
359
|
-
className: (0, _classnames["default"])(prefix +
|
|
361
|
+
className: (0, _classnames["default"])(prefix + "__communication-total-icon", {
|
|
360
362
|
"tu-icon-APP-xi": isShowAllCommunicationRecord,
|
|
361
363
|
"tu-icon-arrow-down1": !isShowAllCommunicationRecord
|
|
362
364
|
})
|
|
@@ -365,6 +367,7 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
365
367
|
}, communicationTrackList.length > 0 && communicationTrackList.map(function (item, index) {
|
|
366
368
|
return /*#__PURE__*/_react["default"].createElement(_CommunicationRecord["default"], {
|
|
367
369
|
communicationTrack: item,
|
|
370
|
+
highLightKeyWord: highLightKeyWord,
|
|
368
371
|
index: index,
|
|
369
372
|
key: item.commentId,
|
|
370
373
|
praiseStatus: _this2.state.praiseStatus,
|
|
@@ -376,12 +379,12 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
376
379
|
}))), !useCustomMblog && /*#__PURE__*/_react["default"].createElement("div", {
|
|
377
380
|
className: "communication__reply__cintainer"
|
|
378
381
|
}, /*#__PURE__*/_react["default"].createElement(_style.ReplyToUser, {
|
|
379
|
-
height: isShowReplyToUser ?
|
|
380
|
-
padding: isShowReplyToUser ?
|
|
382
|
+
height: isShowReplyToUser ? "auto" : "0",
|
|
383
|
+
padding: isShowReplyToUser ? "3px 0" : "0"
|
|
381
384
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
382
385
|
style: {
|
|
383
|
-
position:
|
|
384
|
-
top:
|
|
386
|
+
position: "relative",
|
|
387
|
+
top: "2px"
|
|
385
388
|
}
|
|
386
389
|
}, "\u56DE\u590D"), /*#__PURE__*/_react["default"].createElement(_style.ReplyUser, null, /*#__PURE__*/_react["default"].createElement("span", {
|
|
387
390
|
className: "name"
|
|
@@ -413,7 +416,7 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
413
416
|
onSubmit: function onSubmit() {
|
|
414
417
|
return _this2.setState({
|
|
415
418
|
isShowPraiseRecordPop: false,
|
|
416
|
-
praiseObjId:
|
|
419
|
+
praiseObjId: ""
|
|
417
420
|
});
|
|
418
421
|
}
|
|
419
422
|
}));
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var ConditionRender = function ConditionRender(_ref) {
|
|
9
|
+
var condition = _ref.condition,
|
|
10
|
+
children = _ref.children;
|
|
11
|
+
|
|
12
|
+
if (!condition) {
|
|
13
|
+
return null;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
return children;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
var _default = ConditionRender;
|
|
20
|
+
exports["default"] = _default;
|
|
@@ -156,7 +156,8 @@ var DynamicSearchInput = function DynamicSearchInput(_ref) {
|
|
|
156
156
|
className: prefix + "__input",
|
|
157
157
|
value: searchInputValue,
|
|
158
158
|
onChange: handleInputChange,
|
|
159
|
-
onKeyUp: handleKeyUp
|
|
159
|
+
onKeyUp: handleKeyUp,
|
|
160
|
+
placeholder: searchDynamicType === 'dynamic' ? '按关键词搜索' : '按姓名搜索'
|
|
160
161
|
}), isMouseEnter && searchInputValue && /*#__PURE__*/_react["default"].createElement("i", {
|
|
161
162
|
onClick: handleClearSearchValue,
|
|
162
163
|
className: (0, _classnames["default"])("tu-icon-circle", prefix + "__input-clear")
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
.titaui-dynamic-obj-status {
|
|
2
|
+
display: inline-block;
|
|
3
|
+
width: 18px;
|
|
4
|
+
height: 18px;
|
|
5
|
+
min-width: 18px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.titaui-dynamic-obj-status--delay {
|
|
9
|
+
background: url("../../img/dynamic-delay.svg");
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.titaui-dynamic-obj-status--normal {
|
|
13
|
+
background: url("../../img/dynamic-normal.svg");
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.titaui-dynamic-obj-status--risk {
|
|
17
|
+
background: url("../../img/dynamic-risk.svg");
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.titaui-dynamic-obj-status--end {
|
|
21
|
+
background: url("../../img/dynamic-end.svg");
|
|
22
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
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 _util = require("../../util");
|
|
13
|
+
|
|
14
|
+
require("./index.css");
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
|
|
18
|
+
var prefix = "titaui-dynamic-obj-status";
|
|
19
|
+
var StateIconMapping = {
|
|
20
|
+
delay: "".concat(prefix, "--delay"),
|
|
21
|
+
normal: "".concat(prefix, "--normal"),
|
|
22
|
+
risk: "".concat(prefix, "--risk"),
|
|
23
|
+
end: "".concat(prefix, "--end")
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
var DynamicObjStatus = function DynamicObjStatus(_ref) {
|
|
27
|
+
var _ref$oStatus = _ref.oStatus,
|
|
28
|
+
oStatus = _ref$oStatus === void 0 ? 1 : _ref$oStatus,
|
|
29
|
+
_ref$riskLevel = _ref.riskLevel,
|
|
30
|
+
riskLevel = _ref$riskLevel === void 0 ? 1 : _ref$riskLevel,
|
|
31
|
+
extraClass = _ref.extraClass;
|
|
32
|
+
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
33
|
+
className: (0, _classnames["default"])(extraClass, prefix, StateIconMapping[(0, _util.getProgressState)(oStatus, riskLevel)])
|
|
34
|
+
});
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
var _default = DynamicObjStatus;
|
|
38
|
+
exports["default"] = _default;
|