@senior-agronegocio/angular-components 0.0.85 → 0.0.86

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.
@@ -5540,6 +5540,10 @@
5540
5540
  }
5541
5541
  return null;
5542
5542
  };
5543
+ EventControlBoardComponent.prototype.getProducerBalanceEntryControlIdFromParams = function (param) {
5544
+ var producerBalanceEntryControlId = param.producerBalanceEntryControlId;
5545
+ return producerBalanceEntryControlId ? producerBalanceEntryControlId : null;
5546
+ };
5543
5547
  EventControlBoardComponent.prototype.stepSelected = function (event) {
5544
5548
  var _this = this;
5545
5549
  this.selectedStep = event.step;
@@ -5553,14 +5557,22 @@
5553
5557
  {
5554
5558
  var param = JSON.parse(this.selectedStep.item.input);
5555
5559
  var producerInvoiceId = this.getProducerInvoiceIdFromParams(param);
5560
+ var filterQuery = "";
5556
5561
  if (!producerInvoiceId) {
5557
- this.sidebarLoading = false;
5558
- return;
5562
+ var producerBalanceEntryControlId = this.getProducerBalanceEntryControlIdFromParams(param);
5563
+ if (!producerBalanceEntryControlId) {
5564
+ this.sidebarLoading = false;
5565
+ return;
5566
+ }
5567
+ filterQuery = "producerBalanceEntryControl.id eq '" + producerBalanceEntryControlId + "'";
5568
+ }
5569
+ else {
5570
+ filterQuery = "id eq '" + producerInvoiceId + "'";
5559
5571
  }
5560
5572
  this.eventControlBoardService.producerInvoiceService
5561
5573
  .list({
5562
5574
  displayFields: ["*", "producerBalanceEntryControl.*", "producerBalanceEntryControl.producer.*"],
5563
- filterQuery: "id eq '" + producerInvoiceId + "'",
5575
+ filterQuery: filterQuery,
5564
5576
  page: 0,
5565
5577
  size: 1,
5566
5578
  })