@senior-gestao-pessoas/payroll-core 9.3.0-fdc2ca03-c046-451a-bb4a-4d788fbde8cb → 9.4.0-02f1998a-8c51-4317-9b38-c21241fa2248
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 +121 -63
- 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 +10 -2
- package/components/historical-pix-account-list/historical-pix-account-list.component.d.ts +4 -1
- package/esm2015/components/historical-pix-account/historical-pix-account.component.js +60 -22
- package/esm2015/components/historical-pix-account-list/historical-pix-account-list.component.js +57 -46
- package/esm5/components/historical-pix-account/historical-pix-account.component.js +64 -22
- package/esm5/components/historical-pix-account-list/historical-pix-account-list.component.js +61 -46
- package/fesm2015/senior-gestao-pessoas-payroll-core.js +113 -63
- package/fesm2015/senior-gestao-pessoas-payroll-core.js.map +1 -1
- package/fesm5/senior-gestao-pessoas-payroll-core.js +121 -63
- package/fesm5/senior-gestao-pessoas-payroll-core.js.map +1 -1
- package/locale/en-US.json +1 -1
- package/locale/es-ES.json +1 -1
- package/locale/pt-BR.json +1 -1
- package/package.json +2 -32
- package/senior-gestao-pessoas-payroll-core.metadata.json +1 -1
|
@@ -9268,6 +9268,11 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9268
9268
|
this.isViewMode = false;
|
|
9269
9269
|
this.withSideBar = true;
|
|
9270
9270
|
this.defaultCpfNumber = null;
|
|
9271
|
+
this.listDataReciever = [];
|
|
9272
|
+
this.isViewModeActive = new EventEmitter();
|
|
9273
|
+
this.isEditModeActive = new EventEmitter();
|
|
9274
|
+
this.isDeleteModeActive = new EventEmitter();
|
|
9275
|
+
this.listFromApp = [];
|
|
9271
9276
|
this.visibleChange = new EventEmitter();
|
|
9272
9277
|
this.ngUnsubscribe = new Subject();
|
|
9273
9278
|
this.orderBy = {
|
|
@@ -9301,26 +9306,32 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9301
9306
|
visible: _this.isEditMode,
|
|
9302
9307
|
label: _this.translateService.instant("hcm.payroll.employees_image_cropper_view"),
|
|
9303
9308
|
command: function () {
|
|
9304
|
-
|
|
9305
|
-
|
|
9306
|
-
|
|
9309
|
+
if (_this.isAllowToViewHistorical) {
|
|
9310
|
+
rowData["index"] = key;
|
|
9311
|
+
_this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: false };
|
|
9312
|
+
_this.visible = true;
|
|
9313
|
+
}
|
|
9314
|
+
else {
|
|
9315
|
+
_this.isViewModeActive.emit(true);
|
|
9316
|
+
}
|
|
9307
9317
|
},
|
|
9308
9318
|
},
|
|
9309
9319
|
{
|
|
9310
9320
|
visible: !!(!_this.isEditMode && _this.withSideBar),
|
|
9311
9321
|
label: _this.translateService.instant("hcm.payroll.edit"),
|
|
9312
9322
|
command: function () {
|
|
9313
|
-
if (_this.isAllowToEditHistorical
|
|
9323
|
+
if (_this.isAllowToEditHistorical) {
|
|
9314
9324
|
rowData["index"] = key;
|
|
9315
9325
|
_this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: true };
|
|
9316
9326
|
_this.visible = true;
|
|
9317
9327
|
}
|
|
9318
9328
|
else {
|
|
9319
|
-
_this.
|
|
9320
|
-
|
|
9321
|
-
|
|
9322
|
-
|
|
9323
|
-
|
|
9329
|
+
_this.isEditModeActive.emit(true);
|
|
9330
|
+
if (_this.listFromApp.length == 0) {
|
|
9331
|
+
rowData["index"] = key;
|
|
9332
|
+
_this.pixAccountItemInput = { currentItem: rowData, listData: _this.listDataNoPage, isEditMode: true };
|
|
9333
|
+
_this.visible = true;
|
|
9334
|
+
}
|
|
9324
9335
|
}
|
|
9325
9336
|
},
|
|
9326
9337
|
},
|
|
@@ -9328,16 +9339,16 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9328
9339
|
visible: !_this.isEditMode,
|
|
9329
9340
|
label: _this.translateService.instant("hcm.payroll.delete"),
|
|
9330
9341
|
command: function () {
|
|
9331
|
-
if (_this.isAllowToDeleteHistorical
|
|
9342
|
+
if (_this.isAllowToDeleteHistorical) {
|
|
9332
9343
|
_this.loading = true;
|
|
9333
9344
|
_this.deleteAnnuityItem(key);
|
|
9334
9345
|
}
|
|
9335
9346
|
else {
|
|
9336
|
-
_this.
|
|
9337
|
-
|
|
9338
|
-
|
|
9339
|
-
|
|
9340
|
-
}
|
|
9347
|
+
_this.isDeleteModeActive.emit(true);
|
|
9348
|
+
if (_this.listFromApp.length == 0) {
|
|
9349
|
+
_this.loading = true;
|
|
9350
|
+
_this.deleteAnnuityItem(key);
|
|
9351
|
+
}
|
|
9341
9352
|
}
|
|
9342
9353
|
},
|
|
9343
9354
|
},
|
|
@@ -9348,6 +9359,11 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9348
9359
|
HistoricalPixAccountComponent.prototype.ngOnInit = function () {
|
|
9349
9360
|
this.formGroup.setControl(this.fieldFormGroup, this.historicalPixAccountList);
|
|
9350
9361
|
};
|
|
9362
|
+
HistoricalPixAccountComponent.prototype.ngOnChanges = function (changes) {
|
|
9363
|
+
if (changes['listDataReciever'] && changes['listDataReciever'].currentValue) {
|
|
9364
|
+
this.listFromApp = changes['listDataReciever'].currentValue;
|
|
9365
|
+
}
|
|
9366
|
+
};
|
|
9351
9367
|
HistoricalPixAccountComponent.prototype.createFormGroup = function () {
|
|
9352
9368
|
this.historicalPixAccountList = this.formBuilder.group({
|
|
9353
9369
|
historicalPixAccountList: this.formBuilder.control(null),
|
|
@@ -9404,6 +9420,13 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9404
9420
|
this.pixAccountItemInput = {};
|
|
9405
9421
|
this.visible = true;
|
|
9406
9422
|
};
|
|
9423
|
+
HistoricalPixAccountComponent.prototype.isNotAllowMessage = function () {
|
|
9424
|
+
this.messageService.add({
|
|
9425
|
+
severity: "error",
|
|
9426
|
+
summary: this.translateService.instant("hcm.payroll.error"),
|
|
9427
|
+
detail: this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
|
|
9428
|
+
});
|
|
9429
|
+
};
|
|
9407
9430
|
HistoricalPixAccountComponent.prototype.deleteAnnuityItem = function (index) {
|
|
9408
9431
|
var newlist = __spread(this.getHistoricalPixAccountList());
|
|
9409
9432
|
newlist.sort(compareValues(this.orderBy.field, this.orderBy.direction));
|
|
@@ -9549,23 +9572,30 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9549
9572
|
HistoricalPixAccountComponent.prototype.getFormattedPercentage = function (value) {
|
|
9550
9573
|
return FormatUtilsService.getFormattedPercentage(value);
|
|
9551
9574
|
};
|
|
9575
|
+
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToAddHistorical", {
|
|
9576
|
+
get: function () {
|
|
9577
|
+
return (this.permission["incluir"]);
|
|
9578
|
+
},
|
|
9579
|
+
enumerable: true,
|
|
9580
|
+
configurable: true
|
|
9581
|
+
});
|
|
9552
9582
|
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToDeleteHistorical", {
|
|
9553
9583
|
get: function () {
|
|
9554
|
-
return (this.permission["
|
|
9584
|
+
return (this.permission["excluir"]);
|
|
9555
9585
|
},
|
|
9556
9586
|
enumerable: true,
|
|
9557
9587
|
configurable: true
|
|
9558
9588
|
});
|
|
9559
9589
|
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToEditHistorical", {
|
|
9560
9590
|
get: function () {
|
|
9561
|
-
return (this.permission["
|
|
9591
|
+
return (this.permission["editar"]);
|
|
9562
9592
|
},
|
|
9563
9593
|
enumerable: true,
|
|
9564
9594
|
configurable: true
|
|
9565
9595
|
});
|
|
9566
9596
|
Object.defineProperty(HistoricalPixAccountComponent.prototype, "isAllowToViewHistorical", {
|
|
9567
9597
|
get: function () {
|
|
9568
|
-
return (this.permission["
|
|
9598
|
+
return (this.permission["visualizar"]);
|
|
9569
9599
|
},
|
|
9570
9600
|
enumerable: true,
|
|
9571
9601
|
configurable: true
|
|
@@ -9627,6 +9657,18 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9627
9657
|
__decorate([
|
|
9628
9658
|
Input()
|
|
9629
9659
|
], HistoricalPixAccountComponent.prototype, "permission", void 0);
|
|
9660
|
+
__decorate([
|
|
9661
|
+
Input()
|
|
9662
|
+
], HistoricalPixAccountComponent.prototype, "listDataReciever", void 0);
|
|
9663
|
+
__decorate([
|
|
9664
|
+
Output()
|
|
9665
|
+
], HistoricalPixAccountComponent.prototype, "isViewModeActive", void 0);
|
|
9666
|
+
__decorate([
|
|
9667
|
+
Output()
|
|
9668
|
+
], HistoricalPixAccountComponent.prototype, "isEditModeActive", void 0);
|
|
9669
|
+
__decorate([
|
|
9670
|
+
Output()
|
|
9671
|
+
], HistoricalPixAccountComponent.prototype, "isDeleteModeActive", void 0);
|
|
9630
9672
|
__decorate([
|
|
9631
9673
|
Input()
|
|
9632
9674
|
], HistoricalPixAccountComponent.prototype, "dateChange", null);
|
|
@@ -9643,7 +9685,7 @@ var HistoricalPixAccountComponent = /** @class */ (function () {
|
|
|
9643
9685
|
Component({
|
|
9644
9686
|
// tslint:disable-next-line:component-selector
|
|
9645
9687
|
selector: "c-historical-pix-account",
|
|
9646
|
-
template: "<s-sidebar *ngIf=\"withSideBar\" [visible]=\"visible\" (visibleChange)=\"close()\"\n header=\"{{'hcm.payroll.historical_pix_account_title_form'|translate}}\">\n<pix-account [(visible)]=\"visible\"\n [isEditAndViewValue]=\"pixAccountItemInput\"\n [currency]=\"currency\"\n [customEntity]=\"customEntity\"\n [customService]=\"customService\"\n [getListPixAccount]=\"listDataNoPage\"\n [paramsForm]=\"paramsForm\"\n (pixAccountItemToList)=\"addItemInList($event)\"\n [defaultCpfNumber]=\"defaultCpfNumber\"></pix-account>\n</s-sidebar>\n\n<div *ngIf=\"!withSideBar\">\n <pix-account [(visible)]=\"visible\"\n [isEditAndViewValue]=\"pixAccountItemInput\"\n [currency]=\"currency\"\n [customEntity]=\"customEntity\"\n [customService]=\"customService\"\n [getListPixAccount]=\"listDataNoPage\"\n [withSideBar]=\"false\"\n [isViewMode]=\"isViewMode\"\n [paramsForm]=\"paramsForm\"\n (pixAccountItemToList)=\"addItemInList($event)\"\n [defaultCpfNumber]=\"defaultCpfNumber\"></pix-account>\n</div>\n\n<div class=\"ui-g-1\" *ngIf=\"withSideBar && !isEditMode\">\n <div class=\"form-group \">\n <s-button id=\"ta-addPayAnnuity\"\n [disabled]=\"getTooltipAndDisableButtonAdd || msgTotalLimitByPercentage\"\n (onClick)=\"add()\"\n [pTooltip]=\"getTooltipAndDisableButtonAdd || msgTotalLimitByPercentage\"\n tooltipPosition=\"top\"\n label=\"{{'hcm.payroll.historical_pix_account_add'|translate}}\"></s-button>\n </div>\n</div>\n<div class=\"ui-g-12\">\n <p-table\n id=\"table-annuity\"\n [value]=\"listData\"\n [columns]=\"cols\"\n (onLazyLoad)=\"onLazyLoad($event)\"\n [lazy]=\"true\"\n [scrollable]=\"true\"\n [paginator]=\"true\"\n [totalRecords]=\"totalRecords\"\n [sortMode]=\"'multiple'\"\n *sLoadingState=\"loading\"\n [rows]=\"recordByRow\"\n dataKey=\"id\">\n <ng-template pTemplate=\"colgroup\" let-coumns>\n <colgroup>\n <col [ngClass]=\"'col-default-m'\">\n <col [ngClass]=\"'col-default-m'\">\n <col [ngClass]=\"'col-default-s'\">\n <col [ngClass]=\"'col-action'\">\n </colgroup>\n </ng-template>\n <ng-template pTemplate=\"header\" let-columns>\n <!-- Cabe\u00E7alhos quando da table \u00E9 permitido ordenar as colunas -->\n <tr>\n <!-- Cabe\u00E7alhos das colunas da tabela -->\n <th\n [pSortableColumn]=\"'pixKeyType'\"\n [pTooltip]=\"'hcm.payroll.employees_addition_pix_key_type' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n >\n <div class=\"senior-header\" id=\"table-0\">\n <span\n id=\"table-annuity-s-0\">{{ 'hcm.payroll.employees_addition_pix_key_type' | translate }}</span>\n <p-sortIcon class=\"p-sorticon-status\"\n [field]=\"'hcm.payroll.employees_addition_pix_key_type' | translate\"></p-sortIcon>\n </div>\n </th>\n\n <th\n [pSortableColumn]=\"'pixKey'\"\n [pTooltip]=\"'hcm.payroll.employees_addition_pix_key' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n >\n <div class=\"senior-header\">\n <span>{{ 'hcm.payroll.employees_addition_pix_key' | translate }}</span>\n <p-sortIcon class=\"p-sorticon-status\"\n [field]=\"'hcm.payroll.employees_addition_pix_key' | translate\"></p-sortIcon>\n </div>\n </th>\n\n <th\n [pSortableColumn]=\"'percentage'\"\n [pTooltip]=\"'hcm.payroll.historical_pix_account_label_percentage' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n >\n <div class=\"senior-header\">\n <span>{{ 'hcm.payroll.historical_pix_account_label_percentage' | translate }}</span>\n <p-sortIcon class=\"p-sorticon-status\"\n [field]=\"'hcm.payroll.historical_pix_account_label_percentage' | translate\"></p-sortIcon>\n </div>\n </th>\n <!-- Cabe\u00E7alho da coluna de a\u00E7\u00F5es -->\n <th id=\"col-actions\"></th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\" let-rowData let-key=\"rowIndex\">\n\n <tr [ngClass]=\"'row'+key\" [pSelectableRow]=\"rowData\">\n <td [pTooltip]=\"rowData?.pixKeyType.value\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ rowData?.pixKeyType.value }}</span>\n </td>\n\n <ng-container [ngSwitch]=\"rowData?.pixKeyType.key\">\n <td *ngSwitchCase=\"'TELEPHONE'\"\n [pTooltip]=\"getFormattedTelephoneNumber(rowData?.pixKey)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedTelephoneNumber(rowData?.pixKey) }}</span>\n </td>\n <td *ngSwitchCase=\"'CPF'\"\n [pTooltip]=\"getFormattedCpf(rowData?.pixKey)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedCpf(rowData?.pixKey) }}</span>\n </td>\n <td *ngSwitchCase=\"'CNPJ'\"\n [pTooltip]=\"getFormattedCnpj(rowData?.pixKey)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedCnpj(rowData?.pixKey) }}</span>\n </td>\n <td *ngSwitchDefault\n [pTooltip]=\"rowData?.pixKey\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ rowData?.pixKey }}</span>\n </td>\n </ng-container>\n <td [pTooltip]=\"getFormattedPercentage(rowData?.percentage)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedPercentage(rowData?.percentage) }}</span>\n </td>\n <td id=\"col-actions-{{key}}\" class=\"col-actions \"\n *ngIf=\"actions && actions(rowData, key)?.length\">\n <s-button id=\"table-admission-btn-actions-{{key}}\"\n *ngIf=\"actions(rowData, key).length > 1\" [label]=\"actionLabel\"\n priority=\"default\" [model]=\"scopedActions(rowData, key)\"\n [disabled]=\"false\" [auxiliary]=\"true\"></s-button>\n\n <s-button id=\"table-admission-btn-action-{{key}}\"\n *ngIf=\"actions(rowData, key).length <= 1\"\n [label]=\"scopedActions(rowData, key)[0].label\"\n priority=\"default\"\n (click)=\"scopedActions(rowData, key)[0].command()\"\n [disabled]=\"false\" [auxiliary]=\"true\"></s-button>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"emptymessage\" let-columns>\n <tr>\n <td [attr.colspan]=\"columns.length +2\">\n {{'hcm.payroll.admission_empty_message'|translate}}\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"paginatorright\">\n <span *ngIf=\"totalRecords\">{{recordsMessage}}</span>\n </ng-template>\n </p-table>\n</div>\n",
|
|
9688
|
+
template: "<s-sidebar *ngIf=\"withSideBar\" [visible]=\"visible\" (visibleChange)=\"close()\"\n header=\"{{'hcm.payroll.historical_pix_account_title_form'|translate}}\">\n<pix-account [(visible)]=\"visible\"\n [isEditAndViewValue]=\"pixAccountItemInput\"\n [currency]=\"currency\"\n [customEntity]=\"customEntity\"\n [customService]=\"customService\"\n [getListPixAccount]=\"listDataNoPage\"\n [paramsForm]=\"paramsForm\"\n (pixAccountItemToList)=\"addItemInList($event)\"\n [defaultCpfNumber]=\"defaultCpfNumber\"></pix-account>\n</s-sidebar>\n\n<div *ngIf=\"!withSideBar\">\n <pix-account [(visible)]=\"visible\"\n [isEditAndViewValue]=\"pixAccountItemInput\"\n [currency]=\"currency\"\n [customEntity]=\"customEntity\"\n [customService]=\"customService\"\n [getListPixAccount]=\"listDataNoPage\"\n [withSideBar]=\"false\"\n [isViewMode]=\"isViewMode\"\n [paramsForm]=\"paramsForm\"\n (pixAccountItemToList)=\"addItemInList($event)\"\n [defaultCpfNumber]=\"defaultCpfNumber\"></pix-account>\n</div>\n\n<div class=\"ui-g-1\" *ngIf=\"withSideBar && !isEditMode\">\n <div class=\"form-group \">\n <s-button id=\"ta-addPayAnnuity\"\n [disabled]=\"getTooltipAndDisableButtonAdd || msgTotalLimitByPercentage\"\n (onClick)=\"add()\"\n [pTooltip]=\"getTooltipAndDisableButtonAdd || msgTotalLimitByPercentage\"\n tooltipPosition=\"top\"\n label=\"{{'hcm.payroll.historical_pix_account_add'|translate}}\"></s-button>\n </div>\n</div>\n<div class=\"ui-g-12\">\n <p-table\n id=\"table-annuity\"\n [value]=\"listData\"\n [columns]=\"cols\"\n (onLazyLoad)=\"onLazyLoad($event)\"\n [lazy]=\"true\"\n [scrollable]=\"true\"\n [paginator]=\"true\"\n [totalRecords]=\"totalRecords\"\n [sortMode]=\"'multiple'\"\n *sLoadingState=\"loading\"\n [rows]=\"recordByRow\"\n dataKey=\"id\">\n <ng-template pTemplate=\"colgroup\" let-coumns>\n <colgroup>\n <col [ngClass]=\"'col-default-m'\">\n <col [ngClass]=\"'col-default-m'\">\n <col [ngClass]=\"'col-default-s'\">\n <col [ngClass]=\"'col-action'\">\n </colgroup>\n </ng-template>\n <ng-template pTemplate=\"header\" let-columns>\n <!-- Cabe\u00E7alhos quando da table \u00E9 permitido ordenar as colunas -->\n <tr>\n <!-- Cabe\u00E7alhos das colunas da tabela -->\n <th\n [pSortableColumn]=\"'pixKeyType'\"\n [pTooltip]=\"'hcm.payroll.employees_addition_pix_key_type' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n >\n <div class=\"senior-header\" id=\"table-0\">\n <span\n id=\"table-annuity-s-0\">{{ 'hcm.payroll.employees_addition_pix_key_type' | translate }}</span>\n <p-sortIcon class=\"p-sorticon-status\"\n [field]=\"'hcm.payroll.employees_addition_pix_key_type' | translate\"></p-sortIcon>\n </div>\n </th>\n\n <th\n [pSortableColumn]=\"'pixKey'\"\n [pTooltip]=\"'hcm.payroll.employees_addition_pix_key' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n >\n <div class=\"senior-header\">\n <span>{{ 'hcm.payroll.employees_addition_pix_key' | translate }}</span>\n <p-sortIcon class=\"p-sorticon-status\"\n [field]=\"'hcm.payroll.employees_addition_pix_key' | translate\"></p-sortIcon>\n </div>\n </th>\n\n <th\n [pSortableColumn]=\"'percentage'\"\n [pTooltip]=\"'hcm.payroll.historical_pix_account_label_percentage' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n >\n <div class=\"senior-header\">\n <span>{{ 'hcm.payroll.historical_pix_account_label_percentage' | translate }}</span>\n <p-sortIcon class=\"p-sorticon-status\"\n [field]=\"'hcm.payroll.historical_pix_account_label_percentage' | translate\"></p-sortIcon>\n </div>\n </th>\n <!-- Cabe\u00E7alho da coluna de a\u00E7\u00F5es -->\n <th id=\"col-actions\"></th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\" let-rowData let-key=\"rowIndex\">\n\n <tr [ngClass]=\"'row'+key\" [pSelectableRow]=\"rowData\">\n <td [pTooltip]=\"rowData?.pixKeyType.value\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ rowData?.pixKeyType.value }}</span>\n </td>\n\n <ng-container [ngSwitch]=\"rowData?.pixKeyType.key\">\n <td *ngSwitchCase=\"'TELEPHONE'\"\n [pTooltip]=\"getFormattedTelephoneNumber(rowData?.pixKey)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedTelephoneNumber(rowData?.pixKey) }}</span>\n </td>\n <td *ngSwitchCase=\"'CPF'\"\n [pTooltip]=\"getFormattedCpf(rowData?.pixKey)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedCpf(rowData?.pixKey) }}</span>\n </td>\n <td *ngSwitchCase=\"'CNPJ'\"\n [pTooltip]=\"getFormattedCnpj(rowData?.pixKey)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedCnpj(rowData?.pixKey) }}</span>\n </td>\n <td *ngSwitchDefault\n [pTooltip]=\"rowData?.pixKey\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ rowData?.pixKey }}</span>\n </td>\n </ng-container>\n <td [pTooltip]=\"getFormattedPercentage(rowData?.percentage)\" tooltipPosition=\"top\"\n showDelay=\"500\">\n <span>{{ getFormattedPercentage(rowData?.percentage) }}</span>\n </td>\n <td id=\"col-actions-{{key}}\" class=\"col-actions \"\n *ngIf=\"actions && actions(rowData, key)?.length\">\n <s-button id=\"table-admission-btn-actions-{{key}}\"\n *ngIf=\"!isViewMode && actions(rowData, key).length > 1\" [label]=\"actionLabel\"\n priority=\"default\" [model]=\"scopedActions(rowData, key)\"\n [disabled]=\"false\" [auxiliary]=\"true\"></s-button>\n\n <s-button id=\"table-admission-btn-action-{{key}}\"\n *ngIf=\"!isViewMode && actions(rowData, key).length <= 1\"\n [label]=\"scopedActions(rowData, key)[0].label\"\n priority=\"default\"\n (click)=\"scopedActions(rowData, key)[0].command()\"\n [disabled]=\"false\" [auxiliary]=\"true\"></s-button>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"emptymessage\" let-columns>\n <tr>\n <td [attr.colspan]=\"columns.length +2\">\n {{'hcm.payroll.admission_empty_message'|translate}}\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"paginatorright\">\n <span *ngIf=\"totalRecords\">{{recordsMessage}}</span>\n </ng-template>\n </p-table>\n</div>\n",
|
|
9647
9689
|
styles: [".refresh{width:100%!important}#table-annuity .col-default-s{width:10%}#table-annuity .col-default-m{width:12%}#table-annuity .col-default-l{width:16%}#table-annuity .col-action{width:10%}#table-annuity .icon-warning{text-align:center!important;color:#ff6d00c7!important}@media screen and (max-width:612px){#table-annuity .col-default-1,#table-annuity .col-default-2{width:16%}#table-annuity .col-default-3{width:26%}#table-annuity .col-icon{width:10%}#table-annuity .col-action{width:27%}}#main{display:-webkit-box;display:flex;height:100%;width:100%;-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column}#main form{height:100%}#main .footer{border-top:1px solid #ccc;padding-top:15px;margin-top:15px;flex-shrink:0;margin-bottom:-18px}#main .footer-s-border{padding-left:7px;flex-shrink:0;margin-bottom:-18px}"]
|
|
9648
9690
|
})
|
|
9649
9691
|
], HistoricalPixAccountComponent);
|
|
@@ -10291,6 +10333,8 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10291
10333
|
this.endPoint = "hcm/payroll/queries/historicalEmployeePixQuery";
|
|
10292
10334
|
this.keyPayload = "historicalEmployeePix";
|
|
10293
10335
|
this.withSidebar = true;
|
|
10336
|
+
this.isOnlyView = new EventEmitter();
|
|
10337
|
+
this.isOnlyEdit = new EventEmitter();
|
|
10294
10338
|
this.enableView = new EventEmitter();
|
|
10295
10339
|
this.ngUnsubscribe = new Subject();
|
|
10296
10340
|
this.loading = true;
|
|
@@ -10299,18 +10343,6 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10299
10343
|
label: this.translateService.instant("hcm.payroll.historical_pix_account_label_date_change"),
|
|
10300
10344
|
field: "dateChange",
|
|
10301
10345
|
},
|
|
10302
|
-
{
|
|
10303
|
-
label: this.translateService.instant("hcm.payroll.historical_pix_account_label_pix_key_type"),
|
|
10304
|
-
field: "pixKeyType.value",
|
|
10305
|
-
},
|
|
10306
|
-
{
|
|
10307
|
-
label: this.translateService.instant("hcm.payroll.historical_pix_account_label_pix_key"),
|
|
10308
|
-
field: "pixKey",
|
|
10309
|
-
},
|
|
10310
|
-
{
|
|
10311
|
-
label: this.translateService.instant("hcm.payroll.historical_pix_account_label_percentage"),
|
|
10312
|
-
field: "percentage",
|
|
10313
|
-
},
|
|
10314
10346
|
{
|
|
10315
10347
|
label: this.translateService.instant("hcm.payroll.employees_movimentation_historical_pix_account_label_qtd_account"),
|
|
10316
10348
|
field: "numberOfPixAccount",
|
|
@@ -10331,41 +10363,51 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10331
10363
|
var _this = this;
|
|
10332
10364
|
payload.forEach(function (value) {
|
|
10333
10365
|
value.dateChange = moment$e(value.dateChange).format(_this.dateFormat);
|
|
10334
|
-
value.pixKey = _this.formatPixKeyByType(value.pixKeyType, value.pixKey);
|
|
10335
|
-
value.percentage = FormatUtilsService.getFormattedPercentage(value.percentage);
|
|
10336
10366
|
});
|
|
10337
10367
|
this.onGridLoad(payload);
|
|
10338
10368
|
this.loading = false;
|
|
10339
10369
|
};
|
|
10340
|
-
HistoricalPixAccountListComponent.prototype.formatPixKeyByType = function (pixKeyType, pixKey) {
|
|
10341
|
-
var keyType = pixKeyType ? pixKeyType.key.toUpperCase() : "";
|
|
10342
|
-
if (keyType === "TELEPHONE") {
|
|
10343
|
-
return FormatUtilsService.getFormattedTelephoneNumber(pixKey);
|
|
10344
|
-
}
|
|
10345
|
-
else if (keyType === "CPF") {
|
|
10346
|
-
return FormatUtilsService.getFormattedCpf(pixKey);
|
|
10347
|
-
}
|
|
10348
|
-
else if (keyType === "CNPJ") {
|
|
10349
|
-
return FormatUtilsService.getFormattedCnpj(pixKey);
|
|
10350
|
-
}
|
|
10351
|
-
else {
|
|
10352
|
-
return pixKey;
|
|
10353
|
-
}
|
|
10354
|
-
};
|
|
10355
10370
|
HistoricalPixAccountListComponent.prototype.getMenuActions = function (rowData) {
|
|
10356
10371
|
var _this = this;
|
|
10357
10372
|
return [
|
|
10358
10373
|
{
|
|
10359
10374
|
label: this.translateService.instant("hcm.payroll.employees_image_cropper_view"),
|
|
10360
10375
|
command: function () {
|
|
10361
|
-
|
|
10362
|
-
|
|
10363
|
-
_this.
|
|
10364
|
-
|
|
10365
|
-
|
|
10376
|
+
if (_this.isAllowToViewHistorical) {
|
|
10377
|
+
var dateChange = rowData && rowData.dateChange && moment$e(rowData.dateChange, _this.dateFormat).format("YYYY-MM-DD");
|
|
10378
|
+
if (_this.withSidebar) {
|
|
10379
|
+
_this.isOnlyView.emit(true);
|
|
10380
|
+
_this.router.navigate(["historical-pix-account/" + dateChange], {
|
|
10381
|
+
relativeTo: _this.activatedRoute,
|
|
10382
|
+
});
|
|
10383
|
+
}
|
|
10384
|
+
else {
|
|
10385
|
+
_this.enableView.emit(dateChange);
|
|
10386
|
+
}
|
|
10366
10387
|
}
|
|
10367
10388
|
else {
|
|
10368
|
-
_this.
|
|
10389
|
+
_this.isNotAllowMessage();
|
|
10390
|
+
}
|
|
10391
|
+
},
|
|
10392
|
+
},
|
|
10393
|
+
{
|
|
10394
|
+
label: this.translateService.instant("hcm.payroll.edit"),
|
|
10395
|
+
command: function () {
|
|
10396
|
+
if (_this.isAllowToEditHistorical) {
|
|
10397
|
+
var dateChange = rowData && rowData.dateChange && moment$e(rowData.dateChange, _this.dateFormat).format("YYYY-MM-DD");
|
|
10398
|
+
if (_this.withSidebar) {
|
|
10399
|
+
_this.isOnlyView.emit(false);
|
|
10400
|
+
_this.isOnlyEdit.emit(true);
|
|
10401
|
+
_this.router.navigate(["historical-pix-account/" + dateChange], {
|
|
10402
|
+
relativeTo: _this.activatedRoute,
|
|
10403
|
+
});
|
|
10404
|
+
}
|
|
10405
|
+
else {
|
|
10406
|
+
_this.enableView.emit(dateChange);
|
|
10407
|
+
}
|
|
10408
|
+
}
|
|
10409
|
+
else {
|
|
10410
|
+
_this.isNotAllowMessage();
|
|
10369
10411
|
}
|
|
10370
10412
|
},
|
|
10371
10413
|
},
|
|
@@ -10376,14 +10418,10 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10376
10418
|
_this.delete(rowData.id, rowData.dateChange);
|
|
10377
10419
|
}
|
|
10378
10420
|
else {
|
|
10379
|
-
_this.
|
|
10380
|
-
severity: "error",
|
|
10381
|
-
summary: _this.translateService.instant("hcm.payroll.error"),
|
|
10382
|
-
detail: _this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
|
|
10383
|
-
});
|
|
10421
|
+
_this.isNotAllowMessage();
|
|
10384
10422
|
}
|
|
10385
10423
|
},
|
|
10386
|
-
}
|
|
10424
|
+
}
|
|
10387
10425
|
];
|
|
10388
10426
|
};
|
|
10389
10427
|
HistoricalPixAccountListComponent.prototype.delete = function (id, dateChange) {
|
|
@@ -10438,6 +10476,13 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10438
10476
|
});
|
|
10439
10477
|
}
|
|
10440
10478
|
};
|
|
10479
|
+
HistoricalPixAccountListComponent.prototype.isNotAllowMessage = function () {
|
|
10480
|
+
this.messageService.add({
|
|
10481
|
+
severity: "error",
|
|
10482
|
+
summary: this.translateService.instant("hcm.payroll.error"),
|
|
10483
|
+
detail: this.translateService.instant("hcm.payroll.permission_error_not_allowed"),
|
|
10484
|
+
});
|
|
10485
|
+
};
|
|
10441
10486
|
HistoricalPixAccountListComponent.prototype.onGridLoad = function (payload) {
|
|
10442
10487
|
if (payload && payload.length) {
|
|
10443
10488
|
this.lastRecord = payload[0];
|
|
@@ -10445,21 +10490,28 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10445
10490
|
};
|
|
10446
10491
|
Object.defineProperty(HistoricalPixAccountListComponent.prototype, "isAllowToAddHistorical", {
|
|
10447
10492
|
get: function () {
|
|
10448
|
-
return (this.permission["
|
|
10493
|
+
return (this.permission["incluir"]);
|
|
10449
10494
|
},
|
|
10450
10495
|
enumerable: true,
|
|
10451
10496
|
configurable: true
|
|
10452
10497
|
});
|
|
10453
10498
|
Object.defineProperty(HistoricalPixAccountListComponent.prototype, "isAllowToDeleteHistorical", {
|
|
10454
10499
|
get: function () {
|
|
10455
|
-
return (this.permission["
|
|
10500
|
+
return (this.permission["excluir"]);
|
|
10456
10501
|
},
|
|
10457
10502
|
enumerable: true,
|
|
10458
10503
|
configurable: true
|
|
10459
10504
|
});
|
|
10460
10505
|
Object.defineProperty(HistoricalPixAccountListComponent.prototype, "isAllowToViewHistorical", {
|
|
10461
10506
|
get: function () {
|
|
10462
|
-
return (this.permission["
|
|
10507
|
+
return (this.permission["visualizar"]);
|
|
10508
|
+
},
|
|
10509
|
+
enumerable: true,
|
|
10510
|
+
configurable: true
|
|
10511
|
+
});
|
|
10512
|
+
Object.defineProperty(HistoricalPixAccountListComponent.prototype, "isAllowToEditHistorical", {
|
|
10513
|
+
get: function () {
|
|
10514
|
+
return (this.permission["editar"]);
|
|
10463
10515
|
},
|
|
10464
10516
|
enumerable: true,
|
|
10465
10517
|
configurable: true
|
|
@@ -10514,6 +10566,12 @@ var HistoricalPixAccountListComponent = /** @class */ (function () {
|
|
|
10514
10566
|
__decorate([
|
|
10515
10567
|
Input()
|
|
10516
10568
|
], HistoricalPixAccountListComponent.prototype, "withSidebar", void 0);
|
|
10569
|
+
__decorate([
|
|
10570
|
+
Output()
|
|
10571
|
+
], HistoricalPixAccountListComponent.prototype, "isOnlyView", void 0);
|
|
10572
|
+
__decorate([
|
|
10573
|
+
Output()
|
|
10574
|
+
], HistoricalPixAccountListComponent.prototype, "isOnlyEdit", void 0);
|
|
10517
10575
|
__decorate([
|
|
10518
10576
|
Output()
|
|
10519
10577
|
], HistoricalPixAccountListComponent.prototype, "enableView", void 0);
|