@senior-gestao-pessoas/payroll-core 9.3.0-d99b0dbd-5fc0-4b98-979b-fe30c751fa36 → 9.3.0-ee19ef91-03e0-4a39-923b-12f0b8cf42cc

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.
@@ -9301,9 +9301,18 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
9301
9301
  visible: _this.isEditMode,
9302
9302
  label: _this.translateService.instant("hcm.payroll.employees_image_cropper_view"),
9303
9303
  command: function () {
9304
- rowData["index"] = key;
9305
- _this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: false };
9306
- _this.visible = true;
9304
+ if (_this.isAllowToViewHistorical && rowData) {
9305
+ rowData["index"] = key;
9306
+ _this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: false };
9307
+ _this.visible = true;
9308
+ }
9309
+ else {
9310
+ _this.messageService.add({
9311
+ severity: "error",
9312
+ summary: _this.translateService.instant("hcm.payroll.error"),
9313
+ detail: _this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
9314
+ });
9315
+ }
9307
9316
  },
9308
9317
  },
9309
9318
  {
@@ -9563,6 +9572,13 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
9563
9572
  enumerable: true,
9564
9573
  configurable: true
9565
9574
  });
9575
+ Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToViewHistorical", {
9576
+ get: function () {
9577
+ return (this.permission["Visualizar"]);
9578
+ },
9579
+ enumerable: true,
9580
+ configurable: true
9581
+ });
9566
9582
  HistoricalPixAccountComponent.ctorParameters = function () { return [
9567
9583
  { type: TranslateService },
9568
9584
  { type: ChangeDetectorRef },