tnx-shared 5.3.244 → 5.3.246

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.
@@ -38456,6 +38456,7 @@
38456
38456
  // Dùng trong một số trường hợp code dùng chung template, buộc phải khai báo directive nhưng không phải element nào cũng cần check
38457
38457
  this.enableAuthorize = true;
38458
38458
  this.appCode = '';
38459
+ this.permissionChecked = false;
38459
38460
  this._element = _el.nativeElement;
38460
38461
  this.appCode = this._moduleConfigService.getConfig().appCode;
38461
38462
  this.environment = this._moduleConfigService.getConfig().environment;
@@ -38478,13 +38479,15 @@
38478
38479
  AuthorizeDirective.prototype.ngOnInit = function () {
38479
38480
  };
38480
38481
  AuthorizeDirective.prototype.ngAfterViewInit = function () {
38482
+ };
38483
+ AuthorizeDirective.prototype.permissionCheck = function () {
38481
38484
  var _this = this;
38482
- if (!this.permission) {
38483
- this.setAuthorizeButton();
38484
- }
38485
38485
  if (this._moduleCode) {
38486
38486
  this.appCode = this._moduleCode;
38487
38487
  }
38488
+ if (!this.permission) {
38489
+ this.setAuthorizeButton();
38490
+ }
38488
38491
  if (!this.enableAuthorize) {
38489
38492
  return;
38490
38493
  }
@@ -38519,6 +38522,13 @@
38519
38522
  }
38520
38523
  });
38521
38524
  };
38525
+ AuthorizeDirective.prototype.ngAfterViewChecked = function () {
38526
+ var buttons = sessionStorage.getItem(ComCtxConstants.LOCALSTORAGE_KEY.BUTTON_AUTHORIZE);
38527
+ if (!this.permissionChecked && buttons) {
38528
+ this.permissionCheck();
38529
+ this.permissionChecked = true;
38530
+ }
38531
+ };
38522
38532
  AuthorizeDirective.prototype.setAuthorizeButton = function () {
38523
38533
  var _a, _b, _c, _d, _e;
38524
38534
  var key = window.location.pathname.substring(1).toUpperCase().replace(/\//g, '_');
@@ -49962,10 +49972,10 @@
49962
49972
  else {
49963
49973
  this.showCountItem = false;
49964
49974
  }
49965
- }
49966
- var countItem = dom.DomHandler.findSingle(this.multiContainerEL.nativeElement, '.p-autocomplete-countItem');
49967
- if (this.showCountItem && !countItem) {
49968
- this.focusInput();
49975
+ var countItem = dom.DomHandler.findSingle(this.multiContainerEL.nativeElement, '.p-autocomplete-countItem');
49976
+ if (this.showCountItem && !countItem) {
49977
+ this.focusInput();
49978
+ }
49969
49979
  }
49970
49980
  };
49971
49981
  AutoComplete.prototype.handleSuggestionsChange = function () {