@titaui/pc 1.15.84-beta.2 → 1.15.84-beta.3
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/utils/auth.js +9 -5
- package/package.json +2 -2
package/lib/utils/auth.js
CHANGED
|
@@ -152,7 +152,7 @@ var KRAuth = /*#__PURE__*/function (_BaseAuth2) {
|
|
|
152
152
|
_this2 = _super2.call(this, props);
|
|
153
153
|
var user = props.user,
|
|
154
154
|
createUserId = props.createUserId;
|
|
155
|
-
_this2.loginUserInfor = (0, _bsGlobal.getBSGlobal)('loginUserInfo');
|
|
155
|
+
_this2.loginUserInfor = (0, _bsGlobal.getBSGlobal)('loginUserInfo') || {};
|
|
156
156
|
_this2.userId = _this2.loginUserInfor.Id;
|
|
157
157
|
_this2.user = user;
|
|
158
158
|
_this2.createUserId = createUserId;
|
|
@@ -240,7 +240,9 @@ var EAuth = /*#__PURE__*/function (_BaseAuth3) {
|
|
|
240
240
|
exports.EAuth = EAuth;
|
|
241
241
|
|
|
242
242
|
var hasSuperior = function hasSuperior() {
|
|
243
|
-
|
|
243
|
+
var _getBSGlobal;
|
|
244
|
+
|
|
245
|
+
return !!((_getBSGlobal = (0, _bsGlobal.getBSGlobal)('loginUserInfo')) !== null && _getBSGlobal !== void 0 && _getBSGlobal.ManagerId);
|
|
244
246
|
}; // 动态和项目文件管理权限
|
|
245
247
|
|
|
246
248
|
|
|
@@ -252,13 +254,15 @@ var DynamicManagerAuth = /*#__PURE__*/function (_BaseAuth4) {
|
|
|
252
254
|
var _super4 = _createSuper(DynamicManagerAuth);
|
|
253
255
|
|
|
254
256
|
function DynamicManagerAuth(props) {
|
|
257
|
+
var _getBSGlobal2, _getBSGlobal3;
|
|
258
|
+
|
|
255
259
|
var _this4;
|
|
256
260
|
|
|
257
261
|
_classCallCheck(this, DynamicManagerAuth);
|
|
258
262
|
|
|
259
263
|
_this4 = _super4.call(this, props);
|
|
260
|
-
_this4.isDynamicManager = (0, _bsGlobal.getBSGlobal)('loginUserInfo').IsFeedAndFileManager;
|
|
261
|
-
_this4.isLeader = (0, _bsGlobal.getBSGlobal)('loginUserInfo').IsLeader;
|
|
264
|
+
_this4.isDynamicManager = (_getBSGlobal2 = (0, _bsGlobal.getBSGlobal)('loginUserInfo')) === null || _getBSGlobal2 === void 0 ? void 0 : _getBSGlobal2.IsFeedAndFileManager;
|
|
265
|
+
_this4.isLeader = (_getBSGlobal3 = (0, _bsGlobal.getBSGlobal)('loginUserInfo')) === null || _getBSGlobal3 === void 0 ? void 0 : _getBSGlobal3.IsLeader;
|
|
262
266
|
return _this4;
|
|
263
267
|
}
|
|
264
268
|
|
|
@@ -329,7 +333,7 @@ var MyRole = /*#__PURE__*/function () {
|
|
|
329
333
|
|
|
330
334
|
_classCallCheck(this, MyRole);
|
|
331
335
|
|
|
332
|
-
this.loginUserInfo = (0, _bsGlobal.getBSGlobal)('loginUserInfo');
|
|
336
|
+
this.loginUserInfo = (0, _bsGlobal.getBSGlobal)('loginUserInfo') || {};
|
|
333
337
|
this.role_label = {
|
|
334
338
|
1: 'assistant',
|
|
335
339
|
// 助理或者说动态管理员
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@titaui/pc",
|
|
3
|
-
"version": "1.15.84-beta.
|
|
3
|
+
"version": "1.15.84-beta.3",
|
|
4
4
|
"nameCN": "",
|
|
5
5
|
"description": "",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
"@titaui/rc-trigger": "5.2.5",
|
|
85
85
|
"@titaui/react-flow-renderer": "9.5.4",
|
|
86
86
|
"@titaui/request": "1.1.8",
|
|
87
|
-
"@titaui/rich-editor": "0.1.
|
|
87
|
+
"@titaui/rich-editor": "0.1.76",
|
|
88
88
|
"@titaui/toast": "1.0.0",
|
|
89
89
|
"@types/color": "3.0.3",
|
|
90
90
|
"@types/prosemirror-commands": "1.0.4",
|