@seniorsistemas/yms-integration 1.21.0 → 1.23.0

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 (24) hide show
  1. package/bundles/seniorsistemas-yms-integration.umd.js +61 -29
  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/wms/components/document-grid/document-grid.component.js +49 -22
  6. package/esm2015/src/wms/components/document-grid/insert-key/insert-key.component.js +3 -3
  7. package/esm2015/src/wms/components/document-grid/register-document/register-document.component.js +14 -9
  8. package/esm2015/src/wms/entities/document/document-dto.js +1 -1
  9. package/esm2015/src/wms/entities/document/document.js +2 -2
  10. package/esm5/src/wms/components/document-grid/document-grid.component.js +50 -22
  11. package/esm5/src/wms/components/document-grid/insert-key/insert-key.component.js +3 -3
  12. package/esm5/src/wms/components/document-grid/register-document/register-document.component.js +14 -9
  13. package/esm5/src/wms/entities/document/document-dto.js +1 -1
  14. package/esm5/src/wms/entities/document/document.js +2 -2
  15. package/fesm2015/seniorsistemas-yms-integration.js +61 -30
  16. package/fesm2015/seniorsistemas-yms-integration.js.map +1 -1
  17. package/fesm5/seniorsistemas-yms-integration.js +62 -30
  18. package/fesm5/seniorsistemas-yms-integration.js.map +1 -1
  19. package/package.json +1 -1
  20. package/seniorsistemas-yms-integration.metadata.json +1 -1
  21. package/src/wms/components/document-grid/document-grid.component.d.ts +7 -5
  22. package/src/wms/components/document-grid/register-document/register-document.component.d.ts +1 -1
  23. package/src/wms/entities/document/document-dto.d.ts +3 -1
  24. package/src/wms/entities/document/document.d.ts +3 -1
@@ -1,4 +1,4 @@
1
- import { Subject, throwError, BehaviorSubject, empty, ReplaySubject, NEVER, of, forkJoin } from 'rxjs';
1
+ import { Subject, throwError, BehaviorSubject, empty, ReplaySubject, NEVER, forkJoin, of } from 'rxjs';
2
2
  import { takeUntil, catchError, finalize, map, filter, mergeMap, tap, concatMap, switchMap, debounceTime } from 'rxjs/operators';
3
3
  import { __decorate, __metadata, __param } from 'tslib';
4
4
  import { CommonModule } from '@angular/common';
@@ -2863,13 +2863,15 @@ DocumentService = __decorate([
2863
2863
  ], DocumentService);
2864
2864
 
2865
2865
  let DocumentGridComponent = class DocumentGridComponent {
2866
- constructor(translate, documentService, messageService) {
2866
+ constructor(translate, documentService, messageService, confirmationService) {
2867
2867
  this.translate = translate;
2868
2868
  this.documentService = documentService;
2869
2869
  this.messageService = messageService;
2870
+ this.confirmationService = confirmationService;
2870
2871
  this.viewDocument = new EventEmitter();
2871
2872
  this.gridData = [];
2872
2873
  this.ngUnsubscribe = new Subject();
2874
+ this.selection = [];
2873
2875
  }
2874
2876
  ngOnInit() {
2875
2877
  this.gridColumns = this.getGridColumns();
@@ -2884,6 +2886,7 @@ let DocumentGridComponent = class DocumentGridComponent {
2884
2886
  {
2885
2887
  label: this.translate.instant("yms.int.wms_add_document_invoice_key"),
2886
2888
  command: () => {
2889
+ this.selection = [];
2887
2890
  this.visibleInvoiceKey = true;
2888
2891
  },
2889
2892
  icon: "fa fa-search"
@@ -2891,6 +2894,7 @@ let DocumentGridComponent = class DocumentGridComponent {
2891
2894
  {
2892
2895
  label: this.translate.instant("yms.int.wms_add_document_register"),
2893
2896
  command: () => {
2897
+ this.selection = [];
2894
2898
  this.edit = true;
2895
2899
  this.visibleDocumentRegister = true;
2896
2900
  },
@@ -2901,8 +2905,8 @@ let DocumentGridComponent = class DocumentGridComponent {
2901
2905
  getProp(obj, path) {
2902
2906
  return path.split(".").reduce((result, prop) => (result[prop] === undefined ? "" : result[prop]), obj);
2903
2907
  }
2904
- view(selection) {
2905
- this.viewDocument.emit(selection);
2908
+ view() {
2909
+ this.viewDocument.emit(this.selection[0]);
2906
2910
  this.visibleDocumentRegister = true;
2907
2911
  this.edit = false;
2908
2912
  }
@@ -2921,30 +2925,51 @@ let DocumentGridComponent = class DocumentGridComponent {
2921
2925
  });
2922
2926
  }
2923
2927
  }
2924
- onDelete(selection) {
2925
- if (!selection.id) {
2926
- return;
2927
- }
2928
- this.documentService.delete(selection.id)
2929
- .pipe(takeUntil(this.ngUnsubscribe), finalize(() => {
2930
- this.gridData = [];
2931
- this.listDocuments();
2932
- })).
2933
- subscribe(() => this.message("success", "deleted_message_title", "deleted_message_content"));
2928
+ onDelete() {
2929
+ this.confirmationService.confirm({
2930
+ message: this.translate.instant("delete_confirmation_message"),
2931
+ header: this.translate.instant("delete_confirmation_title"),
2932
+ accept: () => {
2933
+ this.removeDocumentIfIdUndfined();
2934
+ if (this.selection.length < 1) {
2935
+ return empty();
2936
+ }
2937
+ return forkJoin(this.selection.map(document => this.documentService.delete(document.id)))
2938
+ .pipe(takeUntil(this.ngUnsubscribe))
2939
+ .subscribe(() => {
2940
+ this.messageService.add({
2941
+ severity: "success",
2942
+ summary: this.translate.instant("deleted_message_title"),
2943
+ detail: this.translate.instant("deleted_message_content"),
2944
+ });
2945
+ this.gridData = [];
2946
+ this.listDocuments();
2947
+ });
2948
+ }
2949
+ });
2950
+ }
2951
+ removeDocumentIfIdUndfined() {
2952
+ this.selection.forEach((value, index) => {
2953
+ if (!value.id) {
2954
+ this.gridData.splice(index, 1);
2955
+ this.selection.splice(index, 1);
2956
+ }
2957
+ });
2934
2958
  }
2935
2959
  listDocuments() {
2936
2960
  this.documentService.list({
2937
2961
  filterQuery: `schedulingId eq '${this.agenda.id}'`
2938
2962
  })
2939
2963
  .subscribe((contents) => {
2964
+ this.gridData = [];
2940
2965
  if (contents.totalElements > 0) {
2941
2966
  this.gridData = contents.contents;
2942
2967
  this.documentTotalRecords = contents.totalElements;
2943
2968
  }
2944
2969
  else {
2945
- this.disabled = true;
2946
2970
  this.documentTotalRecords = this.gridData.length;
2947
2971
  }
2972
+ this.disabled = true;
2948
2973
  this.loading = false;
2949
2974
  });
2950
2975
  }
@@ -2957,7 +2982,7 @@ let DocumentGridComponent = class DocumentGridComponent {
2957
2982
  { field: "invoiceSerialNumber", header: this.translate.instant("yms.int.wms_register_document_invoice_serial_number") },
2958
2983
  { field: "ownerName", header: this.translate.instant("yms.int.wms_register_document_owner_name") },
2959
2984
  { field: "ownerDocument", header: this.translate.instant("yms.int.wms_register_document_owner_document") },
2960
- { field: "orderReceivingCode", header: this.translate.instant("yms.int.wms_register_document_order_receiving_code") },
2985
+ { field: "code", header: this.translate.instant("yms.int.wms_register_document_order_receiving_code") },
2961
2986
  ];
2962
2987
  }
2963
2988
  message(severity, summary, detail) {
@@ -3011,12 +3036,13 @@ __decorate([
3011
3036
  DocumentGridComponent = __decorate([
3012
3037
  Component({
3013
3038
  selector: 'document-grid',
3014
- template: "<p-panel>\n <p-header>\n <div class=\"buttons\">\n <div>\n <s-button\n label=\"{{'yms.int.wms_add_document' | translate}}\"\n priority=\"primary\"\n [model]=\"getActions()\"\n [auxiliary]=\"false\">\n </s-button>\n <s-button\n label=\"{{'yms.wms_view_button' | translate}}\"\n priority=\"secondary\"\n [auxiliary]=\"false\"\n [disabled]=\"!selection || disabled\"\n (onClick)=\"view(selection)\">\n </s-button>\n <s-button\n label=\"{{'yms.wms_delete_button' | translate}}\"\n priority=\"secondary\"\n [auxiliary]=\"false\"\n [disabled]=\"!selection || disabled\"\n (click)=\"onDelete(selection)\">\n </s-button>\n </div>\n <s-button\n id=\"refresh-button\"\n priority=\"default\"\n iconClass=\"fa fa-refresh\"\n (onClick)=\"listDocuments()\"\n >\n </s-button>\n </div>\n </p-header>\n <div class=\"ui-g\">\n <div class=\"ui-g-12\" *ngIf=\"gridData && gridData.length; else emptyList\">\n <p-table #documentTable [value]=\"gridData\"\n [columns]=\"gridColumns\" dataKey=\"id\" [lazy]=\"true\" [scrollable]=\"true\" [resizableColumns]=\"true\"\n sortMode=\"single\" [paginator]=\"true\" [totalRecords]=\"documentTotalRecords\" rows=\"10\"\n [rowsPerPageOptions]=\"[10, 20, 50, 100]\" [(selection)]=\"selection\"\n [loading]=\"loading\">\n <ng-template pTemplate=\"colgroup\" let-columns>\n <colgroup>\n <col *ngFor=\"let col of columns\" [style.width]=\"col.width\"/>\n </colgroup>\n </ng-template>\n <ng-template pTemplate=\"header\" let-columns>\n <tr>\n <th id=\"col\" *ngFor=\"let col of columns\" [pSortableColumn]=\"col.field\" pResizableColumn>\n <div class=\"senior-header\">\n <span class=\"senior-header-title\">{{ col.header }}</span>\n <p-sortIcon [field]=\"col.field\"></p-sortIcon>\n </div>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\" let-rowData let-columns let-expanded=\"expanded\">\n <tr [pSelectableRow]=\"rowData\">\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"logistcUnitName\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"logistcUnitDocument\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"invoiceKey\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"invoiceNumber\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"invoiceSerialNumber\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"ownerName\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"ownerDocument\"] }}</span>\n </td>\n <td (click)=\"selection = rowData\">\n <span>{{ rowData[\"orderReceivingCode\"] }}</span>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"paginatorright\">\n <span [translate]=\"'total_records'\" [translateParams]=\"{ value: documentTotalRecords }\"></span>\n </ng-template>\n </p-table> \n </div>\n </div>\n <register-document\n [edit]=\"edit\"\n [viewDocument]=\"selection\"\n (document)=\"onChangeDocument($event)\"\n [(visible)]=\"visibleDocumentRegister\"\n [agenda]=\"agenda\">\n </register-document>\n <insert-key (document)=\"onChangeDocument($event)\" [(visible)]=\"visibleInvoiceKey\"></insert-key>\n</p-panel>\n<div class=\"button-save\">\n <s-button \n priority=\"primary\" [label]=\"'save' | translate\" [disabled]=\"!disabled || !this.gridData\" (click)=\"save()\">\n </s-button>\n</div>\n\n\n<ng-template #emptyList>\n <div class=\"center\">\n <s-empty-state\n iconClass=\"fa fa-exclamation-triangle\" [title]=\"'yms.dock.area_dock_empty_state_title' | translate\"\n [description]=\"'yms.dock.area_dock_empty_state_description' | translate\">\n </s-empty-state>\n </div>\n</ng-template>\n",
3015
- styles: [".buttons{display:flex;justify-content:space-between}.center{flex-direction:column;text-align:center}.ui-g{display:block}.button-save{margin:5px 0}#refresh-button{color:#fff}"]
3039
+ template: "<p-panel>\n <p-header>\n <div class=\"buttons\">\n <div>\n <s-button\n label=\"{{'yms.int.wms_add_document' | translate}}\"\n priority=\"primary\"\n [model]=\"getActions()\"\n [auxiliary]=\"false\">\n </s-button>\n <s-button\n label=\"{{'yms.wms_view_button' | translate}}\"\n priority=\"secondary\"\n [auxiliary]=\"false\"\n [disabled]=\"!selection || selection.length !== 1\"\n (onClick)=\"view()\">\n </s-button>\n <s-button\n label=\"{{'yms.wms_delete_button' | translate}}\"\n priority=\"secondary\"\n [disabled]=\"!selection || !selection.length\"\n (click)=\"onDelete()\">\n </s-button>\n </div>\n <s-button\n id=\"refresh-button\"\n priority=\"default\"\n iconClass=\"fa fa-refresh\"\n (onClick)=\"listDocuments()\"\n >\n </s-button>\n </div>\n </p-header>\n <div class=\"ui-g\">\n <div class=\"ui-g-12\" *ngIf=\"gridData && gridData.length; else emptyList\">\n <p-table #documentTable [value]=\"gridData\"\n [columns]=\"gridColumns\" dataKey=\"id\" [lazy]=\"true\" [scrollable]=\"true\" [resizableColumns]=\"true\"\n sortMode=\"multiple\" [paginator]=\"true\" [totalRecords]=\"documentTotalRecords\" rows=\"10\"\n [rowsPerPageOptions]=\"[10, 20, 50, 100]\" [(selection)]=\"selection\"\n [loading]=\"loading\">\n <ng-template pTemplate=\"colgroup\" let-columns>\n <colgroup>\n <col *ngFor=\"let col of columns\" [style.width]=\"col.width\"/>\n </colgroup>\n </ng-template>\n <ng-template pTemplate=\"header\" let-columns>\n <tr>\n <th id=\"checkbox\" class=\"table-checkbox\">\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\n </th>\n <th id=\"col\" *ngFor=\"let col of columns\" [pSortableColumn]=\"col.field\" pResizableColumn>\n <div class=\"senior-header\">\n <span class=\"senior-header-title\">{{ col.header }}</span>\n <p-sortIcon [field]=\"col.field\"></p-sortIcon>\n </div>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\" let-rowData let-columns let-expanded=\"expanded\">\n <tr [pSelectableRow]=\"rowData\">\n <td class=\"table-checkbox\">\n <p-tableCheckbox [value]=\"rowData\"></p-tableCheckbox>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"logistcUnitName\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"logistcUnitDocument\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"invoiceKey\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"invoiceNumber\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"invoiceSerialNumber\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"ownerName\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"ownerDocument\"] }}</span>\n </td>\n <td (click)=\"selection = [rowData]\">\n <span>{{ rowData[\"code\"] }}</span>\n </td>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"paginatorright\">\n <span [translate]=\"'total_records'\" [translateParams]=\"{ value: documentTotalRecords }\"></span>\n </ng-template>\n </p-table> \n </div>\n </div>\n <register-document\n [edit]=\"edit\"\n [viewDocument]=\"selection\"\n (document)=\"onChangeDocument($event)\"\n [(visible)]=\"visibleDocumentRegister\"\n [agenda]=\"agenda\">\n </register-document>\n <insert-key (document)=\"onChangeDocument($event)\" [(visible)]=\"visibleInvoiceKey\"></insert-key>\n</p-panel>\n<div class=\"button-save\">\n <s-button \n priority=\"primary\" [label]=\"'save' | translate\" [disabled]=\"disabled || !this.gridData\" (click)=\"save()\">\n </s-button>\n</div>\n\n\n<ng-template #emptyList>\n <div class=\"center\">\n <s-empty-state\n iconClass=\"fa fa-exclamation-triangle\" [title]=\"'detail_empty_state_title' | translate\"\n [description]=\"'detail_empty_state_description' | translate\">\n </s-empty-state>\n </div>\n</ng-template>\n",
3040
+ styles: [".buttons{display:flex;justify-content:space-between}.center{flex-direction:column;text-align:center}.ui-g{display:block}.button-save{margin:5px 0}#refresh-button{color:#fff}.table-checkbox{width:50px}"]
3016
3041
  }),
3017
3042
  __metadata("design:paramtypes", [TranslateService,
3018
3043
  DocumentService,
3019
- MessageService])
3044
+ MessageService,
3045
+ ConfirmationService])
3020
3046
  ], DocumentGridComponent);
3021
3047
 
3022
3048
  const moment$4 = _moment;
@@ -3040,7 +3066,7 @@ class Document {
3040
3066
  "partnerName",
3041
3067
  "partnerDocument",
3042
3068
  "notes",
3043
- "orderReceivingCode",
3069
+ "code",
3044
3070
  "createdBy",
3045
3071
  "createdDate",
3046
3072
  "lastModifiedBy",
@@ -3184,15 +3210,20 @@ let RegisterDocumentComponent = class RegisterDocumentComponent {
3184
3210
  visibilityConfig() {
3185
3211
  if (!this.edit && this.visible) {
3186
3212
  this.formGroup.disable();
3187
- this.setValuesFormGroup(this.viewDocument);
3213
+ this.setValuesFormGroup(this.viewDocument[0]);
3188
3214
  this.setValueForPartner();
3189
3215
  this.hideSaveButton = true;
3190
3216
  return this.visible;
3191
3217
  }
3192
- return this.visible;
3218
+ if (this.formGroup !== undefined) {
3219
+ this.formGroup.enable();
3220
+ this.setValueForPartner();
3221
+ this.hideSaveButton = false;
3222
+ }
3193
3223
  }
3194
3224
  close() {
3195
3225
  this.visibleChange.emit(false);
3226
+ this.formGroup.reset();
3196
3227
  }
3197
3228
  setValuesFormGroup(document) {
3198
3229
  this.formGroup.get('invoiceKey').setValue(document.invoiceKey);
@@ -3201,7 +3232,7 @@ let RegisterDocumentComponent = class RegisterDocumentComponent {
3201
3232
  this.formGroup.get('logistcUnitDocument').setValue(document.logistcUnitDocument);
3202
3233
  this.formGroup.get('logistcUnitName').setValue(document.logistcUnitName);
3203
3234
  this.formGroup.get('notes').setValue(document.notes);
3204
- this.formGroup.get('orderReceivingCode').setValue(document.orderReceivingCode);
3235
+ this.formGroup.get('code').setValue(document.code);
3205
3236
  this.formGroup.get('ownerDocument').setValue(document.ownerDocument);
3206
3237
  this.formGroup.get('ownerName').setValue(document.ownerName);
3207
3238
  }
@@ -3224,7 +3255,7 @@ let RegisterDocumentComponent = class RegisterDocumentComponent {
3224
3255
  partnerName: [undefined],
3225
3256
  partnerDocument: [undefined],
3226
3257
  notes: [undefined],
3227
- orderReceivingCode: [undefined],
3258
+ code: [undefined],
3228
3259
  });
3229
3260
  }
3230
3261
  save() {
@@ -3241,14 +3272,14 @@ let RegisterDocumentComponent = class RegisterDocumentComponent {
3241
3272
  successMessage() {
3242
3273
  this.messageService.add({
3243
3274
  severity: "success",
3244
- summary: this.translateService.instant("saved_message_title"),
3245
- detail: this.translateService.instant("saved_message_content"),
3275
+ summary: this.translateService.instant("yms.saved_message_title"),
3276
+ detail: this.translateService.instant("yms.int.wms_success_message_description"),
3246
3277
  });
3247
3278
  }
3248
3279
  };
3249
3280
  __decorate([
3250
3281
  Input(),
3251
- __metadata("design:type", Document)
3282
+ __metadata("design:type", Array)
3252
3283
  ], RegisterDocumentComponent.prototype, "viewDocument", void 0);
3253
3284
  __decorate([
3254
3285
  Input(),
@@ -3273,7 +3304,7 @@ __decorate([
3273
3304
  RegisterDocumentComponent = __decorate([
3274
3305
  Component({
3275
3306
  selector: "register-document",
3276
- template: "<s-sidebar\n [visible]=\"visible\"\n header=\"{{ 'yms.int.wms_register_document_add_document' | translate }}\"\n (visibleChange)=\"close()\">\n <form [formGroup]=\"formGroup\">\n <div class=\"ui-g ui-fluid\">\n <div class=\"ui-g-6 required\">\n <label for=\"invoiceKey\">{{'yms.int.wms_register_document_invoice_key' | translate}}</label>\n <input id=\"invoiceKey\" pInputText type=\"text\" formControlName=\"invoiceKey\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"invoiceNumber\">{{'yms.int.wms_register_document_invoice_number' | translate}}</label>\n <input id=\"invoiceNumber\" pInputText type=\"text\" formControlName=\"invoiceNumber\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"invoiceSerialNumber\">\n {{'yms.int.wms_register_document_invoice_serial_number' | translate}}\n </label>\n <input id=\"invoiceSerialNumber\" pInputText type=\"text\" formControlName=\"invoiceSerialNumber\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"logistcUnitName\">{{'yms.int.wms_register_document_logistc_unit_name' | translate}}</label>\n <input id=\"logistcUnitName\" pInputText type=\"text\" formControlName=\"logistcUnitName\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"logistcUnitDocument\">\n {{'yms.int.wms_register_document_logistc_unit_document' | translate}}\n </label>\n <input id=\"logistcUnitDocument\" pInputText type=\"text\" formControlName=\"logistcUnitDocument\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"documentOwnerName\">{{'yms.int.wms_register_document_owner_name' | translate}}</label>\n <input id=\"documentOwnerName\" pInputText type=\"text\" formControlName=\"ownerName\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"ownerDocument\">{{'yms.int.wms_register_document_owner_document' | translate}}</label>\n <input id=\"ownerDocument\" pInputText type=\"text\" formControlName=\"ownerDocument\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"partnerName\">{{'yms.int.wms_register_document_partner_name' | translate}}</label>\n <input id=\"partnerName\" pInputText type=\"text\" formControlName=\"partnerName\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"partnerDocument\">{{'yms.int.wms_register_document_partner_document' | translate}}</label>\n <input id=\"partnerDocument\" pInputText type=\"text\" formControlName=\"partnerDocument\">\n </div>\n <div class=\"ui-g-12\">\n <label for=\"notes\" id=\"notes\">{{'yms.int.wms_register_document_notes' | translate}}</label>\n <textarea id=\"notes\" rows=\"5\" pInputTextarea autoResize=\"autoResize\" formControlName=\"notes\"></textarea>\n </div>\n <div class=\"ui-g-6\">\n <label for=\"orderReceivingCode\">\n {{'yms.int.wms_register_document_order_receiving_code' | translate}}\n </label>\n <input id=\"orderReceivingCode\" pInputText type=\"text\" formControlName=\"orderReceivingCode\">\n </div>\n </div>\n </form>\n <div class=\"space-between\">\n <button\n pButton label=\"{{'save' | translate}}\" (click)=\"save()\" [attr.data-hidden]=\"hideSaveButton\">\n </button>\n <button\n type=\"button\" class=\"ui-button-link\" pButton label=\"{{'cancel' | translate}}\" (click)=\"close()\">\n </button>\n </div>\n</s-sidebar>"
3307
+ template: "<s-sidebar\n [visible]=\"visible\"\n header=\"{{ 'yms.int.wms_register_document_add_document' | translate }}\"\n (visibleChange)=\"close()\">\n <form [formGroup]=\"formGroup\">\n <div class=\"ui-g ui-fluid\">\n <div class=\"ui-g-6 required\">\n <label for=\"invoiceKey\">{{'yms.int.wms_register_document_invoice_key' | translate}}</label>\n <input id=\"invoiceKey\" pInputText type=\"text\" formControlName=\"invoiceKey\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"invoiceNumber\">{{'yms.int.wms_register_document_invoice_number' | translate}}</label>\n <input id=\"invoiceNumber\" pInputText type=\"text\" formControlName=\"invoiceNumber\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"invoiceSerialNumber\">\n {{'yms.int.wms_register_document_invoice_serial_number' | translate}}\n </label>\n <input id=\"invoiceSerialNumber\" pInputText type=\"text\" formControlName=\"invoiceSerialNumber\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"logistcUnitName\">{{'yms.int.wms_register_document_logistc_unit_name' | translate}}</label>\n <input id=\"logistcUnitName\" pInputText type=\"text\" formControlName=\"logistcUnitName\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"logistcUnitDocument\">\n {{'yms.int.wms_register_document_logistc_unit_document' | translate}}\n </label>\n <input id=\"logistcUnitDocument\" pInputText type=\"text\" formControlName=\"logistcUnitDocument\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"documentOwnerName\">{{'yms.int.wms_register_document_owner_name' | translate}}</label>\n <input id=\"documentOwnerName\" pInputText type=\"text\" formControlName=\"ownerName\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"ownerDocument\">{{'yms.int.wms_register_document_owner_document' | translate}}</label>\n <input id=\"ownerDocument\" pInputText type=\"text\" formControlName=\"ownerDocument\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"partnerName\">{{'yms.int.wms_register_document_partner_name' | translate}}</label>\n <input id=\"partnerName\" pInputText type=\"text\" formControlName=\"partnerName\">\n </div>\n <div class=\"ui-g-6\">\n <label for=\"partnerDocument\">{{'yms.int.wms_register_document_partner_document' | translate}}</label>\n <input id=\"partnerDocument\" pInputText type=\"text\" formControlName=\"partnerDocument\">\n </div>\n <div class=\"ui-g-12\">\n <label for=\"notes\" id=\"notes\">{{'yms.int.wms_register_document_notes' | translate}}</label>\n <textarea id=\"notes\" rows=\"5\" pInputTextarea autoResize=\"autoResize\" formControlName=\"notes\"></textarea>\n </div>\n <div class=\"ui-g-6\">\n <label for=\"code\">\n {{'yms.int.wms_register_document_order_receiving_code' | translate}}\n </label>\n <input id=\"code\" pInputText type=\"text\" formControlName=\"code\">\n </div>\n </div>\n </form>\n <div class=\"space-between\">\n <button\n pButton label=\"{{'save' | translate}}\" (click)=\"save()\" [attr.data-hidden]=\"hideSaveButton\">\n </button>\n <button\n type=\"button\" class=\"ui-button-link\" pButton label=\"{{'cancel' | translate}}\" (click)=\"close()\">\n </button>\n </div>\n</s-sidebar>"
3277
3308
  }),
3278
3309
  __metadata("design:paramtypes", [FormBuilder,
3279
3310
  MessageService,
@@ -3339,7 +3370,7 @@ let InsertKeyComponent = class InsertKeyComponent {
3339
3370
  return;
3340
3371
  }
3341
3372
  this.document.emit(content.contents[0]);
3342
- this.message("success", "yms.int.wms_insert_key_success_message_header", "yms.int.wms_insert_key_success_message_description");
3373
+ this.message("success", "yms.int.wms_insert_key_success_message_header", "yms.int.wms_success_message_description");
3343
3374
  this.formGroup.reset();
3344
3375
  });
3345
3376
  }
@@ -3369,7 +3400,7 @@ __decorate([
3369
3400
  InsertKeyComponent = __decorate([
3370
3401
  Component({
3371
3402
  selector: "insert-key",
3372
- template: "<form [formGroup]=\"formGroup\">\n <p-dialog [(visible)]=\"visible\" (visibleChange)=\"cancel()\">\n <p-header>{{'yms.insert_key_header' | translate}}</p-header>\n <div class=\"flex py-2 justify-content-center spacing-bottom\">\n <label for=\"key\">{{'yms.insert_key_label'}}</label>\n <input id=\"key\" class=\"size-input\" pInputText type=\"text\" formControlName=\"key\">\n </div>\n <div class=\"separator\"></div>\n <div class=\"spacing-top\">\n <s-button pButton label=\"{{'save' | translate}}\" (click)=\"add()\"></s-button>\n <s-button\n type=\"button\"\n class=\"ui-button-link\"\n pButton label=\"{{'cancel' | translate}}\"\n (click)=\"cancel()\">\n </s-button>\n </div>\n </p-dialog>\n</form>",
3403
+ template: "<form [formGroup]=\"formGroup\">\n <p-dialog [(visible)]=\"visible\" [modal]=\"true\" (visibleChange)=\"cancel()\">\n <p-header>{{'yms.int.wms_insert_key_header' | translate}}</p-header>\n <div class=\"flex py-2 justify-content-center spacing-bottom\">\n <label for=\"key\">{{'yms.int.wms_insert_key_label' | translate}}</label>\n <input id=\"key\" class=\"size-input\" pInputText type=\"text\" formControlName=\"key\">\n </div>\n <div class=\"separator\"></div>\n <div class=\"spacing-top\">\n <s-button pButton label=\"{{'save' | translate}}\" (click)=\"add()\"></s-button>\n <s-button\n type=\"button\"\n class=\"ui-button-link\"\n pButton label=\"{{'cancel' | translate}}\"\n (click)=\"cancel()\">\n </s-button>\n </div>\n </p-dialog>\n</form>",
3373
3404
  styles: [".spacing-top{margin-top:10px}.spacing-bottom{margin-bottom:10px}.separator{width:100%;margin:5px 0;height:1px;background-color:#ccc}.size-input{width:550px}"]
3374
3405
  }),
3375
3406
  __metadata("design:paramtypes", [FormBuilder,