tnx-shared 5.1.418 → 5.1.419
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/bundles/tnx-shared.umd.js +11 -7
- package/bundles/tnx-shared.umd.js.map +1 -1
- package/bundles/tnx-shared.umd.min.js +1 -1
- package/bundles/tnx-shared.umd.min.js.map +1 -1
- package/components/splash-component/splash-component-v1/splash-component-v1.component.d.ts.map +1 -1
- package/esm2015/components/splash-component/splash-component-v1/splash-component-v1.component.js +9 -3
- package/esm2015/components/splash-component/splash-component-v2/splash-component-v2.component.js +2 -2
- package/esm2015/services/permission.service.js +9 -4
- package/esm2015/services/position.service.js +4 -4
- package/fesm2015/tnx-shared.js +18 -7
- package/fesm2015/tnx-shared.js.map +1 -1
- package/package.json +2 -2
- package/services/permission.service.d.ts.map +1 -1
- package/services/position.service.d.ts +2 -2
- package/services/position.service.d.ts.map +1 -1
- package/tnx-shared.metadata.json +1 -1
|
@@ -20279,7 +20279,7 @@
|
|
|
20279
20279
|
: this._checkPermission(userPermissions, permissionToCheck)];
|
|
20280
20280
|
}
|
|
20281
20281
|
else {
|
|
20282
|
-
console.log(
|
|
20282
|
+
// console.log(`Không có quyền với phân hệ [${service}]`);
|
|
20283
20283
|
return [2 /*return*/, false];
|
|
20284
20284
|
}
|
|
20285
20285
|
return [3 /*break*/, 3];
|
|
@@ -20305,6 +20305,8 @@
|
|
|
20305
20305
|
var userPermissionPointer = 0;
|
|
20306
20306
|
// pointer permission đang check
|
|
20307
20307
|
var permissionToCheckPointer = 0;
|
|
20308
|
+
// mark co the check query param
|
|
20309
|
+
var aboutToCheckQueryParam = false;
|
|
20308
20310
|
// check từng char của 2 mảng
|
|
20309
20311
|
for (; permissionToCheckPointer < permissionToCheck.length;) {
|
|
20310
20312
|
// nếu char là ký tự bắt đầu template => tịnh tiến pointer của 2 mảng
|
|
@@ -20318,10 +20320,13 @@
|
|
|
20318
20320
|
if (userPermission[userPermissionPointer] != '}') {
|
|
20319
20321
|
continue;
|
|
20320
20322
|
}
|
|
20323
|
+
if (userPermission[userPermissionPointer] === '?') {
|
|
20324
|
+
aboutToCheckQueryParam = true;
|
|
20325
|
+
}
|
|
20321
20326
|
++userPermissionPointer; // tiến tiến đến ký tự sau kết thúc template
|
|
20322
20327
|
// check trường hợp trường hợp chuỗi template có dạng "{template}acsekjf"
|
|
20323
20328
|
// => cần check các ký tự sau template và trước ký tự '/'
|
|
20324
|
-
if (userPermission[userPermissionPointer] != '/') {
|
|
20329
|
+
if (userPermission[userPermissionPointer] != '/' && (aboutToCheckQueryParam && userPermission[userPermissionPointer] != '&')) {
|
|
20325
20330
|
needRecheck = true;
|
|
20326
20331
|
for (; userPermissionPointer < userPermission.length; userPermissionPointer++) {
|
|
20327
20332
|
if (userPermissionPointer == userPermission.length - 1) {
|
|
@@ -20339,7 +20344,7 @@
|
|
|
20339
20344
|
if (permissionToCheckPointer == permissionToCheck.length - 1) {
|
|
20340
20345
|
break;
|
|
20341
20346
|
}
|
|
20342
|
-
if (permissionToCheck[permissionToCheckPointer] == '/') {
|
|
20347
|
+
if (permissionToCheck[permissionToCheckPointer] == '/' || (aboutToCheckQueryParam && permissionToCheck[permissionToCheckPointer] == '&')) {
|
|
20343
20348
|
break;
|
|
20344
20349
|
}
|
|
20345
20350
|
}
|
|
@@ -43141,7 +43146,7 @@
|
|
|
43141
43146
|
var PositionService = /** @class */ (function (_super) {
|
|
43142
43147
|
__extends(PositionService, _super);
|
|
43143
43148
|
function PositionService(http, injector, _moduleConfigService) {
|
|
43144
|
-
var _this = _super.call(this, http, injector, _moduleConfigService.getConfig().environment.apiDomain.userOrgEndpoint + "/" + _moduleConfigService.getConfig().environment.apiVersion + "/
|
|
43149
|
+
var _this = _super.call(this, http, injector, _moduleConfigService.getConfig().environment.apiDomain.userOrgEndpoint + "/" + _moduleConfigService.getConfig().environment.apiVersion + "/DmChucVu") || this;
|
|
43145
43150
|
_this._moduleConfigService = _moduleConfigService;
|
|
43146
43151
|
_this.entityName = 'DmChucVu';
|
|
43147
43152
|
_this.serviceCode = 'UserOrg';
|
|
@@ -53713,7 +53718,6 @@
|
|
|
53713
53718
|
return [4 /*yield*/, this._permissionService.isAuthorized(element.code, (element.code + ".MODULE." + element.code).toUpperCase(), true)];
|
|
53714
53719
|
case 3:
|
|
53715
53720
|
isAuthorized = _c.sent();
|
|
53716
|
-
// const isAuthorized = await this._permissionService.isAuthorized(element.code, `test/lksjeflksejflseifjseifjslkejfkiki/test/kkjlskejflsekfjseklfj`.toUpperCase());
|
|
53717
53721
|
if (isAuthorized) {
|
|
53718
53722
|
arr.push(element);
|
|
53719
53723
|
}
|
|
@@ -53748,7 +53752,7 @@
|
|
|
53748
53752
|
}
|
|
53749
53753
|
});
|
|
53750
53754
|
if (_this.appSwitcherItems.length === 1) {
|
|
53751
|
-
_this.switchApp(_this.appSwitcherItems[0]);
|
|
53755
|
+
setTimeout(function (x) { return _this.switchApp(_this.appSwitcherItems[0]); }, 100);
|
|
53752
53756
|
}
|
|
53753
53757
|
}
|
|
53754
53758
|
});
|
|
@@ -53958,7 +53962,7 @@
|
|
|
53958
53962
|
}
|
|
53959
53963
|
});
|
|
53960
53964
|
if (_this.appSwitcherItems.length === 1) {
|
|
53961
|
-
_this.switchApp(_this.appSwitcherItems[0]);
|
|
53965
|
+
setTimeout(function (x) { return _this.switchApp(_this.appSwitcherItems[0]); }, 100);
|
|
53962
53966
|
}
|
|
53963
53967
|
}
|
|
53964
53968
|
});
|