@titaui/pc 1.15.28-beta.2 → 1.15.29
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/nav-top/components/app-center/index.css +0 -29
- package/lib/components/nav-top/components/app-center/index.js +3 -94
- package/lib/components/nav-top/components/user-own-menu/components/own-menu/index.js +1 -12
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.js +4 -6
- package/lib/components/task-relation-modal/relation-single-okr/index.css +16 -5
- package/lib/index.js +0 -8
- package/package.json +1 -3
- package/lib/components/expiration-reminder/img/close.png +0 -0
- package/lib/components/expiration-reminder/img/close.svg +0 -16
- package/lib/components/expiration-reminder/img/emoji.svg +0 -16
- package/lib/components/expiration-reminder/img/qrcode-official.png +0 -0
- package/lib/components/expiration-reminder/img/qrcode-trial.png +0 -0
- package/lib/components/expiration-reminder/img/reminder.png +0 -0
- package/lib/components/expiration-reminder/index.css +0 -112
- package/lib/components/expiration-reminder/index.js +0 -304
- package/lib/components/expiration-reminder/utils.js +0 -58
- package/lib/components/mirroring/index.css +0 -67
- package/lib/components/mirroring/index.js +0 -39
- package/lib/components/nav-top/components/app-center/images/quick.svg +0 -30
- package/lib/components/quick-entrance/img/canceled.svg +0 -15
- package/lib/components/quick-entrance/img/drag-icon.svg +0 -18
- package/lib/components/quick-entrance/img/ork.svg +0 -20
- package/lib/components/quick-entrance/img/performance.svg +0 -20
- package/lib/components/quick-entrance/img/project.svg +0 -21
- package/lib/components/quick-entrance/index.css +0 -172
- package/lib/components/quick-entrance/index.js +0 -317
- package/lib/components/quick-entrance/render-item.js +0 -36
- package/lib/components/quick-entrance/request-api.js +0 -22
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
.titaui-quick-entrance-dialog {
|
|
2
|
-
padding: 0 32px;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.titaui-quick-entrance-dialog__wrap .rc-dialog {
|
|
6
|
-
width: 760px;
|
|
7
|
-
height: 580px;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.titaui-quick-entrance-dialog__title {
|
|
11
|
-
width: 108px;
|
|
12
|
-
font-size: 18px;
|
|
13
|
-
font-weight: 500;
|
|
14
|
-
color: #141C28;
|
|
15
|
-
line-height: 26px;
|
|
16
|
-
padding: 18px 0;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.titaui-quick-entrance-dialog__content {
|
|
20
|
-
width: 696px;
|
|
21
|
-
height: 442px;
|
|
22
|
-
background: #FFFFFF;
|
|
23
|
-
border-radius: 12px;
|
|
24
|
-
border: 1px solid #DFE3EA;
|
|
25
|
-
display: flex;
|
|
26
|
-
flex-direction: row;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
.titaui-quick-entrance-dialog__content__left {
|
|
30
|
-
width: 348px;
|
|
31
|
-
height: 100%;
|
|
32
|
-
flex-shrink: 0;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.titaui-quick-entrance-dialog__content__left-wrapper {
|
|
36
|
-
margin-top: 20px;
|
|
37
|
-
overflow-y: scroll;
|
|
38
|
-
overflow-y: overlay;
|
|
39
|
-
height: 95%;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.titaui-quick-entrance-dialog__content__left-wrapper::-webkit-scrollbar {
|
|
43
|
-
display: none;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.titaui-quick-entrance-dialog__content__left-wrapper:hover::-webkit-scrollbar {
|
|
47
|
-
display: block;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
.titaui-quick-entrance-dialog__content__left__item:nth-child(1) {
|
|
51
|
-
padding-top: 0px;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.titaui-quick-entrance-dialog__content__left__item {
|
|
55
|
-
padding: 20px 20px 0 20px;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-one {
|
|
59
|
-
display: flex;
|
|
60
|
-
flex-direction: row;
|
|
61
|
-
align-items: center;
|
|
62
|
-
margin-bottom: 8px;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-one__icon {
|
|
66
|
-
width: 28px;
|
|
67
|
-
height: 28px;
|
|
68
|
-
display: inline-block;
|
|
69
|
-
background-size: cover;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-one__title {
|
|
73
|
-
margin-left: 8px;
|
|
74
|
-
font-size: 14px;
|
|
75
|
-
font-weight: normal;
|
|
76
|
-
color: #89919F;
|
|
77
|
-
line-height: 22px;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-two {
|
|
81
|
-
display: flex;
|
|
82
|
-
flex-direction: row;
|
|
83
|
-
justify-content: space-between;
|
|
84
|
-
align-items: center;
|
|
85
|
-
height: 36px;
|
|
86
|
-
background: #FFFFFF;
|
|
87
|
-
border-radius: 8px;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-two:hover {
|
|
91
|
-
background: #F0F4FA;
|
|
92
|
-
cursor: pointer;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-two__title {
|
|
96
|
-
margin-left: 36px;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
.titaui-quick-entrance-dialog__content__left__item__menu-two__checkbox {
|
|
100
|
-
display: flex;
|
|
101
|
-
justify-content: center;
|
|
102
|
-
align-items: center;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.titaui-quick-entrance-dialog__content__right {
|
|
106
|
-
flex: 1;
|
|
107
|
-
border-left: 1px solid #DFE3EA;
|
|
108
|
-
height: 100%;
|
|
109
|
-
box-sizing: border-box;
|
|
110
|
-
padding: 20px 20px;
|
|
111
|
-
overflow-y: scroll;
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
.titaui-quick-entrance-dialog__content__right-yixuan {
|
|
115
|
-
font-size: 14px;
|
|
116
|
-
font-weight: normal;
|
|
117
|
-
color: #3F4755;
|
|
118
|
-
line-height: 22px;
|
|
119
|
-
margin-bottom: 12px;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.titaui-quick-entrance-dialog__content__right__item {
|
|
123
|
-
cursor: pointer;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.titaui-quick-entrance-dialog__content__right__item__container {
|
|
127
|
-
cursor: pointer;
|
|
128
|
-
box-sizing: border-box;
|
|
129
|
-
display: flex;
|
|
130
|
-
flex-direction: row;
|
|
131
|
-
align-items: center;
|
|
132
|
-
width: 307px;
|
|
133
|
-
height: 36px;
|
|
134
|
-
background: #F0F4FA;
|
|
135
|
-
border-radius: 8px;
|
|
136
|
-
margin-bottom: 8px;
|
|
137
|
-
padding: 0 8px;
|
|
138
|
-
position: relative;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
.titaui-quick-entrance-dialog__content__right__item__container__drag-icon {
|
|
142
|
-
width: 18px;
|
|
143
|
-
height: 18px;
|
|
144
|
-
background-image: url("./img/drag-icon.svg");
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
.titaui-quick-entrance-dialog__content__right__item__container__cancle-icon {
|
|
148
|
-
width: 16px;
|
|
149
|
-
height: 16px;
|
|
150
|
-
background-image: url("./img/canceled.svg");
|
|
151
|
-
position: absolute;
|
|
152
|
-
right: 8px;
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
.titaui-quick-entrance-dialog__content__right__item__container__title {
|
|
156
|
-
margin-left: 9px;
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
.titaui-quick-entrance-dialog .drag-boder {
|
|
160
|
-
width: 307px;
|
|
161
|
-
position: relative;
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
.titaui-quick-entrance-dialog .drag-boder::before {
|
|
165
|
-
content: '';
|
|
166
|
-
position: absolute;
|
|
167
|
-
top: 0;
|
|
168
|
-
left: 0;
|
|
169
|
-
width: 307px;
|
|
170
|
-
height: 1px;
|
|
171
|
-
background: #2879FF;
|
|
172
|
-
}
|
|
@@ -1,317 +0,0 @@
|
|
|
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 _reactSortablejs = require("react-sortablejs");
|
|
13
|
-
|
|
14
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
15
|
-
|
|
16
|
-
var _dialog = _interopRequireDefault(require("../dialog"));
|
|
17
|
-
|
|
18
|
-
var _renderItem = _interopRequireDefault(require("./render-item"));
|
|
19
|
-
|
|
20
|
-
var _bsGlobal = require("../../utils/bs-global");
|
|
21
|
-
|
|
22
|
-
var _requestApi = require("./request-api");
|
|
23
|
-
|
|
24
|
-
var _checkbox = _interopRequireDefault(require("../checkbox"));
|
|
25
|
-
|
|
26
|
-
require("./index.css");
|
|
27
|
-
|
|
28
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
29
|
-
|
|
30
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
31
|
-
|
|
32
|
-
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; }
|
|
33
|
-
|
|
34
|
-
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
35
|
-
|
|
36
|
-
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."); }
|
|
37
|
-
|
|
38
|
-
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
39
|
-
|
|
40
|
-
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
41
|
-
|
|
42
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
43
|
-
|
|
44
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
45
|
-
|
|
46
|
-
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); }
|
|
47
|
-
|
|
48
|
-
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; }
|
|
49
|
-
|
|
50
|
-
function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
51
|
-
|
|
52
|
-
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
53
|
-
|
|
54
|
-
var preCls = 'titaui-quick-entrance-dialog';
|
|
55
|
-
var QuickEntranceDialog = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
56
|
-
var _props$visible = props.visible,
|
|
57
|
-
visible = _props$visible === void 0 ? false : _props$visible,
|
|
58
|
-
handleOkQuickMenu = props.handleOkQuickMenu;
|
|
59
|
-
|
|
60
|
-
var _useState = (0, _react.useState)(visible),
|
|
61
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
62
|
-
dialogVisible = _useState2[0],
|
|
63
|
-
setDialogVisible = _useState2[1];
|
|
64
|
-
|
|
65
|
-
var _useState3 = (0, _react.useState)([]),
|
|
66
|
-
_useState4 = _slicedToArray(_useState3, 2),
|
|
67
|
-
entrancelist = _useState4[0],
|
|
68
|
-
setEntranceList = _useState4[1];
|
|
69
|
-
|
|
70
|
-
var QuickEntranceDialogRef = (0, _react.useRef)(null);
|
|
71
|
-
(0, _react.useImperativeHandle)(ref, function () {
|
|
72
|
-
return {
|
|
73
|
-
showDialog: showDialog,
|
|
74
|
-
hideDialog: hideDialog
|
|
75
|
-
};
|
|
76
|
-
});
|
|
77
|
-
var newNavigation = (0, _bsGlobal.getBSGlobal)('newNavigation');
|
|
78
|
-
var FilterNavigation = newNavigation.filter(function (item) {
|
|
79
|
-
if (item.appId === 119 || item.appId === 1) {
|
|
80
|
-
return;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
return item;
|
|
84
|
-
});
|
|
85
|
-
(0, _react.useEffect)(function () {
|
|
86
|
-
var quickMenu = newNavigation.find(function (item) {
|
|
87
|
-
return item.appId === 1;
|
|
88
|
-
});
|
|
89
|
-
|
|
90
|
-
if (quickMenu) {
|
|
91
|
-
var quickMenuChildren = quickMenu === null || quickMenu === void 0 ? void 0 : quickMenu.children;
|
|
92
|
-
var quickEntranceArr = [];
|
|
93
|
-
|
|
94
|
-
if (quickMenuChildren.length > 0) {
|
|
95
|
-
quickMenuChildren.forEach(function (item) {
|
|
96
|
-
quickEntranceArr.push({
|
|
97
|
-
id: item.id,
|
|
98
|
-
title: item.title,
|
|
99
|
-
appId: item.appId
|
|
100
|
-
});
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
setEntranceList(quickMenuChildren);
|
|
105
|
-
}
|
|
106
|
-
}, [dialogVisible]);
|
|
107
|
-
|
|
108
|
-
var handleOnOk = function handleOnOk() {
|
|
109
|
-
var menuIdArr = [];
|
|
110
|
-
entrancelist.forEach(function (item) {
|
|
111
|
-
menuIdArr.push(item.id);
|
|
112
|
-
});
|
|
113
|
-
var menuIds = menuIdArr.join(',');
|
|
114
|
-
(0, _requestApi.setHomeQuick)(menuIds).then(function (res) {
|
|
115
|
-
if (res.Code === 1) {
|
|
116
|
-
var newQuickMenu = getNewQuickMenu(menuIdArr);
|
|
117
|
-
updateNewNavigation(newQuickMenu);
|
|
118
|
-
handleOkQuickMenu && handleOkQuickMenu(newQuickMenu);
|
|
119
|
-
}
|
|
120
|
-
});
|
|
121
|
-
hideDialog();
|
|
122
|
-
};
|
|
123
|
-
|
|
124
|
-
var updateNewNavigation = function updateNewNavigation(newQuickMenu) {
|
|
125
|
-
//更新BSGlobal上的newNavigation
|
|
126
|
-
var newNavigation = window.BSGlobal.newNavigation.filter(function (item) {
|
|
127
|
-
if (item.code === 'quick') {
|
|
128
|
-
item.children = newQuickMenu;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
return item;
|
|
132
|
-
});
|
|
133
|
-
window.BSGlobal.newNavigation = newNavigation;
|
|
134
|
-
};
|
|
135
|
-
|
|
136
|
-
var getNewQuickMenu = function getNewQuickMenu(menuIdArr) {
|
|
137
|
-
//得到新的快捷菜单数组。
|
|
138
|
-
var childArr = [];
|
|
139
|
-
var newQuickMenu = [];
|
|
140
|
-
newNavigation.forEach(function (element) {
|
|
141
|
-
if (element.children.length > 0 && element.code !== 'quick') {
|
|
142
|
-
childArr = [].concat(_toConsumableArray(childArr), _toConsumableArray(element.children));
|
|
143
|
-
}
|
|
144
|
-
});
|
|
145
|
-
menuIdArr.forEach(function (id) {
|
|
146
|
-
var findInChildArrItem = childArr.find(function (item) {
|
|
147
|
-
return item.id === id;
|
|
148
|
-
});
|
|
149
|
-
|
|
150
|
-
if (findInChildArrItem) {
|
|
151
|
-
newQuickMenu.push(findInChildArrItem);
|
|
152
|
-
}
|
|
153
|
-
});
|
|
154
|
-
return newQuickMenu;
|
|
155
|
-
};
|
|
156
|
-
|
|
157
|
-
var handleOnCancel = function handleOnCancel() {
|
|
158
|
-
hideDialog();
|
|
159
|
-
};
|
|
160
|
-
|
|
161
|
-
var handleOnClose = function handleOnClose() {
|
|
162
|
-
hideDialog();
|
|
163
|
-
};
|
|
164
|
-
|
|
165
|
-
var handleClickDelete = function handleClickDelete(id) {
|
|
166
|
-
var newEntrancelist = _toConsumableArray(entrancelist);
|
|
167
|
-
|
|
168
|
-
var filterNewEntranceList = newEntrancelist.filter(function (item) {
|
|
169
|
-
if (item.id === id) {
|
|
170
|
-
return;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
return item;
|
|
174
|
-
});
|
|
175
|
-
setEntranceList(filterNewEntranceList);
|
|
176
|
-
};
|
|
177
|
-
|
|
178
|
-
var hideDialog = function hideDialog() {
|
|
179
|
-
setDialogVisible(false);
|
|
180
|
-
};
|
|
181
|
-
|
|
182
|
-
var showDialog = function showDialog() {
|
|
183
|
-
setDialogVisible(true);
|
|
184
|
-
}; // 开始拖拽
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
var onItemDragMove = function onItemDragMove(evt) {
|
|
188
|
-
evt.stopPropagation();
|
|
189
|
-
evt.dragged && evt.dragged.classList.add('drag-boder');
|
|
190
|
-
return true;
|
|
191
|
-
};
|
|
192
|
-
|
|
193
|
-
var onItemDragEnd = function onItemDragEnd(evt) {
|
|
194
|
-
evt.stopPropagation();
|
|
195
|
-
evt.item && evt.item.classList.remove('drag-boder');
|
|
196
|
-
return true;
|
|
197
|
-
};
|
|
198
|
-
|
|
199
|
-
var isCheckedById = function isCheckedById(id, title) {
|
|
200
|
-
var index = entrancelist.findIndex(function (item) {
|
|
201
|
-
return item.id === id;
|
|
202
|
-
});
|
|
203
|
-
|
|
204
|
-
if (index !== -1) {
|
|
205
|
-
return true;
|
|
206
|
-
} else {
|
|
207
|
-
return false;
|
|
208
|
-
}
|
|
209
|
-
};
|
|
210
|
-
|
|
211
|
-
var handleClickMenuTwoItem = function handleClickMenuTwoItem(item) {
|
|
212
|
-
//点击二级菜单选项,更新已选数据
|
|
213
|
-
var findItem = entrancelist.find(function (i) {
|
|
214
|
-
return i.id === item.id;
|
|
215
|
-
});
|
|
216
|
-
var isChecked = true;
|
|
217
|
-
|
|
218
|
-
if (findItem) {
|
|
219
|
-
isChecked = false;
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
var newEntrancelist = _toConsumableArray(entrancelist);
|
|
223
|
-
|
|
224
|
-
var checkedIndex = newEntrancelist.findIndex(function (i) {
|
|
225
|
-
return i.id === item.id;
|
|
226
|
-
});
|
|
227
|
-
|
|
228
|
-
if (isChecked) {
|
|
229
|
-
if (checkedIndex !== -1) {
|
|
230
|
-
setEntranceList(newEntrancelist);
|
|
231
|
-
return;
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
newEntrancelist.push({
|
|
235
|
-
id: item.id,
|
|
236
|
-
title: item.title
|
|
237
|
-
});
|
|
238
|
-
setEntranceList(newEntrancelist);
|
|
239
|
-
} else {
|
|
240
|
-
var filterNewEntrancelist = newEntrancelist.filter(function (i) {
|
|
241
|
-
if (i.id === item.id) {
|
|
242
|
-
return;
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
return i;
|
|
246
|
-
});
|
|
247
|
-
setEntranceList(filterNewEntrancelist);
|
|
248
|
-
}
|
|
249
|
-
};
|
|
250
|
-
|
|
251
|
-
return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_dialog["default"], {
|
|
252
|
-
wrapClassName: "".concat(preCls, "__wrap"),
|
|
253
|
-
noFooterLine: true,
|
|
254
|
-
visible: dialogVisible,
|
|
255
|
-
onOk: handleOnOk,
|
|
256
|
-
onCancel: handleOnCancel,
|
|
257
|
-
onClose: handleOnClose,
|
|
258
|
-
ref: QuickEntranceDialogRef
|
|
259
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
260
|
-
className: preCls
|
|
261
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
262
|
-
className: "".concat(preCls, "__title")
|
|
263
|
-
}, "\u8BBE\u7F6E\u5FEB\u6377\u5165\u53E3"), /*#__PURE__*/_react["default"].createElement("div", {
|
|
264
|
-
className: "".concat(preCls, "__content")
|
|
265
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
266
|
-
className: "".concat(preCls, "__content__left")
|
|
267
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
268
|
-
className: "".concat(preCls, "__content__left-wrapper")
|
|
269
|
-
}, FilterNavigation.map(function (item) {
|
|
270
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
271
|
-
className: "".concat(preCls, "__content__left__item")
|
|
272
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
273
|
-
className: "".concat(preCls, "__content__left__item__menu-one")
|
|
274
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
275
|
-
className: (0, _classnames["default"])("".concat(preCls, "__content__left__item__menu-one__icon"), "app-center__app-item-icon--".concat(item.iconName))
|
|
276
|
-
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
277
|
-
className: "".concat(preCls, "__content__left__item__menu-one__title")
|
|
278
|
-
}, item.title)), item.children.length > 0 && item.children.map(function (i) {
|
|
279
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
280
|
-
className: "".concat(preCls, "__content__left__item__menu-two"),
|
|
281
|
-
onClick: function onClick() {
|
|
282
|
-
return handleClickMenuTwoItem(i);
|
|
283
|
-
}
|
|
284
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
285
|
-
className: "".concat(preCls, "__content__left__item__menu-two__title")
|
|
286
|
-
}, i.title), /*#__PURE__*/_react["default"].createElement("div", {
|
|
287
|
-
className: "".concat(preCls, "__content__left__item__menu-two__checkbox")
|
|
288
|
-
}, /*#__PURE__*/_react["default"].createElement(_checkbox["default"], {
|
|
289
|
-
checked: function checked() {
|
|
290
|
-
return isCheckedById(i.id, i.title);
|
|
291
|
-
}
|
|
292
|
-
})));
|
|
293
|
-
}));
|
|
294
|
-
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
295
|
-
className: "".concat(preCls, "__content__right")
|
|
296
|
-
}, /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
297
|
-
className: "".concat(preCls, "__content__right-yixuan")
|
|
298
|
-
}, "\u5DF2\u9009"), /*#__PURE__*/_react["default"].createElement(_reactSortablejs.ReactSortable, {
|
|
299
|
-
list: entrancelist,
|
|
300
|
-
setList: setEntranceList,
|
|
301
|
-
animation: 200,
|
|
302
|
-
delayOnTouchStart: true,
|
|
303
|
-
delay: 2,
|
|
304
|
-
onEnd: onItemDragEnd,
|
|
305
|
-
onMove: onItemDragMove
|
|
306
|
-
}, entrancelist.length > 0 && entrancelist.map(function (item) {
|
|
307
|
-
return /*#__PURE__*/_react["default"].createElement(_react.Fragment, {
|
|
308
|
-
key: item.id
|
|
309
|
-
}, /*#__PURE__*/_react["default"].createElement(_renderItem["default"], {
|
|
310
|
-
id: item.id,
|
|
311
|
-
title: item.title,
|
|
312
|
-
handleClickDelete: handleClickDelete
|
|
313
|
-
}));
|
|
314
|
-
}))))))));
|
|
315
|
-
});
|
|
316
|
-
var _default = QuickEntranceDialog;
|
|
317
|
-
exports["default"] = _default;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports["default"] = void 0;
|
|
7
|
-
|
|
8
|
-
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
|
|
10
|
-
require("./index.css");
|
|
11
|
-
|
|
12
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
13
|
-
|
|
14
|
-
var preCls = 'titaui-quick-entrance-dialog';
|
|
15
|
-
|
|
16
|
-
var RenderItem = function RenderItem(props) {
|
|
17
|
-
var id = props.id,
|
|
18
|
-
title = props.title,
|
|
19
|
-
handleClickDelete = props.handleClickDelete;
|
|
20
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
21
|
-
className: "".concat(preCls, "__content__right__item__container")
|
|
22
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
23
|
-
className: "".concat(preCls, "__content__right__item__container__drag-icon"),
|
|
24
|
-
draggable: false
|
|
25
|
-
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
26
|
-
className: "".concat(preCls, "__content__right__item__container__title")
|
|
27
|
-
}, title), /*#__PURE__*/_react["default"].createElement("div", {
|
|
28
|
-
className: "".concat(preCls, "__content__right__item__container__cancle-icon"),
|
|
29
|
-
onClick: function onClick() {
|
|
30
|
-
return handleClickDelete(id);
|
|
31
|
-
}
|
|
32
|
-
}));
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
var _default = RenderItem;
|
|
36
|
-
exports["default"] = _default;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.setHomeQuick = void 0;
|
|
7
|
-
|
|
8
|
-
var _request = _interopRequireDefault(require("../../utils/request"));
|
|
9
|
-
|
|
10
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
-
|
|
12
|
-
;
|
|
13
|
-
var rget = _request["default"].rget,
|
|
14
|
-
rpost = _request["default"].rpost;
|
|
15
|
-
|
|
16
|
-
var setHomeQuick = function setHomeQuick(menuIds) {
|
|
17
|
-
return rpost('v3')("menu/set/homeQuick?menuIds=".concat(menuIds)).then(function (res) {
|
|
18
|
-
return res;
|
|
19
|
-
});
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
exports.setHomeQuick = setHomeQuick;
|