@c8y/ngx-components 1010.0.31 → 1010.0.35

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 (61) hide show
  1. package/bundles/c8y-ngx-components-operations-bulk-operations-list.umd.js +18 -10
  2. package/bundles/c8y-ngx-components-operations-bulk-operations-list.umd.js.map +1 -1
  3. package/bundles/c8y-ngx-components-operations-bulk-operations-list.umd.min.js +1 -1
  4. package/bundles/c8y-ngx-components-operations-bulk-operations-list.umd.min.js.map +1 -1
  5. package/bundles/c8y-ngx-components-repository.umd.js +8 -4
  6. package/bundles/c8y-ngx-components-repository.umd.js.map +1 -1
  7. package/bundles/c8y-ngx-components-repository.umd.min.js +1 -1
  8. package/bundles/c8y-ngx-components-repository.umd.min.js.map +1 -1
  9. package/bundles/c8y-ngx-components-sensor-phone.umd.js +1 -1
  10. package/bundles/c8y-ngx-components-sensor-phone.umd.js.map +1 -1
  11. package/bundles/c8y-ngx-components-sensor-phone.umd.min.js +1 -1
  12. package/bundles/c8y-ngx-components-sensor-phone.umd.min.js.map +1 -1
  13. package/bundles/c8y-ngx-components.umd.js +14 -8
  14. package/bundles/c8y-ngx-components.umd.js.map +1 -1
  15. package/bundles/c8y-ngx-components.umd.min.js +1 -1
  16. package/bundles/c8y-ngx-components.umd.min.js.map +1 -1
  17. package/c8y-ngx-components.metadata.json +1 -1
  18. package/core/file-picker/file-picker.component.d.ts +8 -0
  19. package/esm2015/core/file-picker/file-picker.component.js +12 -2
  20. package/esm2015/core/file-picker/file-picker.module.js +6 -8
  21. package/esm2015/operations/bulk-operations-list/bulk-operation-list-item.component.js +4 -3
  22. package/esm2015/operations/bulk-operations-list/bulk-operation-list-item.model.js +16 -9
  23. package/esm2015/repository/configuration/configuration-detail.component.js +7 -2
  24. package/esm2015/repository/firmware/add-firmware-modal.component.js +7 -2
  25. package/esm2015/repository/firmware/add-firmware-patch-modal.component.js +7 -2
  26. package/esm2015/repository/software/add-software-modal.component.js +7 -2
  27. package/esm2015/sensor-phone/sensor-phone-modal.component.js +2 -2
  28. package/esm5/core/file-picker/file-picker.component.js +12 -2
  29. package/esm5/core/file-picker/file-picker.module.js +6 -8
  30. package/esm5/operations/bulk-operations-list/bulk-operation-list-item.component.js +5 -4
  31. package/esm5/operations/bulk-operations-list/bulk-operation-list-item.model.js +16 -9
  32. package/esm5/repository/configuration/configuration-detail.component.js +3 -2
  33. package/esm5/repository/firmware/add-firmware-modal.component.js +3 -2
  34. package/esm5/repository/firmware/add-firmware-patch-modal.component.js +3 -2
  35. package/esm5/repository/software/add-software-modal.component.js +3 -2
  36. package/esm5/sensor-phone/sensor-phone-modal.component.js +2 -2
  37. package/fesm2015/c8y-ngx-components-operations-bulk-operations-list.js +17 -9
  38. package/fesm2015/c8y-ngx-components-operations-bulk-operations-list.js.map +1 -1
  39. package/fesm2015/c8y-ngx-components-repository.js +24 -4
  40. package/fesm2015/c8y-ngx-components-repository.js.map +1 -1
  41. package/fesm2015/c8y-ngx-components-sensor-phone.js +1 -1
  42. package/fesm2015/c8y-ngx-components-sensor-phone.js.map +1 -1
  43. package/fesm2015/c8y-ngx-components.js +14 -8
  44. package/fesm2015/c8y-ngx-components.js.map +1 -1
  45. package/fesm5/c8y-ngx-components-operations-bulk-operations-list.js +18 -10
  46. package/fesm5/c8y-ngx-components-operations-bulk-operations-list.js.map +1 -1
  47. package/fesm5/c8y-ngx-components-repository.js +8 -4
  48. package/fesm5/c8y-ngx-components-repository.js.map +1 -1
  49. package/fesm5/c8y-ngx-components-sensor-phone.js +1 -1
  50. package/fesm5/c8y-ngx-components-sensor-phone.js.map +1 -1
  51. package/fesm5/c8y-ngx-components.js +14 -8
  52. package/fesm5/c8y-ngx-components.js.map +1 -1
  53. package/locales/locales.pot +33 -9
  54. package/operations/bulk-operations-list/bulk-operation-list-item.model.d.ts +2 -0
  55. package/package.json +2 -2
  56. package/repository/c8y-ngx-components-repository.metadata.json +1 -1
  57. package/repository/configuration/configuration-detail.component.d.ts +1 -0
  58. package/repository/firmware/add-firmware-modal.component.d.ts +1 -0
  59. package/repository/firmware/add-firmware-patch-modal.component.d.ts +1 -0
  60. package/repository/software/add-software-modal.component.d.ts +1 -0
  61. package/sensor-phone/c8y-ngx-components-sensor-phone.metadata.json +1 -1
@@ -177,38 +177,45 @@ const BULK_OPERATION_STATUS_LABELS = {
177
177
  EXECUTING: gettext('Executing'),
178
178
  CANCELED: gettext('Canceled'),
179
179
  FAILED: gettext('Completed with failures'),
180
- SUCCESSFUL: gettext('Completed successfully')
180
+ SUCCESSFUL: gettext('Completed successfully'),
181
+ DELETED: gettext('Deleted'),
181
182
  };
182
183
  const BULK_OPERATION_STATUS_OPTIONS = [
183
184
  {
184
185
  label: BULK_OPERATION_STATUS_LABELS.SCHEDULED,
185
186
  generalStatus: [OperationBulkGeneralStatus.SCHEDULED],
186
- iconClass: 'dlt-c8y-icon-calendar text-info'
187
+ iconClass: 'dlt-c8y-icon-calendar text-info',
187
188
  },
188
189
  {
189
190
  label: BULK_OPERATION_STATUS_LABELS.EXECUTING,
190
191
  generalStatus: [
191
192
  OperationBulkGeneralStatus.EXECUTING,
192
- OperationBulkGeneralStatus.EXECUTING_WITH_ERROR
193
+ OperationBulkGeneralStatus.EXECUTING_WITH_ERROR,
193
194
  ],
194
- iconClass: 'dlt-c8y-icon-refresh text-primary'
195
+ iconClass: 'dlt-c8y-icon-refresh text-primary',
196
+ },
197
+ {
198
+ label: BULK_OPERATION_STATUS_LABELS.DELETED,
199
+ generalStatus: [OperationBulkGeneralStatus.DELETED],
200
+ iconClass: 'dlt-c8y-icon-delete-document text-muted',
195
201
  },
196
202
  {
197
203
  label: BULK_OPERATION_STATUS_LABELS.CANCELED,
198
204
  generalStatus: [OperationBulkGeneralStatus.CANCELED],
199
- iconClass: 'dlt-c8y-icon-ban text-muted'
205
+ iconClass: 'dlt-c8y-icon-ban text-muted',
200
206
  },
201
207
  {
202
208
  label: BULK_OPERATION_STATUS_LABELS.FAILED,
203
209
  generalStatus: [OperationBulkGeneralStatus.FAILED],
204
- iconClass: 'dlt-c8y-icon-exclamation-triangle text-danger'
210
+ iconClass: 'dlt-c8y-icon-exclamation-triangle text-danger',
205
211
  },
206
212
  {
207
213
  label: BULK_OPERATION_STATUS_LABELS.SUCCESSFUL,
208
214
  generalStatus: [OperationBulkGeneralStatus.SUCCESSFUL],
209
- iconClass: 'dlt-c8y-icon-check-circle text-success'
210
- }
215
+ iconClass: 'dlt-c8y-icon-check-circle text-success',
216
+ },
211
217
  ];
218
+ const BULK_OPERATION_FALLBACK_STATUS_ICON = 'dlt-c8y-icon-ask-question text-muted';
212
219
 
213
220
  let BulkOperationListItemComponent = class BulkOperationListItemComponent {
214
221
  constructor(bulkOperationsService, modal, alert, bsModalService) {
@@ -239,7 +246,8 @@ let BulkOperationListItemComponent = class BulkOperationListItemComponent {
239
246
  }
240
247
  }
241
248
  getIconClass() {
242
- return this.bulkOperationStatusOptions.find(statusOption => statusOption.generalStatus.includes(this.bulkOperation.generalStatus)).iconClass;
249
+ const statusOptions = this.bulkOperationStatusOptions.find(statusOption => statusOption.generalStatus.includes(this.bulkOperation.generalStatus));
250
+ return statusOptions ? statusOptions.iconClass : BULK_OPERATION_FALLBACK_STATUS_ICON;
243
251
  }
244
252
  calculateFinishDateMs() {
245
253
  const startDateMs = new Date(this.bulkOperation.startDate).getTime();
@@ -1 +1 @@
1
- {"version":3,"file":"c8y-ngx-components-operations-bulk-operations-list.js","sources":["ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-wrapper.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-details.service.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/modals/bulk-operations-modal.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/modals/bulk-operation-modals.service.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/modals/bulk-operations-reschedule-modal.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-list-item.model.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-list-item.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operations-list.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-details-tabs.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-details.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/single-operation-item.model.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/single-operations-list.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/single-operation-item.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/type-list/bulk-operation-type-list.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operations-list.module.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/c8y-ngx-components-operations-bulk-operations-list.ts"],"sourcesContent":["import { Component, Input } from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { BulkOperationDetailsService } from './bulk-operation-details.service';\n\n@Component({\n selector: 'c8y-bulk-operations-wrapper',\n templateUrl: './bulk-operation-wrapper.component.html'\n})\nexport class BulkOperationWrapperComponent {\n @Input() bulkOperation: Partial<IOperationBulk>;\n\n constructor(\n public bulkOperationDetailsService: BulkOperationDetailsService,\n public modalRef: BsModalRef\n ) {}\n}\n","import { Injectable } from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { BsModalService } from 'ngx-bootstrap/modal';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { BulkOperationWrapperComponent } from './bulk-operation-wrapper.component';\n\n@Injectable()\nexport class BulkOperationDetailsService {\n constructor(\n private bulkOperationsService: BulkOperationsService,\n private modalService: BsModalService\n ) {}\n\n async openDetails(bulkOperationId) {\n const bulkOperation: IOperationBulk = (await this.bulkOperationsService.getBulkOperationById(\n bulkOperationId\n )).data;\n const initialState = { bulkOperation };\n this.modalService.show(BulkOperationWrapperComponent, {\n initialState,\n class: 'modal-lg'\n });\n }\n}\n","import { Component, ViewContainerRef, ViewChild, ComponentFactoryResolver } from '@angular/core';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { OperationType } from '@c8y/ngx-components/operations/bulk-operations-service';\n\n@Component({\n selector: 'c8y-bulk-operations-modal',\n templateUrl: 'bulk-operations-modal.component.html'\n})\nexport class BulkOperationsModalComponent {\n @ViewChild('container', { static: false, read: ViewContainerRef }) container;\n showComponent: boolean = false;\n constructor(private bsModalRef: BsModalRef, private resolver: ComponentFactoryResolver) {}\n\n cancel() {\n this.bsModalRef.hide();\n }\n\n createComponent(item: OperationType) {\n if (item && item.component) {\n this.showComponent = true;\n const factory = this.resolver.resolveComponentFactory(item.component);\n this.container.createComponent(factory);\n }\n }\n}\n","import { Injectable } from '@angular/core';\nimport { BsModalRef, BsModalService } from 'ngx-bootstrap/modal';\nimport { BulkOperationsModalComponent } from './bulk-operations-modal.component';\n\n@Injectable()\nexport class BulkOperationModalsService {\n private bsModalRef: BsModalRef;\n\n constructor(private bsModalService: BsModalService) {}\n\n showNewBulkOperationModal() {\n this.bsModalRef = this.bsModalService.show(BulkOperationsModalComponent, {\n backdrop: 'static',\n class: 'modal-sm'\n });\n }\n\n hideNewBulkOperationModal() {\n if (this.bsModalRef) {\n this.bsModalRef.hide();\n }\n }\n}\n","import { Component, OnInit } from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { AlertService, gettext } from '@c8y/ngx-components';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { Subject } from 'rxjs';\nimport { OperationSchedule } from '@c8y/ngx-components/operations/bulk-operation-scheduler';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\n\n@Component({\n selector: 'c8y-bulk-operations-reschedule-modal',\n templateUrl: 'bulk-operations-reschedule-modal.component.html'\n})\nexport class BulkOperationsRescheduleModalComponent implements OnInit {\n closeSubject: Subject<IOperationBulk> = new Subject();\n dateAndDelay: OperationSchedule;\n bulkOperation: Partial<IOperationBulk>;\n isRetryOperation: boolean;\n modalTitle: string;\n\n constructor(\n public bsModalRef: BsModalRef,\n private bulkOperationsService: BulkOperationsService,\n private alert: AlertService\n ) {}\n\n ngOnInit() {\n this.modalTitle = this.getTitle();\n }\n\n onDateAndDelaySelect($event) {\n this.dateAndDelay = $event;\n }\n\n getTitle() {\n return this.isRetryOperation ? gettext('Retry operation') : gettext('Edit schedule');\n }\n\n onCancel() {\n this.bsModalRef.hide();\n }\n\n async onSave() {\n let newBulkOperation;\n this.bulkOperation.startDate = this.dateAndDelay.scheduledDate.toISOString();\n this.bulkOperation.creationRamp = this.dateAndDelay.delayInSeconds;\n\n if (this.isRetryOperation) {\n try {\n newBulkOperation = await this.bulkOperationsService.createBulkOperation(this.bulkOperation);\n this.alert.success(gettext('Successfully rescheduled for a retry.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n } else {\n try {\n newBulkOperation = await this.bulkOperationsService.updateBulkOperation(this.bulkOperation);\n this.alert.success(gettext('Successfully rescheduled.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n }\n\n // send back to component from which modal was called\n this.closeSubject.next(newBulkOperation.data);\n this.bsModalRef.hide();\n }\n}\n","import { OperationBulkGeneralStatus } from '@c8y/client';\nimport { gettext } from '@c8y/ngx-components';\nimport { IStatusOption } from '@c8y/ngx-components/operations/status-filter';\n\nexport const BULK_OPERATION_STATUS_LABELS = {\n SCHEDULED: gettext('Scheduled'),\n EXECUTING: gettext('Executing'),\n CANCELED: gettext('Canceled'),\n FAILED: gettext('Completed with failures'),\n SUCCESSFUL: gettext('Completed successfully')\n};\n\nexport const BULK_OPERATION_STATUS_OPTIONS: IStatusOption[] = [\n {\n label: BULK_OPERATION_STATUS_LABELS.SCHEDULED,\n generalStatus: [OperationBulkGeneralStatus.SCHEDULED],\n iconClass: 'dlt-c8y-icon-calendar text-info'\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.EXECUTING,\n generalStatus: [\n OperationBulkGeneralStatus.EXECUTING,\n OperationBulkGeneralStatus.EXECUTING_WITH_ERROR\n ],\n iconClass: 'dlt-c8y-icon-refresh text-primary'\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.CANCELED,\n generalStatus: [OperationBulkGeneralStatus.CANCELED],\n iconClass: 'dlt-c8y-icon-ban text-muted'\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.FAILED,\n generalStatus: [OperationBulkGeneralStatus.FAILED],\n iconClass: 'dlt-c8y-icon-exclamation-triangle text-danger'\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.SUCCESSFUL,\n generalStatus: [OperationBulkGeneralStatus.SUCCESSFUL],\n iconClass: 'dlt-c8y-icon-check-circle text-success'\n }\n];\n","import {\n Component,\n EventEmitter,\n Input,\n OnChanges,\n OnInit,\n Output,\n SimpleChanges,\n ViewChild\n} from '@angular/core';\nimport { IOperationBulk, OperationBulkGeneralStatus } from '@c8y/client';\nimport {\n AlertService,\n gettext,\n ListItemComponent,\n ModalService,\n Status\n} from '@c8y/ngx-components';\nimport { assign, cloneDeep } from 'lodash-es';\nimport { BsModalRef, BsModalService, ModalOptions } from 'ngx-bootstrap/modal';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { IStatusOption } from '@c8y/ngx-components/operations/status-filter';\nimport { BulkOperationsRescheduleModalComponent } from './modals/bulk-operations-reschedule-modal.component';\nimport { BULK_OPERATION_STATUS_OPTIONS } from './bulk-operation-list-item.model';\n\n@Component({\n selector: 'c8y-bulk-operation-list-item',\n templateUrl: './bulk-operation-list-item.component.html'\n})\nexport class BulkOperationListItemComponent implements OnInit, OnChanges {\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n detailsCollapsed: boolean = true;\n @Input()\n readOnly: boolean = false;\n @Output() showFailedOperation = new EventEmitter();\n @Output() reload: EventEmitter<any> = new EventEmitter();\n @ViewChild('listItem', { static: true }) listItem: ListItemComponent;\n iconClass: string;\n finishDate: number;\n refreshLoading = false;\n bulkOperationGeneralStatus = OperationBulkGeneralStatus;\n bulkOperationStatusOptions: IStatusOption[] = BULK_OPERATION_STATUS_OPTIONS;\n bsModalRef: BsModalRef;\n finishDatePopoverText: string = gettext(\n 'Approximate date, estimated based on the bulk operation settings.'\n );\n progressBarClass: string = 'progress';\n progressBarColor: string;\n progressBarStatus: number = 0;\n\n constructor(\n private bulkOperationsService: BulkOperationsService,\n private modal: ModalService,\n private alert: AlertService,\n private bsModalService: BsModalService\n ) {}\n\n ngOnInit() {\n this.iconClass = this.getIconClass();\n this.finishDate = this.calculateFinishDateMs();\n this.setProgressBar();\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes.bulkOperation && !changes.bulkOperation.firstChange) {\n this.iconClass = this.getIconClass();\n this.setProgressBar();\n }\n }\n\n getIconClass() {\n return this.bulkOperationStatusOptions.find(statusOption =>\n statusOption.generalStatus.includes(this.bulkOperation.generalStatus)\n ).iconClass;\n }\n\n calculateFinishDateMs(): number {\n const startDateMs: number = new Date(this.bulkOperation.startDate).getTime();\n const creationRampMs: number = this.bulkOperation.creationRamp * 1000;\n\n return startDateMs + creationRampMs * this.bulkOperation.progress.all;\n }\n\n progressBarProgressFn() {\n return (\n ((this.bulkOperation.progress.successful + this.bulkOperation.progress.failed) /\n this.bulkOperation.progress.all) *\n 100\n );\n }\n\n setProgressBar() {\n const staticContentOfClass = 'progress-bar progress-striped active progress-bar';\n\n const progressBarState = {\n EXECUTING: {\n progressBarClass: 'progress progress-striped active',\n progressBarColor: `${staticContentOfClass}-primary`,\n progressBarStatus: this.progressBarProgressFn()\n },\n EXECUTING_WITH_ERROR: {\n progressBarClass: 'progress progress-striped active',\n progressBarColor: `${staticContentOfClass}-danger`,\n progressBarStatus: this.progressBarProgressFn()\n },\n FAILED: {\n progressBarClass: 'progress',\n progressBarColor: `${staticContentOfClass}-danger`,\n progressBarStatus: 100\n },\n SUCCESSFUL: {\n progressBarClass: 'progress',\n progressBarColor: `${staticContentOfClass}-success`,\n progressBarStatus: 100\n }\n };\n\n assign(this, progressBarState[this.bulkOperation.generalStatus]);\n }\n\n editSchedule() {\n const rescheduledOperation = cloneDeep(this.bulkOperation);\n const initialState = {\n bulkOperation: rescheduledOperation\n };\n const modalOptions = { initialState, class: 'modal-sm', backdrop: 'static' } as ModalOptions;\n this.bsModalRef = this.bsModalService.show(\n BulkOperationsRescheduleModalComponent,\n modalOptions\n );\n }\n\n async cancelBulkOperation() {\n try {\n await this.modal.confirm(\n gettext('Cancel bulk operation'),\n gettext('You are about to cancel the bulk operation. Do you want to proceed?'),\n Status.DANGER\n );\n await this.bulkOperationsService.deleteBulkOperation(this.bulkOperation.id);\n this.reload.emit();\n this.alert.success(gettext('Operation canceled.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n }\n\n retryFailedOperation() {\n const clonedBulk = cloneDeep(this.bulkOperation);\n\n // change the id to failedparentId similar to the logic in deviceBulkControl.service.js\n delete clonedBulk.groupId;\n clonedBulk.failedParentId = this.bulkOperation.id;\n\n // show reschdedule modal:\n const initialState = {\n bulkOperation: clonedBulk,\n isRetryOperation: true\n };\n const modalOptions = { initialState, class: 'modal-sm', backdrop: 'static' } as ModalOptions;\n this.bsModalRef = this.bsModalService.show(\n BulkOperationsRescheduleModalComponent,\n modalOptions\n );\n this.bsModalRef.content.closeSubject.subscribe(() => {\n this.reload.emit();\n });\n }\n\n async setToSuccessful() {\n try {\n await this.modal.confirm(\n gettext('Set manually bulk operation to SUCCESSFUL'),\n gettext(\n 'You are about to change the bulk operation status to SUCCESSFUL. Do you want to proceed?'\n ),\n Status.DANGER\n );\n\n await this.bulkOperationsService.updateBulkOperation({\n id: this.bulkOperation.id,\n generalStatus: OperationBulkGeneralStatus.SUCCESSFUL\n });\n this.reload.emit();\n this.alert.success(gettext('Operation status changed to SUCCESSFUL.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n }\n\n openFailedOperation(failedParentId) {\n this.showFailedOperation.emit(failedParentId);\n }\n\n isStatusScheduled() {\n return this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.SCHEDULED;\n }\n\n isStatusExecutingOrExecutingWithError() {\n return (\n this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.EXECUTING ||\n this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.EXECUTING_WITH_ERROR\n );\n }\n\n allOperationsCreated() {\n return (\n this.bulkOperation.progress.all ===\n this.bulkOperation.progress.executing +\n this.bulkOperation.progress.failed +\n this.bulkOperation.progress.pending +\n this.bulkOperation.progress.successful\n );\n }\n\n isStatusCanceled() {\n return this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.CANCELED;\n }\n\n isStatusFailed() {\n return this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.FAILED;\n }\n}\n","import { Component, OnInit, QueryList, ViewChild, ViewChildren } from '@angular/core';\nimport { IOperationBulk, IResultList } from '@c8y/client';\nimport { OperationBulkRealtimeService, DatePickerComponent } from '@c8y/ngx-components';\nimport { flatten } from 'lodash-es';\nimport { BehaviorSubject, Observable, combineLatest, pipe } from 'rxjs';\nimport { map, tap, switchMap, withLatestFrom, shareReplay } from 'rxjs/operators';\nimport { StatusFilterComponent, IStatusOption } from '@c8y/ngx-components/operations/status-filter';\nimport {\n BulkOperationsService,\n OperationType\n} from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { BulkOperationModalsService } from './modals/bulk-operation-modals.service';\nimport { BulkOperationListItemComponent } from './bulk-operation-list-item.component';\nimport { BULK_OPERATION_STATUS_OPTIONS } from './bulk-operation-list-item.model';\n@Component({\n selector: 'c8y-bulk-operations',\n templateUrl: './bulk-operations-list.component.html',\n providers: [OperationBulkRealtimeService]\n})\nexport class BulkOperationsListComponent implements OnInit {\n bulkTypes: OperationType[] = [];\n selectedTypeFilters = this.getTypeFilters();\n bulkOperationStatusOptions: IStatusOption[] = BULK_OPERATION_STATUS_OPTIONS;\n\n filterPipe;\n refreshLoading: boolean = false;\n statusFilter$: BehaviorSubject<IStatusOption[]> = new BehaviorSubject(null);\n typeFilter$: BehaviorSubject<OperationType[]> = new BehaviorSubject(null);\n timeFilter$: BehaviorSubject<any> = new BehaviorSubject(null);\n reload$: BehaviorSubject<void> = new BehaviorSubject(null);\n @ViewChildren(BulkOperationListItemComponent) listItems: QueryList<\n BulkOperationListItemComponent\n >;\n @ViewChild('statusFilter', { static: true }) statusFilter: StatusFilterComponent;\n @ViewChild(DatePickerComponent, { static: true }) datePicker: DatePickerComponent;\n\n bulkOperations$: Observable<IResultList<IOperationBulk>> = combineLatest(\n this.statusFilter$,\n this.timeFilter$,\n this.typeFilter$,\n this.reload$\n ).pipe(\n tap(() => {\n this.refreshLoading = true;\n }),\n switchMap(([statusFilters, timeFilters]) => this.filter(statusFilters, timeFilters)),\n withLatestFrom(this.typeFilter$),\n map(([result, typeFilter]: [IResultList<IOperationBulk>, OperationType[]]) => {\n this.filterPipe = pipe(map((data: []) => this.filterByType(data, typeFilter)));\n return { ...result, data: this.filterByType(result.data, typeFilter) };\n }),\n tap(() => {\n this.refreshLoading = false;\n }),\n shareReplay(1)\n );\n\n private allFilterFragments: string[];\n\n constructor(\n public realtime: OperationBulkRealtimeService,\n private bulkOperationsService: BulkOperationsService,\n private bulkOperationModalsService: BulkOperationModalsService\n ) {\n this.allFilterFragments = this.flattenFilterFragments(this.getTypeFilters());\n }\n\n ngOnInit() {\n this.bulkTypes = this.bulkOperationsService.getBulkTypes();\n }\n\n filterByType(bulkOperations: IOperationBulk[], typeFilter) {\n const flattenedFragments: string[] = this.flattenFilterFragments(typeFilter);\n if (\n // return data unfiltered if no filters selected...\n !flattenedFragments.length ||\n // ...or when all filters are selected\n this.allFilterFragments.every(fragment => flattenedFragments.includes(fragment))\n ) {\n return bulkOperations;\n }\n\n const filteredData = bulkOperations.filter(item => {\n return Object.keys(item.operationPrototype).some(key => flattenedFragments.includes(key));\n });\n\n return filteredData;\n }\n\n resetFilter() {\n this.statusFilter$.next(null);\n this.timeFilter$.next(null);\n this.typeFilter$.next(null);\n\n this.datePicker.clearFilter();\n this.selectedTypeFilters = this.getTypeFilters();\n this.statusFilter.reset();\n }\n\n isFilterApplied() {\n return (\n this.statusFilter$.getValue() || this.typeFilter$.getValue() || this.timeFilter$.getValue()\n );\n }\n\n filter(statusFilters, timeFilter) {\n const status =\n statusFilters && statusFilters.length > 0\n ? {\n generalStatus: flatten(statusFilters.map(statusFilter => statusFilter.generalStatus))\n }\n : {};\n\n const time = timeFilter\n ? {\n ...(timeFilter.dateFrom && {\n dateFrom: timeFilter.dateFrom.toISOString()\n }),\n ...(timeFilter.dateTo && {\n dateTo: timeFilter.dateTo.toISOString()\n })\n }\n : {};\n return this.getBulkOperations({ ...status, ...time });\n }\n\n getBulkOperations(filter?) {\n return this.bulkOperationsService.getBulkOperations(filter);\n }\n\n getTypeFilters() {\n return this.bulkOperationsService.getBulkTypes();\n }\n\n addBulkOperation() {\n this.bulkOperationModalsService.showNewBulkOperationModal();\n }\n\n openFailedOperation(failedParentId) {\n this.listItems.forEach(item => {\n if (item.bulkOperation.id === failedParentId) {\n item.listItem.collapsed = false;\n item.listItem.element.nativeElement.scrollIntoView({ behavior: 'smooth', block: 'center' });\n }\n });\n }\n\n compareOperations(operationA: IOperationBulk, operationB: IOperationBulk): number {\n return new Date(operationA.startDate).getTime() - new Date(operationB.startDate).getTime();\n }\n\n private flattenFilterFragments(filters: OperationType[]): string[] {\n return (filters || []).reduce((flattened, current) => flattened.concat(current.fragments), []);\n }\n}\n","import {\n Component,\n EventEmitter,\n Input,\n OnInit,\n Output,\n ViewChild,\n ViewContainerRef\n} from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { gettext, Tab } from '@c8y/ngx-components';\n\n@Component({\n selector: 'c8y-bulk-operation-details-tabs',\n templateUrl: './bulk-operation-details-tabs.component.html'\n})\nexport class BulkOperationDetailsTabsComponent implements OnInit {\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n readOnly: boolean = false;\n @Output() onRetryFailedOperations: EventEmitter<Partial<IOperationBulk>> = new EventEmitter();\n @Output() showFailedOperation: EventEmitter<number> = new EventEmitter();\n\n @ViewChild('details', { static: true }) detailsTemplate: any;\n @ViewChild('audit', { static: true }) auditTemplate: any;\n\n tabs: Tab[] = [];\n template: ViewContainerRef;\n\n ngOnInit(): void {\n this.template = this.detailsTemplate;\n\n this.tabs = [\n {\n label: gettext('Details'),\n path: null,\n icon: 'asterisk',\n template: this.detailsTemplate\n },\n {\n label: gettext('History of changes'),\n path: null,\n icon: 'archive',\n template: this.auditTemplate\n }\n ];\n }\n}\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\nimport { IManagedObject, IOperationBulk } from '@c8y/client';\n\n@Component({\n selector: 'c8y-bulk-operation-details',\n templateUrl: './bulk-operation-details.component.html'\n})\nexport class BulkOperationDetailsComponent {\n allFilterIsSelected: boolean = false;\n collapsed: boolean;\n device: IManagedObject;\n\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n readOnly: boolean = false;\n @Output() showFailedOperation: EventEmitter<number> = new EventEmitter();\n\n scrollToRetriedFromOperation(failedOperationId) {\n this.showFailedOperation.emit(failedOperationId);\n }\n}\n","import { gettext } from '@c8y/ngx-components';\n\nexport const SINGLE_OP_STATUS_NAMES = {\n PENDING: gettext('Pending'),\n EXECUTING: gettext('Executing'),\n FAILED: gettext('Failed'),\n SUCCESSFUL: gettext('Successful'),\n ALL: gettext('All')\n};\n\nexport const SINGLE_OP_STATUS_PROPERTIES = [\n {\n label: SINGLE_OP_STATUS_NAMES.PENDING,\n iconClass: 'dlt-c8y-icon-clock-o text-info',\n selected: false\n },\n {\n label: SINGLE_OP_STATUS_NAMES.EXECUTING,\n iconClass: 'dlt-c8y-icon-refresh text-info',\n selected: false\n },\n {\n label: SINGLE_OP_STATUS_NAMES.SUCCESSFUL,\n iconClass: 'dlt-c8y-icon-check-circle text-success',\n selected: false\n },\n {\n label: SINGLE_OP_STATUS_NAMES.FAILED,\n iconClass: 'dlt-c8y-icon-exclamation-circle text-danger',\n selected: false\n }\n];\n","import {\n AfterViewInit,\n Component,\n EventEmitter,\n Input,\n OnChanges,\n Output,\n SimpleChanges,\n ViewChild\n} from '@angular/core';\nimport { IOperation, IOperationBulk, IResultList } from '@c8y/client';\nimport { StatusFilterComponent, IStatusOption } from '@c8y/ngx-components/operations/status-filter';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { SINGLE_OP_STATUS_NAMES, SINGLE_OP_STATUS_PROPERTIES } from './single-operation-item.model';\n\n@Component({\n selector: 'c8y-single-operations-list',\n templateUrl: './single-operations-list.component.html'\n})\nexport class SingleOperationsListComponent implements AfterViewInit, OnChanges {\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n readOnly: boolean = false;\n @Output() onRetryFailedOperations: EventEmitter<Partial<IOperationBulk>> = new EventEmitter();\n\n @ViewChild(StatusFilterComponent, { static: false })\n statusFilter: StatusFilterComponent;\n\n singleOperationStatusProperties = SINGLE_OP_STATUS_PROPERTIES;\n singleOperationStatusNames = SINGLE_OP_STATUS_NAMES;\n singleOperations: IResultList<IOperation>;\n\n constructor(private bulkOperationsService: BulkOperationsService) {}\n\n async ngAfterViewInit() {\n if (this.statusFilter) {\n this.filterOperationsByType();\n }\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes.bulkOperation && !changes.bulkOperation.firstChange) {\n this.filterOperationsByType();\n }\n }\n\n filterOperationsByType() {\n if (this.statusFilter) {\n const typeFilter = this.getFilterTypeOfSingleOperations();\n\n this.statusFilter.preset(\n typeFilter === this.singleOperationStatusNames.ALL\n ? []\n : [{ label: typeFilter } as IStatusOption]\n );\n } else {\n setTimeout(this.filterOperationsByType.bind(this));\n }\n }\n\n getFilterTypeOfSingleOperations() {\n const progress = this.bulkOperation.progress;\n\n if (progress.failed > 0) {\n return this.singleOperationStatusNames.FAILED;\n } else if (progress.failed === 0 && progress.successful === 0 && progress.pending === 0) {\n return this.singleOperationStatusNames.EXECUTING;\n } else if (progress.failed === 0 && progress.successful === 0 && progress.executing === 0) {\n return this.singleOperationStatusNames.PENDING;\n } else if (progress.failed === 0 && progress.pending === 0 && progress.executing === 0) {\n return this.singleOperationStatusNames.SUCCESSFUL;\n }\n\n return this.singleOperationStatusNames.ALL;\n }\n\n async getOperationsByStatus(filter: IStatusOption[]) {\n this.singleOperations = await this.bulkOperationsService.getSingleOperationsByStatus(\n filter[0] && filter[0].label,\n this.bulkOperation.id\n );\n }\n\n retryBulkOperation() {\n this.onRetryFailedOperations.emit(this.bulkOperation);\n }\n}\n","import { Component, ElementRef, Input, ViewChild } from '@angular/core';\nimport { IOperation } from '@c8y/client';\nimport { AlertService, gettext } from '@c8y/ngx-components';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { omit } from 'lodash-es';\nimport { SINGLE_OP_STATUS_NAMES, SINGLE_OP_STATUS_PROPERTIES } from './single-operation-item.model';\n\n@Component({\n selector: 'c8y-single-operation-item',\n templateUrl: './single-operation-item.component.html'\n})\nexport class SingleOperationItemComponent {\n device = {};\n showIfTextTruncated = false;\n singleOperationStatusNames = SINGLE_OP_STATUS_NAMES;\n singleOperationsStatusProperties = SINGLE_OP_STATUS_PROPERTIES;\n iconClass: string;\n @Input()\n operation: IOperation;\n @Input()\n readOnly: boolean = false;\n @ViewChild('failureReason', { static: true }) failureReasonRef: ElementRef;\n\n constructor(\n private bulkOperationsService: BulkOperationsService,\n private alertService: AlertService\n ) {}\n\n async ngOnInit() {\n this.iconClass = this.getIconClass();\n this.device = await this.getDeviceMO(this.operation.deviceId);\n }\n\n ngAfterViewInit() {\n this.isTextTruncated();\n }\n\n async retrySingleOperation(singleOperation) {\n const operationToCreate = omit(singleOperation, [\n 'id',\n 'self',\n 'status',\n 'failureReason',\n 'creationTime',\n 'delivery'\n ]);\n\n try {\n await this.bulkOperationsService.createSingleOperation(operationToCreate);\n this.alertService.success(gettext('Operation created.'));\n } catch (er) {\n this.alertService.addServerFailure(er);\n }\n }\n\n getIconClass() {\n return this.singleOperationsStatusProperties.find(\n operationProperties => operationProperties.label.toUpperCase() === this.operation.status\n ).iconClass;\n }\n\n private async getDeviceMO(deviceId) {\n const inventoryMO = await this.bulkOperationsService.getManagedObject(deviceId);\n if (inventoryMO) {\n return inventoryMO.data;\n }\n }\n\n private isTextTruncated() {\n if (this.operation.failureReason) {\n const el = this.failureReasonRef.nativeElement;\n this.showIfTextTruncated = el.offsetWidth < el.scrollWidth ? true : false;\n }\n }\n}\n","import { Component, EventEmitter, Output, OnInit } from '@angular/core';\nimport { Router } from '@angular/router';\nimport {\n BulkOperationsService,\n OperationType\n} from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { BulkOperationModalsService } from '../modals/bulk-operation-modals.service';\n\n@Component({\n selector: 'c8y-bulk-operation-type-list',\n templateUrl: './bulk-operation-type-list.component.html'\n})\nexport class BulkOperationTypeListComponent implements OnInit {\n @Output() onCustomType: EventEmitter<OperationType> = new EventEmitter();\n bulkList: OperationType[] = [];\n\n constructor(\n private router: Router,\n private bulkOperationsService: BulkOperationsService,\n private bulkOperationModalsService: BulkOperationModalsService\n ) {}\n\n ngOnInit() {\n this.bulkList = this.bulkOperationsService.getBulkTypes();\n }\n\n handleClick(item: OperationType) {\n if (item.path) {\n this.bulkOperationModalsService.hideNewBulkOperationModal();\n this.router.navigateByUrl(item.path);\n } else if (item.component) {\n this.onCustomType.emit(item);\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouterModule } from '@angular/router';\nimport { PopoverModule } from 'ngx-bootstrap/popover';\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\n\nimport { CoreModule, Route } from '@c8y/ngx-components';\nimport { StatusFilterModule } from '@c8y/ngx-components/operations/status-filter';\nimport { OperationSummaryModule } from '@c8y/ngx-components/operations/operation-summary';\nimport { BulkOperationSchedulerModule } from '@c8y/ngx-components/operations/bulk-operation-scheduler';\n\nimport { BulkOperationDetailsService } from './bulk-operation-details.service';\nimport { BulkOperationsListComponent } from './bulk-operations-list.component';\nimport { BulkOperationListItemComponent } from './bulk-operation-list-item.component';\nimport { BulkOperationDetailsTabsComponent } from './bulk-operation-details-tabs.component';\nimport { BulkOperationDetailsComponent } from './bulk-operation-details.component';\nimport { SingleOperationsListComponent } from './single-operations-list.component';\nimport { SingleOperationItemComponent } from './single-operation-item.component';\nimport { BulkOperationWrapperComponent } from './bulk-operation-wrapper.component';\nimport { BulkOperationTypeListComponent } from './type-list/bulk-operation-type-list.component';\nimport { BulkOperationModalsService } from './modals/bulk-operation-modals.service';\nimport { BulkOperationsModalComponent } from './modals/bulk-operations-modal.component';\nimport { BulkOperationsRescheduleModalComponent } from './modals/bulk-operations-reschedule-modal.component';\n\nexport const bulkOperationListRoutes: Route[] = [\n {\n path: 'devicecontrol/bulk',\n component: BulkOperationsListComponent\n }\n];\n\n/**\n * This module allows for displaying the list of bulk operations and their details.\n */\n@NgModule({\n imports: [\n CoreModule,\n PopoverModule,\n TooltipModule,\n StatusFilterModule,\n OperationSummaryModule,\n BulkOperationSchedulerModule,\n RouterModule.forChild(bulkOperationListRoutes)\n ],\n providers: [BulkOperationDetailsService, BulkOperationModalsService],\n declarations: [\n BulkOperationsListComponent,\n BulkOperationListItemComponent,\n BulkOperationDetailsTabsComponent,\n BulkOperationDetailsComponent,\n SingleOperationsListComponent,\n SingleOperationItemComponent,\n BulkOperationWrapperComponent,\n BulkOperationTypeListComponent,\n BulkOperationsModalComponent,\n BulkOperationsRescheduleModalComponent\n ],\n entryComponents: [\n BulkOperationsListComponent,\n BulkOperationListItemComponent,\n BulkOperationDetailsTabsComponent,\n BulkOperationDetailsComponent,\n SingleOperationsListComponent,\n SingleOperationItemComponent,\n BulkOperationWrapperComponent,\n BulkOperationTypeListComponent,\n BulkOperationsModalComponent,\n BulkOperationsRescheduleModalComponent\n ],\n exports: [\n BulkOperationsListComponent,\n BulkOperationListItemComponent,\n BulkOperationDetailsTabsComponent,\n BulkOperationDetailsComponent,\n SingleOperationsListComponent,\n SingleOperationItemComponent,\n BulkOperationWrapperComponent,\n BulkOperationTypeListComponent,\n BulkOperationsModalComponent,\n BulkOperationsRescheduleModalComponent\n ]\n})\nexport class BulkOperationsListModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["tslib_1.__decorate"],"mappings":";;;;;;;;;;;;;;;;IASa,6BAA6B,GAA1C,MAAa,6BAA6B;IAGxC,YACS,2BAAwD,EACxD,QAAoB;QADpB,gCAA2B,GAA3B,2BAA2B,CAA6B;QACxD,aAAQ,GAAR,QAAQ,CAAY;KACzB;CACL,CAAA;;YAHuC,2BAA2B;YAC9C,UAAU;;AAJpBA;IAAR,KAAK,EAAE;oEAAwC;AADrC,6BAA6B;IAJzC,SAAS,CAAC;QACT,QAAQ,EAAE,6BAA6B;QACvC,+oBAAsD;KACvD,CAAC;GACW,6BAA6B,CAOzC;;ICTY,2BAA2B,GAAxC,MAAa,2BAA2B;IACtC,YACU,qBAA4C,EAC5C,YAA4B;QAD5B,0BAAqB,GAArB,qBAAqB,CAAuB;QAC5C,iBAAY,GAAZ,YAAY,CAAgB;KAClC;IAEE,WAAW,CAAC,eAAe;;YAC/B,MAAM,aAAa,GAAmB,CAAC,MAAM,IAAI,CAAC,qBAAqB,CAAC,oBAAoB,CAC1F,eAAe,CAChB,EAAE,IAAI,CAAC;YACR,MAAM,YAAY,GAAG,EAAE,aAAa,EAAE,CAAC;YACvC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,6BAA6B,EAAE;gBACpD,YAAY;gBACZ,KAAK,EAAE,UAAU;aAClB,CAAC,CAAC;SACJ;KAAA;CACF,CAAA;;YAdkC,qBAAqB;YAC9B,cAAc;;AAH3B,2BAA2B;IADvC,UAAU,EAAE;GACA,2BAA2B,CAgBvC;;ICfY,4BAA4B,GAAzC,MAAa,4BAA4B;IAGvC,YAAoB,UAAsB,EAAU,QAAkC;QAAlE,eAAU,GAAV,UAAU,CAAY;QAAU,aAAQ,GAAR,QAAQ,CAA0B;QADtF,kBAAa,GAAY,KAAK,CAAC;KAC2D;IAE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2B;YAC3B,8BAA8B;YAC9B,iCAAiC;YACjC,6BAA6B;YAC7B,6BAA6B;YAC7B,4BAA4B;YAC5B,6BAA6B;YAC7B,8BAA8B;YAC9B,4BAA4B;YAC5B,sCAAsC;SACvC;KACF,CAAC;GACW,wBAAwB,CAAG;;ACjFxC;;GAEG;;;;"}
1
+ {"version":3,"file":"c8y-ngx-components-operations-bulk-operations-list.js","sources":["ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-wrapper.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-details.service.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/modals/bulk-operations-modal.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/modals/bulk-operation-modals.service.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/modals/bulk-operations-reschedule-modal.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-list-item.model.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-list-item.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operations-list.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-details-tabs.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operation-details.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/single-operation-item.model.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/single-operations-list.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/single-operation-item.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/type-list/bulk-operation-type-list.component.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/bulk-operations-list.module.ts","ng://@c8y/ngx-components/operations/bulk-operations-list/c8y-ngx-components-operations-bulk-operations-list.ts"],"sourcesContent":["import { Component, Input } from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { BulkOperationDetailsService } from './bulk-operation-details.service';\n\n@Component({\n selector: 'c8y-bulk-operations-wrapper',\n templateUrl: './bulk-operation-wrapper.component.html'\n})\nexport class BulkOperationWrapperComponent {\n @Input() bulkOperation: Partial<IOperationBulk>;\n\n constructor(\n public bulkOperationDetailsService: BulkOperationDetailsService,\n public modalRef: BsModalRef\n ) {}\n}\n","import { Injectable } from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { BsModalService } from 'ngx-bootstrap/modal';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { BulkOperationWrapperComponent } from './bulk-operation-wrapper.component';\n\n@Injectable()\nexport class BulkOperationDetailsService {\n constructor(\n private bulkOperationsService: BulkOperationsService,\n private modalService: BsModalService\n ) {}\n\n async openDetails(bulkOperationId) {\n const bulkOperation: IOperationBulk = (await this.bulkOperationsService.getBulkOperationById(\n bulkOperationId\n )).data;\n const initialState = { bulkOperation };\n this.modalService.show(BulkOperationWrapperComponent, {\n initialState,\n class: 'modal-lg'\n });\n }\n}\n","import { Component, ViewContainerRef, ViewChild, ComponentFactoryResolver } from '@angular/core';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { OperationType } from '@c8y/ngx-components/operations/bulk-operations-service';\n\n@Component({\n selector: 'c8y-bulk-operations-modal',\n templateUrl: 'bulk-operations-modal.component.html'\n})\nexport class BulkOperationsModalComponent {\n @ViewChild('container', { static: false, read: ViewContainerRef }) container;\n showComponent: boolean = false;\n constructor(private bsModalRef: BsModalRef, private resolver: ComponentFactoryResolver) {}\n\n cancel() {\n this.bsModalRef.hide();\n }\n\n createComponent(item: OperationType) {\n if (item && item.component) {\n this.showComponent = true;\n const factory = this.resolver.resolveComponentFactory(item.component);\n this.container.createComponent(factory);\n }\n }\n}\n","import { Injectable } from '@angular/core';\nimport { BsModalRef, BsModalService } from 'ngx-bootstrap/modal';\nimport { BulkOperationsModalComponent } from './bulk-operations-modal.component';\n\n@Injectable()\nexport class BulkOperationModalsService {\n private bsModalRef: BsModalRef;\n\n constructor(private bsModalService: BsModalService) {}\n\n showNewBulkOperationModal() {\n this.bsModalRef = this.bsModalService.show(BulkOperationsModalComponent, {\n backdrop: 'static',\n class: 'modal-sm'\n });\n }\n\n hideNewBulkOperationModal() {\n if (this.bsModalRef) {\n this.bsModalRef.hide();\n }\n }\n}\n","import { Component, OnInit } from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { AlertService, gettext } from '@c8y/ngx-components';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { Subject } from 'rxjs';\nimport { OperationSchedule } from '@c8y/ngx-components/operations/bulk-operation-scheduler';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\n\n@Component({\n selector: 'c8y-bulk-operations-reschedule-modal',\n templateUrl: 'bulk-operations-reschedule-modal.component.html'\n})\nexport class BulkOperationsRescheduleModalComponent implements OnInit {\n closeSubject: Subject<IOperationBulk> = new Subject();\n dateAndDelay: OperationSchedule;\n bulkOperation: Partial<IOperationBulk>;\n isRetryOperation: boolean;\n modalTitle: string;\n\n constructor(\n public bsModalRef: BsModalRef,\n private bulkOperationsService: BulkOperationsService,\n private alert: AlertService\n ) {}\n\n ngOnInit() {\n this.modalTitle = this.getTitle();\n }\n\n onDateAndDelaySelect($event) {\n this.dateAndDelay = $event;\n }\n\n getTitle() {\n return this.isRetryOperation ? gettext('Retry operation') : gettext('Edit schedule');\n }\n\n onCancel() {\n this.bsModalRef.hide();\n }\n\n async onSave() {\n let newBulkOperation;\n this.bulkOperation.startDate = this.dateAndDelay.scheduledDate.toISOString();\n this.bulkOperation.creationRamp = this.dateAndDelay.delayInSeconds;\n\n if (this.isRetryOperation) {\n try {\n newBulkOperation = await this.bulkOperationsService.createBulkOperation(this.bulkOperation);\n this.alert.success(gettext('Successfully rescheduled for a retry.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n } else {\n try {\n newBulkOperation = await this.bulkOperationsService.updateBulkOperation(this.bulkOperation);\n this.alert.success(gettext('Successfully rescheduled.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n }\n\n // send back to component from which modal was called\n this.closeSubject.next(newBulkOperation.data);\n this.bsModalRef.hide();\n }\n}\n","import { OperationBulkGeneralStatus } from '@c8y/client';\nimport { gettext } from '@c8y/ngx-components';\nimport { IStatusOption } from '@c8y/ngx-components/operations/status-filter';\n\nexport const BULK_OPERATION_STATUS_LABELS = {\n SCHEDULED: gettext('Scheduled'),\n EXECUTING: gettext('Executing'),\n CANCELED: gettext('Canceled'),\n FAILED: gettext('Completed with failures'),\n SUCCESSFUL: gettext('Completed successfully'),\n DELETED: gettext('Deleted'),\n};\n\nexport const BULK_OPERATION_STATUS_OPTIONS: IStatusOption[] = [\n {\n label: BULK_OPERATION_STATUS_LABELS.SCHEDULED,\n generalStatus: [OperationBulkGeneralStatus.SCHEDULED],\n iconClass: 'dlt-c8y-icon-calendar text-info',\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.EXECUTING,\n generalStatus: [\n OperationBulkGeneralStatus.EXECUTING,\n OperationBulkGeneralStatus.EXECUTING_WITH_ERROR,\n ],\n iconClass: 'dlt-c8y-icon-refresh text-primary',\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.DELETED,\n generalStatus: [OperationBulkGeneralStatus.DELETED],\n iconClass: 'dlt-c8y-icon-delete-document text-muted',\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.CANCELED,\n generalStatus: [OperationBulkGeneralStatus.CANCELED],\n iconClass: 'dlt-c8y-icon-ban text-muted',\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.FAILED,\n generalStatus: [OperationBulkGeneralStatus.FAILED],\n iconClass: 'dlt-c8y-icon-exclamation-triangle text-danger',\n },\n {\n label: BULK_OPERATION_STATUS_LABELS.SUCCESSFUL,\n generalStatus: [OperationBulkGeneralStatus.SUCCESSFUL],\n iconClass: 'dlt-c8y-icon-check-circle text-success',\n },\n];\n\nexport const BULK_OPERATION_FALLBACK_STATUS_ICON = 'dlt-c8y-icon-ask-question text-muted';\n","import {\n Component,\n EventEmitter,\n Input,\n OnChanges,\n OnInit,\n Output,\n SimpleChanges,\n ViewChild\n} from '@angular/core';\nimport { IOperationBulk, OperationBulkGeneralStatus } from '@c8y/client';\nimport {\n AlertService,\n gettext,\n ListItemComponent,\n ModalService,\n Status\n} from '@c8y/ngx-components';\nimport { assign, cloneDeep } from 'lodash-es';\nimport { BsModalRef, BsModalService, ModalOptions } from 'ngx-bootstrap/modal';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { IStatusOption } from '@c8y/ngx-components/operations/status-filter';\nimport { BulkOperationsRescheduleModalComponent } from './modals/bulk-operations-reschedule-modal.component';\nimport { BULK_OPERATION_FALLBACK_STATUS_ICON, BULK_OPERATION_STATUS_OPTIONS } from './bulk-operation-list-item.model';\n\n@Component({\n selector: 'c8y-bulk-operation-list-item',\n templateUrl: './bulk-operation-list-item.component.html'\n})\nexport class BulkOperationListItemComponent implements OnInit, OnChanges {\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n detailsCollapsed: boolean = true;\n @Input()\n readOnly: boolean = false;\n @Output() showFailedOperation = new EventEmitter();\n @Output() reload: EventEmitter<any> = new EventEmitter();\n @ViewChild('listItem', { static: true }) listItem: ListItemComponent;\n iconClass: string;\n finishDate: number;\n refreshLoading = false;\n bulkOperationGeneralStatus = OperationBulkGeneralStatus;\n bulkOperationStatusOptions: IStatusOption[] = BULK_OPERATION_STATUS_OPTIONS;\n bsModalRef: BsModalRef;\n finishDatePopoverText: string = gettext(\n 'Approximate date, estimated based on the bulk operation settings.'\n );\n progressBarClass: string = 'progress';\n progressBarColor: string;\n progressBarStatus: number = 0;\n\n constructor(\n private bulkOperationsService: BulkOperationsService,\n private modal: ModalService,\n private alert: AlertService,\n private bsModalService: BsModalService\n ) {}\n\n ngOnInit() {\n this.iconClass = this.getIconClass();\n this.finishDate = this.calculateFinishDateMs();\n this.setProgressBar();\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes.bulkOperation && !changes.bulkOperation.firstChange) {\n this.iconClass = this.getIconClass();\n this.setProgressBar();\n }\n }\n\n getIconClass() {\n const statusOptions = this.bulkOperationStatusOptions.find(statusOption =>\n statusOption.generalStatus.includes(this.bulkOperation.generalStatus)\n );\n return statusOptions ? statusOptions.iconClass : BULK_OPERATION_FALLBACK_STATUS_ICON;\n }\n\n calculateFinishDateMs(): number {\n const startDateMs: number = new Date(this.bulkOperation.startDate).getTime();\n const creationRampMs: number = this.bulkOperation.creationRamp * 1000;\n\n return startDateMs + creationRampMs * this.bulkOperation.progress.all;\n }\n\n progressBarProgressFn() {\n return (\n ((this.bulkOperation.progress.successful + this.bulkOperation.progress.failed) /\n this.bulkOperation.progress.all) *\n 100\n );\n }\n\n setProgressBar() {\n const staticContentOfClass = 'progress-bar progress-striped active progress-bar';\n\n const progressBarState = {\n EXECUTING: {\n progressBarClass: 'progress progress-striped active',\n progressBarColor: `${staticContentOfClass}-primary`,\n progressBarStatus: this.progressBarProgressFn()\n },\n EXECUTING_WITH_ERROR: {\n progressBarClass: 'progress progress-striped active',\n progressBarColor: `${staticContentOfClass}-danger`,\n progressBarStatus: this.progressBarProgressFn()\n },\n FAILED: {\n progressBarClass: 'progress',\n progressBarColor: `${staticContentOfClass}-danger`,\n progressBarStatus: 100\n },\n SUCCESSFUL: {\n progressBarClass: 'progress',\n progressBarColor: `${staticContentOfClass}-success`,\n progressBarStatus: 100\n }\n };\n\n assign(this, progressBarState[this.bulkOperation.generalStatus]);\n }\n\n editSchedule() {\n const rescheduledOperation = cloneDeep(this.bulkOperation);\n const initialState = {\n bulkOperation: rescheduledOperation\n };\n const modalOptions = { initialState, class: 'modal-sm', backdrop: 'static' } as ModalOptions;\n this.bsModalRef = this.bsModalService.show(\n BulkOperationsRescheduleModalComponent,\n modalOptions\n );\n }\n\n async cancelBulkOperation() {\n try {\n await this.modal.confirm(\n gettext('Cancel bulk operation'),\n gettext('You are about to cancel the bulk operation. Do you want to proceed?'),\n Status.DANGER\n );\n await this.bulkOperationsService.deleteBulkOperation(this.bulkOperation.id);\n this.reload.emit();\n this.alert.success(gettext('Operation canceled.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n }\n\n retryFailedOperation() {\n const clonedBulk = cloneDeep(this.bulkOperation);\n\n // change the id to failedparentId similar to the logic in deviceBulkControl.service.js\n delete clonedBulk.groupId;\n clonedBulk.failedParentId = this.bulkOperation.id;\n\n // show reschdedule modal:\n const initialState = {\n bulkOperation: clonedBulk,\n isRetryOperation: true\n };\n const modalOptions = { initialState, class: 'modal-sm', backdrop: 'static' } as ModalOptions;\n this.bsModalRef = this.bsModalService.show(\n BulkOperationsRescheduleModalComponent,\n modalOptions\n );\n this.bsModalRef.content.closeSubject.subscribe(() => {\n this.reload.emit();\n });\n }\n\n async setToSuccessful() {\n try {\n await this.modal.confirm(\n gettext('Set manually bulk operation to SUCCESSFUL'),\n gettext(\n 'You are about to change the bulk operation status to SUCCESSFUL. Do you want to proceed?'\n ),\n Status.DANGER\n );\n\n await this.bulkOperationsService.updateBulkOperation({\n id: this.bulkOperation.id,\n generalStatus: OperationBulkGeneralStatus.SUCCESSFUL\n });\n this.reload.emit();\n this.alert.success(gettext('Operation status changed to SUCCESSFUL.'));\n } catch (er) {\n this.alert.addServerFailure(er);\n }\n }\n\n openFailedOperation(failedParentId) {\n this.showFailedOperation.emit(failedParentId);\n }\n\n isStatusScheduled() {\n return this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.SCHEDULED;\n }\n\n isStatusExecutingOrExecutingWithError() {\n return (\n this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.EXECUTING ||\n this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.EXECUTING_WITH_ERROR\n );\n }\n\n allOperationsCreated() {\n return (\n this.bulkOperation.progress.all ===\n this.bulkOperation.progress.executing +\n this.bulkOperation.progress.failed +\n this.bulkOperation.progress.pending +\n this.bulkOperation.progress.successful\n );\n }\n\n isStatusCanceled() {\n return this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.CANCELED;\n }\n\n isStatusFailed() {\n return this.bulkOperation.generalStatus === this.bulkOperationGeneralStatus.FAILED;\n }\n}\n","import { Component, OnInit, QueryList, ViewChild, ViewChildren } from '@angular/core';\nimport { IOperationBulk, IResultList } from '@c8y/client';\nimport { OperationBulkRealtimeService, DatePickerComponent } from '@c8y/ngx-components';\nimport { flatten } from 'lodash-es';\nimport { BehaviorSubject, Observable, combineLatest, pipe } from 'rxjs';\nimport { map, tap, switchMap, withLatestFrom, shareReplay } from 'rxjs/operators';\nimport { StatusFilterComponent, IStatusOption } from '@c8y/ngx-components/operations/status-filter';\nimport {\n BulkOperationsService,\n OperationType\n} from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { BulkOperationModalsService } from './modals/bulk-operation-modals.service';\nimport { BulkOperationListItemComponent } from './bulk-operation-list-item.component';\nimport { BULK_OPERATION_STATUS_OPTIONS } from './bulk-operation-list-item.model';\n@Component({\n selector: 'c8y-bulk-operations',\n templateUrl: './bulk-operations-list.component.html',\n providers: [OperationBulkRealtimeService]\n})\nexport class BulkOperationsListComponent implements OnInit {\n bulkTypes: OperationType[] = [];\n selectedTypeFilters = this.getTypeFilters();\n bulkOperationStatusOptions: IStatusOption[] = BULK_OPERATION_STATUS_OPTIONS;\n\n filterPipe;\n refreshLoading: boolean = false;\n statusFilter$: BehaviorSubject<IStatusOption[]> = new BehaviorSubject(null);\n typeFilter$: BehaviorSubject<OperationType[]> = new BehaviorSubject(null);\n timeFilter$: BehaviorSubject<any> = new BehaviorSubject(null);\n reload$: BehaviorSubject<void> = new BehaviorSubject(null);\n @ViewChildren(BulkOperationListItemComponent) listItems: QueryList<\n BulkOperationListItemComponent\n >;\n @ViewChild('statusFilter', { static: true }) statusFilter: StatusFilterComponent;\n @ViewChild(DatePickerComponent, { static: true }) datePicker: DatePickerComponent;\n\n bulkOperations$: Observable<IResultList<IOperationBulk>> = combineLatest(\n this.statusFilter$,\n this.timeFilter$,\n this.typeFilter$,\n this.reload$\n ).pipe(\n tap(() => {\n this.refreshLoading = true;\n }),\n switchMap(([statusFilters, timeFilters]) => this.filter(statusFilters, timeFilters)),\n withLatestFrom(this.typeFilter$),\n map(([result, typeFilter]: [IResultList<IOperationBulk>, OperationType[]]) => {\n this.filterPipe = pipe(map((data: []) => this.filterByType(data, typeFilter)));\n return { ...result, data: this.filterByType(result.data, typeFilter) };\n }),\n tap(() => {\n this.refreshLoading = false;\n }),\n shareReplay(1)\n );\n\n private allFilterFragments: string[];\n\n constructor(\n public realtime: OperationBulkRealtimeService,\n private bulkOperationsService: BulkOperationsService,\n private bulkOperationModalsService: BulkOperationModalsService\n ) {\n this.allFilterFragments = this.flattenFilterFragments(this.getTypeFilters());\n }\n\n ngOnInit() {\n this.bulkTypes = this.bulkOperationsService.getBulkTypes();\n }\n\n filterByType(bulkOperations: IOperationBulk[], typeFilter) {\n const flattenedFragments: string[] = this.flattenFilterFragments(typeFilter);\n if (\n // return data unfiltered if no filters selected...\n !flattenedFragments.length ||\n // ...or when all filters are selected\n this.allFilterFragments.every(fragment => flattenedFragments.includes(fragment))\n ) {\n return bulkOperations;\n }\n\n const filteredData = bulkOperations.filter(item => {\n return Object.keys(item.operationPrototype).some(key => flattenedFragments.includes(key));\n });\n\n return filteredData;\n }\n\n resetFilter() {\n this.statusFilter$.next(null);\n this.timeFilter$.next(null);\n this.typeFilter$.next(null);\n\n this.datePicker.clearFilter();\n this.selectedTypeFilters = this.getTypeFilters();\n this.statusFilter.reset();\n }\n\n isFilterApplied() {\n return (\n this.statusFilter$.getValue() || this.typeFilter$.getValue() || this.timeFilter$.getValue()\n );\n }\n\n filter(statusFilters, timeFilter) {\n const status =\n statusFilters && statusFilters.length > 0\n ? {\n generalStatus: flatten(statusFilters.map(statusFilter => statusFilter.generalStatus))\n }\n : {};\n\n const time = timeFilter\n ? {\n ...(timeFilter.dateFrom && {\n dateFrom: timeFilter.dateFrom.toISOString()\n }),\n ...(timeFilter.dateTo && {\n dateTo: timeFilter.dateTo.toISOString()\n })\n }\n : {};\n return this.getBulkOperations({ ...status, ...time });\n }\n\n getBulkOperations(filter?) {\n return this.bulkOperationsService.getBulkOperations(filter);\n }\n\n getTypeFilters() {\n return this.bulkOperationsService.getBulkTypes();\n }\n\n addBulkOperation() {\n this.bulkOperationModalsService.showNewBulkOperationModal();\n }\n\n openFailedOperation(failedParentId) {\n this.listItems.forEach(item => {\n if (item.bulkOperation.id === failedParentId) {\n item.listItem.collapsed = false;\n item.listItem.element.nativeElement.scrollIntoView({ behavior: 'smooth', block: 'center' });\n }\n });\n }\n\n compareOperations(operationA: IOperationBulk, operationB: IOperationBulk): number {\n return new Date(operationA.startDate).getTime() - new Date(operationB.startDate).getTime();\n }\n\n private flattenFilterFragments(filters: OperationType[]): string[] {\n return (filters || []).reduce((flattened, current) => flattened.concat(current.fragments), []);\n }\n}\n","import {\n Component,\n EventEmitter,\n Input,\n OnInit,\n Output,\n ViewChild,\n ViewContainerRef\n} from '@angular/core';\nimport { IOperationBulk } from '@c8y/client';\nimport { gettext, Tab } from '@c8y/ngx-components';\n\n@Component({\n selector: 'c8y-bulk-operation-details-tabs',\n templateUrl: './bulk-operation-details-tabs.component.html'\n})\nexport class BulkOperationDetailsTabsComponent implements OnInit {\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n readOnly: boolean = false;\n @Output() onRetryFailedOperations: EventEmitter<Partial<IOperationBulk>> = new EventEmitter();\n @Output() showFailedOperation: EventEmitter<number> = new EventEmitter();\n\n @ViewChild('details', { static: true }) detailsTemplate: any;\n @ViewChild('audit', { static: true }) auditTemplate: any;\n\n tabs: Tab[] = [];\n template: ViewContainerRef;\n\n ngOnInit(): void {\n this.template = this.detailsTemplate;\n\n this.tabs = [\n {\n label: gettext('Details'),\n path: null,\n icon: 'asterisk',\n template: this.detailsTemplate\n },\n {\n label: gettext('History of changes'),\n path: null,\n icon: 'archive',\n template: this.auditTemplate\n }\n ];\n }\n}\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\nimport { IManagedObject, IOperationBulk } from '@c8y/client';\n\n@Component({\n selector: 'c8y-bulk-operation-details',\n templateUrl: './bulk-operation-details.component.html'\n})\nexport class BulkOperationDetailsComponent {\n allFilterIsSelected: boolean = false;\n collapsed: boolean;\n device: IManagedObject;\n\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n readOnly: boolean = false;\n @Output() showFailedOperation: EventEmitter<number> = new EventEmitter();\n\n scrollToRetriedFromOperation(failedOperationId) {\n this.showFailedOperation.emit(failedOperationId);\n }\n}\n","import { gettext } from '@c8y/ngx-components';\n\nexport const SINGLE_OP_STATUS_NAMES = {\n PENDING: gettext('Pending'),\n EXECUTING: gettext('Executing'),\n FAILED: gettext('Failed'),\n SUCCESSFUL: gettext('Successful'),\n ALL: gettext('All')\n};\n\nexport const SINGLE_OP_STATUS_PROPERTIES = [\n {\n label: SINGLE_OP_STATUS_NAMES.PENDING,\n iconClass: 'dlt-c8y-icon-clock-o text-info',\n selected: false\n },\n {\n label: SINGLE_OP_STATUS_NAMES.EXECUTING,\n iconClass: 'dlt-c8y-icon-refresh text-info',\n selected: false\n },\n {\n label: SINGLE_OP_STATUS_NAMES.SUCCESSFUL,\n iconClass: 'dlt-c8y-icon-check-circle text-success',\n selected: false\n },\n {\n label: SINGLE_OP_STATUS_NAMES.FAILED,\n iconClass: 'dlt-c8y-icon-exclamation-circle text-danger',\n selected: false\n }\n];\n","import {\n AfterViewInit,\n Component,\n EventEmitter,\n Input,\n OnChanges,\n Output,\n SimpleChanges,\n ViewChild\n} from '@angular/core';\nimport { IOperation, IOperationBulk, IResultList } from '@c8y/client';\nimport { StatusFilterComponent, IStatusOption } from '@c8y/ngx-components/operations/status-filter';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { SINGLE_OP_STATUS_NAMES, SINGLE_OP_STATUS_PROPERTIES } from './single-operation-item.model';\n\n@Component({\n selector: 'c8y-single-operations-list',\n templateUrl: './single-operations-list.component.html'\n})\nexport class SingleOperationsListComponent implements AfterViewInit, OnChanges {\n @Input()\n bulkOperation: Partial<IOperationBulk>;\n @Input()\n readOnly: boolean = false;\n @Output() onRetryFailedOperations: EventEmitter<Partial<IOperationBulk>> = new EventEmitter();\n\n @ViewChild(StatusFilterComponent, { static: false })\n statusFilter: StatusFilterComponent;\n\n singleOperationStatusProperties = SINGLE_OP_STATUS_PROPERTIES;\n singleOperationStatusNames = SINGLE_OP_STATUS_NAMES;\n singleOperations: IResultList<IOperation>;\n\n constructor(private bulkOperationsService: BulkOperationsService) {}\n\n async ngAfterViewInit() {\n if (this.statusFilter) {\n this.filterOperationsByType();\n }\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes.bulkOperation && !changes.bulkOperation.firstChange) {\n this.filterOperationsByType();\n }\n }\n\n filterOperationsByType() {\n if (this.statusFilter) {\n const typeFilter = this.getFilterTypeOfSingleOperations();\n\n this.statusFilter.preset(\n typeFilter === this.singleOperationStatusNames.ALL\n ? []\n : [{ label: typeFilter } as IStatusOption]\n );\n } else {\n setTimeout(this.filterOperationsByType.bind(this));\n }\n }\n\n getFilterTypeOfSingleOperations() {\n const progress = this.bulkOperation.progress;\n\n if (progress.failed > 0) {\n return this.singleOperationStatusNames.FAILED;\n } else if (progress.failed === 0 && progress.successful === 0 && progress.pending === 0) {\n return this.singleOperationStatusNames.EXECUTING;\n } else if (progress.failed === 0 && progress.successful === 0 && progress.executing === 0) {\n return this.singleOperationStatusNames.PENDING;\n } else if (progress.failed === 0 && progress.pending === 0 && progress.executing === 0) {\n return this.singleOperationStatusNames.SUCCESSFUL;\n }\n\n return this.singleOperationStatusNames.ALL;\n }\n\n async getOperationsByStatus(filter: IStatusOption[]) {\n this.singleOperations = await this.bulkOperationsService.getSingleOperationsByStatus(\n filter[0] && filter[0].label,\n this.bulkOperation.id\n );\n }\n\n retryBulkOperation() {\n this.onRetryFailedOperations.emit(this.bulkOperation);\n }\n}\n","import { Component, ElementRef, Input, ViewChild } from '@angular/core';\nimport { IOperation } from '@c8y/client';\nimport { AlertService, gettext } from '@c8y/ngx-components';\nimport { BulkOperationsService } from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { omit } from 'lodash-es';\nimport { SINGLE_OP_STATUS_NAMES, SINGLE_OP_STATUS_PROPERTIES } from './single-operation-item.model';\n\n@Component({\n selector: 'c8y-single-operation-item',\n templateUrl: './single-operation-item.component.html'\n})\nexport class SingleOperationItemComponent {\n device = {};\n showIfTextTruncated = false;\n singleOperationStatusNames = SINGLE_OP_STATUS_NAMES;\n singleOperationsStatusProperties = SINGLE_OP_STATUS_PROPERTIES;\n iconClass: string;\n @Input()\n operation: IOperation;\n @Input()\n readOnly: boolean = false;\n @ViewChild('failureReason', { static: true }) failureReasonRef: ElementRef;\n\n constructor(\n private bulkOperationsService: BulkOperationsService,\n private alertService: AlertService\n ) {}\n\n async ngOnInit() {\n this.iconClass = this.getIconClass();\n this.device = await this.getDeviceMO(this.operation.deviceId);\n }\n\n ngAfterViewInit() {\n this.isTextTruncated();\n }\n\n async retrySingleOperation(singleOperation) {\n const operationToCreate = omit(singleOperation, [\n 'id',\n 'self',\n 'status',\n 'failureReason',\n 'creationTime',\n 'delivery'\n ]);\n\n try {\n await this.bulkOperationsService.createSingleOperation(operationToCreate);\n this.alertService.success(gettext('Operation created.'));\n } catch (er) {\n this.alertService.addServerFailure(er);\n }\n }\n\n getIconClass() {\n return this.singleOperationsStatusProperties.find(\n operationProperties => operationProperties.label.toUpperCase() === this.operation.status\n ).iconClass;\n }\n\n private async getDeviceMO(deviceId) {\n const inventoryMO = await this.bulkOperationsService.getManagedObject(deviceId);\n if (inventoryMO) {\n return inventoryMO.data;\n }\n }\n\n private isTextTruncated() {\n if (this.operation.failureReason) {\n const el = this.failureReasonRef.nativeElement;\n this.showIfTextTruncated = el.offsetWidth < el.scrollWidth ? true : false;\n }\n }\n}\n","import { Component, EventEmitter, Output, OnInit } from '@angular/core';\nimport { Router } from '@angular/router';\nimport {\n BulkOperationsService,\n OperationType\n} from '@c8y/ngx-components/operations/bulk-operations-service';\nimport { BulkOperationModalsService } from '../modals/bulk-operation-modals.service';\n\n@Component({\n selector: 'c8y-bulk-operation-type-list',\n templateUrl: './bulk-operation-type-list.component.html'\n})\nexport class BulkOperationTypeListComponent implements OnInit {\n @Output() onCustomType: EventEmitter<OperationType> = new EventEmitter();\n bulkList: OperationType[] = [];\n\n constructor(\n private router: Router,\n private bulkOperationsService: BulkOperationsService,\n private bulkOperationModalsService: BulkOperationModalsService\n ) {}\n\n ngOnInit() {\n this.bulkList = this.bulkOperationsService.getBulkTypes();\n }\n\n handleClick(item: OperationType) {\n if (item.path) {\n this.bulkOperationModalsService.hideNewBulkOperationModal();\n this.router.navigateByUrl(item.path);\n } else if (item.component) {\n this.onCustomType.emit(item);\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouterModule } from '@angular/router';\nimport { PopoverModule } from 'ngx-bootstrap/popover';\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\n\nimport { CoreModule, Route } from '@c8y/ngx-components';\nimport { StatusFilterModule } from '@c8y/ngx-components/operations/status-filter';\nimport { OperationSummaryModule } from '@c8y/ngx-components/operations/operation-summary';\nimport { BulkOperationSchedulerModule } from '@c8y/ngx-components/operations/bulk-operation-scheduler';\n\nimport { BulkOperationDetailsService } from './bulk-operation-details.service';\nimport { BulkOperationsListComponent } from './bulk-operations-list.component';\nimport { BulkOperationListItemComponent } from './bulk-operation-list-item.component';\nimport { BulkOperationDetailsTabsComponent } from './bulk-operation-details-tabs.component';\nimport { BulkOperationDetailsComponent } from './bulk-operation-details.component';\nimport { SingleOperationsListComponent } from './single-operations-list.component';\nimport { SingleOperationItemComponent } from './single-operation-item.component';\nimport { BulkOperationWrapperComponent } from './bulk-operation-wrapper.component';\nimport { BulkOperationTypeListComponent } from './type-list/bulk-operation-type-list.component';\nimport { BulkOperationModalsService } from './modals/bulk-operation-modals.service';\nimport { BulkOperationsModalComponent } from './modals/bulk-operations-modal.component';\nimport { BulkOperationsRescheduleModalComponent } from './modals/bulk-operations-reschedule-modal.component';\n\nexport const bulkOperationListRoutes: Route[] = [\n {\n path: 'devicecontrol/bulk',\n component: BulkOperationsListComponent\n }\n];\n\n/**\n * This module allows for displaying the list of bulk operations and their details.\n */\n@NgModule({\n imports: [\n CoreModule,\n PopoverModule,\n TooltipModule,\n StatusFilterModule,\n OperationSummaryModule,\n BulkOperationSchedulerModule,\n RouterModule.forChild(bulkOperationListRoutes)\n ],\n providers: [BulkOperationDetailsService, BulkOperationModalsService],\n declarations: [\n BulkOperationsListComponent,\n BulkOperationListItemComponent,\n BulkOperationDetailsTabsComponent,\n BulkOperationDetailsComponent,\n SingleOperationsListComponent,\n SingleOperationItemComponent,\n BulkOperationWrapperComponent,\n BulkOperationTypeListComponent,\n BulkOperationsModalComponent,\n BulkOperationsRescheduleModalComponent\n ],\n entryComponents: [\n BulkOperationsListComponent,\n BulkOperationListItemComponent,\n BulkOperationDetailsTabsComponent,\n BulkOperationDetailsComponent,\n SingleOperationsListComponent,\n SingleOperationItemComponent,\n BulkOperationWrapperComponent,\n BulkOperationTypeListComponent,\n BulkOperationsModalComponent,\n BulkOperationsRescheduleModalComponent\n ],\n exports: [\n BulkOperationsListComponent,\n BulkOperationListItemComponent,\n BulkOperationDetailsTabsComponent,\n BulkOperationDetailsComponent,\n SingleOperationsListComponent,\n SingleOperationItemComponent,\n BulkOperationWrapperComponent,\n BulkOperationTypeListComponent,\n BulkOperationsModalComponent,\n BulkOperationsRescheduleModalComponent\n ]\n})\nexport class BulkOperationsListModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["tslib_1.__decorate"],"mappings":";;;;;;;;;;;;;;;;IASa,6BAA6B,GAA1C,MAAa,6BAA6B;IAGxC,YACS,2BAAwD,EACxD,QAAoB;QADpB,gCAA2B,GAA3B,2BAA2B,CAA6B;QACxD,aAAQ,GAAR,QAAQ,CAAY;KACzB;CACL,CAAA;;YAHuC,2BAA2B;YAC9C,UAAU;;AAJpB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;YAC5B,6BAA6B;YAC7B,8BAA8B;YAC9B,4BAA4B;YAC5B,sCAAsC;SACvC;KACF,CAAC;GACW,wBAAwB,CAAG;;ACjFxC;;GAEG;;;;"}
@@ -1063,6 +1063,11 @@ let AddFirmwareModalComponent = class AddFirmwareModalComponent {
1063
1063
  };
1064
1064
  this.saving = false;
1065
1065
  this.firmwarePreselected = false;
1066
+ this.textForFirmwareUrlPopover = gettext(`Path for binaries can vary depending on device agent implementation, e.g.:
1067
+ /firmware/binaries/firmware1.bin
1068
+ https://firmware/binary/123
1069
+ ftp://firmware/binary/123.tar.gz
1070
+ `);
1066
1071
  }
1067
1072
  ngOnInit() {
1068
1073
  this.setInitialState();
@@ -1164,7 +1169,7 @@ __decorate([
1164
1169
  AddFirmwareModalComponent = __decorate([
1165
1170
  Component({
1166
1171
  selector: 'c8y-add-firmware-software-modal',
1167
- template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'c8y-firmware'\"></i>\n <h4 translate>\n Add firmware\n </h4>\n </div>\n <div class=\"p-16 text-center separator-bottom\" *ngIf=\"!firmwarePreselected\">\n <p class=\"lead m-0\" translate>\n Select or create new firmware\n </p>\n </div>\n <form\n class=\"d-contents\"\n autocomplete=\"off\"\n #firmwareForm=\"ngForm\"\n (ngSubmit)=\"firmwareForm.form.valid && save()\"\n >\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <div [hidden]=\"firmwarePreselected\">\n <c8y-form-group>\n <label for=\"firmwareName\" translate>Firmware</label>\n <c8y-typeahead\n [(ngModel)]=\"model.selected\"\n name=\"firmwareName\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"onInput.next($event)\"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"\n let firmware of firmwaresResult;\n loadMore: 'auto';\n notFound: notFoundTemplate\n \"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"onFirmwareSelect(firmware)\"\n [active]=\"model.selected === firmware\"\n >\n <c8y-highlight\n [text]=\"firmware.name || '--'\"\n [pattern]=\"onInput | async\"\n ></c8y-highlight>\n </c8y-li>\n <ng-template #notFoundTemplate>\n <c8y-li class=\"bg-gray-lighter p-8\" *ngIf=\"(onInput | async)?.length > 0\">\n <span translate>No match found, add new`firmware`? </span>\n <button\n title=\"{{ 'Create new`firmware`' | translate }}\"\n type=\"button\"\n class=\"btn btn-primary btn-xs m-l-16\"\n translate\n >\n Create new`firmware`\n </button>\n </c8y-li>\n </ng-template>\n </c8y-typeahead>\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"firmwareDescription\" translate>Description</label>\n <input\n id=\"firmwareDescription\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"description\"\n [(ngModel)]=\"model.description\"\n placeholder=\"{{ 'e.g. Firmware for hardware revision b' | translate }}\"\n [disabled]=\"model.selected?.id\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"firmwareDeviceTypeFilter\" translate>Device type filter</label>\n <input\n id=\"firmwareDeviceTypeFilter\"\n class=\"form-control\"\n name=\"firmwareDeviceTypeFilter\"\n popover=\"{{\n 'If the filter is set, the firmware will show up for installation only for devices of that type. If no filter is set, it will be available for all devices.'\n | translate\n }}\"\n [(ngModel)]=\"model.deviceType\"\n placeholder=\"{{ 'e.g.' | translate }} c8y_Linux\"\n [disabled]=\"model.selected?.id\"\n />\n </c8y-form-group>\n </div>\n\n <c8y-form-group>\n <label for=\"firmwareVersion\" translate>Version</label>\n <input\n id=\"firmwareVersion\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"version\"\n [(ngModel)]=\"model.version\"\n placeholder=\"{{ 'e.g.' | translate }} 1.0.0\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Firmware file</div>\n <c8y-file-picker [maxAllowedFiles]=\"1\" (onFilesPicked)=\"onFile($event)\">\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n <div class=\"modal-footer\">\n <button\n title=\"{{ 'Cancel' | translate }}\"\n class=\"btn btn-default\"\n type=\"button\"\n (click)=\"cancel()\"\n [disabled]=\"saving\"\n translate\n >\n Cancel\n </button>\n\n <button\n title=\"{{ 'Add firmware' | translate }}\"\n class=\"btn btn-primary\"\n type=\"submit\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !firmwareForm.form.valid ||\n firmwareForm.form.pristine ||\n saving ||\n (!model.binary?.url && !model.binary?.file)\n \"\n translate\n >\n Add firmware\n </button>\n </div>\n </form>\n</div>\n"
1172
+ template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'c8y-firmware'\"></i>\n <h4 translate>\n Add firmware\n </h4>\n </div>\n <div class=\"p-16 text-center separator-bottom\" *ngIf=\"!firmwarePreselected\">\n <p class=\"lead m-0\" translate>\n Select or create new firmware\n </p>\n </div>\n <form\n class=\"d-contents\"\n autocomplete=\"off\"\n #firmwareForm=\"ngForm\"\n (ngSubmit)=\"firmwareForm.form.valid && save()\"\n >\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <div [hidden]=\"firmwarePreselected\">\n <c8y-form-group>\n <label for=\"firmwareName\" translate>Firmware</label>\n <c8y-typeahead\n [(ngModel)]=\"model.selected\"\n name=\"firmwareName\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"onInput.next($event)\"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"\n let firmware of firmwaresResult;\n loadMore: 'auto';\n notFound: notFoundTemplate\n \"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"onFirmwareSelect(firmware)\"\n [active]=\"model.selected === firmware\"\n >\n <c8y-highlight\n [text]=\"firmware.name || '--'\"\n [pattern]=\"onInput | async\"\n ></c8y-highlight>\n </c8y-li>\n <ng-template #notFoundTemplate>\n <c8y-li class=\"bg-gray-lighter p-8\" *ngIf=\"(onInput | async)?.length > 0\">\n <span translate>No match found, add new`firmware`? </span>\n <button\n title=\"{{ 'Create new`firmware`' | translate }}\"\n type=\"button\"\n class=\"btn btn-primary btn-xs m-l-16\"\n translate\n >\n Create new`firmware`\n </button>\n </c8y-li>\n </ng-template>\n </c8y-typeahead>\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"firmwareDescription\" translate>Description</label>\n <input\n id=\"firmwareDescription\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"description\"\n [(ngModel)]=\"model.description\"\n placeholder=\"{{ 'e.g. Firmware for hardware revision b' | translate }}\"\n [disabled]=\"model.selected?.id\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"firmwareDeviceTypeFilter\" translate>Device type filter</label>\n <input\n id=\"firmwareDeviceTypeFilter\"\n class=\"form-control\"\n name=\"firmwareDeviceTypeFilter\"\n popover=\"{{\n 'If the filter is set, the firmware will show up for installation only for devices of that type. If no filter is set, it will be available for all devices.'\n | translate\n }}\"\n [(ngModel)]=\"model.deviceType\"\n placeholder=\"{{ 'e.g.' | translate }} c8y_Linux\"\n [disabled]=\"model.selected?.id\"\n />\n </c8y-form-group>\n </div>\n\n <c8y-form-group>\n <label for=\"firmwareVersion\" translate>Version</label>\n <input\n id=\"firmwareVersion\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"version\"\n [(ngModel)]=\"model.version\"\n placeholder=\"{{ 'e.g.' | translate }} 1.0.0\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Firmware file</div>\n <c8y-file-picker [maxAllowedFiles]=\"1\" (onFilesPicked)=\"onFile($event)\" [fileUrlPopover]=\"textForFirmwareUrlPopover\">\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n <div class=\"modal-footer\">\n <button\n title=\"{{ 'Cancel' | translate }}\"\n class=\"btn btn-default\"\n type=\"button\"\n (click)=\"cancel()\"\n [disabled]=\"saving\"\n translate\n >\n Cancel\n </button>\n\n <button\n title=\"{{ 'Add firmware' | translate }}\"\n class=\"btn btn-primary\"\n type=\"submit\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !firmwareForm.form.valid ||\n firmwareForm.form.pristine ||\n saving ||\n (!model.binary?.url && !model.binary?.file)\n \"\n translate\n >\n Add firmware\n </button>\n </div>\n </form>\n</div>\n"
1168
1173
  })
1169
1174
  ], AddFirmwareModalComponent);
1170
1175
 
@@ -1174,6 +1179,11 @@ let AddFirmwarePatchModalComponent = class AddFirmwarePatchModalComponent {
1174
1179
  this.repository = repository;
1175
1180
  this.alert = alert;
1176
1181
  this.saved = new EventEmitter();
1182
+ this.textForFirmwareUrlPopover = gettext(`Path for binaries can vary depending on device agent implementation, e.g.:
1183
+ /firmware/binaries/firmware1.bin
1184
+ https://firmware/binary/123
1185
+ ftp://firmware/binary/123.tar.gz
1186
+ `);
1177
1187
  this.model = {
1178
1188
  selected: undefined,
1179
1189
  dependency: null,
@@ -1278,7 +1288,7 @@ __decorate([
1278
1288
  AddFirmwarePatchModalComponent = __decorate([
1279
1289
  Component({
1280
1290
  selector: 'c8y-add-firmware-patch-modal.component',
1281
- template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'c8y-firmware'\"></i>\n <h4 translate>\n Add firmware patch\n </h4>\n </div>\n <div class=\"p-16 text-center separator-bottom\">\n <p class=\"lead m-0\" translate>\n Select a firmware version\n </p>\n </div>\n\n <form class=\"d-contents\" autocomplete=\"off\" #firmwarePatchForm=\"ngForm\" (ngSubmit)=\"save()\">\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <div [hidden]=\"firmwarePreselected\">\n <c8y-form-group>\n <label for=\"firmwareName\" translate>Firmware</label>\n <c8y-typeahead\n [ngModel]=\"model.selected\"\n name=\"firmwareName\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"firmwareInput$.next($event)\"\n [allowFreeEntries]=\"false\"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"let firmware of firmwares$ | async; loadMore: 'auto'\"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"model.selected = firmware; firmwareSelected$.next(firmware)\"\n [active]=\"model.selected === firmware\"\n >\n <c8y-highlight\n [text]=\"firmware.name || '--'\"\n [pattern]=\"firmwareInput$ | async\"\n ></c8y-highlight>\n </c8y-li>\n </c8y-typeahead>\n <c8y-messages\n ><c8y-message\n name=\"notExisting\"\n [text]=\"'Select one of the existing firmwares.' | translate\"\n ></c8y-message>\n </c8y-messages>\n </c8y-form-group>\n </div>\n\n <c8y-form-group>\n <label for=\"patchDependency\" class=\"m-r-8\" translate>Version</label>\n <c8y-typeahead\n [ngModel]=\"model.dependency\"\n name=\"patchDependency\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"patchDependencyInput$.next($event)\"\n [displayProperty]=\"'c8y_Firmware.version'\"\n [allowFreeEntries]=\"false\"\n [disabled]=\"\n (baseVersions$ | async) === null || (baseVersions$ | async)?.data.length === 0\n \"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"\n let baseVersion of baseVersions$;\n loadMore: 'auto';\n pipe: baseVersionsFilterPipe\n \"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"model.dependency = baseVersion\"\n [active]=\"model.dependency === baseVersion\"\n >\n <c8y-highlight\n [text]=\"baseVersion.c8y_Firmware.version || '--'\"\n [pattern]=\"patchDependencyInput$ | async\"\n ></c8y-highlight>\n </c8y-li>\n </c8y-typeahead>\n <c8y-messages\n ><c8y-message\n name=\"notExisting\"\n [text]=\"'Select one of the existing versions.' | translate\"\n ></c8y-message>\n </c8y-messages>\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"patchVersion\" translate>Patch</label>\n <input\n id=\"patchVersion\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"patchVersion\"\n [(ngModel)]=\"model.patchVersion\"\n placeholder=\"{{ 'e.g.' | translate }} 1.0.0\"\n required\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Patch file</div>\n <c8y-file-picker [maxAllowedFiles]=\"1\" (onFilesPicked)=\"onFile($event)\">\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n <div class=\"modal-footer\">\n <button\n title=\"{{ 'Cancel' | translate }}\"\n class=\"btn btn-default\"\n type=\"button\"\n (click)=\"cancel()\"\n [disabled]=\"saving\"\n translate\n >\n Cancel\n </button>\n <button\n title=\"{{ 'Add firmware patch' | translate }}\"\n class=\"btn btn-primary\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n type=\"submit\"\n [disabled]=\"\n !firmwarePatchForm.form.valid ||\n firmwarePatchForm.form.pristine ||\n (!model.binary?.url && !model.binary?.file) ||\n saving\n \"\n translate\n >\n Add firmware patch\n </button>\n </div>\n </form>\n</div>\n"
1291
+ template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'c8y-firmware'\"></i>\n <h4 translate>\n Add firmware patch\n </h4>\n </div>\n <div class=\"p-16 text-center separator-bottom\">\n <p class=\"lead m-0\" translate>\n Select a firmware version\n </p>\n </div>\n\n <form\n class=\"d-contents\"\n autocomplete=\"off\"\n #firmwarePatchForm=\"ngForm\"\n (ngSubmit)=\"firmwarePatchForm.form.valid && save()\"\n >\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <div [hidden]=\"firmwarePreselected\">\n <c8y-form-group>\n <label for=\"firmwareName\" translate>Firmware</label>\n <c8y-typeahead\n [ngModel]=\"model.selected\"\n name=\"firmwareName\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"firmwareInput$.next($event)\"\n [allowFreeEntries]=\"false\"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"let firmware of firmwares$ | async; loadMore: 'auto'\"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"model.selected = firmware; firmwareSelected$.next(firmware)\"\n [active]=\"model.selected === firmware\"\n >\n <c8y-highlight\n [text]=\"firmware.name || '--'\"\n [pattern]=\"firmwareInput$ | async\"\n ></c8y-highlight>\n </c8y-li>\n </c8y-typeahead>\n <c8y-messages\n ><c8y-message\n name=\"notExisting\"\n [text]=\"'Select one of the existing firmwares.' | translate\"\n ></c8y-message>\n </c8y-messages>\n </c8y-form-group>\n </div>\n\n <c8y-form-group>\n <label for=\"patchDependency\" class=\"m-r-8\" translate>Version</label>\n <c8y-typeahead\n [ngModel]=\"model.dependency\"\n name=\"patchDependency\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"patchDependencyInput$.next($event)\"\n [displayProperty]=\"'c8y_Firmware.version'\"\n [allowFreeEntries]=\"false\"\n [disabled]=\"\n (baseVersions$ | async) === null || (baseVersions$ | async)?.data.length === 0\n \"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"\n let baseVersion of baseVersions$;\n loadMore: 'auto';\n pipe: baseVersionsFilterPipe\n \"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"model.dependency = baseVersion\"\n [active]=\"model.dependency === baseVersion\"\n >\n <c8y-highlight\n [text]=\"baseVersion.c8y_Firmware.version || '--'\"\n [pattern]=\"patchDependencyInput$ | async\"\n ></c8y-highlight>\n </c8y-li>\n </c8y-typeahead>\n <c8y-messages\n ><c8y-message\n name=\"notExisting\"\n [text]=\"'Select one of the existing versions.' | translate\"\n ></c8y-message>\n </c8y-messages>\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"patchVersion\" translate>Patch</label>\n <input\n id=\"patchVersion\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"patchVersion\"\n [(ngModel)]=\"model.patchVersion\"\n placeholder=\"{{ 'e.g.' | translate }} 1.0.0\"\n required\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Patch file</div>\n <c8y-file-picker [maxAllowedFiles]=\"1\" (onFilesPicked)=\"onFile($event)\" [fileUrlPopover]=\"textForFirmwareUrlPopover\">\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n <div class=\"modal-footer\">\n <button\n title=\"{{ 'Cancel' | translate }}\"\n class=\"btn btn-default\"\n type=\"button\"\n (click)=\"cancel()\"\n [disabled]=\"saving\"\n translate\n >\n Cancel\n </button>\n <button\n title=\"{{ 'Add firmware patch' | translate }}\"\n class=\"btn btn-primary\"\n type=\"submit\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !firmwarePatchForm.form.valid ||\n firmwarePatchForm.form.pristine ||\n (!model.binary?.url && !model.binary?.file) ||\n saving\n \"\n translate\n >\n Add firmware patch\n </button>\n </div>\n </form>\n</div>\n"
1282
1292
  })
1283
1293
  ], AddFirmwarePatchModalComponent);
1284
1294
 
@@ -1544,6 +1554,11 @@ let AddSoftwareModalComponent = class AddSoftwareModalComponent {
1544
1554
  };
1545
1555
  this.saving = false;
1546
1556
  this.softwarePreselected = false;
1557
+ this.textForSoftwareUrlPopover = gettext(`Path for binaries can vary depending on device agent implementation, e.g.:
1558
+ /software/binaries/software1.bin
1559
+ https://software/binary/123
1560
+ ftp://software/binary/123.tar.gz
1561
+ `);
1547
1562
  }
1548
1563
  ngOnInit() {
1549
1564
  this.setInitialState();
@@ -1645,7 +1660,7 @@ __decorate([
1645
1660
  AddSoftwareModalComponent = __decorate([
1646
1661
  Component({
1647
1662
  selector: 'c8y-add-software-software-modal',
1648
- template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'c8y-tools'\"></i>\n <h4 translate>\n Add software\n </h4>\n </div>\n <div class=\"p-16 text-center separator-bottom\" *ngIf=\"!softwarePreselected\">\n <p class=\"lead m-0\" translate>\n Select or create new software\n </p>\n </div>\n <form\n class=\"d-contents\"\n autocomplete=\"off\"\n #softwareForm=\"ngForm\"\n (ngSubmit)=\"softwareForm.form.valid && save()\"\n >\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <div [hidden]=\"softwarePreselected\">\n <c8y-form-group>\n <label for=\"softwareName\" translate>Software</label>\n <c8y-typeahead\n [(ngModel)]=\"model.selected\"\n name=\"softwareName\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"onInput.next($event)\"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"\n let software of softwaresResult;\n loadMore: 'auto';\n notFound: notFoundTemplate\n \"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"onSoftwareSelect(software)\"\n [active]=\"model.selected === software\"\n >\n <c8y-highlight\n [text]=\"software.name || '--'\"\n [pattern]=\"onInput | async\"\n ></c8y-highlight>\n </c8y-li>\n <ng-template #notFoundTemplate>\n <c8y-li class=\"bg-gray-lighter p-8\" *ngIf=\"(onInput | async)?.length > 0\">\n <span translate>No match found, add new`software`? </span>\n <button\n title=\"{{ 'Create new`software`' | translate }}\"\n type=\"button\"\n class=\"btn btn-primary btn-xs m-l-16\"\n translate\n >\n Create new`software`\n </button>\n </c8y-li>\n </ng-template>\n </c8y-typeahead>\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"softwareDescription\" translate>Description</label>\n <input\n id=\"softwareDescription\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"description\"\n [(ngModel)]=\"model.description\"\n placeholder=\"{{ 'e.g. Cloud connectivity software' | translate }}\"\n [disabled]=\"model.selected?.id\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"softwareDeviceTypeFilter\" translate>Device type filter</label>\n <input\n id=\"softwareDeviceTypeFilter\"\n class=\"form-control\"\n name=\"softwareDeviceTypeFilter\"\n popover=\"{{\n 'If the filter is set, the firmware will show up for installation only for devices of that type. If no filter is set, it will be available for all devices.'\n | translate\n }}\"\n [(ngModel)]=\"model.deviceType\"\n placeholder=\"{{ 'e.g.' | translate }} c8y_Linux\"\n [disabled]=\"model.selected?.id\"\n />\n </c8y-form-group>\n </div>\n\n <c8y-form-group>\n <label for=\"softwareVersion\" translate>Version</label>\n <input\n id=\"softwareVersion\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"version\"\n [(ngModel)]=\"model.version\"\n placeholder=\"{{ 'e.g.' | translate }} 1.0.0\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Software file</div>\n <c8y-file-picker [maxAllowedFiles]=\"1\" (onFilesPicked)=\"onFile($event)\">\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n <div class=\"modal-footer\">\n <button\n title=\"{{ 'Cancel' | translate }}\"\n class=\"btn btn-default\"\n type=\"button\"\n (click)=\"cancel()\"\n [disabled]=\"saving\"\n translate\n >\n Cancel\n </button>\n\n <button\n title=\"{{ 'Add software' | translate }}\"\n class=\"btn btn-primary\"\n type=\"submit\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !softwareForm.form.valid ||\n softwareForm.form.pristine ||\n saving ||\n (!model.binary?.url && !model.binary?.file)\n \"\n translate\n >\n Add software\n </button>\n </div>\n </form>\n</div>\n"
1663
+ template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'c8y-tools'\"></i>\n <h4 translate>\n Add software\n </h4>\n </div>\n <div class=\"p-16 text-center separator-bottom\" *ngIf=\"!softwarePreselected\">\n <p class=\"lead m-0\" translate>\n Select or create new software\n </p>\n </div>\n <form\n class=\"d-contents\"\n autocomplete=\"off\"\n #softwareForm=\"ngForm\"\n (ngSubmit)=\"softwareForm.form.valid && save()\"\n >\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <div [hidden]=\"softwarePreselected\">\n <c8y-form-group>\n <label for=\"softwareName\" translate>Software</label>\n <c8y-typeahead\n [(ngModel)]=\"model.selected\"\n name=\"softwareName\"\n placeholder=\"{{ 'Select or enter' | translate }}\"\n (onSearch)=\"onInput.next($event)\"\n [required]=\"true\"\n >\n <c8y-li\n *c8yFor=\"\n let software of softwaresResult;\n loadMore: 'auto';\n notFound: notFoundTemplate\n \"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"onSoftwareSelect(software)\"\n [active]=\"model.selected === software\"\n >\n <c8y-highlight\n [text]=\"software.name || '--'\"\n [pattern]=\"onInput | async\"\n ></c8y-highlight>\n </c8y-li>\n <ng-template #notFoundTemplate>\n <c8y-li class=\"bg-gray-lighter p-8\" *ngIf=\"(onInput | async)?.length > 0\">\n <span translate>No match found, add new`software`? </span>\n <button\n title=\"{{ 'Create new`software`' | translate }}\"\n type=\"button\"\n class=\"btn btn-primary btn-xs m-l-16\"\n translate\n >\n Create new`software`\n </button>\n </c8y-li>\n </ng-template>\n </c8y-typeahead>\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"softwareDescription\" translate>Description</label>\n <input\n id=\"softwareDescription\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"description\"\n [(ngModel)]=\"model.description\"\n placeholder=\"{{ 'e.g. Cloud connectivity software' | translate }}\"\n [disabled]=\"model.selected?.id\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label for=\"softwareDeviceTypeFilter\" translate>Device type filter</label>\n <input\n id=\"softwareDeviceTypeFilter\"\n class=\"form-control\"\n name=\"softwareDeviceTypeFilter\"\n popover=\"{{\n 'If the filter is set, the firmware will show up for installation only for devices of that type. If no filter is set, it will be available for all devices.'\n | translate\n }}\"\n [(ngModel)]=\"model.deviceType\"\n placeholder=\"{{ 'e.g.' | translate }} c8y_Linux\"\n [disabled]=\"model.selected?.id\"\n />\n </c8y-form-group>\n </div>\n\n <c8y-form-group>\n <label for=\"softwareVersion\" translate>Version</label>\n <input\n id=\"softwareVersion\"\n class=\"form-control\"\n autocomplete=\"off\"\n name=\"version\"\n [(ngModel)]=\"model.version\"\n placeholder=\"{{ 'e.g.' | translate }} 1.0.0\"\n [required]=\"true\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Software file</div>\n <c8y-file-picker [maxAllowedFiles]=\"1\" (onFilesPicked)=\"onFile($event)\" [fileUrlPopover]=\"textForSoftwareUrlPopover\">\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n <div class=\"modal-footer\">\n <button\n title=\"{{ 'Cancel' | translate }}\"\n class=\"btn btn-default\"\n type=\"button\"\n (click)=\"cancel()\"\n [disabled]=\"saving\"\n translate\n >\n Cancel\n </button>\n\n <button\n title=\"{{ 'Add software' | translate }}\"\n class=\"btn btn-primary\"\n type=\"submit\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !softwareForm.form.valid ||\n softwareForm.form.pristine ||\n saving ||\n (!model.binary?.url && !model.binary?.file)\n \"\n translate\n >\n Add software\n </button>\n </div>\n </form>\n</div>\n"
1649
1664
  })
1650
1665
  ], AddSoftwareModalComponent);
1651
1666
 
@@ -1841,6 +1856,11 @@ let ConfigurationDetailComponent = class ConfigurationDetailComponent {
1841
1856
  this.mo = {};
1842
1857
  this.saving = false;
1843
1858
  this.uploadChoice = 'uploadBinary';
1859
+ this.textForConfigurationUrlPopover = gettext(`Path for binaries can vary depending on device agent implementation, e.g.:
1860
+ /configuration/binaries/configuration1.bin
1861
+ https://configuration/binary/123
1862
+ ftp://configuration/binary/123.tar.gz
1863
+ `);
1844
1864
  this.result = new Promise((resolve, reject) => {
1845
1865
  this._save = resolve;
1846
1866
  this._cancel = reject;
@@ -1925,7 +1945,7 @@ __decorate([
1925
1945
  ConfigurationDetailComponent = __decorate([
1926
1946
  Component({
1927
1947
  selector: 'c8y-configuration-detail',
1928
- template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'cogs'\"></i>\n <h4 translate *ngIf=\"mo.id\">Update configuration</h4>\n <h4 translate *ngIf=\"!mo.id\">Add configuration</h4>\n </div>\n\n <form class=\"d-contents\" #configurationForm=\"ngForm\" (ngSubmit)=\"configurationForm.form.valid && save()\">\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <c8y-form-group>\n <label translate>Name</label>\n <input\n type=\"text\"\n class=\"form-control\"\n placeholder=\"{{ 'e.g.' | translate }} hosts\"\n autocomplete=\"off\"\n required\n maxlength=\"254\"\n [(ngModel)]=\"version\"\n name=\"version\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label translate>Device type</label>\n <input\n type=\"text\"\n class=\"form-control\"\n placeholder=\"{{ 'e.g.' | translate }} c8y_Linux\"\n maxlength=\"254\"\n autocomplete=\"off\"\n [(ngModel)]=\"deviceType\"\n name=\"deviceType\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label translate>Description</label>\n <input\n type=\"text\"\n class=\"form-control\"\n placeholder=\"{{ 'e.g. Host configuration' | translate }} c8y_Linux\"\n maxlength=\"254\"\n autocomplete=\"off\"\n [(ngModel)]=\"description\"\n name=\"description\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label translate>Configuration type</label>\n <c8y-typeahead\n [(ngModel)]=\"selected\"\n name=\"confType\"\n placeholder=\"{{ 'e.g.' | translate }} ssh\"\n (onSearch)=\"setPipe($event)\"\n displayProperty=\"configurationType\"\n >\n <c8y-li\n *c8yFor=\"let config of configs; pipe: filterPipe; notFound: notFoundTemplate\"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"selected = config; setPipe('')\"\n [active]=\"selected === config\"\n >\n <c8y-highlight\n [text]=\"config.configurationType || '--'\"\n [pattern]=\"pattern\"\n ></c8y-highlight>\n </c8y-li>\n <ng-template #notFoundTemplate>\n <c8y-li class=\"bg-gray-lighter p-8\" *ngIf=\"pattern.length > 0\">\n <span translate>No match found, add new`configuration`?</span>\n <button title=\"Create new`configuration`\" type=\"button\" class=\"btn btn-primary btn-xs m-l-16\" translate>\n Create new`configuration`\n </button>\n </c8y-li>\n </ng-template>\n </c8y-typeahead>\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Configuration file</div>\n <c8y-file-picker\n [maxAllowedFiles]=\"1\"\n (onFilesPicked)=\"onFile($event)\"\n [uploadChoice]=\"uploadChoice\"\n [fileUrl]=\"binary.url\"\n [fileBinary]=\"binary.file\"\n >\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n\n <div class=\"modal-footer\">\n <button\n (click)=\"cancel()\"\n type=\"button\"\n class=\"btn btn-default\"\n title=\"{{ 'Cancel' | translate }}\"\n [disabled]=\"saving\"\n >\n <span translate>Cancel</span>\n </button>\n <button\n class=\"btn btn-primary\"\n type=\"submit\"\n title=\"{{ submitButtonTitle | translate }}\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !configurationForm.valid ||\n configurationForm.pristine ||\n (!binary?.url && !binary?.file) ||\n saving\n \"\n >\n {{ submitButtonTitle | translate }}\n </button>\n </div>\n </form>\n</div>\n"
1948
+ template: "<div class=\"viewport-modal\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'cogs'\"></i>\n <h4 translate *ngIf=\"mo.id\">Update configuration</h4>\n <h4 translate *ngIf=\"!mo.id\">Add configuration</h4>\n </div>\n\n <form class=\"d-contents\" #configurationForm=\"ngForm\" (ngSubmit)=\"configurationForm.form.valid && save()\">\n <div class=\"modal-inner-scroll\">\n <div class=\"modal-body\">\n <c8y-form-group>\n <label translate>Name</label>\n <input\n type=\"text\"\n class=\"form-control\"\n placeholder=\"{{ 'e.g.' | translate }} hosts\"\n autocomplete=\"off\"\n required\n maxlength=\"254\"\n [(ngModel)]=\"version\"\n name=\"version\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label translate>Device type</label>\n <input\n type=\"text\"\n class=\"form-control\"\n placeholder=\"{{ 'e.g.' | translate }} c8y_Linux\"\n maxlength=\"254\"\n autocomplete=\"off\"\n [(ngModel)]=\"deviceType\"\n name=\"deviceType\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label translate>Description</label>\n <input\n type=\"text\"\n class=\"form-control\"\n placeholder=\"{{ 'e.g. Host configuration' | translate }} c8y_Linux\"\n maxlength=\"254\"\n autocomplete=\"off\"\n [(ngModel)]=\"description\"\n name=\"description\"\n />\n </c8y-form-group>\n\n <c8y-form-group>\n <label translate>Configuration type</label>\n <c8y-typeahead\n [(ngModel)]=\"selected\"\n name=\"confType\"\n placeholder=\"{{ 'e.g.' | translate }} ssh\"\n (onSearch)=\"setPipe($event)\"\n displayProperty=\"configurationType\"\n >\n <c8y-li\n *c8yFor=\"let config of configs; pipe: filterPipe; notFound: notFoundTemplate\"\n class=\"p-l-8 p-r-8 c8y-list__item--link\"\n (click)=\"selected = config; setPipe('')\"\n [active]=\"selected === config\"\n >\n <c8y-highlight\n [text]=\"config.configurationType || '--'\"\n [pattern]=\"pattern\"\n ></c8y-highlight>\n </c8y-li>\n <ng-template #notFoundTemplate>\n <c8y-li class=\"bg-gray-lighter p-8\" *ngIf=\"pattern.length > 0\">\n <span translate>No match found, add new`configuration`?</span>\n <button title=\"Create new`configuration`\" type=\"button\" class=\"btn btn-primary btn-xs m-l-16\" translate>\n Create new`configuration`\n </button>\n </c8y-li>\n </ng-template>\n </c8y-typeahead>\n </c8y-form-group>\n\n <c8y-form-group>\n <div class=\"legend form-block m-t-40\" translate>Configuration file</div>\n <c8y-file-picker\n [maxAllowedFiles]=\"1\"\n (onFilesPicked)=\"onFile($event)\"\n [uploadChoice]=\"uploadChoice\"\n [fileUrl]=\"binary.url\"\n [fileBinary]=\"binary.file\"\n [fileUrlPopover]=\"textForConfigurationUrlPopover\"\n >\n </c8y-file-picker>\n </c8y-form-group>\n </div>\n </div>\n\n <div class=\"modal-footer\">\n <button\n (click)=\"cancel()\"\n type=\"button\"\n class=\"btn btn-default\"\n title=\"{{ 'Cancel' | translate }}\"\n [disabled]=\"saving\"\n >\n <span translate>Cancel</span>\n </button>\n <button\n class=\"btn btn-primary\"\n type=\"submit\"\n title=\"{{ submitButtonTitle | translate }}\"\n [ngClass]=\"{ 'btn-pending': saving }\"\n [disabled]=\"\n !configurationForm.valid ||\n configurationForm.pristine ||\n (!binary?.url && !binary?.file) ||\n saving\n \"\n >\n {{ submitButtonTitle | translate }}\n </button>\n </div>\n </form>\n</div>\n"
1929
1949
  })
1930
1950
  ], ConfigurationDetailComponent);
1931
1951