@senior-gestao-pessoas/payroll-core 9.3.0-784091e9-e857-4112-9344-e47026fdac80 → 9.3.0-7aaf9dac-728c-48d9-acf3-c7589164bebb
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/senior-gestao-pessoas-payroll-core.umd.js +126 -22
- package/bundles/senior-gestao-pessoas-payroll-core.umd.js.map +1 -1
- package/bundles/senior-gestao-pessoas-payroll-core.umd.min.js +1 -1
- package/bundles/senior-gestao-pessoas-payroll-core.umd.min.js.map +1 -1
- package/components/historical-pix-account/historical-pix-account.component.d.ts +14 -2
- package/components/historical-pix-account-list/historical-pix-account-list.component.d.ts +3 -0
- package/esm2015/components/historical-pix-account/historical-pix-account.component.js +79 -12
- package/esm2015/components/historical-pix-account-list/historical-pix-account-list.component.js +31 -13
- package/esm5/components/historical-pix-account/historical-pix-account.component.js +95 -12
- package/esm5/components/historical-pix-account-list/historical-pix-account-list.component.js +35 -13
- package/fesm2015/senior-gestao-pessoas-payroll-core.js +106 -22
- package/fesm2015/senior-gestao-pessoas-payroll-core.js.map +1 -1
- package/fesm5/senior-gestao-pessoas-payroll-core.js +126 -22
- package/fesm5/senior-gestao-pessoas-payroll-core.js.map +1 -1
- package/package.json +1 -1
- package/senior-gestao-pessoas-payroll-core.metadata.json +1 -1
|
@@ -9422,17 +9422,22 @@
|
|
|
9422
9422
|
}());
|
|
9423
9423
|
|
|
9424
9424
|
var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
9425
|
-
function HistoricalPixAccountComponent(translateService, cd, formBuilder) {
|
|
9425
|
+
function HistoricalPixAccountComponent(translateService, cd, formBuilder, messageService) {
|
|
9426
9426
|
var _this = this;
|
|
9427
9427
|
this.translateService = translateService;
|
|
9428
9428
|
this.cd = cd;
|
|
9429
9429
|
this.formBuilder = formBuilder;
|
|
9430
|
+
this.messageService = messageService;
|
|
9430
9431
|
this.recordByRow = 1;
|
|
9431
9432
|
this.showDateChange = false;
|
|
9432
9433
|
this.isEditMode = false;
|
|
9433
9434
|
this.isViewMode = false;
|
|
9434
9435
|
this.withSideBar = true;
|
|
9435
9436
|
this.defaultCpfNumber = null;
|
|
9437
|
+
this.listDataReciever = [];
|
|
9438
|
+
this.isOnlyView = new core.EventEmitter();
|
|
9439
|
+
this.isOnlyEdit = new core.EventEmitter();
|
|
9440
|
+
this.isOnlyDelete = new core.EventEmitter();
|
|
9436
9441
|
this.visibleChange = new core.EventEmitter();
|
|
9437
9442
|
this.ngUnsubscribe = new rxjs.Subject();
|
|
9438
9443
|
this.orderBy = {
|
|
@@ -9466,26 +9471,52 @@
|
|
|
9466
9471
|
visible: _this.isEditMode,
|
|
9467
9472
|
label: _this.translateService.instant("hcm.payroll.employees_image_cropper_view"),
|
|
9468
9473
|
command: function () {
|
|
9469
|
-
|
|
9470
|
-
|
|
9471
|
-
|
|
9474
|
+
if (_this.isAllowToViewHistorical) {
|
|
9475
|
+
rowData["index"] = key;
|
|
9476
|
+
_this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: false };
|
|
9477
|
+
_this.visible = true;
|
|
9478
|
+
}
|
|
9479
|
+
else {
|
|
9480
|
+
_this.isOnlyView.emit(true);
|
|
9481
|
+
}
|
|
9472
9482
|
},
|
|
9473
9483
|
},
|
|
9474
9484
|
{
|
|
9475
9485
|
visible: !!(!_this.isEditMode && _this.withSideBar),
|
|
9476
9486
|
label: _this.translateService.instant("hcm.payroll.edit"),
|
|
9477
9487
|
command: function () {
|
|
9478
|
-
|
|
9479
|
-
|
|
9480
|
-
|
|
9488
|
+
if (_this.isAllowToEditHistorical) {
|
|
9489
|
+
console.log("ENTER IN isAllowToEditHistorical");
|
|
9490
|
+
rowData["index"] = key;
|
|
9491
|
+
_this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: true };
|
|
9492
|
+
_this.visible = true;
|
|
9493
|
+
}
|
|
9494
|
+
else {
|
|
9495
|
+
_this.isOnlyEdit.emit(true);
|
|
9496
|
+
if (!_this.listDataReciever) {
|
|
9497
|
+
console.log("ENTER IN listDataReciever");
|
|
9498
|
+
rowData["index"] = key;
|
|
9499
|
+
_this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: true };
|
|
9500
|
+
_this.visible = true;
|
|
9501
|
+
}
|
|
9502
|
+
}
|
|
9481
9503
|
},
|
|
9482
9504
|
},
|
|
9483
9505
|
{
|
|
9484
9506
|
visible: !_this.isEditMode,
|
|
9485
9507
|
label: _this.translateService.instant("hcm.payroll.delete"),
|
|
9486
9508
|
command: function () {
|
|
9487
|
-
_this.
|
|
9488
|
-
|
|
9509
|
+
if (_this.isAllowToDeleteHistorical) {
|
|
9510
|
+
_this.loading = true;
|
|
9511
|
+
_this.deleteAnnuityItem(key);
|
|
9512
|
+
}
|
|
9513
|
+
else {
|
|
9514
|
+
_this.isOnlyDelete.emit(true);
|
|
9515
|
+
if (!_this.listDataReciever) {
|
|
9516
|
+
_this.loading = true;
|
|
9517
|
+
_this.deleteAnnuityItem(key);
|
|
9518
|
+
}
|
|
9519
|
+
}
|
|
9489
9520
|
},
|
|
9490
9521
|
},
|
|
9491
9522
|
];
|
|
@@ -9551,6 +9582,13 @@
|
|
|
9551
9582
|
this.pixAccountItemInput = {};
|
|
9552
9583
|
this.visible = true;
|
|
9553
9584
|
};
|
|
9585
|
+
HistoricalPixAccountComponent.prototype.isNotAllowMessage = function () {
|
|
9586
|
+
this.messageService.add({
|
|
9587
|
+
severity: "error",
|
|
9588
|
+
summary: this.translateService.instant("hcm.payroll.error"),
|
|
9589
|
+
detail: this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
|
|
9590
|
+
});
|
|
9591
|
+
};
|
|
9554
9592
|
HistoricalPixAccountComponent.prototype.deleteAnnuityItem = function (index) {
|
|
9555
9593
|
var newlist = __spread(this.getHistoricalPixAccountList());
|
|
9556
9594
|
newlist.sort(compareValues(this.orderBy.field, this.orderBy.direction));
|
|
@@ -9696,10 +9734,39 @@
|
|
|
9696
9734
|
HistoricalPixAccountComponent.prototype.getFormattedPercentage = function (value) {
|
|
9697
9735
|
return FormatUtilsService.getFormattedPercentage(value);
|
|
9698
9736
|
};
|
|
9737
|
+
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToAddHistorical", {
|
|
9738
|
+
get: function () {
|
|
9739
|
+
return (this.permission["incluir"]);
|
|
9740
|
+
},
|
|
9741
|
+
enumerable: true,
|
|
9742
|
+
configurable: true
|
|
9743
|
+
});
|
|
9744
|
+
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToDeleteHistorical", {
|
|
9745
|
+
get: function () {
|
|
9746
|
+
return (this.permission["excluir"]);
|
|
9747
|
+
},
|
|
9748
|
+
enumerable: true,
|
|
9749
|
+
configurable: true
|
|
9750
|
+
});
|
|
9751
|
+
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToEditHistorical", {
|
|
9752
|
+
get: function () {
|
|
9753
|
+
return (this.permission["editar"]);
|
|
9754
|
+
},
|
|
9755
|
+
enumerable: true,
|
|
9756
|
+
configurable: true
|
|
9757
|
+
});
|
|
9758
|
+
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToViewHistorical", {
|
|
9759
|
+
get: function () {
|
|
9760
|
+
return (this.permission["visualizar"]);
|
|
9761
|
+
},
|
|
9762
|
+
enumerable: true,
|
|
9763
|
+
configurable: true
|
|
9764
|
+
});
|
|
9699
9765
|
HistoricalPixAccountComponent.ctorParameters = function () { return [
|
|
9700
9766
|
{ type: core$1.TranslateService },
|
|
9701
9767
|
{ type: core.ChangeDetectorRef },
|
|
9702
|
-
{ type: forms.FormBuilder }
|
|
9768
|
+
{ type: forms.FormBuilder },
|
|
9769
|
+
{ type: api.MessageService }
|
|
9703
9770
|
]; };
|
|
9704
9771
|
__decorate([
|
|
9705
9772
|
core.ViewChild(angularComponents.CustomFieldsComponent, { static: false })
|
|
@@ -9749,6 +9816,21 @@
|
|
|
9749
9816
|
__decorate([
|
|
9750
9817
|
core.Input()
|
|
9751
9818
|
], HistoricalPixAccountComponent.prototype, "defaultCpfNumber", void 0);
|
|
9819
|
+
__decorate([
|
|
9820
|
+
core.Input()
|
|
9821
|
+
], HistoricalPixAccountComponent.prototype, "permission", void 0);
|
|
9822
|
+
__decorate([
|
|
9823
|
+
core.Input()
|
|
9824
|
+
], HistoricalPixAccountComponent.prototype, "listDataReciever", void 0);
|
|
9825
|
+
__decorate([
|
|
9826
|
+
core.Output()
|
|
9827
|
+
], HistoricalPixAccountComponent.prototype, "isOnlyView", void 0);
|
|
9828
|
+
__decorate([
|
|
9829
|
+
core.Output()
|
|
9830
|
+
], HistoricalPixAccountComponent.prototype, "isOnlyEdit", void 0);
|
|
9831
|
+
__decorate([
|
|
9832
|
+
core.Output()
|
|
9833
|
+
], HistoricalPixAccountComponent.prototype, "isOnlyDelete", void 0);
|
|
9752
9834
|
__decorate([
|
|
9753
9835
|
core.Input()
|
|
9754
9836
|
], HistoricalPixAccountComponent.prototype, "dateChange", null);
|
|
@@ -10413,6 +10495,7 @@
|
|
|
10413
10495
|
this.endPoint = "hcm/payroll/queries/historicalEmployeePixQuery";
|
|
10414
10496
|
this.keyPayload = "historicalEmployeePix";
|
|
10415
10497
|
this.withSidebar = true;
|
|
10498
|
+
this.isOnlyView = new core.EventEmitter();
|
|
10416
10499
|
this.enableView = new core.EventEmitter();
|
|
10417
10500
|
this.ngUnsubscribe = new rxjs.Subject();
|
|
10418
10501
|
this.loading = true;
|
|
@@ -10480,13 +10563,21 @@
|
|
|
10480
10563
|
{
|
|
10481
10564
|
label: this.translateService.instant("hcm.payroll.employees_image_cropper_view"),
|
|
10482
10565
|
command: function () {
|
|
10483
|
-
|
|
10484
|
-
|
|
10485
|
-
_this.
|
|
10486
|
-
|
|
10487
|
-
|
|
10488
|
-
|
|
10489
|
-
|
|
10566
|
+
if (_this.isAllowToViewHistorical) {
|
|
10567
|
+
var dateChange = rowData && rowData.dateChange && moment$e(rowData.dateChange, _this.dateFormat).format("YYYY-MM-DD");
|
|
10568
|
+
if (_this.withSidebar) {
|
|
10569
|
+
_this.isOnlyView.emit(true);
|
|
10570
|
+
_this.router.navigate(["historical-pix-account/" + dateChange], {
|
|
10571
|
+
relativeTo: _this.activatedRoute,
|
|
10572
|
+
});
|
|
10573
|
+
}
|
|
10574
|
+
else {
|
|
10575
|
+
_this.enableView.emit(dateChange);
|
|
10576
|
+
}
|
|
10577
|
+
}
|
|
10578
|
+
else {
|
|
10579
|
+
_this.isNotAllowMessage();
|
|
10580
|
+
}
|
|
10490
10581
|
},
|
|
10491
10582
|
},
|
|
10492
10583
|
{
|
|
@@ -10496,11 +10587,7 @@
|
|
|
10496
10587
|
_this.delete(rowData.id, rowData.dateChange);
|
|
10497
10588
|
}
|
|
10498
10589
|
else {
|
|
10499
|
-
_this.
|
|
10500
|
-
severity: "error",
|
|
10501
|
-
summary: _this.translateService.instant("hcm.payroll.error"),
|
|
10502
|
-
detail: _this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
|
|
10503
|
-
});
|
|
10590
|
+
_this.isNotAllowMessage();
|
|
10504
10591
|
}
|
|
10505
10592
|
},
|
|
10506
10593
|
},
|
|
@@ -10558,6 +10645,13 @@
|
|
|
10558
10645
|
});
|
|
10559
10646
|
}
|
|
10560
10647
|
};
|
|
10648
|
+
HistoricalPixAccountListComponent.prototype.isNotAllowMessage = function () {
|
|
10649
|
+
this.messageService.add({
|
|
10650
|
+
severity: "error",
|
|
10651
|
+
summary: this.translateService.instant("hcm.payroll.error"),
|
|
10652
|
+
detail: this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
|
|
10653
|
+
});
|
|
10654
|
+
};
|
|
10561
10655
|
HistoricalPixAccountListComponent.prototype.onGridLoad = function (payload) {
|
|
10562
10656
|
if (payload && payload.length) {
|
|
10563
10657
|
this.lastRecord = payload[0];
|
|
@@ -10577,6 +10671,13 @@
|
|
|
10577
10671
|
enumerable: true,
|
|
10578
10672
|
configurable: true
|
|
10579
10673
|
});
|
|
10674
|
+
Object.defineProperty(HistoricalPixAccountListComponent.prototype, "isAllowToViewHistorical", {
|
|
10675
|
+
get: function () {
|
|
10676
|
+
return (this.permission["visualizar"]);
|
|
10677
|
+
},
|
|
10678
|
+
enumerable: true,
|
|
10679
|
+
configurable: true
|
|
10680
|
+
});
|
|
10580
10681
|
Object.defineProperty(HistoricalPixAccountListComponent.prototype, "scopedActions", {
|
|
10581
10682
|
get: function () {
|
|
10582
10683
|
return this.getMenuActions.bind(this);
|
|
@@ -10627,6 +10728,9 @@
|
|
|
10627
10728
|
__decorate([
|
|
10628
10729
|
core.Input()
|
|
10629
10730
|
], HistoricalPixAccountListComponent.prototype, "withSidebar", void 0);
|
|
10731
|
+
__decorate([
|
|
10732
|
+
core.Output()
|
|
10733
|
+
], HistoricalPixAccountListComponent.prototype, "isOnlyView", void 0);
|
|
10630
10734
|
__decorate([
|
|
10631
10735
|
core.Output()
|
|
10632
10736
|
], HistoricalPixAccountListComponent.prototype, "enableView", void 0);
|