@senior-gestao-pessoas/hcm-entity-lookups 4.1.3 → 4.1.4-develop-c419c6ef

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.
Files changed (79) hide show
  1. package/bundles/senior-gestao-pessoas-hcm-entity-lookups.umd.js +770 -486
  2. package/bundles/senior-gestao-pessoas-hcm-entity-lookups.umd.js.map +1 -1
  3. package/bundles/senior-gestao-pessoas-hcm-entity-lookups.umd.min.js +1 -1
  4. package/bundles/senior-gestao-pessoas-hcm-entity-lookups.umd.min.js.map +1 -1
  5. package/core/entities/e-001-pes/e-001-pes-dto.d.ts +1 -0
  6. package/core/entities/e-001-pes/e-001-pes.d.ts +1 -0
  7. package/core/entities/e-070-fil/e-070-fil.d.ts +1 -2
  8. package/core/entities/fpas-registration/fpas-registration-dto.d.ts +5 -0
  9. package/core/entities/fpas-registration/fpas-registration.d.ts +8 -0
  10. package/core/entities/fpas-registration/fpas-registration.module.d.ts +2 -0
  11. package/core/entities/fpas-registration/fpas-registration.service.d.ts +13 -0
  12. package/core/index.d.ts +0 -1
  13. package/esm2015/core/core-lookup.module.js +4 -4
  14. package/esm2015/core/entities/e-001-pes/e-001-pes-dto.js +1 -1
  15. package/esm2015/core/entities/e-001-pes/e-001-pes.js +1 -1
  16. package/esm2015/core/entities/e-070-fil/e-070-fil.js +1 -6
  17. package/esm2015/core/entities/fpas-registration/fpas-registration-dto.js +5 -0
  18. package/esm2015/core/entities/fpas-registration/fpas-registration.js +23 -0
  19. package/esm2015/core/entities/fpas-registration/fpas-registration.module.js +24 -0
  20. package/esm2015/core/entities/fpas-registration/fpas-registration.service.js +27 -0
  21. package/esm2015/core/index.js +1 -2
  22. package/esm2015/lookups/esocial-category-lookup/esocial-category-lookup.module.js +2 -4
  23. package/esm2015/lookups/fpas-registration-lookup/fpas-registration-lookup.component.js +56 -0
  24. package/esm2015/lookups/fpas-registration-lookup/fpas-registration-lookup.module.js +29 -0
  25. package/esm2015/lookups/fpas-registration-lookup/fpas-registration-lookup.service.js +192 -0
  26. package/esm2015/lookups/person-lookup/person-lookup.component.js +24 -105
  27. package/esm2015/lookups/person-lookup/person-lookup.module.js +10 -8
  28. package/esm2015/lookups/person-lookup/person-lookup.service.js +192 -0
  29. package/esm2015/public-api.js +4 -1
  30. package/esm2015/senior-gestao-pessoas-hcm-entity-lookups.js +4 -3
  31. package/esm5/core/core-lookup.module.js +4 -4
  32. package/esm5/core/entities/e-001-pes/e-001-pes-dto.js +1 -1
  33. package/esm5/core/entities/e-001-pes/e-001-pes.js +1 -1
  34. package/esm5/core/entities/e-070-fil/e-070-fil.js +1 -6
  35. package/esm5/core/entities/fpas-registration/fpas-registration-dto.js +5 -0
  36. package/esm5/core/entities/fpas-registration/fpas-registration.js +28 -0
  37. package/esm5/core/entities/fpas-registration/fpas-registration.module.js +27 -0
  38. package/esm5/core/entities/fpas-registration/fpas-registration.service.js +30 -0
  39. package/esm5/core/index.js +1 -2
  40. package/esm5/lookups/esocial-category-lookup/esocial-category-lookup.module.js +2 -4
  41. package/esm5/lookups/fpas-registration-lookup/fpas-registration-lookup.component.js +61 -0
  42. package/esm5/lookups/fpas-registration-lookup/fpas-registration-lookup.module.js +32 -0
  43. package/esm5/lookups/fpas-registration-lookup/fpas-registration-lookup.service.js +202 -0
  44. package/esm5/lookups/person-lookup/person-lookup.component.js +25 -110
  45. package/esm5/lookups/person-lookup/person-lookup.module.js +10 -8
  46. package/esm5/lookups/person-lookup/person-lookup.service.js +202 -0
  47. package/esm5/public-api.js +4 -1
  48. package/esm5/senior-gestao-pessoas-hcm-entity-lookups.js +4 -3
  49. package/fesm2015/senior-gestao-pessoas-hcm-entity-lookups.js +736 -474
  50. package/fesm2015/senior-gestao-pessoas-hcm-entity-lookups.js.map +1 -1
  51. package/fesm5/senior-gestao-pessoas-hcm-entity-lookups.js +765 -483
  52. package/fesm5/senior-gestao-pessoas-hcm-entity-lookups.js.map +1 -1
  53. package/lookups/fpas-registration-lookup/fpas-registration-lookup.component.d.ts +24 -0
  54. package/lookups/fpas-registration-lookup/fpas-registration-lookup.module.d.ts +2 -0
  55. package/lookups/fpas-registration-lookup/fpas-registration-lookup.service.d.ts +25 -0
  56. package/lookups/person-lookup/person-lookup.component.d.ts +6 -11
  57. package/lookups/person-lookup/person-lookup.service.d.ts +25 -0
  58. package/package.json +1 -1
  59. package/public-api.d.ts +3 -0
  60. package/senior-gestao-pessoas-hcm-entity-lookups.d.ts +3 -2
  61. package/senior-gestao-pessoas-hcm-entity-lookups.metadata.json +1 -1
  62. package/core/entities/company-branch-indications/company-branch-indications-dto.d.ts +0 -14
  63. package/core/entities/company-branch-indications/company-branch-indications.d.ts +0 -19
  64. package/core/entities/company-branch-indications/company-branch-indications.module.d.ts +0 -2
  65. package/core/entities/company-branch-indications/company-branch-indications.service.d.ts +0 -14
  66. package/core/entities/company-branch-indications/index.d.ts +0 -3
  67. package/core/entities/e-social-category/esocial-category.module.d.ts +0 -2
  68. package/esm2015/core/entities/company-branch-indications/company-branch-indications-dto.js +0 -5
  69. package/esm2015/core/entities/company-branch-indications/company-branch-indications.js +0 -42
  70. package/esm2015/core/entities/company-branch-indications/company-branch-indications.module.js +0 -38
  71. package/esm2015/core/entities/company-branch-indications/company-branch-indications.service.js +0 -45
  72. package/esm2015/core/entities/company-branch-indications/index.js +0 -3
  73. package/esm2015/core/entities/e-social-category/esocial-category.module.js +0 -24
  74. package/esm5/core/entities/company-branch-indications/company-branch-indications-dto.js +0 -5
  75. package/esm5/core/entities/company-branch-indications/company-branch-indications.js +0 -45
  76. package/esm5/core/entities/company-branch-indications/company-branch-indications.module.js +0 -41
  77. package/esm5/core/entities/company-branch-indications/company-branch-indications.service.js +0 -48
  78. package/esm5/core/entities/company-branch-indications/index.js +0 -3
  79. package/esm5/core/entities/e-social-category/esocial-category.module.js +0 -27
@@ -5069,100 +5069,174 @@
5069
5069
  return E001PesService;
5070
5070
  }(EntityService));
5071
5071
 
5072
- var PersonLookupComponent = /** @class */ (function (_super) {
5073
- __extends(PersonLookupComponent, _super);
5074
- function PersonLookupComponent(translate, cdRef, structerService, personService, configService) {
5075
- var _this = _super.call(this, translate, cdRef, configService, structerService) || this;
5076
- _this.translate = translate;
5077
- _this.cdRef = cdRef;
5078
- _this.structerService = structerService;
5079
- _this.personService = personService;
5080
- _this.configService = configService;
5081
- _this.filters = [];
5082
- _this.personAdvancedDisplayFields = ["id", "codPes", "nomPes", "datNas"];
5083
- _this.personLookupDisplayFields = ["codPes", "nomPes"];
5084
- _this.personLookupSeparator = " - ";
5085
- _this.controlName = "person";
5086
- _this.personSearchFields = _this.getPersonSearchFields();
5087
- _this.personSearchGridFields = _this.getPersonSearchFields();
5088
- return _this;
5072
+ var PersonLookupService = /** @class */ (function () {
5073
+ function PersonLookupService(translate, configService, personService) {
5074
+ this.translate = translate;
5075
+ this.configService = configService;
5076
+ this.personService = personService;
5077
+ this.lookupServiceConfig = {
5078
+ lookupDisplayFields: ["codPes", "nomPes"],
5079
+ lookupSeparator: " - ",
5080
+ searchSubject: new rxjs.Subject(),
5081
+ lookupSubject: new rxjs.Subject(),
5082
+ entityName: "e001Pes",
5083
+ dynamicFormOptions: {
5084
+ cancelLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".cancel"),
5085
+ clearLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".clear"),
5086
+ dataKey: "id",
5087
+ emptyFieldLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".list_grid_empty_field"),
5088
+ emptyMessage: this.translate.instant(this.configService.getTranslationPrefix() + ".empty_message_field"),
5089
+ filterLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".filter"),
5090
+ filterTitle: this.translate.instant(this.configService.getTranslationPrefix() + ".filters"),
5091
+ label: this.translate.instant(this.configService.getTranslationPrefix() + ".company_linked_location"),
5092
+ lookupDisplayField: "label",
5093
+ multiple: false,
5094
+ name: "person",
5095
+ recordLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".records_found"),
5096
+ recordsLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".records_found"),
5097
+ required: true,
5098
+ searchEmptyTitle: this.translate.instant(this.configService.getTranslationPrefix() + ".nothing_found"),
5099
+ searchFields: this.getPersonSearchFields(),
5100
+ searchGridFields: this.getPersonSearchFields(),
5101
+ searchTitle: this.translate.instant(this.configService.getTranslationPrefix() + ".company_linked_location_search_title"),
5102
+ selectLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".select"),
5103
+ visible: true,
5104
+ isCollective: false,
5105
+ },
5106
+ filters: {
5107
+ additionalFilter: undefined,
5108
+ initialFilter: undefined,
5109
+ companyIds: [],
5110
+ },
5111
+ };
5112
+ this.ngUnsubscribe = new rxjs.Subject();
5089
5113
  }
5090
- PersonLookupComponent.prototype.onPersonLookupRequest = function (value) {
5114
+ PersonLookupService.prototype.updateSuggestions = function (value) {
5115
+ if (value === null || value === void 0 ? void 0 : value[this.lookupServiceConfig.entityName]) {
5116
+ value[this.lookupServiceConfig.entityName].label = this.getSuggestionValue(this.lookupServiceConfig.lookupDisplayFields, this.lookupServiceConfig.entityName, value, this.lookupServiceConfig.lookupSeparator);
5117
+ if ((value === null || value === void 0 ? void 0 : value[this.lookupServiceConfig.entityName].label.trim()) === this.lookupServiceConfig.lookupSeparator.trim()) {
5118
+ delete value[this.lookupServiceConfig.entityName].label;
5119
+ }
5120
+ }
5121
+ };
5122
+ PersonLookupService.prototype.getSuggestionValue = function (displayFields, ownerEntity, value, separator) {
5123
+ return displayFields
5124
+ .map(function (field) { return getProp(value, ownerEntity + "." + field); })
5125
+ .reduce(function (acc, val) { return "" + acc + separator + val; });
5126
+ };
5127
+ PersonLookupService.prototype.getFormField = function () {
5091
5128
  var _this = this;
5092
- var sort = this.personLookupDisplayFields.map(function (field) { return ({
5093
- field: field,
5094
- order: 1,
5095
- }); });
5096
- var filterQuery = createLookupRequestFilter(value, this.getPersonSearchFields()); // NOSONAR
5097
- var displayFields = mergeUnique(this.personLookupDisplayFields, this.personAdvancedDisplayFields);
5098
- this.personService
5099
- .list({ sort: sort, filterQuery: this.buildFilterQueryWithFilters(filterQuery), displayFields: displayFields })
5100
- .pipe(operators.takeUntil(this.ngUnsubscribe))
5101
- .pipe(operators.map(function (list) { return (__assign(__assign({}, list), { contents: list.contents.map(function (item) { return (__assign(__assign({}, item), { label: _this.personLookupDisplayFields.map(function (field) {
5102
- if (field.indexOf(".") > 0)
5103
- item[field] = getProp(item, field);
5104
- return item[field];
5105
- })
5106
- .join(_this.personLookupSeparator) })); }) })); }))
5107
- .subscribe(function (list) {
5108
- _this.personLookupSuggestions = list.contents;
5109
- _this.personSearchTotalRecords = list.totalElements;
5129
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
5130
+ return new angularComponents.FormField({
5131
+ cancelLabel: (_a = this.lookupServiceConfig.dynamicFormOptions) === null || _a === void 0 ? void 0 : _a.cancelLabel,
5132
+ clearLabel: (_b = this.lookupServiceConfig.dynamicFormOptions) === null || _b === void 0 ? void 0 : _b.clearLabel,
5133
+ recordLabel: (_c = this.lookupServiceConfig.dynamicFormOptions) === null || _c === void 0 ? void 0 : _c.recordLabel,
5134
+ recordsLabel: (_d = this.lookupServiceConfig.dynamicFormOptions) === null || _d === void 0 ? void 0 : _d.recordsLabel,
5135
+ searchEmptyTitle: (_e = this.lookupServiceConfig.dynamicFormOptions) === null || _e === void 0 ? void 0 : _e.searchEmptyTitle,
5136
+ searchFields: (_f = this.lookupServiceConfig.dynamicFormOptions) === null || _f === void 0 ? void 0 : _f.searchFields,
5137
+ searchTitle: (_g = this.lookupServiceConfig.dynamicFormOptions) === null || _g === void 0 ? void 0 : _g.searchTitle,
5138
+ selectLabel: (_h = this.lookupServiceConfig.dynamicFormOptions) === null || _h === void 0 ? void 0 : _h.selectLabel,
5139
+ dataKey: (_j = this.lookupServiceConfig.dynamicFormOptions) === null || _j === void 0 ? void 0 : _j.dataKey,
5140
+ emptyFieldLabel: (_k = this.lookupServiceConfig.dynamicFormOptions) === null || _k === void 0 ? void 0 : _k.emptyFieldLabel,
5141
+ emptyMessage: (_l = this.lookupServiceConfig.dynamicFormOptions) === null || _l === void 0 ? void 0 : _l.emptyMessage,
5142
+ filterLabel: (_m = this.lookupServiceConfig.dynamicFormOptions) === null || _m === void 0 ? void 0 : _m.filterLabel,
5143
+ filterTitle: (_o = this.lookupServiceConfig.dynamicFormOptions) === null || _o === void 0 ? void 0 : _o.filterTitle,
5144
+ label: (_p = this.lookupServiceConfig.dynamicFormOptions) === null || _p === void 0 ? void 0 : _p.label,
5145
+ lookupDisplayField: (_q = this.lookupServiceConfig.dynamicFormOptions) === null || _q === void 0 ? void 0 : _q.lookupDisplayField,
5146
+ multiple: (_r = this.lookupServiceConfig.dynamicFormOptions) === null || _r === void 0 ? void 0 : _r.multiple,
5147
+ name: (_s = this.lookupServiceConfig.dynamicFormOptions) === null || _s === void 0 ? void 0 : _s.name,
5148
+ onLookupRequest: function (value) { return _this.onPersonLookupRequest(value); },
5149
+ onSearchRequest: function (event) { return _this.onPersonSearchRequest(event); },
5150
+ required: function () { var _a; return (_a = _this.lookupServiceConfig.dynamicFormOptions) === null || _a === void 0 ? void 0 : _a.required; },
5151
+ searchObservable: this.lookupServiceConfig.searchSubject,
5152
+ suggestionsObservable: this.lookupServiceConfig.lookupSubject,
5153
+ type: angularComponents.FieldType.Lookup,
5154
+ visible: function () { var _a; return !((_a = _this.lookupServiceConfig.dynamicFormOptions) === null || _a === void 0 ? void 0 : _a.isCollective); },
5110
5155
  });
5111
5156
  };
5112
- PersonLookupComponent.prototype.buildFilterQueryWithFilters = function (filterQuery) {
5113
- var _a;
5114
- if ((_a = this.filters) === null || _a === void 0 ? void 0 : _a.length) {
5115
- return __spread(this.filters, [filterQuery]).filter(function (it) { return it === null || it === void 0 ? void 0 : it.length; }).join(" and ");
5116
- }
5117
- return filterQuery;
5157
+ PersonLookupService.prototype.onPersonSearchRequest = function (event) {
5158
+ var _this = this;
5159
+ var _a, _b, _c, _d;
5160
+ this.onPersonSearchRequestObservable(event, (_b = (_a = this.lookupServiceConfig) === null || _a === void 0 ? void 0 : _a.filters) === null || _b === void 0 ? void 0 : _b.additionalFilter, (_d = (_c = this.lookupServiceConfig) === null || _c === void 0 ? void 0 : _c.filters) === null || _d === void 0 ? void 0 : _d.companyIds, true).subscribe(function (data) { return _this.lookupServiceConfig.searchSubject.next(data); });
5118
5161
  };
5119
- PersonLookupComponent.prototype.onPersonSearchRequest = function (event) {
5162
+ PersonLookupService.prototype.onPersonSearchRequestObservable = function (event, additionalFilter, companyIds, isDynamicForm) {
5120
5163
  var _this = this;
5164
+ if (isDynamicForm === void 0) { isDynamicForm = false; }
5121
5165
  var first = event.first, rows = event.rows, multiSortMeta = event.multiSortMeta, filterData = event.filterData;
5122
5166
  var page = first / rows;
5123
5167
  var sort = multiSortMeta;
5124
- var filterQuery = this.getPersonSearchFields()
5125
- .filter(function (_a) {
5126
- var name = _a.name;
5127
- return filterData[name] != undefined && filterData[name] != "";
5128
- })
5129
- .map(function (_a) {
5130
- var name = _a.name, type = _a.type;
5131
- var value = filterData[name];
5132
- if (typeof value == "number")
5133
- return name + " eq " + value;
5134
- else if (type == angularComponents.FieldType.Date)
5135
- return name + " eq '" + moment$k(value).format("YYYY-MM-DD") + "'";
5136
- else if (type == angularComponents.FieldType.Time)
5137
- return name + " eq '" + moment$k(value).format("HH:mm:ss") + "'";
5138
- else if (type == angularComponents.FieldType.DateTime)
5139
- return name + " eq '" + moment$k(value).format() + "'";
5140
- else if (type == angularComponents.FieldType.Enum)
5141
- return name + " eq '" + value + "'";
5142
- else if (type == angularComponents.FieldType.String)
5143
- return "containing(upper(" + name + "), upper('" + value.replace(/'/g, "\\'") + "'))";
5144
- else
5145
- return name + " eq '" + value + "'";
5168
+ var personFilterQuery = createSearchRequestFilter(filterData, this.getPersonSearchFields());
5169
+ personFilterQuery = this.getFiltersDefaultPerson(companyIds, personFilterQuery, additionalFilter);
5170
+ var displayFields = mergeUnique(this.lookupServiceConfig.lookupDisplayFields.concat("e070emp"), __spread(this.lookupServiceConfig.lookupDisplayFields));
5171
+ return this.personService
5172
+ .list({ page: page, sort: sort, filterQuery: personFilterQuery, displayFields: displayFields })
5173
+ .pipe(operators.takeUntil(this.ngUnsubscribe))
5174
+ .pipe(operators.map(function (list) { return _this.mapToComponent(list, isDynamicForm); }));
5175
+ };
5176
+ PersonLookupService.prototype.getFiltersDefaultPerson = function (companyIds, filterData, additionalFilter) {
5177
+ var filters = [];
5178
+ additionalFilter && filters.push("(" + additionalFilter + ")");
5179
+ filterData && filters.push("(" + filterData + ")");
5180
+ (companyIds === null || companyIds === void 0 ? void 0 : companyIds.length) && filters.push("(e070emp.id in (" + companyIds.map(function (id) { return "'" + id + "'"; }) + "))");
5181
+ return filters.join(' and ');
5182
+ };
5183
+ PersonLookupService.prototype.mapToComponent = function (list, isDynamicForm) {
5184
+ var _this = this;
5185
+ if (isDynamicForm === void 0) { isDynamicForm = false; }
5186
+ if (isDynamicForm) {
5187
+ return ({
5188
+ gridData: list.contents
5189
+ .map(function (item) { return (__assign(__assign({}, item), { label: _this.getLabelForMaping(item) })); }),
5190
+ totalRecords: list === null || list === void 0 ? void 0 : list.totalElements,
5191
+ });
5192
+ }
5193
+ else {
5194
+ return (__assign(__assign({}, list), { contents: list.contents.map(function (item) { return (__assign(__assign({}, item), { label: _this.getLabelForMaping(item) })); }) }));
5195
+ }
5196
+ };
5197
+ PersonLookupService.prototype.getLabelForMaping = function (item) {
5198
+ var _this = this;
5199
+ return this.lookupServiceConfig.lookupDisplayFields
5200
+ .map(function (field) {
5201
+ if (field === "name" && !(item === null || item === void 0 ? void 0 : item.name)) {
5202
+ item.name = _this.translate
5203
+ .instant(_this.configService.getTranslationPrefix() + ".list_grid_empty_field");
5204
+ }
5205
+ if (field.indexOf(".") > 0) {
5206
+ return getProp(item, field);
5207
+ }
5208
+ return item[field];
5146
5209
  })
5147
- .join(" and ");
5148
- var displayFields = mergeUnique(this.personLookupDisplayFields, this.personAdvancedDisplayFields);
5149
- this.personService
5150
- .list({ page: page, sort: sort, filterQuery: this.buildFilterQueryWithFilters(filterQuery), displayFields: displayFields })
5210
+ .join(this.lookupServiceConfig.lookupSeparator);
5211
+ };
5212
+ PersonLookupService.prototype.onPersonLookupRequest = function (value) {
5213
+ var _this = this;
5214
+ var _a, _b, _c, _d;
5215
+ this.onPersonLookupRequestObservable(value, (_b = (_a = this.lookupServiceConfig) === null || _a === void 0 ? void 0 : _a.filters) === null || _b === void 0 ? void 0 : _b.additionalFilter, (_d = (_c = this.lookupServiceConfig) === null || _c === void 0 ? void 0 : _c.filters) === null || _d === void 0 ? void 0 : _d.companyIds).subscribe(function (data) { return _this.lookupServiceConfig.lookupSubject.next(data.contents); });
5216
+ };
5217
+ PersonLookupService.prototype.onPersonLookupRequestObservable = function (value, additionalFilter, companyIds) {
5218
+ var _this = this;
5219
+ var sort = this.lookupServiceConfig.lookupDisplayFields
5220
+ .map(function (field) { return ({ field: field, order: 1 }); });
5221
+ var personFilterQuery = createLookupRequestFilter(value, this.getPersonSearchFields());
5222
+ personFilterQuery = this.getFiltersDefaultPerson(companyIds, personFilterQuery, additionalFilter);
5223
+ var displayFields = mergeUnique(this.lookupServiceConfig.lookupDisplayFields.concat("e070emp"), __spread(this.lookupServiceConfig.lookupDisplayFields));
5224
+ return this.personService
5225
+ .list({ sort: sort, filterQuery: personFilterQuery, displayFields: displayFields })
5151
5226
  .pipe(operators.takeUntil(this.ngUnsubscribe))
5152
- .pipe(operators.map(function (list) { return (__assign(__assign({}, list), { contents: list.contents.map(function (item) { return (__assign(__assign({}, item), { label: _this.personLookupDisplayFields
5227
+ .pipe(operators.map(function (list) { return (__assign(__assign({}, list), { contents: list.contents.map(function (item) { return (__assign(__assign({}, item), { label: _this.lookupServiceConfig.lookupDisplayFields
5153
5228
  .map(function (field) {
5154
- if (field.indexOf(".") > 0)
5155
- item[field] = getProp(item, field);
5229
+ if (field === "name" && !item.name) {
5230
+ item.name = _this.translate
5231
+ .instant(_this.configService.getTranslationPrefix() + ".list_grid_empty_field");
5232
+ }
5233
+ if (field.indexOf(".") > 0) {
5234
+ return getProp(item, field);
5235
+ }
5156
5236
  return item[field];
5157
- })
5158
- .join(_this.personLookupSeparator) })); }) })); }))
5159
- .subscribe(function (list) {
5160
- _this.personSearchGridData = list.contents;
5161
- _this.personSearchTotalRecords = list.totalElements;
5162
- });
5237
+ }).join(_this.lookupServiceConfig.lookupSeparator) })); }) })); }));
5163
5238
  };
5164
- PersonLookupComponent.prototype.getPersonSearchFields = function () {
5165
- var _a, _b, _c;
5239
+ PersonLookupService.prototype.getPersonSearchFields = function () {
5166
5240
  return [
5167
5241
  new angularComponents.FormField({
5168
5242
  name: "codPes",
@@ -5173,31 +5247,68 @@
5173
5247
  name: "nomPes",
5174
5248
  label: this.translate.instant(this.configService.getTranslationPrefix() + ".e_001_pes_nom"),
5175
5249
  type: angularComponents.FieldType.String,
5176
- }),
5177
- new angularComponents.FormField({
5178
- name: "datNas",
5179
- label: this.translate.instant(this.configService.getTranslationPrefix() + ".e_001_pes_dat"),
5180
- type: angularComponents.FieldType.Date,
5181
- calendarLocaleOptions: (_a = this.locale) === null || _a === void 0 ? void 0 : _a.calendar,
5182
- dateFormat: (_c = (_b = this.locale) === null || _b === void 0 ? void 0 : _b.calendar) === null || _c === void 0 ? void 0 : _c.dateFormat,
5183
- appendTo: "body",
5184
- }),
5250
+ })
5185
5251
  ];
5186
5252
  };
5253
+ PersonLookupService.ctorParameters = function () { return [
5254
+ { type: core$1.TranslateService },
5255
+ { type: EntityLookupConfigService },
5256
+ { type: E001PesService }
5257
+ ]; };
5258
+ PersonLookupService = __decorate([
5259
+ core.Injectable()
5260
+ ], PersonLookupService);
5261
+ return PersonLookupService;
5262
+ }());
5263
+
5264
+ var PersonLookupComponent = /** @class */ (function (_super) {
5265
+ __extends(PersonLookupComponent, _super);
5266
+ function PersonLookupComponent(translate, cdRef, configService, structerService, personLookupService) {
5267
+ var _this = _super.call(this, translate, cdRef, configService, structerService) || this;
5268
+ _this.translate = translate;
5269
+ _this.cdRef = cdRef;
5270
+ _this.configService = configService;
5271
+ _this.structerService = structerService;
5272
+ _this.personLookupService = personLookupService;
5273
+ _this.controlName = "person";
5274
+ _this.entity = "e001Pes";
5275
+ _this.domain = "erpx_fnd";
5276
+ _this.service = "person";
5277
+ _this.useDateValidation = false;
5278
+ return _this;
5279
+ }
5280
+ PersonLookupComponent.prototype.ngOnInit = function () {
5281
+ this.personSearchFields = this.personLookupService.getPersonSearchFields();
5282
+ this.personSearchGridFields = this.personLookupService.getPersonSearchFields();
5283
+ };
5284
+ PersonLookupComponent.prototype.onPersonLookupRequest = function (value) {
5285
+ var _this = this;
5286
+ this.personLookupService
5287
+ .onPersonLookupRequestObservable(value, this.personLookupService.lookupServiceConfig.filters.additionalFilter, this.companyIds)
5288
+ .subscribe(function (list) {
5289
+ _this.personLookupSuggestions = list === null || list === void 0 ? void 0 : list.contents;
5290
+ });
5291
+ };
5292
+ PersonLookupComponent.prototype.onPersonSearchRequest = function (event) {
5293
+ var _this = this;
5294
+ this.personLookupService
5295
+ .onPersonSearchRequestObservable(event, this.personLookupService.lookupServiceConfig.filters.additionalFilter, this.companyIds)
5296
+ .subscribe(function (list) {
5297
+ _this.personSearchGridData = list === null || list === void 0 ? void 0 : list.contents;
5298
+ _this.personSearchTotalRecords = list === null || list === void 0 ? void 0 : list.totalElements;
5299
+ });
5300
+ };
5187
5301
  PersonLookupComponent.ctorParameters = function () { return [
5188
5302
  { type: core$1.TranslateService },
5189
5303
  { type: core.ChangeDetectorRef },
5304
+ { type: EntityLookupConfigService },
5190
5305
  { type: StructureFilterService },
5191
- { type: E001PesService },
5192
- { type: EntityLookupConfigService }
5306
+ { type: PersonLookupService }
5193
5307
  ]; };
5194
- __decorate([
5195
- core.Input()
5196
- ], PersonLookupComponent.prototype, "filters", void 0);
5197
5308
  PersonLookupComponent = __decorate([
5198
5309
  core.Component({
5199
5310
  selector: "fnd-person-lookup",
5200
- template: "<s-loading-state [loading]=\"loading\" [blockWindow]=\"true\"></s-loading-state>\n<form [formGroup]=\"formGroup\">\n <s-lookup id=\"ff-person-id\" dataKey=\"id\" name=\"personId\"\n lookupDisplayField=\"label\" [formControlName]=\"controlName\"\n [cancelLabel]=\"configService.getTranslationPrefix() + '.cancel' | translate\"\n [clearLabel]=\"configService.getTranslationPrefix() + '.clear' | translate\"\n [emptyFieldLabel]=\"configService.getTranslationPrefix() + '.nothing_found' | translate\"\n [filterLabel]=\"configService.getTranslationPrefix() + '.filter' | translate\"\n [filterTitle]=\"configService.getTranslationPrefix() + '.filters' | translate\"\n [lookupSuggestions]=\"personLookupSuggestions\"\n [searchEmptyTitle]=\"configService.getTranslationPrefix() + '.nothing_found' | translate\"\n [searchFields]=\"personSearchFields\" [searchGridData]=\"personSearchGridData\" [searchTitle]=\"\n configService.getTranslationPrefix() + '.data_person_id_lookup_title'\n | translate\" [searchTotalRecords]=\"personSearchTotalRecords\"\n [selectLabel]=\"configService.getTranslationPrefix() + '.select' | translate\" [showSearch]=\"true\"\n (onLookupRequest)=\"onPersonLookupRequest($event)\"\n [searchTotalRecordsLabel]=\"configService.getTranslationPrefix()\n + '.total_records' | translate: {value: personSearchTotalRecords}\"\n (onSearchRequest)=\"onPersonSearchRequest($event)\"></s-lookup>\n</form>\n"
5311
+ template: "<s-loading-state [loading]=\"loading\" [blockWindow]=\"true\"></s-loading-state>\n<form [formGroup]=\"formGroup\">\n <s-lookup dataKey=\"id\" id=\"person\" name=\"person\" [formControlName]=\"controlName\"\n [searchFields]=\"personSearchFields\"\n [searchGridFields]=\"personSearchGridFields\"\n [searchGridData]=\"personSearchGridData\"\n (onSelect)=\"selectOption($event)\"\n (onClear)=\"onClearItem($event)\"\n [multiple]=\"multiple\"\n [disabled]=\"isDisabled\"\n [lookupSuggestions]=\"personLookupSuggestions\"\n (onLookupRequest)=\"onPersonLookupRequest($event)\"\n (onSearchRequest)=\"onPersonSearchRequest($event)\"\n lookupDisplayField=\"label\"\n [searchTotalRecords]=\"personSearchTotalRecords\"\n [searchTitle]=\"configService.getTranslationPrefix() \n + '.e_001_pes_search_title' | translate\"\n [searchEmptyTitle]=\"configService.getTranslationPrefix()\n + '.nothing_found' | translate\" [filterLabel]=\"configService.getTranslationPrefix()\n + '.filter' | translate\" [filterTitle]=\"configService.getTranslationPrefix()\n + '.filters' | translate\" [clearLabel]=\"configService.getTranslationPrefix()\n + '.clear' | translate\" [cancelLabel]=\"configService.getTranslationPrefix()\n + '.cancel' | translate\" [selectLabel]=\"configService.getTranslationPrefix()\n + '.select' | translate\" [searchTotalRecordsLabel]=\"configService.getTranslationPrefix()\n + '.total_records' | translate: {value: personSearchTotalRecords}\"></s-lookup>\n</form>\n"
5201
5312
  })
5202
5313
  ], PersonLookupComponent);
5203
5314
  return PersonLookupComponent;
@@ -5208,18 +5319,19 @@
5208
5319
  }
5209
5320
  PersonLookupModule = __decorate([
5210
5321
  core.NgModule({
5211
- imports: [
5212
- SharedModule,
5213
- angularComponents.LoadingStateModule,
5322
+ declarations: [
5323
+ PersonLookupComponent,
5214
5324
  ],
5215
5325
  exports: [
5216
5326
  PersonLookupComponent,
5217
5327
  ],
5218
- providers: [
5219
- E001PesService,
5328
+ imports: [
5329
+ SharedModule,
5330
+ angularComponents.LoadingStateModule,
5220
5331
  ],
5221
- declarations: [
5222
- PersonLookupComponent
5332
+ providers: [
5333
+ PersonLookupService,
5334
+ E001PesService
5223
5335
  ],
5224
5336
  })
5225
5337
  ], PersonLookupModule);
@@ -6194,28 +6306,6 @@
6194
6306
  return ESocialCategoryService;
6195
6307
  }(EntityService));
6196
6308
 
6197
- var ESocialCategoryModule = /** @class */ (function () {
6198
- function ESocialCategoryModule() {
6199
- }
6200
- ESocialCategoryModule = __decorate([
6201
- core.NgModule({
6202
- imports: [
6203
- platformComponents.PermissionsModule.forChild([
6204
- {
6205
- name: 'eSocialCategory',
6206
- actions: ['Visualizar', 'Incluir', 'Editar', 'Excluir'],
6207
- uri: "res://senior.com.br/tax_obligation/shared/entities/eSocialCategory",
6208
- },
6209
- ])
6210
- ],
6211
- providers: [
6212
- ESocialCategoryService
6213
- ]
6214
- })
6215
- ], ESocialCategoryModule);
6216
- return ESocialCategoryModule;
6217
- }());
6218
-
6219
6309
  var ESocialCategoryLookupService = /** @class */ (function () {
6220
6310
  function ESocialCategoryLookupService(translate, configService, esocialCategoryService) {
6221
6311
  this.translate = translate;
@@ -6435,8 +6525,7 @@
6435
6525
  core.NgModule({
6436
6526
  imports: [
6437
6527
  SharedModule,
6438
- angularComponents.LoadingStateModule,
6439
- ESocialCategoryModule
6528
+ angularComponents.LoadingStateModule
6440
6529
  ],
6441
6530
  exports: [
6442
6531
  ESocialCategoryLookupComponent,
@@ -6986,40 +7075,331 @@
6986
7075
  return AdministrativeJudicialCaseLookupModule;
6987
7076
  }());
6988
7077
 
6989
- var EntityLookupModule = /** @class */ (function () {
6990
- function EntityLookupModule() {
7078
+ var FpasRegistrationService = /** @class */ (function (_super) {
7079
+ __extends(FpasRegistrationService, _super);
7080
+ function FpasRegistrationService(http, messageService, translate, configService) {
7081
+ var _this = _super.call(this, http, messageService, "tax_obligation/shared/entities/fpasRegistration", "tax_obligation/shared/actions", translate, configService) || this;
7082
+ _this.http = http;
7083
+ _this.messageService = messageService;
7084
+ _this.translate = translate;
7085
+ _this.configService = configService;
7086
+ return _this;
6991
7087
  }
6992
- EntityLookupModule_1 = EntityLookupModule;
6993
- EntityLookupModule.forRoot = function (config) {
6994
- return {
6995
- ngModule: EntityLookupModule_1,
6996
- providers: [
6997
- {
6998
- provide: ProjectConfigsInjectionToken,
6999
- useValue: config
7000
- }
7001
- ]
7002
- };
7003
- };
7004
- var EntityLookupModule_1;
7005
- EntityLookupModule = EntityLookupModule_1 = __decorate([
7006
- core.NgModule({
7007
- providers: []
7008
- })
7009
- ], EntityLookupModule);
7010
- return EntityLookupModule;
7011
- }());
7088
+ FpasRegistrationService.ctorParameters = function () { return [
7089
+ { type: http.HttpClient },
7090
+ { type: api.MessageService },
7091
+ { type: core$1.TranslateService },
7092
+ { type: EntityLookupConfigService }
7093
+ ]; };
7094
+ FpasRegistrationService = __decorate([
7095
+ core.Injectable()
7096
+ ], FpasRegistrationService);
7097
+ return FpasRegistrationService;
7098
+ }(EntityService));
7012
7099
 
7013
- var fallback = {
7014
- "hcm_contract.employment_additional_info.e_001_pes_cod": "Código",
7015
- "hcm_contract.employment_additional_info.e_001_pes_nom": "Nome",
7016
- "hcm_contract.employment_additional_info.e_001_pes_dat": "Data de nascimento",
7017
- "hcm_contract.employment_additional_info.e_044_ccu_cod_ccu": "Código",
7018
- "hcm_contract.employment_additional_info.e_044_ccu_des_ccu": "Descrição",
7019
- "hcm_contract.employment_additional_info.e_070_fil_cod_fil": "Código",
7020
- "hcm_contract.employment_additional_info.e_070_fil_nom_fil": "Nome",
7021
- "hcm_contract.employment_additional_info.data_person_id_lookup_title": "Localizar a pessoa",
7022
- "hcm_contract.employment_additional_info.cost_center_history_cost_center_search_title": "Localizar o centro de custo",
7100
+ var FpasRegistrationLookupService = /** @class */ (function () {
7101
+ function FpasRegistrationLookupService(translate, configService, fpasRegistrationService) {
7102
+ this.translate = translate;
7103
+ this.configService = configService;
7104
+ this.fpasRegistrationService = fpasRegistrationService;
7105
+ this.lookupServiceConfig = {
7106
+ lookupDisplayFields: ["code", "name"],
7107
+ lookupSeparator: " - ",
7108
+ searchSubject: new rxjs.Subject(),
7109
+ lookupSubject: new rxjs.Subject(),
7110
+ entityName: "fpasRegistration",
7111
+ dynamicFormOptions: {
7112
+ cancelLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".cancel"),
7113
+ clearLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".clear"),
7114
+ dataKey: "id",
7115
+ emptyFieldLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".list_grid_empty_field"),
7116
+ emptyMessage: this.translate.instant(this.configService.getTranslationPrefix() + ".empty_message_field"),
7117
+ filterLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".filter"),
7118
+ filterTitle: this.translate.instant(this.configService.getTranslationPrefix() + ".filters"),
7119
+ label: this.translate.instant(this.configService.getTranslationPrefix() + ".company_linked_location"),
7120
+ lookupDisplayField: "label",
7121
+ multiple: false,
7122
+ name: "fpasRegistration",
7123
+ recordLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".records_found"),
7124
+ recordsLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".records_found"),
7125
+ required: true,
7126
+ searchEmptyTitle: this.translate.instant(this.configService.getTranslationPrefix() + ".nothing_found"),
7127
+ searchFields: this.getFpasRegistrationSearchFields(),
7128
+ searchGridFields: this.getFpasRegistrationSearchFields(),
7129
+ searchTitle: this.translate.instant(this.configService.getTranslationPrefix() + ".company_linked_location_search_title"),
7130
+ selectLabel: this.translate.instant(this.configService.getTranslationPrefix() + ".select"),
7131
+ visible: true,
7132
+ isCollective: false,
7133
+ },
7134
+ filters: {
7135
+ additionalFilter: undefined,
7136
+ initialFilter: undefined,
7137
+ companyIds: [],
7138
+ },
7139
+ };
7140
+ this.ngUnsubscribe = new rxjs.Subject();
7141
+ }
7142
+ FpasRegistrationLookupService.prototype.updateSuggestions = function (value) {
7143
+ if (value === null || value === void 0 ? void 0 : value[this.lookupServiceConfig.entityName]) {
7144
+ value[this.lookupServiceConfig.entityName].label = this.getSuggestionValue(this.lookupServiceConfig.lookupDisplayFields, this.lookupServiceConfig.entityName, value, this.lookupServiceConfig.lookupSeparator);
7145
+ if ((value === null || value === void 0 ? void 0 : value[this.lookupServiceConfig.entityName].label.trim()) === this.lookupServiceConfig.lookupSeparator.trim()) {
7146
+ delete value[this.lookupServiceConfig.entityName].label;
7147
+ }
7148
+ }
7149
+ };
7150
+ FpasRegistrationLookupService.prototype.getSuggestionValue = function (displayFields, ownerEntity, value, separator) {
7151
+ return displayFields
7152
+ .map(function (field) { return getProp(value, ownerEntity + "." + field); })
7153
+ .reduce(function (acc, val) { return "" + acc + separator + val; });
7154
+ };
7155
+ FpasRegistrationLookupService.prototype.getFormField = function () {
7156
+ var _this = this;
7157
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
7158
+ return new angularComponents.FormField({
7159
+ cancelLabel: (_a = this.lookupServiceConfig.dynamicFormOptions) === null || _a === void 0 ? void 0 : _a.cancelLabel,
7160
+ clearLabel: (_b = this.lookupServiceConfig.dynamicFormOptions) === null || _b === void 0 ? void 0 : _b.clearLabel,
7161
+ recordLabel: (_c = this.lookupServiceConfig.dynamicFormOptions) === null || _c === void 0 ? void 0 : _c.recordLabel,
7162
+ recordsLabel: (_d = this.lookupServiceConfig.dynamicFormOptions) === null || _d === void 0 ? void 0 : _d.recordsLabel,
7163
+ searchEmptyTitle: (_e = this.lookupServiceConfig.dynamicFormOptions) === null || _e === void 0 ? void 0 : _e.searchEmptyTitle,
7164
+ searchFields: (_f = this.lookupServiceConfig.dynamicFormOptions) === null || _f === void 0 ? void 0 : _f.searchFields,
7165
+ searchTitle: (_g = this.lookupServiceConfig.dynamicFormOptions) === null || _g === void 0 ? void 0 : _g.searchTitle,
7166
+ selectLabel: (_h = this.lookupServiceConfig.dynamicFormOptions) === null || _h === void 0 ? void 0 : _h.selectLabel,
7167
+ dataKey: (_j = this.lookupServiceConfig.dynamicFormOptions) === null || _j === void 0 ? void 0 : _j.dataKey,
7168
+ emptyFieldLabel: (_k = this.lookupServiceConfig.dynamicFormOptions) === null || _k === void 0 ? void 0 : _k.emptyFieldLabel,
7169
+ emptyMessage: (_l = this.lookupServiceConfig.dynamicFormOptions) === null || _l === void 0 ? void 0 : _l.emptyMessage,
7170
+ filterLabel: (_m = this.lookupServiceConfig.dynamicFormOptions) === null || _m === void 0 ? void 0 : _m.filterLabel,
7171
+ filterTitle: (_o = this.lookupServiceConfig.dynamicFormOptions) === null || _o === void 0 ? void 0 : _o.filterTitle,
7172
+ label: (_p = this.lookupServiceConfig.dynamicFormOptions) === null || _p === void 0 ? void 0 : _p.label,
7173
+ lookupDisplayField: (_q = this.lookupServiceConfig.dynamicFormOptions) === null || _q === void 0 ? void 0 : _q.lookupDisplayField,
7174
+ multiple: (_r = this.lookupServiceConfig.dynamicFormOptions) === null || _r === void 0 ? void 0 : _r.multiple,
7175
+ name: (_s = this.lookupServiceConfig.dynamicFormOptions) === null || _s === void 0 ? void 0 : _s.name,
7176
+ onLookupRequest: function (value) { return _this.onFpasRegistrationLookupRequest(value); },
7177
+ onSearchRequest: function (event) { return _this.onFpasRegistrationSearchRequest(event); },
7178
+ required: function () { var _a; return (_a = _this.lookupServiceConfig.dynamicFormOptions) === null || _a === void 0 ? void 0 : _a.required; },
7179
+ searchObservable: this.lookupServiceConfig.searchSubject,
7180
+ suggestionsObservable: this.lookupServiceConfig.lookupSubject,
7181
+ type: angularComponents.FieldType.Lookup,
7182
+ visible: function () { var _a; return !((_a = _this.lookupServiceConfig.dynamicFormOptions) === null || _a === void 0 ? void 0 : _a.isCollective); },
7183
+ });
7184
+ };
7185
+ FpasRegistrationLookupService.prototype.onFpasRegistrationSearchRequest = function (event) {
7186
+ var _this = this;
7187
+ var _a, _b, _c, _d;
7188
+ this.onFpasRegistrationSearchRequestObservable(event, (_b = (_a = this.lookupServiceConfig) === null || _a === void 0 ? void 0 : _a.filters) === null || _b === void 0 ? void 0 : _b.additionalFilter, (_d = (_c = this.lookupServiceConfig) === null || _c === void 0 ? void 0 : _c.filters) === null || _d === void 0 ? void 0 : _d.companyIds, true).subscribe(function (data) { return _this.lookupServiceConfig.searchSubject.next(data); });
7189
+ };
7190
+ FpasRegistrationLookupService.prototype.onFpasRegistrationSearchRequestObservable = function (event, additionalFilter, companyIds, isDynamicForm) {
7191
+ var _this = this;
7192
+ if (isDynamicForm === void 0) { isDynamicForm = false; }
7193
+ var first = event.first, rows = event.rows, multiSortMeta = event.multiSortMeta, filterData = event.filterData;
7194
+ var page = first / rows;
7195
+ var sort = multiSortMeta;
7196
+ var fpasRegistrationFilterQuery = createSearchRequestFilter(filterData, this.getFpasRegistrationSearchFields());
7197
+ fpasRegistrationFilterQuery = this.getFiltersDefaultFpasRegistration(companyIds, fpasRegistrationFilterQuery, additionalFilter);
7198
+ var displayFields = mergeUnique(this.lookupServiceConfig.lookupDisplayFields.concat("e070emp"), __spread(this.lookupServiceConfig.lookupDisplayFields));
7199
+ return this.fpasRegistrationService
7200
+ .list({ page: page, sort: sort, filterQuery: fpasRegistrationFilterQuery, displayFields: displayFields })
7201
+ .pipe(operators.takeUntil(this.ngUnsubscribe))
7202
+ .pipe(operators.map(function (list) { return _this.mapToComponent(list, isDynamicForm); }));
7203
+ };
7204
+ FpasRegistrationLookupService.prototype.getFiltersDefaultFpasRegistration = function (companyIds, filterData, additionalFilter) {
7205
+ var filters = [];
7206
+ additionalFilter && filters.push("(" + additionalFilter + ")");
7207
+ filterData && filters.push("(" + filterData + ")");
7208
+ (companyIds === null || companyIds === void 0 ? void 0 : companyIds.length) && filters.push("(e070emp.id in (" + companyIds.map(function (id) { return "'" + id + "'"; }) + "))");
7209
+ return filters.join(' and ');
7210
+ };
7211
+ FpasRegistrationLookupService.prototype.mapToComponent = function (list, isDynamicForm) {
7212
+ var _this = this;
7213
+ if (isDynamicForm === void 0) { isDynamicForm = false; }
7214
+ if (isDynamicForm) {
7215
+ return ({
7216
+ gridData: list.contents
7217
+ .map(function (item) { return (__assign(__assign({}, item), { label: _this.getLabelForMaping(item) })); }),
7218
+ totalRecords: list === null || list === void 0 ? void 0 : list.totalElements,
7219
+ });
7220
+ }
7221
+ else {
7222
+ return (__assign(__assign({}, list), { contents: list.contents.map(function (item) { return (__assign(__assign({}, item), { label: _this.getLabelForMaping(item) })); }) }));
7223
+ }
7224
+ };
7225
+ FpasRegistrationLookupService.prototype.getLabelForMaping = function (item) {
7226
+ var _this = this;
7227
+ return this.lookupServiceConfig.lookupDisplayFields
7228
+ .map(function (field) {
7229
+ if (field === "name" && !(item === null || item === void 0 ? void 0 : item.name)) {
7230
+ item.name = _this.translate
7231
+ .instant(_this.configService.getTranslationPrefix() + ".list_grid_empty_field");
7232
+ }
7233
+ if (field.indexOf(".") > 0) {
7234
+ return getProp(item, field);
7235
+ }
7236
+ return item[field];
7237
+ })
7238
+ .join(this.lookupServiceConfig.lookupSeparator);
7239
+ };
7240
+ FpasRegistrationLookupService.prototype.onFpasRegistrationLookupRequest = function (value) {
7241
+ var _this = this;
7242
+ var _a, _b, _c, _d;
7243
+ this.onFpasRegistrationLookupRequestObservable(value, (_b = (_a = this.lookupServiceConfig) === null || _a === void 0 ? void 0 : _a.filters) === null || _b === void 0 ? void 0 : _b.additionalFilter, (_d = (_c = this.lookupServiceConfig) === null || _c === void 0 ? void 0 : _c.filters) === null || _d === void 0 ? void 0 : _d.companyIds).subscribe(function (data) { return _this.lookupServiceConfig.lookupSubject.next(data.contents); });
7244
+ };
7245
+ FpasRegistrationLookupService.prototype.onFpasRegistrationLookupRequestObservable = function (value, additionalFilter, companyIds) {
7246
+ var _this = this;
7247
+ var sort = this.lookupServiceConfig.lookupDisplayFields
7248
+ .map(function (field) { return ({ field: field, order: 1 }); });
7249
+ var fpasRegistrationFilterQuery = createLookupRequestFilter(value, this.getFpasRegistrationSearchFields());
7250
+ fpasRegistrationFilterQuery = this.getFiltersDefaultFpasRegistration(companyIds, fpasRegistrationFilterQuery, additionalFilter);
7251
+ var displayFields = mergeUnique(this.lookupServiceConfig.lookupDisplayFields.concat("e070emp"), __spread(this.lookupServiceConfig.lookupDisplayFields));
7252
+ return this.fpasRegistrationService
7253
+ .list({ sort: sort, filterQuery: fpasRegistrationFilterQuery, displayFields: displayFields })
7254
+ .pipe(operators.takeUntil(this.ngUnsubscribe))
7255
+ .pipe(operators.map(function (list) { return (__assign(__assign({}, list), { contents: list.contents.map(function (item) { return (__assign(__assign({}, item), { label: _this.lookupServiceConfig.lookupDisplayFields
7256
+ .map(function (field) {
7257
+ if (field === "name" && !item.name) {
7258
+ item.name = _this.translate
7259
+ .instant(_this.configService.getTranslationPrefix() + ".list_grid_empty_field");
7260
+ }
7261
+ if (field.indexOf(".") > 0) {
7262
+ return getProp(item, field);
7263
+ }
7264
+ return item[field];
7265
+ }).join(_this.lookupServiceConfig.lookupSeparator) })); }) })); }));
7266
+ };
7267
+ FpasRegistrationLookupService.prototype.getFpasRegistrationSearchFields = function () {
7268
+ return [
7269
+ new angularComponents.FormField({
7270
+ name: "code",
7271
+ label: this.translate.instant(this.configService.getTranslationPrefix() + ".fpas_registration_code"),
7272
+ type: angularComponents.FieldType.Integer,
7273
+ }),
7274
+ new angularComponents.FormField({
7275
+ name: "name",
7276
+ label: this.translate.instant(this.configService.getTranslationPrefix() + ".fpas_registration_name"),
7277
+ type: angularComponents.FieldType.String,
7278
+ })
7279
+ ];
7280
+ };
7281
+ FpasRegistrationLookupService.ctorParameters = function () { return [
7282
+ { type: core$1.TranslateService },
7283
+ { type: EntityLookupConfigService },
7284
+ { type: FpasRegistrationService }
7285
+ ]; };
7286
+ FpasRegistrationLookupService = __decorate([
7287
+ core.Injectable()
7288
+ ], FpasRegistrationLookupService);
7289
+ return FpasRegistrationLookupService;
7290
+ }());
7291
+
7292
+ var FpasRegistrationLookupComponent = /** @class */ (function (_super) {
7293
+ __extends(FpasRegistrationLookupComponent, _super);
7294
+ function FpasRegistrationLookupComponent(translate, cdRef, configService, structerService, fpasRegistrationLookupService) {
7295
+ var _this = _super.call(this, translate, cdRef, configService, structerService) || this;
7296
+ _this.translate = translate;
7297
+ _this.cdRef = cdRef;
7298
+ _this.configService = configService;
7299
+ _this.structerService = structerService;
7300
+ _this.fpasRegistrationLookupService = fpasRegistrationLookupService;
7301
+ _this.controlName = "fpasRegistration";
7302
+ _this.entity = "fpasRegistration";
7303
+ _this.domain = "tax_obligation";
7304
+ _this.service = "shared";
7305
+ _this.useDateValidation = false;
7306
+ return _this;
7307
+ }
7308
+ FpasRegistrationLookupComponent.prototype.ngOnInit = function () {
7309
+ this.fpasRegistrationSearchFields = this.fpasRegistrationLookupService.getFpasRegistrationSearchFields();
7310
+ this.fpasRegistrationSearchGridFields = this.fpasRegistrationLookupService.getFpasRegistrationSearchFields();
7311
+ };
7312
+ FpasRegistrationLookupComponent.prototype.onFpasRegistrationLookupRequest = function (value) {
7313
+ var _this = this;
7314
+ this.fpasRegistrationLookupService
7315
+ .onFpasRegistrationLookupRequestObservable(value, this.fpasRegistrationLookupService.lookupServiceConfig.filters.additionalFilter, this.companyIds)
7316
+ .subscribe(function (list) {
7317
+ _this.fpasRegistrationSuggestions = list === null || list === void 0 ? void 0 : list.contents;
7318
+ });
7319
+ };
7320
+ FpasRegistrationLookupComponent.prototype.onFpasRegistrationSearchRequest = function (event) {
7321
+ var _this = this;
7322
+ this.fpasRegistrationLookupService
7323
+ .onFpasRegistrationSearchRequestObservable(event, this.fpasRegistrationLookupService.lookupServiceConfig.filters.additionalFilter, this.companyIds)
7324
+ .subscribe(function (list) {
7325
+ _this.fpasRegistrationSearchGridData = list === null || list === void 0 ? void 0 : list.contents;
7326
+ _this.fpasRegistrationSearchTotalRecords = list === null || list === void 0 ? void 0 : list.totalElements;
7327
+ });
7328
+ };
7329
+ FpasRegistrationLookupComponent.ctorParameters = function () { return [
7330
+ { type: core$1.TranslateService },
7331
+ { type: core.ChangeDetectorRef },
7332
+ { type: EntityLookupConfigService },
7333
+ { type: StructureFilterService },
7334
+ { type: FpasRegistrationLookupService }
7335
+ ]; };
7336
+ FpasRegistrationLookupComponent = __decorate([
7337
+ core.Component({
7338
+ selector: "hcm-fpas-registration-lookup",
7339
+ template: "<s-loading-state [loading]=\"loading\" [blockWindow]=\"true\"></s-loading-state>\n<form [formGroup]=\"formGroup\">\n <s-lookup dataKey=\"id\" id=\"fpasRegistration\" name=\"fpasRegistration\" [formControlName]=\"controlName\"\n [searchFields]=\"fpasRegistrationSearchFields\"\n [searchGridFields]=\"fpasRegistrationSearchGridFields\"\n [searchGridData]=\"fpasRegistrationSearchGridData\"\n (onSelect)=\"selectOption($event)\"\n (onClear)=\"onClearItem($event)\"\n [multiple]=\"multiple\"\n [disabled]=\"isDisabled\"\n [lookupSuggestions]=\"fpasRegistrationSuggestions\"\n (onLookupRequest)=\"onFpasRegistrationLookupRequest($event)\"\n (onSearchRequest)=\"onFpasRegistrationSearchRequest($event)\"\n lookupDisplayField=\"label\"\n [searchTotalRecords]=\"fpasRegistrationSearchTotalRecords\"\n [searchTitle]=\"configService.getTranslationPrefix() \n + '.fpas_registration_search_title' | translate\"\n [searchEmptyTitle]=\"configService.getTranslationPrefix()\n + '.nothing_found' | translate\" [filterLabel]=\"configService.getTranslationPrefix()\n + '.filter' | translate\" [filterTitle]=\"configService.getTranslationPrefix()\n + '.filters' | translate\" [clearLabel]=\"configService.getTranslationPrefix()\n + '.clear' | translate\" [cancelLabel]=\"configService.getTranslationPrefix()\n + '.cancel' | translate\" [selectLabel]=\"configService.getTranslationPrefix()\n + '.select' | translate\" [searchTotalRecordsLabel]=\"configService.getTranslationPrefix()\n + '.total_records' | translate: {value: fpasRegistrationSearchTotalRecords}\"></s-lookup>\n</form>\n"
7340
+ })
7341
+ ], FpasRegistrationLookupComponent);
7342
+ return FpasRegistrationLookupComponent;
7343
+ }(BaseLookupComponent));
7344
+
7345
+ var FpasRegistrationLookupModule = /** @class */ (function () {
7346
+ function FpasRegistrationLookupModule() {
7347
+ }
7348
+ FpasRegistrationLookupModule = __decorate([
7349
+ core.NgModule({
7350
+ declarations: [
7351
+ FpasRegistrationLookupComponent,
7352
+ ],
7353
+ exports: [
7354
+ FpasRegistrationLookupComponent,
7355
+ ],
7356
+ imports: [
7357
+ SharedModule,
7358
+ angularComponents.LoadingStateModule,
7359
+ ],
7360
+ providers: [
7361
+ FpasRegistrationLookupService,
7362
+ FpasRegistrationService
7363
+ ],
7364
+ })
7365
+ ], FpasRegistrationLookupModule);
7366
+ return FpasRegistrationLookupModule;
7367
+ }());
7368
+
7369
+ var EntityLookupModule = /** @class */ (function () {
7370
+ function EntityLookupModule() {
7371
+ }
7372
+ EntityLookupModule_1 = EntityLookupModule;
7373
+ EntityLookupModule.forRoot = function (config) {
7374
+ return {
7375
+ ngModule: EntityLookupModule_1,
7376
+ providers: [
7377
+ {
7378
+ provide: ProjectConfigsInjectionToken,
7379
+ useValue: config
7380
+ }
7381
+ ]
7382
+ };
7383
+ };
7384
+ var EntityLookupModule_1;
7385
+ EntityLookupModule = EntityLookupModule_1 = __decorate([
7386
+ core.NgModule({
7387
+ providers: []
7388
+ })
7389
+ ], EntityLookupModule);
7390
+ return EntityLookupModule;
7391
+ }());
7392
+
7393
+ var fallback = {
7394
+ "hcm_contract.employment_additional_info.e_001_pes_cod": "Código",
7395
+ "hcm_contract.employment_additional_info.e_001_pes_nom": "Nome",
7396
+ "hcm_contract.employment_additional_info.e_001_pes_dat": "Data de nascimento",
7397
+ "hcm_contract.employment_additional_info.e_044_ccu_cod_ccu": "Código",
7398
+ "hcm_contract.employment_additional_info.e_044_ccu_des_ccu": "Descrição",
7399
+ "hcm_contract.employment_additional_info.e_070_fil_cod_fil": "Código",
7400
+ "hcm_contract.employment_additional_info.e_070_fil_nom_fil": "Nome",
7401
+ "hcm_contract.employment_additional_info.data_person_id_lookup_title": "Localizar a pessoa",
7402
+ "hcm_contract.employment_additional_info.cost_center_history_cost_center_search_title": "Localizar o centro de custo",
7023
7403
  "hcm_contract.employment_additional_info.employee_employer_cod_emp": "Código da empresa",
7024
7404
  "hcm_contract.employment_additional_info.employee_employment_relationship_contract_type": "Tipo de contrato",
7025
7405
  "hcm_contract.employment_additional_info.employee_person_nom_pes": "Nome do colaborador",
@@ -7050,93 +7430,6 @@
7050
7430
  "hcm_contract.employment_additional_info.resignation_situation_type_all": "Todos"
7051
7431
  };
7052
7432
 
7053
- var projectInfo = {
7054
- app: "gestao-pessoas",
7055
- domain: "hcm_entity",
7056
- service: "lookups",
7057
- };
7058
- var environment = {
7059
- name: "@senior-gestao-pessoas/hcm-entity-lookups",
7060
- project: projectInfo,
7061
- production: false,
7062
- ignorePermissions: false,
7063
- };
7064
-
7065
- /*{CA:PACKAGE_IMPORTS:START}*/
7066
- /*{CA:PACKAGE_IMPORTS:END}*/
7067
- /*{CA:PROJECT_IMPORTS:START}*/
7068
- /*{CA:PROJECT_IMPORTS:END}*/
7069
- var CompanyBranchIndicationsService = /** @class */ (function (_super) {
7070
- __extends(CompanyBranchIndicationsService, _super);
7071
- /*{CA:CLASS_ATTRIBUTES:START}*/
7072
- /*{CA:CLASS_ATTRIBUTES:END}*/
7073
- function CompanyBranchIndicationsService(http, messageService, translate, configService) {
7074
- var _this = _super.call(this, http, messageService, environment.project.domain + "/" + environment.project.service + "/entities/companyBranchIndications", environment.project.domain + "/" + environment.project.service + "/actions", translate, configService) || this;
7075
- _this.http = http;
7076
- _this.messageService = messageService;
7077
- _this.translate = translate;
7078
- _this.configService = configService;
7079
- return _this;
7080
- /*{CA:CONSTRUCTOR_END:START}*/
7081
- /*{CA:CONSTRUCTOR_END:END}*/
7082
- }
7083
- CompanyBranchIndicationsService.prototype.listExternalCompanyBranchIndications = function (listParams) {
7084
- return this.http
7085
- .get("hcm_foundation/general/entities/companyBranchIndications", {
7086
- params: this.getListQueryParams(listParams),
7087
- })
7088
- .pipe(this.defaultCatch());
7089
- };
7090
- CompanyBranchIndicationsService.ctorParameters = function () { return [
7091
- { type: http.HttpClient },
7092
- { type: api.MessageService },
7093
- { type: core$1.TranslateService },
7094
- { type: EntityLookupConfigService }
7095
- ]; };
7096
- CompanyBranchIndicationsService = __decorate([
7097
- core.Injectable()
7098
- ], CompanyBranchIndicationsService);
7099
- return CompanyBranchIndicationsService;
7100
- }(EntityService));
7101
- /*{CA:FILE_CONTENTS:START}*/
7102
- /*{CA:FILE_CONTENTS:END}*/
7103
-
7104
- /*{CA:PACKAGE_IMPORTS:START}*/
7105
- /*{CA:PACKAGE_IMPORTS:END}*/
7106
- /*{CA:PROJECT_IMPORTS:START}*/
7107
- /*{CA:PROJECT_IMPORTS:END}*/
7108
- var CompanyBranchIndicationsModule = /** @class */ (function () {
7109
- function CompanyBranchIndicationsModule() {
7110
- }
7111
- CompanyBranchIndicationsModule = __decorate([
7112
- core.NgModule({
7113
- imports: [
7114
- platformComponents.PermissionsModule.forChild([
7115
- {
7116
- name: "companyBranchIndications",
7117
- actions: ["Visualizar", "Incluir", "Editar", "Excluir"],
7118
- uri: "res://senior.com.br/hcm_contract/employment_contract/entities/companyBranchIndications",
7119
- },
7120
- ]),
7121
- ],
7122
- providers: [
7123
- CompanyBranchIndicationsService,
7124
- ],
7125
- declarations: [
7126
- /*{CA:MODULE_DECLARATIONS:START}*/
7127
- /*{CA:MODULE_DECLARATIONS:END}*/
7128
- ],
7129
- exports: [
7130
- /*{CA:MODULE_EXPORTS:START}*/
7131
- /*{CA:MODULE_EXPORTS:END}*/
7132
- ],
7133
- })
7134
- ], CompanyBranchIndicationsModule);
7135
- return CompanyBranchIndicationsModule;
7136
- }());
7137
- /*{CA:FILE_CONTENTS:START}*/
7138
- /*{CA:FILE_CONTENTS:END}*/
7139
-
7140
7433
  var E001PesModule = /** @class */ (function () {
7141
7434
  function E001PesModule() {
7142
7435
  }
@@ -7161,6 +7454,18 @@
7161
7454
  return E001PesModule;
7162
7455
  }());
7163
7456
 
7457
+ var projectInfo = {
7458
+ app: "gestao-pessoas",
7459
+ domain: "hcm_entity",
7460
+ service: "lookups",
7461
+ };
7462
+ var environment = {
7463
+ name: "@senior-gestao-pessoas/hcm-entity-lookups",
7464
+ project: projectInfo,
7465
+ production: false,
7466
+ ignorePermissions: false,
7467
+ };
7468
+
7164
7469
  /*{CA:PACKAGE_IMPORTS:START}*/
7165
7470
  /*{CA:PACKAGE_IMPORTS:END}*/
7166
7471
  /*{CA:PROJECT_IMPORTS:START}*/
@@ -8057,13 +8362,34 @@
8057
8362
  return CompanyLinkedLocationModule;
8058
8363
  }());
8059
8364
 
8365
+ var FpasRegistrationModule = /** @class */ (function () {
8366
+ function FpasRegistrationModule() {
8367
+ }
8368
+ FpasRegistrationModule = __decorate([
8369
+ core.NgModule({
8370
+ imports: [
8371
+ platformComponents.PermissionsModule.forChild([
8372
+ {
8373
+ name: 'fpasRegistration',
8374
+ actions: ['Visualizar', 'Incluir', 'Editar', 'Excluir'],
8375
+ uri: "res://senior.com.br/tax_obligation/shared/entities/fpasRegistration",
8376
+ },
8377
+ ]),
8378
+ ],
8379
+ providers: [
8380
+ FpasRegistrationService
8381
+ ]
8382
+ })
8383
+ ], FpasRegistrationModule);
8384
+ return FpasRegistrationModule;
8385
+ }());
8386
+
8060
8387
  var CoreLookupModule = /** @class */ (function () {
8061
8388
  function CoreLookupModule() {
8062
8389
  }
8063
8390
  CoreLookupModule = __decorate([
8064
8391
  core.NgModule({
8065
8392
  imports: [
8066
- CompanyBranchIndicationsModule,
8067
8393
  E030AgeModule,
8068
8394
  E030BanModule,
8069
8395
  E044CcuModule,
@@ -8086,154 +8412,24 @@
8086
8412
  VariableEntryModule,
8087
8413
  CalculationDefinitionModule,
8088
8414
  EmploymentRelationshipModule,
8089
- WageTypePayrollModule,
8090
- CompanyLinkedLocationModule
8091
- ],
8092
- })
8093
- ], CoreLookupModule);
8094
- return CoreLookupModule;
8095
- }());
8096
-
8097
- var moment = moment$k;
8098
- var Holiday = /** @class */ (function () {
8099
- function Holiday() {
8100
- this.deleted = false;
8101
- /*{CA:CLASS_METHODS:START}*/
8102
- /*{CA:CLASS_METHODS:END}*/
8103
- }
8104
- /*{CA:CLASS_ATTRIBUTES:START}*/
8105
- /*{CA:CLASS_ATTRIBUTES:END}*/
8106
- Holiday.fromDto = function (holidayDto, originEntity) {
8107
- var model = __assign({}, holidayDto);
8108
- model.createdDate = model.createdDate && moment(model.createdDate).toDate();
8109
- model.lastModifiedDate = model.lastModifiedDate && moment(model.lastModifiedDate).toDate();
8110
- var lookupSeparator = " - ";
8111
- var displayFields = [
8112
- "id",
8113
- "name",
8114
- "day",
8115
- "month",
8116
- "year",
8117
- "deleted",
8118
- "extIntSts",
8119
- "extIntMsg",
8120
- "createdBy",
8121
- "createdDate",
8122
- "lastModifiedBy",
8123
- "lastModifiedDate",
8124
- ];
8125
- model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
8126
- return model;
8127
- };
8128
- Holiday.toDto = function (holiday, originEntity) {
8129
- var dto = __assign({}, holiday);
8130
- dto.createdDate = dto.createdDate && moment(dto.createdDate).format();
8131
- dto.lastModifiedDate = dto.lastModifiedDate && moment(dto.lastModifiedDate).format();
8132
- delete dto.label;
8133
- return dto;
8134
- };
8135
- return Holiday;
8136
- }());
8137
- /*{CA:FILE_CONTENTS:START}*/
8138
- /*{CA:FILE_CONTENTS:END}*/
8139
-
8140
- var moment$1 = moment$k;
8141
- var HolidayGroup = /** @class */ (function () {
8142
- function HolidayGroup() {
8143
- this.deleted = false;
8144
- /*{CA:CLASS_METHODS:START}*/
8145
- /*{CA:CLASS_METHODS:END}*/
8146
- }
8147
- /*{CA:CLASS_ATTRIBUTES:START}*/
8148
- /*{CA:CLASS_ATTRIBUTES:END}*/
8149
- HolidayGroup.fromDto = function (holidayGroupDto, originEntity) {
8150
- var model = __assign({}, holidayGroupDto);
8151
- model.createdDate = model.createdDate && moment$1(model.createdDate).toDate();
8152
- model.lastModifiedDate = model.lastModifiedDate && moment$1(model.lastModifiedDate).toDate();
8153
- var lookupSeparator = " - ";
8154
- var displayFields = [
8155
- "id",
8156
- "code",
8157
- "name",
8158
- "deleted",
8159
- "extIntSts",
8160
- "extIntMsg",
8161
- "createdBy",
8162
- "createdDate",
8163
- "lastModifiedBy",
8164
- "lastModifiedDate",
8165
- ];
8166
- model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
8167
- if (originEntity !== "Holiday" && model.holiday)
8168
- model.holiday = Object.values(model.holiday).map(function (item) { return Holiday.fromDto(item, "HolidayGroup"); });
8169
- return model;
8170
- };
8171
- HolidayGroup.toDto = function (holidayGroup, originEntity) {
8172
- var dto = __assign({}, holidayGroup);
8173
- dto.createdDate = dto.createdDate && moment$1(dto.createdDate).format();
8174
- dto.lastModifiedDate = dto.lastModifiedDate && moment$1(dto.lastModifiedDate).format();
8175
- delete dto.label;
8176
- if (originEntity !== "Holiday" && dto.holiday)
8177
- dto.holiday = Object.values(dto.holiday)
8178
- .map(function (item) { return Holiday.toDto(item, "HolidayGroup"); })
8179
- .filter(function (item) { return Object.keys(item).length; });
8180
- return dto;
8181
- };
8182
- return HolidayGroup;
8183
- }());
8184
- /*{CA:FILE_CONTENTS:START}*/
8185
- /*{CA:FILE_CONTENTS:END}*/
8186
-
8187
- /*{CA:PACKAGE_IMPORTS:START}*/
8188
- /*{CA:PACKAGE_IMPORTS:END}*/
8189
- /*{CA:PROJECT_IMPORTS:START}*/
8190
- /*{CA:PROJECT_IMPORTS:END}*/
8191
- var CompanyBranchIndications = /** @class */ (function () {
8192
- function CompanyBranchIndications() {
8193
- this.deleted = false;
8194
- /*{CA:CLASS_METHODS:START}*/
8195
- /*{CA:CLASS_METHODS:END}*/
8196
- }
8197
- /*{CA:CLASS_ATTRIBUTES:START}*/
8198
- /*{CA:CLASS_ATTRIBUTES:END}*/
8199
- CompanyBranchIndications.fromDto = function (companyBranchIndicationsDto, originEntity) {
8200
- var model = __assign({}, companyBranchIndicationsDto);
8201
- model.createdDate = model.createdDate && moment$k(model.createdDate).toDate();
8202
- model.lastModifiedDate = model.lastModifiedDate && moment$k(model.lastModifiedDate).toDate();
8203
- var lookupSeparator = " - ";
8204
- var displayFields = ["id", "deleted", "extIntSts", "extIntMsg", "createdBy", "createdDate", "lastModifiedBy", "lastModifiedDate"];
8205
- model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
8206
- if (originEntity !== "HolidayGroup" && model.nightlyHolidayGroup)
8207
- model.nightlyHolidayGroup = HolidayGroup.fromDto(model.nightlyHolidayGroup, "CompanyBranchIndications");
8208
- if (originEntity !== "HolidayGroup" && model.daytimeHolidayGroup)
8209
- model.daytimeHolidayGroup = HolidayGroup.fromDto(model.daytimeHolidayGroup, "CompanyBranchIndications");
8210
- return model;
8211
- };
8212
- CompanyBranchIndications.toDto = function (companyBranchIndications, originEntity) {
8213
- var dto = __assign({}, companyBranchIndications);
8214
- dto.createdDate = dto.createdDate && moment$k(dto.createdDate).format();
8215
- dto.lastModifiedDate = dto.lastModifiedDate && moment$k(dto.lastModifiedDate).format();
8216
- delete dto.label;
8217
- if (originEntity !== "HolidayGroup" && dto.nightlyHolidayGroup)
8218
- dto.nightlyHolidayGroup = HolidayGroup.toDto(dto.nightlyHolidayGroup, "CompanyBranchIndications");
8219
- if (originEntity !== "HolidayGroup" && dto.daytimeHolidayGroup)
8220
- dto.daytimeHolidayGroup = HolidayGroup.toDto(dto.daytimeHolidayGroup, "CompanyBranchIndications");
8221
- return dto;
8222
- };
8223
- return CompanyBranchIndications;
8415
+ WageTypePayrollModule,
8416
+ CompanyLinkedLocationModule,
8417
+ FpasRegistrationModule
8418
+ ],
8419
+ })
8420
+ ], CoreLookupModule);
8421
+ return CoreLookupModule;
8224
8422
  }());
8225
- /*{CA:FILE_CONTENTS:START}*/
8226
- /*{CA:FILE_CONTENTS:END}*/
8227
8423
 
8228
- var moment$2 = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8424
+ var moment = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8229
8425
  var E001Pes = /** @class */ (function () {
8230
8426
  function E001Pes() {
8231
8427
  this.excluido = false;
8232
8428
  }
8233
8429
  E001Pes.fromDto = function (e001PesDto, originEntity) {
8234
8430
  var model = __assign({}, e001PesDto);
8235
- model.createdDate = model.createdDate && moment$2(model.createdDate).toDate();
8236
- model.lastModifiedDate = model.lastModifiedDate && moment$2(model.lastModifiedDate).toDate();
8431
+ model.createdDate = model.createdDate && moment(model.createdDate).toDate();
8432
+ model.lastModifiedDate = model.lastModifiedDate && moment(model.lastModifiedDate).toDate();
8237
8433
  var lookupSeparator = " - ";
8238
8434
  var displayFields = ["nomPes"];
8239
8435
  model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
@@ -8241,8 +8437,8 @@
8241
8437
  };
8242
8438
  E001Pes.toDto = function (e001Pes, originEntity) {
8243
8439
  var dto = __assign({}, e001Pes);
8244
- dto.createdDate = dto.createdDate && moment$2(dto.createdDate).format();
8245
- dto.lastModifiedDate = dto.lastModifiedDate && moment$2(dto.lastModifiedDate).format();
8440
+ dto.createdDate = dto.createdDate && moment(dto.createdDate).format();
8441
+ dto.lastModifiedDate = dto.lastModifiedDate && moment(dto.lastModifiedDate).format();
8246
8442
  delete dto.label;
8247
8443
  delete dto._discriminator;
8248
8444
  return dto;
@@ -8250,17 +8446,17 @@
8250
8446
  return E001Pes;
8251
8447
  }());
8252
8448
 
8253
- var moment$3 = moment$k;
8449
+ var moment$1 = moment$k;
8254
8450
  var Employee = /** @class */ (function () {
8255
8451
  function Employee() {
8256
8452
  this.deleted = false;
8257
8453
  }
8258
8454
  Employee.fromDto = function (employeeDto, originEntity) {
8259
8455
  var model = __assign({}, employeeDto);
8260
- model.hireDate = model.hireDate && moment$3(model.hireDate).toDate();
8261
- model.dismissalDate = model.dismissalDate && moment$3(model.dismissalDate).toDate();
8262
- model.createdDate = model.createdDate && moment$3(model.createdDate).toDate();
8263
- model.lastModifiedDate = model.lastModifiedDate && moment$3(model.lastModifiedDate).toDate();
8456
+ model.hireDate = model.hireDate && moment$1(model.hireDate).toDate();
8457
+ model.dismissalDate = model.dismissalDate && moment$1(model.dismissalDate).toDate();
8458
+ model.createdDate = model.createdDate && moment$1(model.createdDate).toDate();
8459
+ model.lastModifiedDate = model.lastModifiedDate && moment$1(model.lastModifiedDate).toDate();
8264
8460
  var lookupSeparator = " - ";
8265
8461
  var displayFields = [
8266
8462
  "id",
@@ -8284,10 +8480,10 @@
8284
8480
  };
8285
8481
  Employee.toDto = function (employee, originEntity) {
8286
8482
  var dto = __assign({}, employee);
8287
- dto.hireDate = dto.hireDate && moment$3(dto.hireDate).format("YYYY-MM-DD");
8288
- dto.dismissalDate = dto.dismissalDate && moment$3(dto.dismissalDate).format("YYYY-MM-DD");
8289
- dto.createdDate = dto.createdDate && moment$3(dto.createdDate).format();
8290
- dto.lastModifiedDate = dto.lastModifiedDate && moment$3(dto.lastModifiedDate).format();
8483
+ dto.hireDate = dto.hireDate && moment$1(dto.hireDate).format("YYYY-MM-DD");
8484
+ dto.dismissalDate = dto.dismissalDate && moment$1(dto.dismissalDate).format("YYYY-MM-DD");
8485
+ dto.createdDate = dto.createdDate && moment$1(dto.createdDate).format();
8486
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$1(dto.lastModifiedDate).format();
8291
8487
  delete dto.label;
8292
8488
  delete dto._discriminator;
8293
8489
  delete dto.employer._discriminator;
@@ -8300,7 +8496,7 @@
8300
8496
  return Employee;
8301
8497
  }());
8302
8498
 
8303
- var moment$4 = moment$k;
8499
+ var moment$2 = moment$k;
8304
8500
  var Position = /** @class */ (function () {
8305
8501
  function Position() {
8306
8502
  this.deleted = false;
@@ -8311,8 +8507,8 @@
8311
8507
  /*{CA:CLASS_ATTRIBUTES:END}*/
8312
8508
  Position.fromDto = function (positionDto, originEntity) {
8313
8509
  var model = __assign({}, positionDto);
8314
- model.createdDate = model.createdDate && moment$4(model.createdDate).toDate();
8315
- model.lastModifiedDate = model.lastModifiedDate && moment$4(model.lastModifiedDate).toDate();
8510
+ model.createdDate = model.createdDate && moment$2(model.createdDate).toDate();
8511
+ model.lastModifiedDate = model.lastModifiedDate && moment$2(model.lastModifiedDate).toDate();
8316
8512
  var lookupSeparator = " - ";
8317
8513
  var displayFields = [
8318
8514
  "id",
@@ -8331,8 +8527,8 @@
8331
8527
  };
8332
8528
  Position.toDto = function (position, originEntity) {
8333
8529
  var dto = __assign({}, position);
8334
- dto.createdDate = dto.createdDate && moment$4(dto.createdDate).format();
8335
- dto.lastModifiedDate = dto.lastModifiedDate && moment$4(dto.lastModifiedDate).format();
8530
+ dto.createdDate = dto.createdDate && moment$2(dto.createdDate).format();
8531
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$2(dto.lastModifiedDate).format();
8336
8532
  delete dto.label;
8337
8533
  return dto;
8338
8534
  };
@@ -8341,14 +8537,14 @@
8341
8537
  /*{CA:FILE_CONTENTS:START}*/
8342
8538
  /*{CA:FILE_CONTENTS:END}*/
8343
8539
 
8344
- var moment$5 = moment$k;
8540
+ var moment$3 = moment$k;
8345
8541
  var JobPositionStructure = /** @class */ (function () {
8346
8542
  function JobPositionStructure() {
8347
8543
  }
8348
8544
  JobPositionStructure.fromDto = function (jobPositionStructureDto, originEntity) {
8349
8545
  var model = __assign({}, jobPositionStructureDto);
8350
- model.createdDate = model.createdDate && moment$5(model.createdDate).toDate();
8351
- model.lastModifiedDate = model.lastModifiedDate && moment$5(model.lastModifiedDate).toDate();
8546
+ model.createdDate = model.createdDate && moment$3(model.createdDate).toDate();
8547
+ model.lastModifiedDate = model.lastModifiedDate && moment$3(model.lastModifiedDate).toDate();
8352
8548
  var lookupSeparator = " - ";
8353
8549
  var displayFields = ["id", "code", "createdBy", "createdDate", "lastModifiedBy", "lastModifiedDate"];
8354
8550
  model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
@@ -8356,22 +8552,22 @@
8356
8552
  };
8357
8553
  JobPositionStructure.toDto = function (jobPositionStructure, originEntity) {
8358
8554
  var dto = __assign({}, jobPositionStructure);
8359
- dto.createdDate = dto.createdDate && moment$5(dto.createdDate).format();
8360
- dto.lastModifiedDate = dto.lastModifiedDate && moment$5(dto.lastModifiedDate).format();
8555
+ dto.createdDate = dto.createdDate && moment$3(dto.createdDate).format();
8556
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$3(dto.lastModifiedDate).format();
8361
8557
  delete dto.label;
8362
8558
  return dto;
8363
8559
  };
8364
8560
  return JobPositionStructure;
8365
8561
  }());
8366
8562
 
8367
- var moment$6 = moment$k;
8563
+ var moment$4 = moment$k;
8368
8564
  var JobPosition = /** @class */ (function () {
8369
8565
  function JobPosition() {
8370
8566
  }
8371
8567
  JobPosition.fromDto = function (jobPositionDto, originEntity) {
8372
8568
  var model = __assign({}, jobPositionDto);
8373
- model.createdDate = model.createdDate && moment$6(model.createdDate).toDate();
8374
- model.lastModifiedDate = model.lastModifiedDate && moment$6(model.lastModifiedDate).toDate();
8569
+ model.createdDate = model.createdDate && moment$4(model.createdDate).toDate();
8570
+ model.lastModifiedDate = model.lastModifiedDate && moment$4(model.lastModifiedDate).toDate();
8375
8571
  var lookupSeparator = " - ";
8376
8572
  var displayFields = [
8377
8573
  "id",
@@ -8393,8 +8589,8 @@
8393
8589
  };
8394
8590
  JobPosition.toDto = function (jobPosition, originEntity) {
8395
8591
  var dto = __assign({}, jobPosition);
8396
- dto.createdDate = dto.createdDate && moment$6(dto.createdDate).format();
8397
- dto.lastModifiedDate = dto.lastModifiedDate && moment$6(dto.lastModifiedDate).format();
8592
+ dto.createdDate = dto.createdDate && moment$4(dto.createdDate).format();
8593
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$4(dto.lastModifiedDate).format();
8398
8594
  delete dto.label;
8399
8595
  if (originEntity !== "JobPositionStructure" && dto.jobPositionStructure)
8400
8596
  dto.jobPositionStructure = JobPositionStructure.toDto(dto.jobPositionStructure, "JobPosition");
@@ -8403,14 +8599,14 @@
8403
8599
  return JobPosition;
8404
8600
  }());
8405
8601
 
8406
- var moment$7 = moment$k;
8602
+ var moment$5 = moment$k;
8407
8603
  var Syndicate = /** @class */ (function () {
8408
8604
  function Syndicate() {
8409
8605
  }
8410
8606
  Syndicate.fromDto = function (syndicateDto, originEntity) {
8411
8607
  var model = __assign({}, syndicateDto);
8412
- model.createdDate = model.createdDate && moment$7(model.createdDate).toDate();
8413
- model.lastModifiedDate = model.lastModifiedDate && moment$7(model.lastModifiedDate).toDate();
8608
+ model.createdDate = model.createdDate && moment$5(model.createdDate).toDate();
8609
+ model.lastModifiedDate = model.lastModifiedDate && moment$5(model.lastModifiedDate).toDate();
8414
8610
  var lookupSeparator = " - ";
8415
8611
  var displayFields = [
8416
8612
  "id",
@@ -8428,22 +8624,22 @@
8428
8624
  };
8429
8625
  Syndicate.toDto = function (syndicate, originEntity) {
8430
8626
  var dto = __assign({}, syndicate);
8431
- dto.createdDate = dto.createdDate && moment$7(dto.createdDate).format();
8432
- dto.lastModifiedDate = dto.lastModifiedDate && moment$7(dto.lastModifiedDate).format();
8627
+ dto.createdDate = dto.createdDate && moment$5(dto.createdDate).format();
8628
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$5(dto.lastModifiedDate).format();
8433
8629
  delete dto.label;
8434
8630
  return dto;
8435
8631
  };
8436
8632
  return Syndicate;
8437
8633
  }());
8438
8634
 
8439
- var moment$8 = moment$k;
8635
+ var moment$6 = moment$k;
8440
8636
  var EmploymentRelationship = /** @class */ (function () {
8441
8637
  function EmploymentRelationship() {
8442
8638
  }
8443
8639
  EmploymentRelationship.fromDto = function (employmentRelationshipDto, originEntity) {
8444
8640
  var model = __assign({}, employmentRelationshipDto);
8445
- model.createdDate = model.createdDate && moment$8(model.createdDate).toDate();
8446
- model.lastModifiedDate = model.lastModifiedDate && moment$8(model.lastModifiedDate).toDate();
8641
+ model.createdDate = model.createdDate && moment$6(model.createdDate).toDate();
8642
+ model.lastModifiedDate = model.lastModifiedDate && moment$6(model.lastModifiedDate).toDate();
8447
8643
  var lookupSeparator = " - ";
8448
8644
  var displayFields = [
8449
8645
  "id",
@@ -8461,23 +8657,23 @@
8461
8657
  };
8462
8658
  EmploymentRelationship.toDto = function (employmentRelationship, originEntity) {
8463
8659
  var dto = __assign({}, employmentRelationship);
8464
- dto.createdDate = dto.createdDate && moment$8(dto.createdDate).format();
8465
- dto.lastModifiedDate = dto.lastModifiedDate && moment$8(dto.lastModifiedDate).format();
8660
+ dto.createdDate = dto.createdDate && moment$6(dto.createdDate).format();
8661
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$6(dto.lastModifiedDate).format();
8466
8662
  delete dto.label;
8467
8663
  return dto;
8468
8664
  };
8469
8665
  return EmploymentRelationship;
8470
8666
  }());
8471
8667
 
8472
- var moment$9 = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8668
+ var moment$7 = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8473
8669
  var Workshift = /** @class */ (function () {
8474
8670
  function Workshift() {
8475
8671
  this.deleted = false;
8476
8672
  }
8477
8673
  Workshift.fromDto = function (workshiftDto, originEntity) {
8478
8674
  var model = __assign({}, workshiftDto);
8479
- model.createdDate = model.createdDate && moment$9(model.createdDate).toDate();
8480
- model.lastModifiedDate = model.lastModifiedDate && moment$9(model.lastModifiedDate).toDate();
8675
+ model.createdDate = model.createdDate && moment$7(model.createdDate).toDate();
8676
+ model.lastModifiedDate = model.lastModifiedDate && moment$7(model.lastModifiedDate).toDate();
8481
8677
  var lookupSeparator = " - ";
8482
8678
  var displayFields = [
8483
8679
  "id",
@@ -8497,8 +8693,8 @@
8497
8693
  };
8498
8694
  Workshift.toDto = function (workshift, originEntity) {
8499
8695
  var dto = __assign({}, workshift);
8500
- dto.createdDate = dto.createdDate && moment$9(dto.createdDate).format();
8501
- dto.lastModifiedDate = dto.lastModifiedDate && moment$9(dto.lastModifiedDate).format();
8696
+ dto.createdDate = dto.createdDate && moment$7(dto.createdDate).format();
8697
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$7(dto.lastModifiedDate).format();
8502
8698
  delete dto.label;
8503
8699
  delete dto._discriminator;
8504
8700
  return dto;
@@ -8506,16 +8702,16 @@
8506
8702
  return Workshift;
8507
8703
  }());
8508
8704
 
8509
- var moment$a = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8705
+ var moment$8 = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8510
8706
  var WorkshiftGroup = /** @class */ (function () {
8511
8707
  function WorkshiftGroup() {
8512
8708
  this.deleted = false;
8513
8709
  }
8514
8710
  WorkshiftGroup.fromDto = function (workshiftGroupDto, originEntity) {
8515
8711
  var model = __assign({}, workshiftGroupDto);
8516
- model.baseDate = model.baseDate && moment$a(model.baseDate).toDate();
8517
- model.createdDate = model.createdDate && moment$a(model.createdDate).toDate();
8518
- model.lastModifiedDate = model.lastModifiedDate && moment$a(model.lastModifiedDate).toDate();
8712
+ model.baseDate = model.baseDate && moment$8(model.baseDate).toDate();
8713
+ model.createdDate = model.createdDate && moment$8(model.createdDate).toDate();
8714
+ model.lastModifiedDate = model.lastModifiedDate && moment$8(model.lastModifiedDate).toDate();
8519
8715
  var lookupSeparator = " - ";
8520
8716
  var displayFields = [
8521
8717
  "id",
@@ -8534,9 +8730,9 @@
8534
8730
  };
8535
8731
  WorkshiftGroup.toDto = function (workshiftGroup, originEntity) {
8536
8732
  var dto = __assign({}, workshiftGroup);
8537
- dto.baseDate = dto.baseDate && moment$a(dto.baseDate).format("YYYY-MM-DD");
8538
- dto.createdDate = dto.createdDate && moment$a(dto.createdDate).format();
8539
- dto.lastModifiedDate = dto.lastModifiedDate && moment$a(dto.lastModifiedDate).format();
8733
+ dto.baseDate = dto.baseDate && moment$8(dto.baseDate).format("YYYY-MM-DD");
8734
+ dto.createdDate = dto.createdDate && moment$8(dto.createdDate).format();
8735
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$8(dto.lastModifiedDate).format();
8540
8736
  delete dto.label;
8541
8737
  delete dto._discriminator;
8542
8738
  return dto;
@@ -8544,7 +8740,7 @@
8544
8740
  return WorkshiftGroup;
8545
8741
  }());
8546
8742
 
8547
- var moment$b = moment$k;
8743
+ var moment$9 = moment$k;
8548
8744
  var PositionActingType = /** @class */ (function () {
8549
8745
  function PositionActingType() {
8550
8746
  this.deleted = false;
@@ -8555,8 +8751,8 @@
8555
8751
  /*{CA:CLASS_ATTRIBUTES:END}*/
8556
8752
  PositionActingType.fromDto = function (positionActingTypeDto, originEntity) {
8557
8753
  var model = __assign({}, positionActingTypeDto);
8558
- model.createdDate = model.createdDate && moment$b(model.createdDate).toDate();
8559
- model.lastModifiedDate = model.lastModifiedDate && moment$b(model.lastModifiedDate).toDate();
8754
+ model.createdDate = model.createdDate && moment$9(model.createdDate).toDate();
8755
+ model.lastModifiedDate = model.lastModifiedDate && moment$9(model.lastModifiedDate).toDate();
8560
8756
  var lookupSeparator = " - ";
8561
8757
  var displayFields = [
8562
8758
  "id",
@@ -8575,8 +8771,8 @@
8575
8771
  };
8576
8772
  PositionActingType.toDto = function (positionActingType, originEntity) {
8577
8773
  var dto = __assign({}, positionActingType);
8578
- dto.createdDate = dto.createdDate && moment$b(dto.createdDate).format();
8579
- dto.lastModifiedDate = dto.lastModifiedDate && moment$b(dto.lastModifiedDate).format();
8774
+ dto.createdDate = dto.createdDate && moment$9(dto.createdDate).format();
8775
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$9(dto.lastModifiedDate).format();
8580
8776
  delete dto.label;
8581
8777
  return dto;
8582
8778
  };
@@ -8585,7 +8781,7 @@
8585
8781
  /*{CA:FILE_CONTENTS:START}*/
8586
8782
  /*{CA:FILE_CONTENTS:END}*/
8587
8783
 
8588
- var moment$c = moment$k;
8784
+ var moment$a = moment$k;
8589
8785
  var LocationStructure = /** @class */ (function () {
8590
8786
  function LocationStructure() {
8591
8787
  }
@@ -8593,8 +8789,8 @@
8593
8789
  /*{CA:CLASS_ATTRIBUTES:END}*/
8594
8790
  LocationStructure.fromDto = function (locationStructureDto, originEntity) {
8595
8791
  var model = __assign({}, locationStructureDto);
8596
- model.createdDate = model.createdDate && moment$c(model.createdDate).toDate();
8597
- model.lastModifiedDate = model.lastModifiedDate && moment$c(model.lastModifiedDate).toDate();
8792
+ model.createdDate = model.createdDate && moment$a(model.createdDate).toDate();
8793
+ model.lastModifiedDate = model.lastModifiedDate && moment$a(model.lastModifiedDate).toDate();
8598
8794
  var lookupSeparator = " - ";
8599
8795
  var displayFields = [
8600
8796
  "id",
@@ -8613,8 +8809,8 @@
8613
8809
  };
8614
8810
  LocationStructure.toDto = function (locationStructure, originEntity) {
8615
8811
  var dto = __assign({}, locationStructure);
8616
- dto.createdDate = dto.createdDate && moment$c(dto.createdDate).format();
8617
- dto.lastModifiedDate = dto.lastModifiedDate && moment$c(dto.lastModifiedDate).format();
8812
+ dto.createdDate = dto.createdDate && moment$a(dto.createdDate).format();
8813
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$a(dto.lastModifiedDate).format();
8618
8814
  delete dto.label;
8619
8815
  return dto;
8620
8816
  };
@@ -8623,7 +8819,7 @@
8623
8819
  /*{CA:FILE_CONTENTS:START}*/
8624
8820
  /*{CA:FILE_CONTENTS:END}*/
8625
8821
 
8626
- var moment$d = moment$k;
8822
+ var moment$b = moment$k;
8627
8823
  var Location = /** @class */ (function () {
8628
8824
  function Location() {
8629
8825
  }
@@ -8631,10 +8827,10 @@
8631
8827
  /*{CA:CLASS_ATTRIBUTES:END}*/
8632
8828
  Location.fromDto = function (locationDto, originEntity) {
8633
8829
  var model = __assign({}, locationDto);
8634
- model.initialValidity = model.initialValidity && moment$d(model.initialValidity).toDate();
8635
- model.finalValidity = model.finalValidity && moment$d(model.finalValidity).toDate();
8636
- model.createdDate = model.createdDate && moment$d(model.createdDate).toDate();
8637
- model.lastModifiedDate = model.lastModifiedDate && moment$d(model.lastModifiedDate).toDate();
8830
+ model.initialValidity = model.initialValidity && moment$b(model.initialValidity).toDate();
8831
+ model.finalValidity = model.finalValidity && moment$b(model.finalValidity).toDate();
8832
+ model.createdDate = model.createdDate && moment$b(model.createdDate).toDate();
8833
+ model.lastModifiedDate = model.lastModifiedDate && moment$b(model.lastModifiedDate).toDate();
8638
8834
  var lookupSeparator = " - ";
8639
8835
  var displayFields = [
8640
8836
  "id",
@@ -8657,10 +8853,10 @@
8657
8853
  };
8658
8854
  Location.toDto = function (location, originEntity) {
8659
8855
  var dto = __assign({}, location);
8660
- dto.initialValidity = dto.initialValidity && moment$d(dto.initialValidity).format("YYYY-MM-DD");
8661
- dto.finalValidity = dto.finalValidity && moment$d(dto.finalValidity).format("YYYY-MM-DD");
8662
- dto.createdDate = dto.createdDate && moment$d(dto.createdDate).format();
8663
- dto.lastModifiedDate = dto.lastModifiedDate && moment$d(dto.lastModifiedDate).format();
8856
+ dto.initialValidity = dto.initialValidity && moment$b(dto.initialValidity).format("YYYY-MM-DD");
8857
+ dto.finalValidity = dto.finalValidity && moment$b(dto.finalValidity).format("YYYY-MM-DD");
8858
+ dto.createdDate = dto.createdDate && moment$b(dto.createdDate).format();
8859
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$b(dto.lastModifiedDate).format();
8664
8860
  delete dto.label;
8665
8861
  if (originEntity !== "LocationStructure" && dto.locationStructure)
8666
8862
  dto.locationStructure = LocationStructure.toDto(dto.locationStructure, "Location");
@@ -8671,7 +8867,7 @@
8671
8867
  /*{CA:FILE_CONTENTS:START}*/
8672
8868
  /*{CA:FILE_CONTENTS:END}*/
8673
8869
 
8674
- var moment$e = moment$k;
8870
+ var moment$c = moment$k;
8675
8871
  var E030Ban = /** @class */ (function () {
8676
8872
  function E030Ban() {
8677
8873
  this.excluido = false;
@@ -8682,8 +8878,8 @@
8682
8878
  /*{CA:CLASS_ATTRIBUTES:END}*/
8683
8879
  E030Ban.fromDto = function (e030BanDto, originEntity) {
8684
8880
  var model = __assign({}, e030BanDto);
8685
- model.createdDate = model.createdDate && moment$e(model.createdDate).toDate();
8686
- model.lastModifiedDate = model.lastModifiedDate && moment$e(model.lastModifiedDate).toDate();
8881
+ model.createdDate = model.createdDate && moment$c(model.createdDate).toDate();
8882
+ model.lastModifiedDate = model.lastModifiedDate && moment$c(model.lastModifiedDate).toDate();
8687
8883
  var lookupSeparator = " - ";
8688
8884
  var displayFields = [
8689
8885
  "id",
@@ -8703,8 +8899,8 @@
8703
8899
  };
8704
8900
  E030Ban.toDto = function (e030Ban, originEntity) {
8705
8901
  var dto = __assign({}, e030Ban);
8706
- dto.createdDate = dto.createdDate && moment$e(dto.createdDate).format();
8707
- dto.lastModifiedDate = dto.lastModifiedDate && moment$e(dto.lastModifiedDate).format();
8902
+ dto.createdDate = dto.createdDate && moment$c(dto.createdDate).format();
8903
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$c(dto.lastModifiedDate).format();
8708
8904
  delete dto.label;
8709
8905
  return dto;
8710
8906
  };
@@ -8713,7 +8909,7 @@
8713
8909
  /*{CA:FILE_CONTENTS:START}*/
8714
8910
  /*{CA:FILE_CONTENTS:END}*/
8715
8911
 
8716
- var moment$f = moment$k;
8912
+ var moment$d = moment$k;
8717
8913
  var E030Age = /** @class */ (function () {
8718
8914
  function E030Age() {
8719
8915
  this.excluido = false;
@@ -8724,8 +8920,8 @@
8724
8920
  /*{CA:CLASS_ATTRIBUTES:END}*/
8725
8921
  E030Age.fromDto = function (e030AgeDto, originEntity) {
8726
8922
  var model = __assign({}, e030AgeDto);
8727
- model.createdDate = model.createdDate && moment$f(model.createdDate).toDate();
8728
- model.lastModifiedDate = model.lastModifiedDate && moment$f(model.lastModifiedDate).toDate();
8923
+ model.createdDate = model.createdDate && moment$d(model.createdDate).toDate();
8924
+ model.lastModifiedDate = model.lastModifiedDate && moment$d(model.lastModifiedDate).toDate();
8729
8925
  var lookupSeparator = " - ";
8730
8926
  var displayFields = [
8731
8927
  "id",
@@ -8746,8 +8942,8 @@
8746
8942
  };
8747
8943
  E030Age.toDto = function (e030Age, originEntity) {
8748
8944
  var dto = __assign({}, e030Age);
8749
- dto.createdDate = dto.createdDate && moment$f(dto.createdDate).format();
8750
- dto.lastModifiedDate = dto.lastModifiedDate && moment$f(dto.lastModifiedDate).format();
8945
+ dto.createdDate = dto.createdDate && moment$d(dto.createdDate).format();
8946
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$d(dto.lastModifiedDate).format();
8751
8947
  delete dto.label;
8752
8948
  if (originEntity !== "E030Ban" && dto.e030ban)
8753
8949
  dto.e030ban = E030Ban.toDto(dto.e030ban, "E030Age");
@@ -8758,7 +8954,7 @@
8758
8954
  /*{CA:FILE_CONTENTS:START}*/
8759
8955
  /*{CA:FILE_CONTENTS:END}*/
8760
8956
 
8761
- var moment$g = moment$k;
8957
+ var moment$e = moment$k;
8762
8958
  var E044Ccu = /** @class */ (function () {
8763
8959
  function E044Ccu() {
8764
8960
  }
@@ -8766,8 +8962,8 @@
8766
8962
  /*{CA:CLASS_ATTRIBUTES:END}*/
8767
8963
  E044Ccu.fromDto = function (e044CcuDto, originEntity) {
8768
8964
  var model = __assign({}, e044CcuDto);
8769
- model.createdDate = model.createdDate && moment$g(model.createdDate).toDate();
8770
- model.lastModifiedDate = model.lastModifiedDate && moment$g(model.lastModifiedDate).toDate();
8965
+ model.createdDate = model.createdDate && moment$e(model.createdDate).toDate();
8966
+ model.lastModifiedDate = model.lastModifiedDate && moment$e(model.lastModifiedDate).toDate();
8771
8967
  var lookupSeparator = " - ";
8772
8968
  var displayFields = [
8773
8969
  "id",
@@ -8786,8 +8982,8 @@
8786
8982
  };
8787
8983
  E044Ccu.toDto = function (e044Ccu, originEntity) {
8788
8984
  var dto = __assign({}, e044Ccu);
8789
- dto.createdDate = dto.createdDate && moment$g(dto.createdDate).format();
8790
- dto.lastModifiedDate = dto.lastModifiedDate && moment$g(dto.lastModifiedDate).format();
8985
+ dto.createdDate = dto.createdDate && moment$e(dto.createdDate).format();
8986
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$e(dto.lastModifiedDate).format();
8791
8987
  delete dto.label;
8792
8988
  return dto;
8793
8989
  };
@@ -8796,7 +8992,7 @@
8796
8992
  /*{CA:FILE_CONTENTS:START}*/
8797
8993
  /*{CA:FILE_CONTENTS:END}*/
8798
8994
 
8799
- var moment$h = moment$k;
8995
+ var moment$f = moment$k;
8800
8996
  var E070Emp = /** @class */ (function () {
8801
8997
  function E070Emp() {
8802
8998
  this.excluido = false;
@@ -8807,8 +9003,8 @@
8807
9003
  /*{CA:CLASS_ATTRIBUTES:END}*/
8808
9004
  E070Emp.fromDto = function (e070EmpDto, originEntity) {
8809
9005
  var model = __assign({}, e070EmpDto);
8810
- model.createdDate = model.createdDate && moment$h(model.createdDate).toDate();
8811
- model.lastModifiedDate = model.lastModifiedDate && moment$h(model.lastModifiedDate).toDate();
9006
+ model.createdDate = model.createdDate && moment$f(model.createdDate).toDate();
9007
+ model.lastModifiedDate = model.lastModifiedDate && moment$f(model.lastModifiedDate).toDate();
8812
9008
  var lookupSeparator = " - ";
8813
9009
  var displayFields = [
8814
9010
  "id",
@@ -8827,8 +9023,8 @@
8827
9023
  };
8828
9024
  E070Emp.toDto = function (e070Emp, originEntity) {
8829
9025
  var dto = __assign({}, e070Emp);
8830
- dto.createdDate = dto.createdDate && moment$h(dto.createdDate).format();
8831
- dto.lastModifiedDate = dto.lastModifiedDate && moment$h(dto.lastModifiedDate).format();
9026
+ dto.createdDate = dto.createdDate && moment$f(dto.createdDate).format();
9027
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$f(dto.lastModifiedDate).format();
8832
9028
  delete dto.label;
8833
9029
  return dto;
8834
9030
  };
@@ -8837,7 +9033,7 @@
8837
9033
  /*{CA:FILE_CONTENTS:START}*/
8838
9034
  /*{CA:FILE_CONTENTS:END}*/
8839
9035
 
8840
- var moment$i = moment$k;
9036
+ var moment$g = moment$k;
8841
9037
  var E070Fil = /** @class */ (function () {
8842
9038
  function E070Fil() {
8843
9039
  this.deleted = false;
@@ -8848,8 +9044,8 @@
8848
9044
  /*{CA:CLASS_ATTRIBUTES:END}*/
8849
9045
  E070Fil.fromDto = function (e070FilDto, originEntity) {
8850
9046
  var model = __assign({}, e070FilDto);
8851
- model.createdDate = model.createdDate && moment$i(model.createdDate).toDate();
8852
- model.lastModifiedDate = model.lastModifiedDate && moment$i(model.lastModifiedDate).toDate();
9047
+ model.createdDate = model.createdDate && moment$g(model.createdDate).toDate();
9048
+ model.lastModifiedDate = model.lastModifiedDate && moment$g(model.lastModifiedDate).toDate();
8853
9049
  var lookupSeparator = " - ";
8854
9050
  var displayFields = [
8855
9051
  "id",
@@ -8866,19 +9062,15 @@
8866
9062
  model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
8867
9063
  if (originEntity !== "E070Emp" && model.e070emp)
8868
9064
  model.e070emp = E070Emp.fromDto(model.e070emp, "E070Fil");
8869
- if (originEntity !== "CompanyBranchIndications" && model.companyBranchIndications)
8870
- model.companyBranchIndications = CompanyBranchIndications.fromDto(model.companyBranchIndications, "E070Fil");
8871
9065
  return model;
8872
9066
  };
8873
9067
  E070Fil.toDto = function (e070Fil, originEntity) {
8874
9068
  var dto = __assign({}, e070Fil);
8875
- dto.createdDate = dto.createdDate && moment$i(dto.createdDate).format();
8876
- dto.lastModifiedDate = dto.lastModifiedDate && moment$i(dto.lastModifiedDate).format();
9069
+ dto.createdDate = dto.createdDate && moment$g(dto.createdDate).format();
9070
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$g(dto.lastModifiedDate).format();
8877
9071
  delete dto.label;
8878
9072
  if (originEntity !== "E070Emp" && dto.e070emp)
8879
9073
  dto.e070emp = E070Emp.toDto(dto.e070emp, "E070Fil");
8880
- if (originEntity !== "CompanyBranchIndications" && dto.companyBranchIndications)
8881
- dto.companyBranchIndications = CompanyBranchIndications.toDto(dto.companyBranchIndications, "E070Fil");
8882
9074
  return dto;
8883
9075
  };
8884
9076
  return E070Fil;
@@ -8886,6 +9078,96 @@
8886
9078
  /*{CA:FILE_CONTENTS:START}*/
8887
9079
  /*{CA:FILE_CONTENTS:END}*/
8888
9080
 
9081
+ var moment$h = moment$k;
9082
+ var Holiday = /** @class */ (function () {
9083
+ function Holiday() {
9084
+ this.deleted = false;
9085
+ /*{CA:CLASS_METHODS:START}*/
9086
+ /*{CA:CLASS_METHODS:END}*/
9087
+ }
9088
+ /*{CA:CLASS_ATTRIBUTES:START}*/
9089
+ /*{CA:CLASS_ATTRIBUTES:END}*/
9090
+ Holiday.fromDto = function (holidayDto, originEntity) {
9091
+ var model = __assign({}, holidayDto);
9092
+ model.createdDate = model.createdDate && moment$h(model.createdDate).toDate();
9093
+ model.lastModifiedDate = model.lastModifiedDate && moment$h(model.lastModifiedDate).toDate();
9094
+ var lookupSeparator = " - ";
9095
+ var displayFields = [
9096
+ "id",
9097
+ "name",
9098
+ "day",
9099
+ "month",
9100
+ "year",
9101
+ "deleted",
9102
+ "extIntSts",
9103
+ "extIntMsg",
9104
+ "createdBy",
9105
+ "createdDate",
9106
+ "lastModifiedBy",
9107
+ "lastModifiedDate",
9108
+ ];
9109
+ model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
9110
+ return model;
9111
+ };
9112
+ Holiday.toDto = function (holiday, originEntity) {
9113
+ var dto = __assign({}, holiday);
9114
+ dto.createdDate = dto.createdDate && moment$h(dto.createdDate).format();
9115
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$h(dto.lastModifiedDate).format();
9116
+ delete dto.label;
9117
+ return dto;
9118
+ };
9119
+ return Holiday;
9120
+ }());
9121
+ /*{CA:FILE_CONTENTS:START}*/
9122
+ /*{CA:FILE_CONTENTS:END}*/
9123
+
9124
+ var moment$i = moment$k;
9125
+ var HolidayGroup = /** @class */ (function () {
9126
+ function HolidayGroup() {
9127
+ this.deleted = false;
9128
+ /*{CA:CLASS_METHODS:START}*/
9129
+ /*{CA:CLASS_METHODS:END}*/
9130
+ }
9131
+ /*{CA:CLASS_ATTRIBUTES:START}*/
9132
+ /*{CA:CLASS_ATTRIBUTES:END}*/
9133
+ HolidayGroup.fromDto = function (holidayGroupDto, originEntity) {
9134
+ var model = __assign({}, holidayGroupDto);
9135
+ model.createdDate = model.createdDate && moment$i(model.createdDate).toDate();
9136
+ model.lastModifiedDate = model.lastModifiedDate && moment$i(model.lastModifiedDate).toDate();
9137
+ var lookupSeparator = " - ";
9138
+ var displayFields = [
9139
+ "id",
9140
+ "code",
9141
+ "name",
9142
+ "deleted",
9143
+ "extIntSts",
9144
+ "extIntMsg",
9145
+ "createdBy",
9146
+ "createdDate",
9147
+ "lastModifiedBy",
9148
+ "lastModifiedDate",
9149
+ ];
9150
+ model.label = displayFields.map(function (field) { return model[field]; }).join(lookupSeparator);
9151
+ if (originEntity !== "Holiday" && model.holiday)
9152
+ model.holiday = Object.values(model.holiday).map(function (item) { return Holiday.fromDto(item, "HolidayGroup"); });
9153
+ return model;
9154
+ };
9155
+ HolidayGroup.toDto = function (holidayGroup, originEntity) {
9156
+ var dto = __assign({}, holidayGroup);
9157
+ dto.createdDate = dto.createdDate && moment$i(dto.createdDate).format();
9158
+ dto.lastModifiedDate = dto.lastModifiedDate && moment$i(dto.lastModifiedDate).format();
9159
+ delete dto.label;
9160
+ if (originEntity !== "Holiday" && dto.holiday)
9161
+ dto.holiday = Object.values(dto.holiday)
9162
+ .map(function (item) { return Holiday.toDto(item, "HolidayGroup"); })
9163
+ .filter(function (item) { return Object.keys(item).length; });
9164
+ return dto;
9165
+ };
9166
+ return HolidayGroup;
9167
+ }());
9168
+ /*{CA:FILE_CONTENTS:START}*/
9169
+ /*{CA:FILE_CONTENTS:END}*/
9170
+
8889
9171
  /*{CA:PACKAGE_IMPORTS:START}*/
8890
9172
  var moment$j = moment$k; // @HACK Necessary because of https://github.com/rollup/rollup/issues/670
8891
9173
  /*{CA:PROJECT_IMPORTS:START}*/
@@ -9151,8 +9433,6 @@
9151
9433
  exports.Characteristics = Characteristics;
9152
9434
  exports.CharacteristicsService = CharacteristicsService;
9153
9435
  exports.CollectiveHistoryFiltersService = CollectiveHistoryFiltersService;
9154
- exports.CompanyBranchIndications = CompanyBranchIndications;
9155
- exports.CompanyBranchIndicationsService = CompanyBranchIndicationsService;
9156
9436
  exports.CompanyBranchLookupModule = CompanyBranchLookupModule;
9157
9437
  exports.CompanyBranchLookupService = CompanyBranchLookupService;
9158
9438
  exports.CompanyLinkedLocation = CompanyLinkedLocation;
@@ -9196,6 +9476,8 @@
9196
9476
  exports.EmploymentRelationshipService = EmploymentRelationshipService;
9197
9477
  exports.EntityLookupConfigService = EntityLookupConfigService;
9198
9478
  exports.EntityLookupModule = EntityLookupModule;
9479
+ exports.FpasRegistrationLookupModule = FpasRegistrationLookupModule;
9480
+ exports.FpasRegistrationLookupService = FpasRegistrationLookupService;
9199
9481
  exports.Holiday = Holiday;
9200
9482
  exports.HolidayGroup = HolidayGroup;
9201
9483
  exports.HolidayGroupService = HolidayGroupService;
@@ -9211,6 +9493,7 @@
9211
9493
  exports.LocationLookupService = LocationLookupService;
9212
9494
  exports.LocationService = LocationService;
9213
9495
  exports.PersonLookupModule = PersonLookupModule;
9496
+ exports.PersonLookupService = PersonLookupService;
9214
9497
  exports.PisPasepTaxationLookupComponent = PisPasepTaxationLookupComponent;
9215
9498
  exports.PisPasepTaxationLookupModule = PisPasepTaxationLookupModule;
9216
9499
  exports.PisPasepTaxationLookupService = PisPasepTaxationLookupService;
@@ -9263,11 +9546,12 @@
9263
9546
  exports.ɵbd = EmploymentRelationshipModule;
9264
9547
  exports.ɵbe = WageTypePayrollModule;
9265
9548
  exports.ɵbf = CompanyLinkedLocationModule;
9549
+ exports.ɵbg = FpasRegistrationModule;
9266
9550
  exports.ɵc = SharedModule;
9267
9551
  exports.ɵd = CompanyBranchLookupComponent;
9268
9552
  exports.ɵe = PersonLookupComponent;
9269
- exports.ɵf = ESocialCategoryModule;
9270
- exports.ɵg = CompanyBranchIndicationsModule;
9553
+ exports.ɵf = FpasRegistrationLookupComponent;
9554
+ exports.ɵg = FpasRegistrationService;
9271
9555
  exports.ɵh = E030AgeModule;
9272
9556
  exports.ɵi = E030BanModule;
9273
9557
  exports.ɵj = E044CcuModule;