@senior-gestao-empresarial/angular-components 7.14.1 → 7.15.0-a253e448-5c12-41fb-896f-7e01bd46fc46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/senior-gestao-empresarial-angular-components.umd.js +59 -3
- package/bundles/senior-gestao-empresarial-angular-components.umd.js.map +1 -1
- package/bundles/senior-gestao-empresarial-angular-components.umd.min.js +1 -1
- package/bundles/senior-gestao-empresarial-angular-components.umd.min.js.map +1 -1
- package/components/lookups/entities/lista-servico-nacional-lookup.d.ts +8 -0
- package/components/lookups/erp-lookups.d.ts +11 -3
- package/components/lookups/index.d.ts +1 -0
- package/esm2015/components/lookups/entities/lista-servico-nacional-lookup.js +34 -0
- package/esm2015/components/lookups/erp-lookups.js +24 -3
- package/esm2015/components/lookups/erp-lookups.module.js +3 -1
- package/esm2015/components/lookups/index.js +2 -1
- package/esm5/components/lookups/entities/lista-servico-nacional-lookup.js +37 -0
- package/esm5/components/lookups/erp-lookups.js +29 -5
- package/esm5/components/lookups/erp-lookups.module.js +3 -1
- package/esm5/components/lookups/index.js +2 -1
- package/fesm2015/senior-gestao-empresarial-angular-components.js +52 -3
- package/fesm2015/senior-gestao-empresarial-angular-components.js.map +1 -1
- package/fesm5/senior-gestao-empresarial-angular-components.js +58 -4
- package/fesm5/senior-gestao-empresarial-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/senior-gestao-empresarial-angular-components.metadata.json +1 -1
|
@@ -429,6 +429,15 @@
|
|
|
429
429
|
/** Contains string value (Ex: /Products?$filter=containing(lower(name), lower('my name'))) */
|
|
430
430
|
EnumLogicalOperator["Contains"] = "containing";
|
|
431
431
|
})(exports.EnumLogicalOperator || (exports.EnumLogicalOperator = {}));
|
|
432
|
+
var ErpLookupsSearchField = /** @class */ (function (_super) {
|
|
433
|
+
__extends(ErpLookupsSearchField, _super);
|
|
434
|
+
function ErpLookupsSearchField(searchFieldOptions, args) {
|
|
435
|
+
var _this = _super.call(this, args) || this;
|
|
436
|
+
_this.searchFieldOptions = searchFieldOptions;
|
|
437
|
+
return _this;
|
|
438
|
+
}
|
|
439
|
+
return ErpLookupsSearchField;
|
|
440
|
+
}(angularComponents.FormField));
|
|
432
441
|
var ErpLookups = /** @class */ (function () {
|
|
433
442
|
/**
|
|
434
443
|
* Criação de um lookup.
|
|
@@ -471,6 +480,9 @@
|
|
|
471
480
|
translationKey = prefix + ".lookup_" + _this.toSnakeCase(_this.entity) + "_" + _this.toSnakeCase(fieldName);
|
|
472
481
|
label = _this.translate.instant(translationKey);
|
|
473
482
|
}
|
|
483
|
+
if ("searchFieldOptions" in field) {
|
|
484
|
+
return new ErpLookupsSearchField(field.searchFieldOptions, __assign(__assign({}, field), { label: label }));
|
|
485
|
+
}
|
|
474
486
|
return new angularComponents.FormField(__assign(__assign({}, field), { label: label }));
|
|
475
487
|
});
|
|
476
488
|
};
|
|
@@ -654,13 +666,24 @@
|
|
|
654
666
|
var name = _a.name;
|
|
655
667
|
return filterData[name] != undefined && filterData[name] != "";
|
|
656
668
|
})
|
|
657
|
-
.map(function (
|
|
658
|
-
var
|
|
669
|
+
.map(function (formField) {
|
|
670
|
+
var _a;
|
|
671
|
+
var name = formField.name, type = formField.type, multiple = formField.multiple;
|
|
659
672
|
var value = filterData[name];
|
|
660
673
|
if (typeof value == "number")
|
|
661
674
|
return name + " eq " + value;
|
|
662
|
-
else if (type == angularComponents.FieldType.Date)
|
|
675
|
+
else if (type == angularComponents.FieldType.Date) {
|
|
676
|
+
if ('searchFieldOptions' in formField &&
|
|
677
|
+
((_a = formField.searchFieldOptions) === null || _a === void 0 ? void 0 : _a.useAs) ===
|
|
678
|
+
angularComponents.FieldType.DateTime) {
|
|
679
|
+
return "(" + name + " " + exports.EnumLogicalOperator.Gt + " '" + moment(value)
|
|
680
|
+
.startOf('day')
|
|
681
|
+
.toISOString() + "' " + exports.EnumLogicalOperator.And + " " + name + " " + exports.EnumLogicalOperator.Lt + " '" + moment(value)
|
|
682
|
+
.endOf('day')
|
|
683
|
+
.toISOString() + "')";
|
|
684
|
+
}
|
|
663
685
|
return name + " eq '" + moment(value).format("YYYY-MM-DD") + "'";
|
|
686
|
+
}
|
|
664
687
|
else if (type == angularComponents.FieldType.Time)
|
|
665
688
|
return name + " eq '" + moment(value).format("HH:mm:ss") + "'";
|
|
666
689
|
else if (type == angularComponents.FieldType.DateTime)
|
|
@@ -7300,6 +7323,36 @@
|
|
|
7300
7323
|
return IndOperacaoFornecimentoLookup;
|
|
7301
7324
|
}(ErpLookups));
|
|
7302
7325
|
|
|
7326
|
+
var lookupFields$3 = [
|
|
7327
|
+
{
|
|
7328
|
+
name: "codigo",
|
|
7329
|
+
type: angularComponents.FieldType.String,
|
|
7330
|
+
},
|
|
7331
|
+
{
|
|
7332
|
+
name: "descricao",
|
|
7333
|
+
type: angularComponents.FieldType.String,
|
|
7334
|
+
},
|
|
7335
|
+
];
|
|
7336
|
+
var searchFields$1 = __spread(lookupFields$3);
|
|
7337
|
+
var searchGridFields = __spread(lookupFields$3);
|
|
7338
|
+
var ListaServicoNacionalLookup = /** @class */ (function (_super) {
|
|
7339
|
+
__extends(ListaServicoNacionalLookup, _super);
|
|
7340
|
+
function ListaServicoNacionalLookup(lookupService, translate) {
|
|
7341
|
+
var _this = _super.call(this, lookupService, translate, "listaServicoNacional", lookupFields$3, searchFields$1, searchGridFields, "erpx_cpl_imp", "cadastros") || this;
|
|
7342
|
+
_this.lookupService = lookupService;
|
|
7343
|
+
_this.translate = translate;
|
|
7344
|
+
return _this;
|
|
7345
|
+
}
|
|
7346
|
+
ListaServicoNacionalLookup.ctorParameters = function () { return [
|
|
7347
|
+
{ type: ErpLookupsService },
|
|
7348
|
+
{ type: core$1.TranslateService }
|
|
7349
|
+
]; };
|
|
7350
|
+
ListaServicoNacionalLookup = __decorate([
|
|
7351
|
+
core.Injectable()
|
|
7352
|
+
], ListaServicoNacionalLookup);
|
|
7353
|
+
return ListaServicoNacionalLookup;
|
|
7354
|
+
}(ErpLookups));
|
|
7355
|
+
|
|
7303
7356
|
var ErpLookupsModule = /** @class */ (function () {
|
|
7304
7357
|
function ErpLookupsModule() {
|
|
7305
7358
|
}
|
|
@@ -7431,6 +7484,7 @@
|
|
|
7431
7484
|
OrigemMercadoriaLookup,
|
|
7432
7485
|
E095HfoSupGerLookup,
|
|
7433
7486
|
IndOperacaoFornecimentoLookup,
|
|
7487
|
+
ListaServicoNacionalLookup
|
|
7434
7488
|
],
|
|
7435
7489
|
declarations: [],
|
|
7436
7490
|
exports: [],
|
|
@@ -8982,6 +9036,7 @@
|
|
|
8982
9036
|
exports.EquipmentLookup = EquipmentLookup;
|
|
8983
9037
|
exports.ErpLookups = ErpLookups;
|
|
8984
9038
|
exports.ErpLookupsModule = ErpLookupsModule;
|
|
9039
|
+
exports.ErpLookupsSearchField = ErpLookupsSearchField;
|
|
8985
9040
|
exports.ErpLookupsService = ErpLookupsService;
|
|
8986
9041
|
exports.ErpPolling = ErpPolling;
|
|
8987
9042
|
exports.ExportUtils = ExportUtils;
|
|
@@ -8991,6 +9046,7 @@
|
|
|
8991
9046
|
exports.IndOperacaoFornecimentoLookup = IndOperacaoFornecimentoLookup;
|
|
8992
9047
|
exports.LeiComplementar1162003Lookup = LeiComplementar1162003Lookup;
|
|
8993
9048
|
exports.LigacaoItemFornecedorLookup = LigacaoItemFornecedorLookup;
|
|
9049
|
+
exports.ListaServicoNacionalLookup = ListaServicoNacionalLookup;
|
|
8994
9050
|
exports.LookupValidationUtils = LookupValidationUtils;
|
|
8995
9051
|
exports.NbsLookup = NbsLookup;
|
|
8996
9052
|
exports.NcmLookup = NcmLookup;
|