@seniorsistemas/yms-integration 1.5.2 → 1.5.5

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 (22) hide show
  1. package/bundles/seniorsistemas-yms-integration.umd.js +15 -2
  2. package/bundles/seniorsistemas-yms-integration.umd.js.map +1 -1
  3. package/bundles/seniorsistemas-yms-integration.umd.min.js +1 -1
  4. package/bundles/seniorsistemas-yms-integration.umd.min.js.map +1 -1
  5. package/esm2015/src/erp-senior/core/erp-process-data/erp-process-service.js +4 -2
  6. package/esm2015/src/erp-senior/devolucao/form/devolucao-form.component.js +3 -1
  7. package/esm2015/src/erp-senior/expedicao/form/expedicao-form.component.js +3 -1
  8. package/esm2015/src/erp-senior/processo-avulso/form/processo-avulso-form.component.js +3 -1
  9. package/esm2015/src/erp-senior/recebimento/form/recebimento-form.component.js +5 -2
  10. package/esm2015/src/erp-senior/recebimento-ordem-compra/form/recebimento-ordem-compra-form.component.js +3 -1
  11. package/esm5/src/erp-senior/core/erp-process-data/erp-process-service.js +4 -2
  12. package/esm5/src/erp-senior/devolucao/form/devolucao-form.component.js +3 -1
  13. package/esm5/src/erp-senior/expedicao/form/expedicao-form.component.js +3 -1
  14. package/esm5/src/erp-senior/processo-avulso/form/processo-avulso-form.component.js +3 -1
  15. package/esm5/src/erp-senior/recebimento/form/recebimento-form.component.js +5 -2
  16. package/esm5/src/erp-senior/recebimento-ordem-compra/form/recebimento-ordem-compra-form.component.js +3 -1
  17. package/fesm2015/seniorsistemas-yms-integration.js +15 -2
  18. package/fesm2015/seniorsistemas-yms-integration.js.map +1 -1
  19. package/fesm5/seniorsistemas-yms-integration.js +15 -2
  20. package/fesm5/seniorsistemas-yms-integration.js.map +1 -1
  21. package/package.json +1 -1
  22. package/seniorsistemas-yms-integration.metadata.json +1 -1
@@ -3676,9 +3676,11 @@
3676
3676
  };
3677
3677
  ErpProcessService.prototype.listarIdsFornecedores = function (formGroup) {
3678
3678
  var listaFornecedores = [];
3679
+ console.log("formGroup-fornecedores :" + formGroup.get("fornecedores"));
3679
3680
  var fornecedores = formGroup.get("fornecedores") != null ? formGroup.get("fornecedores").value : null;
3681
+ console.log("Fornecedores :" + fornecedores);
3680
3682
  if (fornecedores != null) {
3681
- fornecedores.forEach(function (element) { return listaFornecedores.push(element.fornecedor); });
3683
+ fornecedores.filter(function (element) { return element.fornecedor != null && element.fornecedor != undefined; }).forEach(function (element) { return listaFornecedores.push(element.fornecedor); });
3682
3684
  }
3683
3685
  return listaFornecedores.map(function (val) { return val.id; });
3684
3686
  };
@@ -5114,6 +5116,8 @@
5114
5116
  message: this.translate.instant("yms.patio.agenda_revalidacao_message"),
5115
5117
  accept: function () {
5116
5118
  _this.agenda.status = StatusAgenda.REJEITADO_POR_VALIDACAO;
5119
+ _this.agenda.motorista = { id: _this.erpProcessData.motoristaId };
5120
+ _this.agenda.veiculo = { id: _this.erpProcessData.veiculoId };
5117
5121
  _this.agendaService
5118
5122
  .atualizarAgenda(_this.agenda)
5119
5123
  .pipe(operators.takeUntil(_this.ngUnsubscribe), operators.concatMap(function (_) { return _this.getSaveObservable(); }), operators.finalize(function () { return _this.loading = false; }))
@@ -5853,6 +5857,8 @@
5853
5857
  message: this.translate.instant("yms.patio.agenda_revalidacao_message"),
5854
5858
  accept: function () {
5855
5859
  _this.agenda.status = StatusAgenda.REJEITADO_POR_VALIDACAO;
5860
+ _this.agenda.motorista = { id: _this.erpProcessData.motoristaId };
5861
+ _this.agenda.veiculo = { id: _this.erpProcessData.veiculoId };
5856
5862
  _this.agendaService
5857
5863
  .atualizarAgenda(_this.agenda)
5858
5864
  .pipe(operators.takeUntil(_this.ngUnsubscribe), operators.concatMap(function (_) { return _this.getSaveObservable(); }), operators.finalize(function () { return _this.loading = false; }))
@@ -7274,6 +7280,8 @@
7274
7280
  message: this.translate.instant("yms.patio.agenda_revalidacao_message"),
7275
7281
  accept: function () {
7276
7282
  _this.agenda.status = StatusAgenda.REJEITADO_POR_VALIDACAO;
7283
+ _this.agenda.motorista = { id: _this.erpProcessData.motoristaId };
7284
+ _this.agenda.veiculo = { id: _this.erpProcessData.veiculoId };
7277
7285
  _this.agendaService
7278
7286
  .atualizarAgenda(_this.agenda)
7279
7287
  .pipe(operators.takeUntil(_this.ngUnsubscribe), operators.concatMap(function (_) { return _this.getSaveObservable(); }), operators.finalize(function () { return _this.loading = false; }))
@@ -8223,6 +8231,8 @@
8223
8231
  message: this.translate.instant("yms.patio.agenda_revalidacao_message"),
8224
8232
  accept: function () {
8225
8233
  _this.agenda.status = StatusAgenda.REJEITADO_POR_VALIDACAO;
8234
+ _this.agenda.motorista = { id: _this.erpProcessData.motoristaId };
8235
+ _this.agenda.veiculo = { id: _this.erpProcessData.veiculoId };
8226
8236
  _this.agendaService
8227
8237
  .atualizarAgenda(_this.agenda)
8228
8238
  .pipe(operators.takeUntil(_this.ngUnsubscribe), operators.concatMap(function (_) { return _this.getSaveObservable(); }), operators.finalize(function () { return _this.loading = false; }))
@@ -9687,6 +9697,8 @@
9687
9697
  message: this.translate.instant("yms.patio.agenda_revalidacao_message"),
9688
9698
  accept: function () {
9689
9699
  _this.agenda.status = StatusAgenda.REJEITADO_POR_VALIDACAO;
9700
+ _this.agenda.motorista = { id: _this.erpProcessData.motoristaId };
9701
+ _this.agenda.veiculo = { id: _this.erpProcessData.veiculoId };
9690
9702
  _this.agendaService
9691
9703
  .atualizarAgenda(_this.agenda)
9692
9704
  .pipe(operators.takeUntil(_this.ngUnsubscribe), operators.concatMap(function (_) { return _this.getSaveObservable(); }), operators.finalize(function () { return _this.loading = false; }))
@@ -10370,7 +10382,7 @@
10370
10382
  produto: [{ value: undefined, disabled: true }, forms.Validators.compose([forms.Validators.required])],
10371
10383
  derivacao: [{ value: undefined, disabled: true }, forms.Validators.compose([])],
10372
10384
  transportadora: [{ value: undefined, disabled: false }, forms.Validators.compose([])],
10373
- agenda: [{ value: undefined, disabled: false }, forms.Validators.compose([forms.Validators.required])],
10385
+ agenda: [{ value: this.agenda, disabled: false }, forms.Validators.compose([forms.Validators.required])],
10374
10386
  transgenia: [{ value: undefined, disabled: true }, forms.Validators.compose([])],
10375
10387
  fornecedores: this.formBuilder.array([]),
10376
10388
  createdBy: [{ value: undefined, disabled: true }, forms.Validators.compose([])],
@@ -10851,6 +10863,7 @@
10851
10863
  };
10852
10864
  RecebimentoFormComponent.prototype.getSaveObservable = function () {
10853
10865
  var value = this.formGroup.getRawValue();
10866
+ value.agenda = this.agenda;
10854
10867
  var recebimentoDto = RecebimentoContrato.toDto(value);
10855
10868
  var observable;
10856
10869
  if (this.isNew() && !value.id) {