@seniorsistemas/yms-integration 1.28.0 → 1.29.1

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 (27) hide show
  1. package/bundles/seniorsistemas-yms-integration.umd.js +120 -1
  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/index.js +3 -1
  6. package/esm2015/src/wms/components/document-grid/insert-key/insert-key.component.js +6 -2
  7. package/esm2015/src/wms/components/document-list/document-list.component.js +88 -0
  8. package/esm2015/src/wms/components/document-list/document-list.module.js +32 -0
  9. package/esm2015/src/wms/entities/agenda/agenda-dto.js +1 -0
  10. package/esm2015/src/wms/entities/document/document.service.js +4 -1
  11. package/esm5/index.js +3 -1
  12. package/esm5/src/wms/components/document-grid/insert-key/insert-key.component.js +6 -2
  13. package/esm5/src/wms/components/document-list/document-list.component.js +93 -0
  14. package/esm5/src/wms/components/document-list/document-list.module.js +33 -0
  15. package/esm5/src/wms/entities/agenda/agenda-dto.js +1 -0
  16. package/esm5/src/wms/entities/document/document.service.js +4 -1
  17. package/fesm2015/seniorsistemas-yms-integration.js +113 -2
  18. package/fesm2015/seniorsistemas-yms-integration.js.map +1 -1
  19. package/fesm5/seniorsistemas-yms-integration.js +119 -2
  20. package/fesm5/seniorsistemas-yms-integration.js.map +1 -1
  21. package/index.d.ts +2 -0
  22. package/package.json +1 -1
  23. package/seniorsistemas-yms-integration.metadata.json +1 -1
  24. package/src/wms/components/document-list/document-list.component.d.ts +26 -0
  25. package/src/wms/components/document-list/document-list.module.d.ts +5 -0
  26. package/src/wms/entities/agenda/agenda-dto.d.ts +12 -0
  27. package/src/wms/entities/document/document.service.d.ts +1 -0
@@ -2918,6 +2918,9 @@ let DocumentService = class DocumentService extends EntityService {
2918
2918
  findDocuments(input) {
2919
2919
  return this.http.post('yms_int/wms/queries/findDocuments', input);
2920
2920
  }
2921
+ getSystemIntegration() {
2922
+ return this.http.get('yms_int/wms/queries/getSystemIntegration');
2923
+ }
2921
2924
  };
2922
2925
  DocumentService = __decorate([
2923
2926
  Injectable(),
@@ -3382,7 +3385,11 @@ let InsertKeyComponent = class InsertKeyComponent {
3382
3385
  searchKey() {
3383
3386
  const key = {
3384
3387
  documentKeys: [this.formGroup.get('key').value],
3385
- invoices: undefined,
3388
+ invoices: [{
3389
+ number: this.formGroup.get('invoiceNumber').value,
3390
+ serialNumber: this.formGroup.get('invoiceSerie').value,
3391
+ partnerDocument: this.formGroup.get('partnerDocument').value
3392
+ }],
3386
3393
  logistcUnitName: undefined,
3387
3394
  size: 0,
3388
3395
  offset: 0
@@ -3526,6 +3533,110 @@ WmsModule = __decorate([
3526
3533
  __metadata("design:paramtypes", [IntegrationDispatcher])
3527
3534
  ], WmsModule);
3528
3535
 
3536
+ const INFORMACAOES_ADICIONAIS_HEADER$1 = "Informações adicionais";
3537
+ let DocumentListDescritor = class DocumentListDescritor {
3538
+ };
3539
+ DocumentListDescritor = __decorate([
3540
+ ControleCircuito({
3541
+ header: INFORMACAOES_ADICIONAIS_HEADER$1,
3542
+ name: 'yms.integracao.wms'
3543
+ })
3544
+ ], DocumentListDescritor);
3545
+ let DocumentListComponent = class DocumentListComponent extends DocumentListDescritor {
3546
+ constructor(documentService) {
3547
+ super();
3548
+ this.documentService = documentService;
3549
+ this.getColumns = [];
3550
+ this.documents = [];
3551
+ this.labels = [];
3552
+ }
3553
+ ngOnInit() {
3554
+ this.getSystemIntegration();
3555
+ }
3556
+ getSystemIntegration() {
3557
+ this.documentService.getSystemIntegration().subscribe((system) => {
3558
+ this.wmsSystem = system.system;
3559
+ this.getDocumentBySchedulingId();
3560
+ });
3561
+ }
3562
+ getDocumentBySchedulingId() {
3563
+ this.documentService.list({
3564
+ filterQuery: `schedulingId eq '${this.agenda.id}'`
3565
+ }).subscribe((contents) => {
3566
+ if (contents.totalElements > 0) {
3567
+ this.documents = contents.contents;
3568
+ this.getColumns = this.getColumnLabels();
3569
+ }
3570
+ });
3571
+ }
3572
+ getColumnLabels() {
3573
+ if (this.isWmsWIS()) {
3574
+ return [
3575
+ ...this.getLabelsInvoice()
3576
+ ];
3577
+ }
3578
+ if (this.isWmsSeniorConnect()) {
3579
+ return [
3580
+ { label: 'yms.int.wms_purchaseOrder' },
3581
+ { label: 'yms.int.wms_register_document_partner_name' },
3582
+ { label: 'yms.int.wms_register_document_partner_document' }
3583
+ ];
3584
+ }
3585
+ return [
3586
+ { label: 'yms.int.wms_register_document_invoice_key' },
3587
+ ...this.getLabelsInvoice()
3588
+ ];
3589
+ }
3590
+ isWmsSeniorConnect() {
3591
+ return this.wmsSystem === WmsSystem.SENIOR_CONNECT;
3592
+ }
3593
+ isWmsWIS() {
3594
+ return this.wmsSystem === WmsSystem.WIS;
3595
+ }
3596
+ getLabelsInvoice() {
3597
+ return [
3598
+ { label: 'yms.int.wms_register_document_invoice_number' },
3599
+ { label: 'yms.int.wms_register_document_invoice_serial_number' }
3600
+ ];
3601
+ }
3602
+ };
3603
+ __decorate([
3604
+ Input(),
3605
+ __metadata("design:type", Object)
3606
+ ], DocumentListComponent.prototype, "agenda", void 0);
3607
+ __decorate([
3608
+ Input(),
3609
+ __metadata("design:type", String)
3610
+ ], DocumentListComponent.prototype, "wmsSystem", void 0);
3611
+ DocumentListComponent = __decorate([
3612
+ Component({
3613
+ template: "<div> \n <p-table [value]=\"documents\">\n <ng-template pTemplate=\"header\">\n <tr>\n <th id=\"columns\" *ngFor=\"let column of getColumns\">\n <div class=\"senior-header\">\n <span class=\"senior-header-title\">{{ column.label | translate }}</span>\n </div>\n </th>\n </tr>\n </ng-template>\n <ng-template let-rowData pTemplate=\"body\">\n <tr *ngIf=\"isWmsWIS()\">\n <td id=\"\">{{rowData?.invoiceNumber}}</td>\n <td id=\"\">{{rowData?.invoiceSerialNumber}}</td>\n </tr>\n <tr *ngIf=\"isWmsSeniorConnect()\">\n <td id=\"\">{{rowData?.key}}</td>\n <td id=\"\">{{rowData?.partnerName}}</td>\n <td id=\"\">{{rowData?.partnerDocument}}</td>\n </tr>\n <tr *ngIf=\"!isWmsWIS() && !isWmsSeniorConnect()\">\n <td id=\"\">{{rowData?.invoiceKey}}</td>\n <td id=\"\">{{rowData?.invoiceNumber}}</td>\n <td id=\"\">{{rowData?.invoiceSerialNumber}}</td>\n </tr>\n </ng-template>\n </p-table>\n</div>"
3614
+ }),
3615
+ __metadata("design:paramtypes", [DocumentService])
3616
+ ], DocumentListComponent);
3617
+
3618
+ let DocumentListModule = class DocumentListModule {
3619
+ constructor(dispatcher) {
3620
+ this.dispatcher = dispatcher;
3621
+ this.dispatcher.dispatch(DocumentListComponent);
3622
+ }
3623
+ };
3624
+ DocumentListModule = __decorate([
3625
+ NgModule({
3626
+ imports: [
3627
+ CommonModule,
3628
+ TranslateModule,
3629
+ LoadingStateModule,
3630
+ TableModule
3631
+ ],
3632
+ declarations: [DocumentListComponent],
3633
+ entryComponents: [DocumentListComponent],
3634
+ exports: [DocumentListComponent],
3635
+ providers: [DocumentService]
3636
+ }),
3637
+ __metadata("design:paramtypes", [IntegrationDispatcher])
3638
+ ], DocumentListModule);
3639
+
3529
3640
  class EntityService$1 {
3530
3641
  constructor(http, messageService, entityUrl, actionsUrl) {
3531
3642
  this.http = http;
@@ -13231,5 +13342,5 @@ DockModule = __decorate([
13231
13342
  })
13232
13343
  ], DockModule);
13233
13344
 
13234
- export { AgendaModule, AgendaService, BalancaModule, BalancasService, CamerasModule, CamerasService, CancelasModule, CidadeModule, CidadeService, ContratoCompraItemModule, ContratoCompraItemService, ContratoCompraModule, ContratoCompraService, ControladorCancelaComponent, ControladorCancelaDescritor, ControladorCancelasService, CoreModule, DockModule, DockService, ERP_ENVIRONMENT, ERP_SENIOR_HEADER, EmpresaModule, EmpresaService, ErpFormConfigService, ErpProcessData, ErpProcessService, ErpSeniorModule, EstadoModule, EstadoService, ExpedicaoChegadaVeiculoOverride, ExpedicaoModule, ExpedicaoService, FamiliaProdutoModule, FamiliaProdutoService, FieldCustomizationService, FilialModule, FilialService, FormComponent, FormDescritor, FormSamComponent, FormSamDescritor, FormWmsComponent, FormWmsDescritor, HasChangeService, INFORMACAOES_ADICIONAIS_HEADER, InfoComponent, InfoDescritor, IntegrationWebSocket, LogsModule, LogsService, LprModule, LprService, PaisModule, PaisService, PedidoVendaItemModule, PedidoVendaItemService, PedidoVendaModule, PedidoVendaService, PessoaEnderecoModule, PessoaEnderecoService, PessoaFisicaModule, PessoaFisicaService, PessoaJuridicaModule, PessoaJuridicaService, PessoaModule, PessoaService, PortariasComponent, PortariasDescritor, PortariasModule, ProdutoModule, ProdutoService, RecebimentoChegadaVeiculoOverride, RecebimentoContratoModule, RecebimentoContratoService, RoyaltyModule, RoyaltyService, SAM_SENIOR_HEADER, SafraModule, SafraService, SamSeniorModule, SnapshotComponent, SnapshotDescritor, TransportadoraModule, TransportadoraService, UnidadeMedidaModule, UnidadeMedidaService, VisitorListComponent, VisitorListModule, VisitorListService, VisualizarBalancaComponent, VisualizarBalancaDescritor, WmsModule, highlightLanguages, Service as ɵa, CustomStompConfig as ɵb, RegisterDocumentComponent as ɵba, InsertKeyModule as ɵbb, InsertKeyComponent as ɵbc, EntityService$1 as ɵbd, IntegrationService$1 as ɵbe, RecebimentoFormComponent as ɵbf, DerivacaoService as ɵbg, NotaValidatorService as ɵbh, TransgeniaService as ɵbi, VerificaNotafiscal as ɵbj, BuildFormField as ɵbk, ExpedicaoFormComponent as ɵbl, ExpedicaoInfoComponent as ɵbm, RecebimentoInfoComponent as ɵbn, DevolucaoFormComponent as ɵbo, DevolucaoService as ɵbp, DevolucaoChegadaVeiculoOverride as ɵbq, RecebimentoOrdemCompraFormComponent as ɵbr, OrdemCompraService as ɵbs, RecebimentoOrdemCompraService as ɵbt, RecebimentoOrdemCompraChegadaVeiculoOverride as ɵbu, RecebimentoOrdemCompraInfoComponent as ɵbv, DevolucaoInfoComponent as ɵbw, ContratoFormComponent as ɵbx, OrdemCompraFormComponent as ɵby, ProcessoAvulsoFormComponent as ɵbz, ViewImageComponent as ɵc, ProcessoAvulsoService as ɵca, ProcessoAvulsoChegadaVeiculoOverride as ɵcb, ProcessoAvulsoInfoComponent as ɵcc, LogIntegracaoDescritor as ɵcd, LogIntegracaoComponent as ɵce, LogIntegracaoService as ɵcf, DerivacaoModule as ɵcg, DevolucaoModule as ɵch, OrdemCompraModule as ɵci, RecebimentoOrdemCompraModule as ɵcj, TransgeniaModule as ɵck, ProcessoAvulsoModule as ɵcl, LogIntegracaoModule as ɵcm, NotaFormModule as ɵcn, DirectivesModule as ɵco, TrimDirective as ɵcp, NotaFormComponent as ɵcq, LogDescritor as ɵd, LogsComponent as ɵe, PortariasService as ɵf, EntradaComponent as ɵg, AgendasComponent as ɵh, ConfirmacaoComponent as ɵi, VisitedInfoDescritor as ɵj, VisitedInfoComponent as ɵk, VisitedInfoService as ɵl, SchedulingComponent as ɵm, LobbyService as ɵn, EntityService as ɵo, SchedulingService as ɵp, VisitanteComponent as ɵq, VisitanteFormComponent as ɵr, CredencialFormComponent as ɵs, FocusService as ɵt, FormWmsService as ɵu, DocumentGridModule as ɵv, DocumentGridComponent as ɵw, DocumentService as ɵx, IntegrationService as ɵy, RegisterDocumentModule as ɵz };
13345
+ export { AgendaModule, AgendaService, BalancaModule, BalancasService, CamerasModule, CamerasService, CancelasModule, CidadeModule, CidadeService, ContratoCompraItemModule, ContratoCompraItemService, ContratoCompraModule, ContratoCompraService, ControladorCancelaComponent, ControladorCancelaDescritor, ControladorCancelasService, CoreModule, DockModule, DockService, DocumentListComponent, DocumentListModule, ERP_ENVIRONMENT, ERP_SENIOR_HEADER, EmpresaModule, EmpresaService, ErpFormConfigService, ErpProcessData, ErpProcessService, ErpSeniorModule, EstadoModule, EstadoService, ExpedicaoChegadaVeiculoOverride, ExpedicaoModule, ExpedicaoService, FamiliaProdutoModule, FamiliaProdutoService, FieldCustomizationService, FilialModule, FilialService, FormComponent, FormDescritor, FormSamComponent, FormSamDescritor, FormWmsComponent, FormWmsDescritor, HasChangeService, INFORMACAOES_ADICIONAIS_HEADER, InfoComponent, InfoDescritor, IntegrationWebSocket, LogsModule, LogsService, LprModule, LprService, PaisModule, PaisService, PedidoVendaItemModule, PedidoVendaItemService, PedidoVendaModule, PedidoVendaService, PessoaEnderecoModule, PessoaEnderecoService, PessoaFisicaModule, PessoaFisicaService, PessoaJuridicaModule, PessoaJuridicaService, PessoaModule, PessoaService, PortariasComponent, PortariasDescritor, PortariasModule, ProdutoModule, ProdutoService, RecebimentoChegadaVeiculoOverride, RecebimentoContratoModule, RecebimentoContratoService, RoyaltyModule, RoyaltyService, SAM_SENIOR_HEADER, SafraModule, SafraService, SamSeniorModule, SnapshotComponent, SnapshotDescritor, TransportadoraModule, TransportadoraService, UnidadeMedidaModule, UnidadeMedidaService, VisitorListComponent, VisitorListModule, VisitorListService, VisualizarBalancaComponent, VisualizarBalancaDescritor, WmsModule, highlightLanguages, Service as ɵa, CustomStompConfig as ɵb, RegisterDocumentComponent as ɵba, InsertKeyModule as ɵbb, InsertKeyComponent as ɵbc, EntityService$1 as ɵbd, IntegrationService$1 as ɵbe, RecebimentoFormComponent as ɵbf, DerivacaoService as ɵbg, NotaValidatorService as ɵbh, TransgeniaService as ɵbi, VerificaNotafiscal as ɵbj, BuildFormField as ɵbk, ExpedicaoFormComponent as ɵbl, ExpedicaoInfoComponent as ɵbm, RecebimentoInfoComponent as ɵbn, DevolucaoFormComponent as ɵbo, DevolucaoService as ɵbp, DevolucaoChegadaVeiculoOverride as ɵbq, RecebimentoOrdemCompraFormComponent as ɵbr, OrdemCompraService as ɵbs, RecebimentoOrdemCompraService as ɵbt, RecebimentoOrdemCompraChegadaVeiculoOverride as ɵbu, RecebimentoOrdemCompraInfoComponent as ɵbv, DevolucaoInfoComponent as ɵbw, ContratoFormComponent as ɵbx, OrdemCompraFormComponent as ɵby, ProcessoAvulsoFormComponent as ɵbz, ViewImageComponent as ɵc, ProcessoAvulsoService as ɵca, ProcessoAvulsoChegadaVeiculoOverride as ɵcb, ProcessoAvulsoInfoComponent as ɵcc, LogIntegracaoDescritor as ɵcd, LogIntegracaoComponent as ɵce, LogIntegracaoService as ɵcf, DerivacaoModule as ɵcg, DevolucaoModule as ɵch, OrdemCompraModule as ɵci, RecebimentoOrdemCompraModule as ɵcj, TransgeniaModule as ɵck, ProcessoAvulsoModule as ɵcl, LogIntegracaoModule as ɵcm, NotaFormModule as ɵcn, DirectivesModule as ɵco, TrimDirective as ɵcp, NotaFormComponent as ɵcq, LogDescritor as ɵd, LogsComponent as ɵe, PortariasService as ɵf, EntradaComponent as ɵg, AgendasComponent as ɵh, ConfirmacaoComponent as ɵi, VisitedInfoDescritor as ɵj, VisitedInfoComponent as ɵk, VisitedInfoService as ɵl, SchedulingComponent as ɵm, LobbyService as ɵn, EntityService as ɵo, SchedulingService as ɵp, VisitanteComponent as ɵq, VisitanteFormComponent as ɵr, CredencialFormComponent as ɵs, FocusService as ɵt, FormWmsService as ɵu, DocumentGridModule as ɵv, DocumentGridComponent as ɵw, DocumentService as ɵx, IntegrationService as ɵy, RegisterDocumentModule as ɵz };
13235
13346
  //# sourceMappingURL=seniorsistemas-yms-integration.js.map