@senior-agronegocio/angular-components 0.0.64 → 0.0.65
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-agronegocio-angular-components.umd.js +199 -95
- package/bundles/senior-agronegocio-angular-components.umd.js.map +1 -1
- package/bundles/senior-agronegocio-angular-components.umd.min.js +2 -2
- package/bundles/senior-agronegocio-angular-components.umd.min.js.map +1 -1
- package/common/numbers.d.ts +6 -0
- package/components/cancel-event-dialog/cancel-event-dialog-config.d.ts +7 -0
- package/components/cancel-event-dialog/cancel-event-dialog.component.d.ts +33 -0
- package/components/cancel-event-dialog/cancel-event-dialog.module.d.ts +2 -0
- package/components/cancel-event-dialog/index.d.ts +3 -0
- package/components/event-control-board/common/event-operation.d.ts +5 -1
- package/components/event-control-board/event-control-board.component.d.ts +5 -4
- package/components/event-control-board/index.d.ts +2 -0
- package/components/index.d.ts +1 -0
- package/esm2015/common/numbers.js +8 -0
- package/esm2015/components/cancel-event-dialog/cancel-event-dialog-config.js +1 -0
- package/esm2015/components/cancel-event-dialog/cancel-event-dialog.component.js +115 -0
- package/esm2015/components/cancel-event-dialog/cancel-event-dialog.module.js +27 -0
- package/esm2015/components/cancel-event-dialog/index.js +3 -0
- package/esm2015/components/event-control-board/common/event-control-constants.js +5 -1
- package/esm2015/components/event-control-board/common/event-operation.js +5 -1
- package/esm2015/components/event-control-board/event-control-board.component.js +21 -54
- package/esm2015/components/event-control-board/event-control-board.module.js +6 -4
- package/esm2015/components/event-control-board/index.js +2 -1
- package/esm2015/components/index.js +2 -1
- package/esm2015/services/i18n/en-US.js +4 -3
- package/esm2015/services/i18n/es-CO.js +4 -3
- package/esm2015/services/i18n/pt-BR.js +10 -5
- package/esm5/common/numbers.js +8 -0
- package/esm5/components/cancel-event-dialog/cancel-event-dialog-config.js +1 -0
- package/esm5/components/cancel-event-dialog/cancel-event-dialog.component.js +117 -0
- package/esm5/components/cancel-event-dialog/cancel-event-dialog.module.js +30 -0
- package/esm5/components/cancel-event-dialog/index.js +3 -0
- package/esm5/components/event-control-board/common/event-control-constants.js +5 -1
- package/esm5/components/event-control-board/common/event-operation.js +5 -1
- package/esm5/components/event-control-board/event-control-board.component.js +21 -56
- package/esm5/components/event-control-board/event-control-board.module.js +6 -4
- package/esm5/components/event-control-board/index.js +2 -1
- package/esm5/components/index.js +2 -1
- package/esm5/services/i18n/en-US.js +4 -3
- package/esm5/services/i18n/es-CO.js +4 -3
- package/esm5/services/i18n/pt-BR.js +10 -5
- package/fesm2015/senior-agronegocio-angular-components.js +197 -98
- package/fesm2015/senior-agronegocio-angular-components.js.map +1 -1
- package/fesm5/senior-agronegocio-angular-components.js +202 -100
- package/fesm5/senior-agronegocio-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/senior-agronegocio-angular-components.metadata.json +1 -1
- package/services/i18n/en-US.d.ts +1 -0
- package/services/i18n/es-CO.d.ts +1 -0
- package/services/i18n/pt-BR.d.ts +5 -0
- package/components/event-control-board/common/origin-operation.d.ts +0 -5
- package/esm2015/components/event-control-board/common/origin-operation.js +0 -7
- package/esm5/components/event-control-board/common/origin-operation.js +0 -7
|
@@ -3521,7 +3521,7 @@
|
|
|
3521
3521
|
"agro.angular_components.error_invalid": "Valor inválido",
|
|
3522
3522
|
"agro.angular_components.error_max_length": "O valor máximo de caracteres é {0}",
|
|
3523
3523
|
"agro.angular_components.error_max_value": "O valor máximo é {0}",
|
|
3524
|
-
"agro.angular_components.error_min_length": "O valor mínimo de caracteres é {
|
|
3524
|
+
"agro.angular_components.error_min_length": "O valor mínimo de caracteres é {valor}",
|
|
3525
3525
|
"agro.angular_components.error_min_value": "O valor mínimo é {0}",
|
|
3526
3526
|
"agro.angular_components.error_not_found_description": "O recurso solicitado não foi encontrado",
|
|
3527
3527
|
"agro.angular_components.error_not_found_title": "Não encontrado",
|
|
@@ -3645,8 +3645,8 @@
|
|
|
3645
3645
|
"agro.angular_components.CHANGE_REQUEST": "Solicitação de alteração",
|
|
3646
3646
|
"agro.angular_components.CHANGE_RESPONSE": "Resposta da solicitação de alteração",
|
|
3647
3647
|
"agro.angular_components.PROCESS_FIXATION": "Processa a fixação",
|
|
3648
|
-
"agro.angular_components.TRANSFER_CREATE_INCOMING_INVOICE": "
|
|
3649
|
-
"agro.angular_components.TRANSFER_CREATE_OUTGOING_INVOICE": "
|
|
3648
|
+
"agro.angular_components.TRANSFER_CREATE_INCOMING_INVOICE": "Emissão NF de entrada",
|
|
3649
|
+
"agro.angular_components.TRANSFER_CREATE_OUTGOING_INVOICE": "Emissão NF de saída",
|
|
3650
3650
|
"agro.angular_components.TRANSFER_PRODUCER_BALANCE": "Transferência de saldo entre produtores",
|
|
3651
3651
|
"agro.angular_components.control_code": "Identificador",
|
|
3652
3652
|
"agro.angular_components.fixation_event": "Fixação",
|
|
@@ -3672,7 +3672,12 @@
|
|
|
3672
3672
|
"agro.angular_components.invoice_type_OUTGOING": "Saída",
|
|
3673
3673
|
"agro.angular_components.invoice_type_RETURN": "Devolução",
|
|
3674
3674
|
"agro.angular_components.invoice_type_SERVICE": "Serviço",
|
|
3675
|
-
"agro.angular_components.invoice_type_SYMBOLIC_RETURN": "Devolução simbólica"
|
|
3675
|
+
"agro.angular_components.invoice_type_SYMBOLIC_RETURN": "Devolução simbólica",
|
|
3676
|
+
"agro.angular_components.cancel_reason": "Motivo do cancelamento",
|
|
3677
|
+
"agro.angular_components.TRANSFER_CANCEL_INCOMING_INVOICE": "Cancelamento de NF de entrada",
|
|
3678
|
+
"agro.angular_components.TRANSFER_CANCEL_OUTGOING_INVOICE": "Cancelamento de NF de saída ",
|
|
3679
|
+
"agro.angular_components.TRANSFER_REVERSE_PRODUCER_BALANCE": "Estorno dos saldos de produtores",
|
|
3680
|
+
"agro.angular_components.TRANSFER_CONCLUDE_CANCEL": "Conclusão do cancelamento",
|
|
3676
3681
|
};
|
|
3677
3682
|
|
|
3678
3683
|
var enUS = {
|
|
@@ -3751,7 +3756,7 @@
|
|
|
3751
3756
|
"agro.angular_components.error_invalid": "Invalid value",
|
|
3752
3757
|
"agro.angular_components.error_max_length": "The maximum number of characters is {0}",
|
|
3753
3758
|
"agro.angular_components.error_max_value": "The maximum value is {0}",
|
|
3754
|
-
"agro.angular_components.error_min_length": "The minimum number of characters is {
|
|
3759
|
+
"agro.angular_components.error_min_length": "The minimum number of characters is {valor}",
|
|
3755
3760
|
"agro.angular_components.error_min_value": "The minimum value is {0}",
|
|
3756
3761
|
"agro.angular_components.error_not_found_description": "The requested resource was not found",
|
|
3757
3762
|
"agro.angular_components.error_not_found_title": "Not found",
|
|
@@ -3902,7 +3907,8 @@
|
|
|
3902
3907
|
"agro.angular_components.invoice_type_OUTGOING": "Outgoing",
|
|
3903
3908
|
"agro.angular_components.invoice_type_RETURN": "Return",
|
|
3904
3909
|
"agro.angular_components.invoice_type_SERVICE": "Service",
|
|
3905
|
-
"agro.angular_components.invoice_type_SYMBOLIC_RETURN": "Symbolic return"
|
|
3910
|
+
"agro.angular_components.invoice_type_SYMBOLIC_RETURN": "Symbolic return",
|
|
3911
|
+
"agro.angular_components.cancel_reason": "Cancellation reason"
|
|
3906
3912
|
};
|
|
3907
3913
|
|
|
3908
3914
|
var esCO = {
|
|
@@ -3981,7 +3987,7 @@
|
|
|
3981
3987
|
"agro.angular_components.error_invalid": "Valor inválido",
|
|
3982
3988
|
"agro.angular_components.error_max_length": "El valor máximo de caracteres es {0}",
|
|
3983
3989
|
"agro.angular_components.error_max_value": "El valor máximo es {0}",
|
|
3984
|
-
"agro.angular_components.error_min_length": "El valor mínimo de caracteres es {
|
|
3990
|
+
"agro.angular_components.error_min_length": "El valor mínimo de caracteres es {valor}",
|
|
3985
3991
|
"agro.angular_components.error_min_value": "El valor mínimo es {0}",
|
|
3986
3992
|
"agro.angular_components.error_not_found_description": "El recurso solicitado no fue encontrado",
|
|
3987
3993
|
"agro.angular_components.error_not_found_title": "No encontrado",
|
|
@@ -4132,7 +4138,8 @@
|
|
|
4132
4138
|
"agro.angular_components.invoice_type_OUTGOING": "Salida",
|
|
4133
4139
|
"agro.angular_components.invoice_type_RETURN": "Devolución",
|
|
4134
4140
|
"agro.angular_components.invoice_type_SERVICE": "Servicio",
|
|
4135
|
-
"agro.angular_components.invoice_type_SYMBOLIC_RETURN": "Devolución simbólica"
|
|
4141
|
+
"agro.angular_components.invoice_type_SYMBOLIC_RETURN": "Devolución simbólica",
|
|
4142
|
+
"agro.angular_components.cancel_reason": "Motivo de la cancelación"
|
|
4136
4143
|
};
|
|
4137
4144
|
|
|
4138
4145
|
var LibTranslationService = /** @class */ (function () {
|
|
@@ -4186,15 +4193,121 @@
|
|
|
4186
4193
|
return LibTranslationService;
|
|
4187
4194
|
}());
|
|
4188
4195
|
|
|
4189
|
-
var
|
|
4190
|
-
(function (
|
|
4191
|
-
|
|
4192
|
-
|
|
4193
|
-
|
|
4194
|
-
|
|
4195
|
-
|
|
4196
|
-
|
|
4197
|
-
|
|
4196
|
+
var NUMBERS;
|
|
4197
|
+
(function (NUMBERS) {
|
|
4198
|
+
NUMBERS[NUMBERS["ZERO"] = 0] = "ZERO";
|
|
4199
|
+
NUMBERS[NUMBERS["TWELVE"] = 12] = "TWELVE";
|
|
4200
|
+
NUMBERS[NUMBERS["FIFTEEN"] = 15] = "FIFTEEN";
|
|
4201
|
+
NUMBERS[NUMBERS["HUNDRED"] = 100] = "HUNDRED";
|
|
4202
|
+
})(NUMBERS || (NUMBERS = {}));
|
|
4203
|
+
|
|
4204
|
+
var CancelEventDialogComponent = /** @class */ (function () {
|
|
4205
|
+
function CancelEventDialogComponent(formBuilder, config, ref, translate) {
|
|
4206
|
+
this.formBuilder = formBuilder;
|
|
4207
|
+
this.config = config;
|
|
4208
|
+
this.ref = ref;
|
|
4209
|
+
this.translate = translate;
|
|
4210
|
+
this.loading = false;
|
|
4211
|
+
this.reasonMinLength = NUMBERS.FIFTEEN;
|
|
4212
|
+
this.ngUnsubscribe = new rxjs.Subject();
|
|
4213
|
+
this.cpSize = {
|
|
4214
|
+
sm: 12,
|
|
4215
|
+
md: NUMBERS.TWELVE,
|
|
4216
|
+
lg: NUMBERS.TWELVE,
|
|
4217
|
+
xl: NUMBERS.TWELVE,
|
|
4218
|
+
};
|
|
4219
|
+
this.priority = angularComponents.ButtonPriority;
|
|
4220
|
+
}
|
|
4221
|
+
CancelEventDialogComponent.prototype.ngOnInit = function () {
|
|
4222
|
+
this.setFormGroup();
|
|
4223
|
+
this.setFormFields();
|
|
4224
|
+
this.setDataConfigDialog();
|
|
4225
|
+
this.setTranslations();
|
|
4226
|
+
};
|
|
4227
|
+
CancelEventDialogComponent.prototype.ngOnDestroy = function () {
|
|
4228
|
+
this.ngUnsubscribe.next();
|
|
4229
|
+
this.ngUnsubscribe.complete();
|
|
4230
|
+
};
|
|
4231
|
+
CancelEventDialogComponent.prototype.setFormGroup = function () {
|
|
4232
|
+
this.formGroup = this.formBuilder.group({
|
|
4233
|
+
reason: [{ value: null, disabled: false }, forms.Validators.compose([forms.Validators.required, forms.Validators.minLength(this.reasonMinLength)])],
|
|
4234
|
+
});
|
|
4235
|
+
};
|
|
4236
|
+
CancelEventDialogComponent.prototype.setFormFields = function () {
|
|
4237
|
+
this.formFields = [
|
|
4238
|
+
new angularComponents.FormField({
|
|
4239
|
+
name: "reason",
|
|
4240
|
+
label: this.translate.instant("agro.angular_components.cancel_reason"),
|
|
4241
|
+
type: angularComponents.FieldType.String,
|
|
4242
|
+
multiple: false,
|
|
4243
|
+
required: function () { return true; },
|
|
4244
|
+
size: this.cpSize,
|
|
4245
|
+
maxLength: NUMBERS.HUNDRED,
|
|
4246
|
+
}),
|
|
4247
|
+
];
|
|
4248
|
+
};
|
|
4249
|
+
CancelEventDialogComponent.prototype.setDataConfigDialog = function () {
|
|
4250
|
+
var _a, _b, _c, _d;
|
|
4251
|
+
this.cancelEventDialogConfig = (_b = (_a = this.config.data) === null || _a === void 0 ? void 0 : _a.cancelEventDialogConfig) !== null && _b !== void 0 ? _b : {};
|
|
4252
|
+
this.reasonMinLength = (_d = (_c = this.cancelEventDialogConfig) === null || _c === void 0 ? void 0 : _c.reasonMinLength) !== null && _d !== void 0 ? _d : NUMBERS.FIFTEEN;
|
|
4253
|
+
};
|
|
4254
|
+
CancelEventDialogComponent.prototype.setTranslations = function () {
|
|
4255
|
+
this.translations = {
|
|
4256
|
+
required: this.translate.instant("agro.angular_components.error_required"),
|
|
4257
|
+
min: this.translate.instant("agro.angular_components.error_min_value"),
|
|
4258
|
+
max: this.translate.instant("agro.angular_components.error_max_value"),
|
|
4259
|
+
minlength: this.translate.instant("agro.angular_components.error_min_length", { valor: this.reasonMinLength }),
|
|
4260
|
+
maxlength: this.translate.instant("agro.angular_components.error_max_length_transfer_code"),
|
|
4261
|
+
pattern: this.translate.instant("agro.angular_components.error_invalid"),
|
|
4262
|
+
FormDateError_data1: this.translate.instant("agro.angular_components.initial_invalid_date"),
|
|
4263
|
+
FormDateError_data2: this.translate.instant("agro.angular_components.end_invalid_date"),
|
|
4264
|
+
};
|
|
4265
|
+
};
|
|
4266
|
+
CancelEventDialogComponent.prototype.handleConfirmClick = function () {
|
|
4267
|
+
var _a, _b;
|
|
4268
|
+
if (this.formGroup.invalid && ((_a = this.cancelEventDialogConfig) === null || _a === void 0 ? void 0 : _a.withReason)) {
|
|
4269
|
+
this.validateAllFormFields(this.formGroup);
|
|
4270
|
+
return;
|
|
4271
|
+
}
|
|
4272
|
+
var reason = (_b = this.formGroup.get("reason")) === null || _b === void 0 ? void 0 : _b.value;
|
|
4273
|
+
this.loading = true;
|
|
4274
|
+
this.cancelEventDialogConfig.cancelFunction(reason);
|
|
4275
|
+
this.loading = false;
|
|
4276
|
+
this.ref.close(true);
|
|
4277
|
+
};
|
|
4278
|
+
CancelEventDialogComponent.prototype.validateAllFormFields = function (formGroup) {
|
|
4279
|
+
var _this = this;
|
|
4280
|
+
Object.keys(formGroup.controls).forEach(function (field) {
|
|
4281
|
+
var control = formGroup.get(field);
|
|
4282
|
+
if (control instanceof forms.FormControl) {
|
|
4283
|
+
control.markAsDirty({ onlySelf: true });
|
|
4284
|
+
}
|
|
4285
|
+
if (control instanceof forms.FormGroup) {
|
|
4286
|
+
_this.validateAllFormFields(control);
|
|
4287
|
+
}
|
|
4288
|
+
});
|
|
4289
|
+
};
|
|
4290
|
+
CancelEventDialogComponent.prototype.handleCancelClick = function () {
|
|
4291
|
+
this.ref.close();
|
|
4292
|
+
};
|
|
4293
|
+
CancelEventDialogComponent.ctorParameters = function () { return [
|
|
4294
|
+
{ type: forms.FormBuilder },
|
|
4295
|
+
{ type: primeng.DynamicDialogConfig },
|
|
4296
|
+
{ type: primeng.DynamicDialogRef },
|
|
4297
|
+
{ type: LibTranslationService }
|
|
4298
|
+
]; };
|
|
4299
|
+
__decorate([
|
|
4300
|
+
core.Input()
|
|
4301
|
+
], CancelEventDialogComponent.prototype, "cancelEventDialogConfig", void 0);
|
|
4302
|
+
CancelEventDialogComponent = __decorate([
|
|
4303
|
+
core.Component({
|
|
4304
|
+
selector: "s-cancel-event-dialog",
|
|
4305
|
+
template: "<div class=\"content\" *sLoadingState=\"loading\">\r\n <div class=\"top\">\r\n <div *ngIf=\"cancelEventDialogConfig?.message\" class=\"message-container\">\r\n <span>{{ cancelEventDialogConfig?.message }}</span>\r\n </div>\r\n <div class=\"form-container\" *ngIf=\"cancelEventDialogConfig?.withReason\">\r\n <s-dynamic-form [fields]=\"formFields\" [form]=\"formGroup\" [errorMessages]=\"translations\">\r\n </s-dynamic-form>\r\n </div>\r\n </div>\r\n <div class=\"footer\">\r\n <s-button [priority]=\"priority.Secondary\" label=\"{{ 'agro.angular_components.no' | libTranslate }}\"\r\n (click)=\"handleCancelClick()\"></s-button>\r\n <s-button [priority]=\"priority.Primary\" label=\"{{ 'agro.angular_components.yes' | libTranslate }}\" (click)=\"handleConfirmClick()\"></s-button>\r\n </div>\r\n</div>\r\n",
|
|
4306
|
+
styles: [".message-container{padding:.5rem}.footer{display:-ms-flexbox;display:flex;width:100%;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end;padding:.5rem}.content{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100%;box-sizing:border-box}.content.loading{min-height:150px;display:-ms-flexbox;display:flex;width:100%}.content .top{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:justify;justify-content:space-between}@media screen and (max-width:760px){.content{-ms-flex-pack:justify;justify-content:space-between}.content .top{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:justify;justify-content:space-between}}"]
|
|
4307
|
+
})
|
|
4308
|
+
], CancelEventDialogComponent);
|
|
4309
|
+
return CancelEventDialogComponent;
|
|
4310
|
+
}());
|
|
4198
4311
|
|
|
4199
4312
|
var EventOperation;
|
|
4200
4313
|
(function (EventOperation) {
|
|
@@ -4218,6 +4331,10 @@
|
|
|
4218
4331
|
EventOperation["CANCEL_FINANCIAL_FIXATION"] = "CANCEL_FINANCIAL_FIXATION";
|
|
4219
4332
|
EventOperation["CANCEL_PRODUCER_NET_VALUE_FIXATION"] = "CANCEL_PRODUCER_NET_VALUE_FIXATION";
|
|
4220
4333
|
EventOperation["CANCEL_FIXATION"] = "CANCEL_FIXATION";
|
|
4334
|
+
EventOperation["TRANSFER_CANCEL_INCOMING_INVOICE"] = "TRANSFER_CANCEL_INCOMING_INVOICE";
|
|
4335
|
+
EventOperation["TRANSFER_CANCEL_OUTGOING_INVOICE"] = "TRANSFER_CANCEL_OUTGOING_INVOICE";
|
|
4336
|
+
EventOperation["TRANSFER_REVERSE_PRODUCER_BALANCE"] = "TRANSFER_REVERSE_PRODUCER_BALANCE";
|
|
4337
|
+
EventOperation["TRANSFER_CONCLUDE_CANCEL"] = "TRANSFER_CONCLUDE_CANCEL";
|
|
4221
4338
|
})(EventOperation || (EventOperation = {}));
|
|
4222
4339
|
|
|
4223
4340
|
var EventOrigin;
|
|
@@ -4277,6 +4394,10 @@
|
|
|
4277
4394
|
{ label: "agro.angular_components." + EventOperation.CANCEL_FINANCIAL_FIXATION, value: EventOperation.CANCEL_FINANCIAL_FIXATION },
|
|
4278
4395
|
{ label: "agro.angular_components." + EventOperation.CANCEL_PRODUCER_NET_VALUE_FIXATION, value: EventOperation.CANCEL_PRODUCER_NET_VALUE_FIXATION },
|
|
4279
4396
|
{ label: "agro.angular_components." + EventOperation.CANCEL_FIXATION, value: EventOperation.CANCEL_FIXATION },
|
|
4397
|
+
{ label: "agro.angular_components." + EventOperation.TRANSFER_CANCEL_INCOMING_INVOICE, value: EventOperation.TRANSFER_CANCEL_INCOMING_INVOICE },
|
|
4398
|
+
{ label: "agro.angular_components." + EventOperation.TRANSFER_CANCEL_OUTGOING_INVOICE, value: EventOperation.TRANSFER_CANCEL_OUTGOING_INVOICE },
|
|
4399
|
+
{ label: "agro.angular_components." + EventOperation.TRANSFER_REVERSE_PRODUCER_BALANCE, value: EventOperation.TRANSFER_REVERSE_PRODUCER_BALANCE },
|
|
4400
|
+
{ label: "agro.angular_components." + EventOperation.TRANSFER_CONCLUDE_CANCEL, value: EventOperation.TRANSFER_CONCLUDE_CANCEL },
|
|
4280
4401
|
];
|
|
4281
4402
|
var eventStatus = [
|
|
4282
4403
|
{ label: "agro.angular_components.panel_title_events_completed_successfully", value: EventStatus.SUCCESS },
|
|
@@ -4289,6 +4410,27 @@
|
|
|
4289
4410
|
{ path: "invoice", field: InputFields.AGRO_INVOICE_TYPE },
|
|
4290
4411
|
];
|
|
4291
4412
|
|
|
4413
|
+
var InvoiceType;
|
|
4414
|
+
(function (InvoiceType) {
|
|
4415
|
+
InvoiceType["INCOMING"] = "INCOMING";
|
|
4416
|
+
InvoiceType["OUTGOING"] = "OUTGOING";
|
|
4417
|
+
InvoiceType["RETURN"] = "RETURN";
|
|
4418
|
+
InvoiceType["COMPLEMENT"] = "COMPLEMENT";
|
|
4419
|
+
InvoiceType["SYMBOLIC_RETURN"] = "SYMBOLIC_RETURN";
|
|
4420
|
+
InvoiceType["ADJUSTMENT"] = "ADJUSTMENT";
|
|
4421
|
+
InvoiceType["SERVICE"] = "SERVICE";
|
|
4422
|
+
})(InvoiceType || (InvoiceType = {}));
|
|
4423
|
+
|
|
4424
|
+
var invoiceTypeTranslate = [
|
|
4425
|
+
{ value: InvoiceType.INCOMING, label: "agro.angular_components.invoice_type_" + InvoiceType.INCOMING },
|
|
4426
|
+
{ value: InvoiceType.COMPLEMENT, label: "agro.angular_components.invoice_type_" + InvoiceType.COMPLEMENT },
|
|
4427
|
+
{ value: InvoiceType.ADJUSTMENT, label: "agro.angular_components.invoice_type_" + InvoiceType.ADJUSTMENT },
|
|
4428
|
+
{ value: InvoiceType.OUTGOING, label: "agro.angular_components.invoice_type_" + InvoiceType.OUTGOING },
|
|
4429
|
+
{ value: InvoiceType.RETURN, label: "agro.angular_components.invoice_type_" + InvoiceType.RETURN },
|
|
4430
|
+
{ value: InvoiceType.SERVICE, label: "agro.angular_components.invoice_type_" + InvoiceType.SERVICE },
|
|
4431
|
+
{ value: InvoiceType.SYMBOLIC_RETURN, label: "agro.angular_components.invoice_type_" + InvoiceType.SYMBOLIC_RETURN },
|
|
4432
|
+
];
|
|
4433
|
+
|
|
4292
4434
|
var LookupErrorMessages = {
|
|
4293
4435
|
required: 'agro.angular_components.error_required',
|
|
4294
4436
|
min: 'agro.angular_components.error_min_value',
|
|
@@ -4300,13 +4442,6 @@
|
|
|
4300
4442
|
FormDateError_data2: 'agro.angular_components.end_invalid_date'
|
|
4301
4443
|
};
|
|
4302
4444
|
|
|
4303
|
-
var OriginOperation;
|
|
4304
|
-
(function (OriginOperation) {
|
|
4305
|
-
OriginOperation["ENTRY_IN_DEPOSIT"] = "ENTRY_IN_DEPOSIT";
|
|
4306
|
-
OriginOperation["IMMEDIATE_BUY_ENTRY"] = "IMMEDIATE_BUY_ENTRY";
|
|
4307
|
-
OriginOperation["ENTRY_TO_BE_FIXED"] = "ENTRY_TO_BE_FIXED";
|
|
4308
|
-
})(OriginOperation || (OriginOperation = {}));
|
|
4309
|
-
|
|
4310
4445
|
var EntityService = /** @class */ (function () {
|
|
4311
4446
|
function EntityService(http, messageService, entityUrl, actionsUrl, queriesUrl, translate) {
|
|
4312
4447
|
this.http = http;
|
|
@@ -4658,36 +4793,15 @@
|
|
|
4658
4793
|
return PaginatorStorageService;
|
|
4659
4794
|
}());
|
|
4660
4795
|
|
|
4661
|
-
var InvoiceType;
|
|
4662
|
-
(function (InvoiceType) {
|
|
4663
|
-
InvoiceType["INCOMING"] = "INCOMING";
|
|
4664
|
-
InvoiceType["OUTGOING"] = "OUTGOING";
|
|
4665
|
-
InvoiceType["RETURN"] = "RETURN";
|
|
4666
|
-
InvoiceType["COMPLEMENT"] = "COMPLEMENT";
|
|
4667
|
-
InvoiceType["SYMBOLIC_RETURN"] = "SYMBOLIC_RETURN";
|
|
4668
|
-
InvoiceType["ADJUSTMENT"] = "ADJUSTMENT";
|
|
4669
|
-
InvoiceType["SERVICE"] = "SERVICE";
|
|
4670
|
-
})(InvoiceType || (InvoiceType = {}));
|
|
4671
|
-
|
|
4672
|
-
var invoiceTypeTranslate = [
|
|
4673
|
-
{ value: InvoiceType.INCOMING, label: "agro.angular_components.invoice_type_" + InvoiceType.INCOMING },
|
|
4674
|
-
{ value: InvoiceType.COMPLEMENT, label: "agro.angular_components.invoice_type_" + InvoiceType.COMPLEMENT },
|
|
4675
|
-
{ value: InvoiceType.ADJUSTMENT, label: "agro.angular_components.invoice_type_" + InvoiceType.ADJUSTMENT },
|
|
4676
|
-
{ value: InvoiceType.OUTGOING, label: "agro.angular_components.invoice_type_" + InvoiceType.OUTGOING },
|
|
4677
|
-
{ value: InvoiceType.RETURN, label: "agro.angular_components.invoice_type_" + InvoiceType.RETURN },
|
|
4678
|
-
{ value: InvoiceType.SERVICE, label: "agro.angular_components.invoice_type_" + InvoiceType.SERVICE },
|
|
4679
|
-
{ value: InvoiceType.SYMBOLIC_RETURN, label: "agro.angular_components.invoice_type_" + InvoiceType.SYMBOLIC_RETURN },
|
|
4680
|
-
];
|
|
4681
|
-
|
|
4682
4796
|
var EventControlBoardComponent = /** @class */ (function () {
|
|
4683
|
-
function EventControlBoardComponent(translate, formBuilder, websocketService, eventControlBoardService, paginatorStorageService, messageService,
|
|
4797
|
+
function EventControlBoardComponent(translate, formBuilder, websocketService, eventControlBoardService, paginatorStorageService, messageService, dialogService) {
|
|
4684
4798
|
this.translate = translate;
|
|
4685
4799
|
this.formBuilder = formBuilder;
|
|
4686
4800
|
this.websocketService = websocketService;
|
|
4687
4801
|
this.eventControlBoardService = eventControlBoardService;
|
|
4688
4802
|
this.paginatorStorageService = paginatorStorageService;
|
|
4689
4803
|
this.messageService = messageService;
|
|
4690
|
-
this.
|
|
4804
|
+
this.dialogService = dialogService;
|
|
4691
4805
|
this.steps = [];
|
|
4692
4806
|
this.showSidebar = false;
|
|
4693
4807
|
this.showReprocessButton = false;
|
|
@@ -5100,52 +5214,15 @@
|
|
|
5100
5214
|
this.displayModal = true;
|
|
5101
5215
|
};
|
|
5102
5216
|
EventControlBoardComponent.prototype.openCancelModal = function () {
|
|
5103
|
-
var
|
|
5104
|
-
this.
|
|
5105
|
-
header: this.
|
|
5106
|
-
|
|
5107
|
-
|
|
5108
|
-
|
|
5109
|
-
|
|
5110
|
-
|
|
5111
|
-
_this.cancelFixation();
|
|
5217
|
+
var _a;
|
|
5218
|
+
this.dialogService.open(CancelEventDialogComponent, {
|
|
5219
|
+
header: (_a = this.cancelEventDialogConfig) === null || _a === void 0 ? void 0 : _a.header,
|
|
5220
|
+
contentStyle: { "height": "100%" },
|
|
5221
|
+
closable: true,
|
|
5222
|
+
closeOnEscape: false,
|
|
5223
|
+
data: {
|
|
5224
|
+
cancelEventDialogConfig: this.cancelEventDialogConfig,
|
|
5112
5225
|
},
|
|
5113
|
-
reject: function () {
|
|
5114
|
-
_this.gridLoading = false;
|
|
5115
|
-
}
|
|
5116
|
-
});
|
|
5117
|
-
};
|
|
5118
|
-
EventControlBoardComponent.prototype.cancelFixation = function () {
|
|
5119
|
-
var _this = this;
|
|
5120
|
-
var params = {
|
|
5121
|
-
filterQuery: "id eq '" + this.gridData[exports.AGRO_NUMBERS.ZERO].externalId + "'",
|
|
5122
|
-
displayFields: ['*', 'fixationItem']
|
|
5123
|
-
};
|
|
5124
|
-
this.eventControlBoardService.fixationService
|
|
5125
|
-
.list(params)
|
|
5126
|
-
.pipe(operators.takeUntil(this.ngUnsubscribe), operators.switchMap(function (result) {
|
|
5127
|
-
var fixationEntity = result.contents[exports.AGRO_NUMBERS.ZERO];
|
|
5128
|
-
if (fixationEntity.status !== FixationStatus.FINISHED) {
|
|
5129
|
-
_this.addMessage('warn', 'agro.angular_components.warn_cancel_fixation_message_title', 'agro.angular_components.warn_cancel_fixation_message_description');
|
|
5130
|
-
_this.gridLoading = false;
|
|
5131
|
-
return rxjs.EMPTY;
|
|
5132
|
-
}
|
|
5133
|
-
if (fixationEntity.fixationItem[0].originOperation === OriginOperation.IMMEDIATE_BUY_ENTRY) {
|
|
5134
|
-
_this.addMessage('warn', 'agro.angular_components.warn_cancel_fixation_message_title', 'agro.angular_components.warn_immediate_cancel_fixation_message_description');
|
|
5135
|
-
_this.gridLoading = false;
|
|
5136
|
-
return rxjs.EMPTY;
|
|
5137
|
-
}
|
|
5138
|
-
return _this.eventControlBoardService.fixationService.cancelFixation({
|
|
5139
|
-
fixationId: _this.gridData[exports.AGRO_NUMBERS.ZERO].externalId
|
|
5140
|
-
});
|
|
5141
|
-
}), operators.catchError(function (err) {
|
|
5142
|
-
_this.addMessage('error', 'agro.angular_components.error_cancel_fixation_message_title', 'agro.angular_components.error_cancel_fixation_message_description');
|
|
5143
|
-
_this.gridLoading = false;
|
|
5144
|
-
throw err;
|
|
5145
|
-
}))
|
|
5146
|
-
.subscribe(function () {
|
|
5147
|
-
_this.addMessage('info', 'agro.angular_components.cancel_fixation_message_title', 'agro.angular_components.cancel_fixation_message_description');
|
|
5148
|
-
_this.gridLoading = false;
|
|
5149
5226
|
});
|
|
5150
5227
|
};
|
|
5151
5228
|
EventControlBoardComponent.prototype.confirmModal = function () {
|
|
@@ -5166,7 +5243,7 @@
|
|
|
5166
5243
|
{ type: EventControlBoardService },
|
|
5167
5244
|
{ type: PaginatorStorageService },
|
|
5168
5245
|
{ type: primeng.MessageService },
|
|
5169
|
-
{ type: primeng.
|
|
5246
|
+
{ type: primeng.DialogService }
|
|
5170
5247
|
]; };
|
|
5171
5248
|
__decorate([
|
|
5172
5249
|
core.Input()
|
|
@@ -5195,6 +5272,9 @@
|
|
|
5195
5272
|
__decorate([
|
|
5196
5273
|
core.Input()
|
|
5197
5274
|
], EventControlBoardComponent.prototype, "showCancelButton", void 0);
|
|
5275
|
+
__decorate([
|
|
5276
|
+
core.Input()
|
|
5277
|
+
], EventControlBoardComponent.prototype, "cancelEventDialogConfig", void 0);
|
|
5198
5278
|
EventControlBoardComponent = __decorate([
|
|
5199
5279
|
core.Component({
|
|
5200
5280
|
selector: 'event-control-board',
|
|
@@ -6072,6 +6152,27 @@
|
|
|
6072
6152
|
return FixationModule;
|
|
6073
6153
|
}());
|
|
6074
6154
|
|
|
6155
|
+
var CancelEventDialogModule = /** @class */ (function () {
|
|
6156
|
+
function CancelEventDialogModule() {
|
|
6157
|
+
}
|
|
6158
|
+
CancelEventDialogModule = __decorate([
|
|
6159
|
+
core.NgModule({
|
|
6160
|
+
imports: [
|
|
6161
|
+
common.CommonModule,
|
|
6162
|
+
forms.ReactiveFormsModule,
|
|
6163
|
+
tooltip.TooltipModule,
|
|
6164
|
+
angularComponents.ButtonModule,
|
|
6165
|
+
LibTranslationModule,
|
|
6166
|
+
angularComponents.DynamicFormModule,
|
|
6167
|
+
angularComponents.LoadingStateModule
|
|
6168
|
+
],
|
|
6169
|
+
declarations: [CancelEventDialogComponent],
|
|
6170
|
+
exports: [CancelEventDialogComponent],
|
|
6171
|
+
})
|
|
6172
|
+
], CancelEventDialogModule);
|
|
6173
|
+
return CancelEventDialogModule;
|
|
6174
|
+
}());
|
|
6175
|
+
|
|
6075
6176
|
var EventControlBoardModule = /** @class */ (function () {
|
|
6076
6177
|
function EventControlBoardModule() {
|
|
6077
6178
|
}
|
|
@@ -6101,12 +6202,13 @@
|
|
|
6101
6202
|
TicketModule,
|
|
6102
6203
|
WebsocketModule,
|
|
6103
6204
|
LibTranslationModule,
|
|
6104
|
-
FixationModule
|
|
6205
|
+
FixationModule,
|
|
6206
|
+
CancelEventDialogModule,
|
|
6105
6207
|
],
|
|
6106
6208
|
declarations: [EventControlBoardComponent],
|
|
6107
6209
|
exports: [EventControlBoardComponent],
|
|
6108
6210
|
providers: [E012famService, E205depService, PaginatorStorageService,
|
|
6109
|
-
EventControlService, EventControlBoardService, primeng.
|
|
6211
|
+
EventControlService, EventControlBoardService, primeng.DialogService],
|
|
6110
6212
|
})
|
|
6111
6213
|
], EventControlBoardModule);
|
|
6112
6214
|
return EventControlBoardModule;
|
|
@@ -6147,6 +6249,8 @@
|
|
|
6147
6249
|
exports.AgroPlatformUtils = AgroPlatformUtils;
|
|
6148
6250
|
exports.AgroStringUtils = AgroStringUtils;
|
|
6149
6251
|
exports.AsyncLock = AsyncLock;
|
|
6252
|
+
exports.CancelEventDialogComponent = CancelEventDialogComponent;
|
|
6253
|
+
exports.CancelEventDialogModule = CancelEventDialogModule;
|
|
6150
6254
|
exports.Colors = Colors;
|
|
6151
6255
|
exports.E001TnsModule = E001TnsModule;
|
|
6152
6256
|
exports.E001pesModule = E001pesModule;
|