tnx-shared 5.3.248 → 5.3.249

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.
@@ -20759,7 +20759,7 @@
20759
20759
  var _this = this;
20760
20760
  if (enumCanBo === void 0) { enumCanBo = exports.EnumCanBo.TRONG_DON_VI; }
20761
20761
  var _a;
20762
- var columns = this.lstEntityPickerColumn;
20762
+ var columns = __spreadArray([], __read(this.lstEntityPickerColumn));
20763
20763
  if (((_a = control.columns) === null || _a === void 0 ? void 0 : _a.length) > 0) {
20764
20764
  columns.push.apply(columns, __spreadArray([], __read(control.columns)));
20765
20765
  }
@@ -21744,6 +21744,9 @@
21744
21744
  _this.endPoint = _moduleConfigService.getConfig().environment.apiDomain.authorizationEndpoint;
21745
21745
  return _this;
21746
21746
  }
21747
+ BasePermissionService.prototype.getPermissionByCode = function (code) {
21748
+ return this.defaultGet(this.serviceUri + "/GetPermissionByCode?code=" + code);
21749
+ };
21747
21750
  return BasePermissionService;
21748
21751
  }(BaseService));
21749
21752
  BasePermissionService.ɵprov = i0__namespace.ɵɵdefineInjectable({ factory: function BasePermissionService_Factory() { return new BasePermissionService(i0__namespace.ɵɵinject(i1__namespace$1.HttpClient), i0__namespace.ɵɵinject(i0__namespace.INJECTOR), i0__namespace.ɵɵinject(ModuleConfigService)); }, token: BasePermissionService, providedIn: "root" });
@@ -25692,7 +25695,7 @@
25692
25695
  ListComponentBase.prototype.setAuthorizeButton = function (lstButtonTemplate) {
25693
25696
  var _a, _b;
25694
25697
  return __awaiter(this, void 0, void 0, function () {
25695
- var filterPermission, lstPermissionCode, buttonSetting, lstMenuButton, lstMenuButtons, _c_1;
25698
+ var lstPermissionCode, buttonSetting, lstMenuButton, lstMenuButtons, _c_1;
25696
25699
  var _this = this;
25697
25700
  return __generator(this, function (_h) {
25698
25701
  switch (_h.label) {
@@ -25701,8 +25704,7 @@
25701
25704
  if (i0.isDevMode()) {
25702
25705
  this.authorizeButtonKey = (this.serviceCode.toUpperCase() || this._moduleConfigService.getConfig().appCode.toUpperCase()) + "_" + window.location.pathname.substring(1).toUpperCase();
25703
25706
  }
25704
- filterPermission = [this.newFilter('code', exports.Operator.contain, "[" + this.authorizeButtonKey + "]")];
25705
- return [4 /*yield*/, this._basePermissionService.getAllWithIgnore(filterPermission, 'code,id')];
25707
+ return [4 /*yield*/, this._basePermissionService.getPermissionByCode("[" + this.authorizeButtonKey + "]")];
25706
25708
  case 1:
25707
25709
  lstPermissionCode = (_a = (_h.sent()).data) !== null && _a !== void 0 ? _a : [];
25708
25710
  buttonSetting = JSON.parse(sessionStorage.getItem(ComCtxConstants.LOCALSTORAGE_KEY.BUTTON_AUTHORIZE) || '{}');