diff --git a/.github/release.yml b/.github/release.yml index 01ba7d863e..1d760fe7bf 100644 --- a/.github/release.yml +++ b/.github/release.yml @@ -1,5 +1,5 @@ # -# Copyright © 2016-2022 The Thingsboard Authors +# Copyright © 2016-2023 The Thingsboard Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/application/pom.xml b/application/pom.xml index 815243f85b..0d9982f281 100644 --- a/application/pom.xml +++ b/application/pom.xml @@ -1,6 +1,6 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/msa/black-box-tests/src/test/resources/smokesRuleChain.xml b/msa/black-box-tests/src/test/resources/smokesRuleChain.xml index 5834ad6558..dbb22782ca 100644 --- a/msa/black-box-tests/src/test/resources/smokesRuleChain.xml +++ b/msa/black-box-tests/src/test/resources/smokesRuleChain.xml @@ -1,7 +1,7 @@ -
admin.queue-name diff --git a/ui-ngx/src/app/modules/home/components/queue/queue-form.component.scss b/ui-ngx/src/app/modules/home/components/queue/queue-form.component.scss index 874660cbdf..660293581f 100644 --- a/ui-ngx/src/app/modules/home/components/queue/queue-form.component.scss +++ b/ui-ngx/src/app/modules/home/components/queue/queue-form.component.scss @@ -1,5 +1,5 @@ /** - * Copyright © 2016-2022 The Thingsboard Authors + * Copyright © 2016-2023 The Thingsboard Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/ui-ngx/src/app/modules/home/components/queue/queue-form.component.ts b/ui-ngx/src/app/modules/home/components/queue/queue-form.component.ts index 3268c5b2f9..f854fc9edf 100644 --- a/ui-ngx/src/app/modules/home/components/queue/queue-form.component.ts +++ b/ui-ngx/src/app/modules/home/components/queue/queue-form.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -17,9 +17,9 @@ import { Component, forwardRef, Input, OnDestroy, OnInit } from '@angular/core'; import { ControlValueAccessor, - FormBuilder, - FormControl, - FormGroup, + UntypedFormBuilder, + UntypedFormControl, + UntypedFormGroup, NG_VALIDATORS, NG_VALUE_ACCESSOR, Validator, @@ -64,7 +64,7 @@ export class QueueFormComponent implements ControlValueAccessor, OnInit, OnDestr @Input() systemQueue = false; - queueFormGroup: FormGroup; + queueFormGroup: UntypedFormGroup; hideBatchSize = false; queueSubmitStrategyTypes = QueueSubmitStrategyTypes; @@ -80,7 +80,7 @@ export class QueueFormComponent implements ControlValueAccessor, OnInit, OnDestr private valueChange$: Subscription = null; constructor(private utils: UtilsService, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { } registerOnChange(fn: any): void { @@ -167,7 +167,7 @@ export class QueueFormComponent implements ControlValueAccessor, OnInit, OnDestr } } - public validate(c: FormControl) { + public validate(c: UntypedFormControl) { if (c.parent && !this.systemQueue) { const queueName = c.value.name; const profileQueues = []; @@ -199,7 +199,7 @@ export class QueueFormComponent implements ControlValueAccessor, OnInit, OnDestr } submitStrategyTypeChanged() { - const form = this.queueFormGroup.get('submitStrategy') as FormGroup; + const form = this.queueFormGroup.get('submitStrategy') as UntypedFormGroup; const type: QueueSubmitStrategyTypes = form.get('type').value; const batchSizeField = form.get('batchSize'); if (type === QueueSubmitStrategyTypes.BATCH) { diff --git a/ui-ngx/src/app/modules/home/components/relation/relation-dialog.component.html b/ui-ngx/src/app/modules/home/components/relation/relation-dialog.component.html index 9ae32f6fd8..0af8805a50 100644 --- a/ui-ngx/src/app/modules/home/components/relation/relation-dialog.component.html +++ b/ui-ngx/src/app/modules/home/components/relation/relation-dialog.component.html @@ -1,6 +1,6 @@ - {{ 'rulechain.rulechain-required' | translate }} + + + diff --git a/ui-ngx/src/app/modules/home/components/rule-chain/rule-chain-autocomplete.component.ts b/ui-ngx/src/app/modules/home/components/rule-chain/rule-chain-autocomplete.component.ts index 3db424012f..f371f4201f 100644 --- a/ui-ngx/src/app/modules/home/components/rule-chain/rule-chain-autocomplete.component.ts +++ b/ui-ngx/src/app/modules/home/components/rule-chain/rule-chain-autocomplete.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -15,7 +15,7 @@ /// import { Component, ElementRef, forwardRef, Input, OnInit, ViewChild } from '@angular/core'; -import { ControlValueAccessor, FormBuilder, FormGroup, NG_VALUE_ACCESSOR } from '@angular/forms'; +import { ControlValueAccessor, UntypedFormBuilder, UntypedFormGroup, NG_VALUE_ACCESSOR } from '@angular/forms'; import { Observable, of } from 'rxjs'; import { catchError, debounceTime, distinctUntilChanged, map, share, switchMap, tap } from 'rxjs/operators'; import { Store } from '@ngrx/store'; @@ -43,18 +43,19 @@ import { RuleChainType } from '@app/shared/models/rule-chain.models'; }) export class RuleChainAutocompleteComponent implements ControlValueAccessor, OnInit { - selectRuleChainFormGroup: FormGroup; - - ruleChainLabel = 'rulechain.rulechain'; + selectRuleChainFormGroup: UntypedFormGroup; modelValue: string | null; @Input() - labelText: string; + labelText: string = 'rulechain.rulechain'; @Input() requiredText: string; + @Input() + ruleChainType: RuleChainType = RuleChainType.CORE; + private requiredValue: boolean; get required(): boolean { return this.requiredValue; @@ -83,7 +84,7 @@ export class RuleChainAutocompleteComponent implements ControlValueAccessor, OnI public truncate: TruncatePipe, private entityService: EntityService, private ruleChainService: RuleChainService, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { this.selectRuleChainFormGroup = this.fb.group({ ruleChainId: [null] }); @@ -191,9 +192,8 @@ export class RuleChainAutocompleteComponent implements ControlValueAccessor, OnI fetchRuleChain(searchText?: string): Observable>> { this.searchText = searchText; - // @voba: at the moment device profiles are not supported by edge, so 'core' hardcoded return this.entityService.getEntitiesByNameFilter(EntityType.RULE_CHAIN, searchText, - 50, RuleChainType.CORE, {ignoreLoading: true}).pipe( + 50, this.ruleChainType, {ignoreLoading: true}).pipe( catchError(() => of([])) ); } diff --git a/ui-ngx/src/app/modules/home/components/shared-home-components.module.ts b/ui-ngx/src/app/modules/home/components/shared-home-components.module.ts index 2494661584..fbfc297439 100644 --- a/ui-ngx/src/app/modules/home/components/shared-home-components.module.ts +++ b/ui-ngx/src/app/modules/home/components/shared-home-components.module.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. diff --git a/ui-ngx/src/app/modules/home/components/sms/aws-sns-provider-configuration.component.html b/ui-ngx/src/app/modules/home/components/sms/aws-sns-provider-configuration.component.html index e72cd7f077..8b29a5fbdc 100644 --- a/ui-ngx/src/app/modules/home/components/sms/aws-sns-provider-configuration.component.html +++ b/ui-ngx/src/app/modules/home/components/sms/aws-sns-provider-configuration.component.html @@ -1,6 +1,6 @@ -

{{ 'version-control.create-entities-version' | translate }}

diff --git a/ui-ngx/src/app/modules/home/components/vc/complex-version-create.component.ts b/ui-ngx/src/app/modules/home/components/vc/complex-version-create.component.ts index 3d6cf3c735..50edca8ce7 100644 --- a/ui-ngx/src/app/modules/home/components/vc/complex-version-create.component.ts +++ b/ui-ngx/src/app/modules/home/components/vc/complex-version-create.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core'; import { PageComponent } from '@shared/components/page.component'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { ComplexVersionCreateRequest, createDefaultEntityTypesVersionCreate, @@ -52,7 +52,7 @@ export class ComplexVersionCreateComponent extends PageComponent implements OnIn @Input() popoverComponent: TbPopoverComponent; - createVersionFormGroup: FormGroup; + createVersionFormGroup: UntypedFormGroup; syncStrategies = Object.values(SyncStrategy); @@ -77,7 +77,7 @@ export class ComplexVersionCreateComponent extends PageComponent implements OnIn private cd: ChangeDetectorRef, private sanitizer: DomSanitizer, private translate: TranslateService, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } diff --git a/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.html b/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.html index 86e756b7f1..f9904c700f 100644 --- a/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.html +++ b/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.html @@ -1,6 +1,6 @@ -

{{ 'version-control.restore-entities-from-version' | translate: {versionName} }}

diff --git a/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.ts b/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.ts index dda0f6b39d..ce6e85acc1 100644 --- a/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.ts +++ b/ui-ngx/src/app/modules/home/components/vc/complex-version-load.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core'; import { PageComponent } from '@shared/components/page.component'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { createDefaultEntityTypesVersionLoad, EntityTypeLoadResult, EntityTypeVersionLoadRequest, @@ -53,7 +53,7 @@ export class ComplexVersionLoadComponent extends PageComponent implements OnInit @Input() popoverComponent: TbPopoverComponent; - loadVersionFormGroup: FormGroup; + loadVersionFormGroup: UntypedFormGroup; versionLoadResult: VersionLoadResult = null; @@ -72,7 +72,7 @@ export class ComplexVersionLoadComponent extends PageComponent implements OnInit private cd: ChangeDetectorRef, private translate: TranslateService, private sanitizer: DomSanitizer, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } diff --git a/ui-ngx/src/app/modules/home/components/vc/entity-types-version-create.component.html b/ui-ngx/src/app/modules/home/components/vc/entity-types-version-create.component.html index 14c98613fc..a3fee96758 100644 --- a/ui-ngx/src/app/modules/home/components/vc/entity-types-version-create.component.html +++ b/ui-ngx/src/app/modules/home/components/vc/entity-types-version-create.component.html @@ -1,6 +1,6 @@ -

{{ 'version-control.create-entity-version' | translate }}

diff --git a/ui-ngx/src/app/modules/home/components/vc/entity-version-create.component.ts b/ui-ngx/src/app/modules/home/components/vc/entity-version-create.component.ts index 0b8812f94d..7f99434c34 100644 --- a/ui-ngx/src/app/modules/home/components/vc/entity-version-create.component.ts +++ b/ui-ngx/src/app/modules/home/components/vc/entity-version-create.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core'; import { PageComponent } from '@shared/components/page.component'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { SingleEntityVersionCreateRequest, VersionCreateRequestType, @@ -58,7 +58,7 @@ export class EntityVersionCreateComponent extends PageComponent implements OnIni @Input() popoverComponent: TbPopoverComponent; - createVersionFormGroup: FormGroup; + createVersionFormGroup: UntypedFormGroup; entityTypes = EntityType; @@ -72,7 +72,7 @@ export class EntityVersionCreateComponent extends PageComponent implements OnIni private entitiesVersionControlService: EntitiesVersionControlService, private cd: ChangeDetectorRef, private translate: TranslateService, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } diff --git a/ui-ngx/src/app/modules/home/components/vc/entity-version-diff.component.html b/ui-ngx/src/app/modules/home/components/vc/entity-version-diff.component.html index aa0c9284a9..62686847af 100644 --- a/ui-ngx/src/app/modules/home/components/vc/entity-version-diff.component.html +++ b/ui-ngx/src/app/modules/home/components/vc/entity-version-diff.component.html @@ -1,6 +1,6 @@ -

{{ 'version-control.restore-entity-from-version' | translate: {versionName} }}

diff --git a/ui-ngx/src/app/modules/home/components/vc/entity-version-restore.component.ts b/ui-ngx/src/app/modules/home/components/vc/entity-version-restore.component.ts index 44f86129d8..320504052e 100644 --- a/ui-ngx/src/app/modules/home/components/vc/entity-version-restore.component.ts +++ b/ui-ngx/src/app/modules/home/components/vc/entity-version-restore.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { ChangeDetectorRef, Component, Input, OnDestroy, OnInit, Sanitizer } from '@angular/core'; import { PageComponent } from '@shared/components/page.component'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { EntityDataInfo, SingleEntityVersionLoadRequest, VersionCreationResult, @@ -58,7 +58,7 @@ export class EntityVersionRestoreComponent extends PageComponent implements OnIn entityDataInfo: EntityDataInfo = null; - restoreFormGroup: FormGroup; + restoreFormGroup: UntypedFormGroup; errorMessage: SafeHtml; @@ -71,7 +71,7 @@ export class EntityVersionRestoreComponent extends PageComponent implements OnIn private cd: ChangeDetectorRef, private translate: TranslateService, private sanitizer: DomSanitizer, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } diff --git a/ui-ngx/src/app/modules/home/components/vc/entity-versions-table.component.html b/ui-ngx/src/app/modules/home/components/vc/entity-versions-table.component.html index 46b0be09c0..68a7f06bcd 100644 --- a/ui-ngx/src/app/modules/home/components/vc/entity-versions-table.component.html +++ b/ui-ngx/src/app/modules/home/components/vc/entity-versions-table.component.html @@ -1,6 +1,6 @@ -
, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.flotBarKeySettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.html index b91b716ce3..095c80727e 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.html @@ -1,6 +1,6 @@ -
diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.ts index 285c339edf..f60b37f490 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-bar-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { flotDefaultSettings } from '@home/components/widget/lib/settings/chart/flot-widget-settings.component'; @@ -28,14 +28,14 @@ import { flotDefaultSettings } from '@home/components/widget/lib/settings/chart/ }) export class FlotBarWidgetSettingsComponent extends WidgetSettingsComponent { - flotBarWidgetSettingsForm: FormGroup; + flotBarWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.flotBarWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-key-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-key-settings.component.html index 5741bfae9f..54dc2f6f15 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-key-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-key-settings.component.html @@ -1,6 +1,6 @@ -
, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.flotLineKeySettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.html index 299627f9e2..ca06d3987d 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.html @@ -1,6 +1,6 @@ -
diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.ts index d2b0e76ca6..7cd2056683 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-line-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { flotDefaultSettings } from '@home/components/widget/lib/settings/chart/flot-widget-settings.component'; @@ -29,14 +29,14 @@ import { deepClone } from '@core/utils'; }) export class FlotLineWidgetSettingsComponent extends WidgetSettingsComponent { - flotLineWidgetSettingsForm: FormGroup; + flotLineWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.flotLineWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-pie-key-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-pie-key-settings.component.html index 8649e5e97d..6b2779ac58 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-pie-key-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/chart/flot-pie-key-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/knob-control-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/knob-control-widget-settings.component.ts index dae3045110..59c1658e6b 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/knob-control-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/knob-control-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; @@ -27,14 +27,14 @@ import { AppState } from '@core/core.state'; }) export class KnobControlWidgetSettingsComponent extends WidgetSettingsComponent { - knobControlWidgetSettingsForm: FormGroup; + knobControlWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.knobControlWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.html index c4e934eabe..9944d3173a 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.ts index 8ee8ebe127..a50db04103 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/led-indicator-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { WidgetService } from '@core/http/widget.service'; @@ -41,15 +41,15 @@ export class LedIndicatorWidgetSettingsComponent extends WidgetSettingsComponent dataKeyType = DataKeyType; - ledIndicatorWidgetSettingsForm: FormGroup; + ledIndicatorWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, private widgetService: WidgetService, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.ledIndicatorWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/persistent-table-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/persistent-table-widget-settings.component.html index 47b3ef545d..8e2078e881 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/persistent-table-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/persistent-table-widget-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/round-switch-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/round-switch-widget-settings.component.ts index cf7ee3bbb9..2c470ea363 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/round-switch-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/round-switch-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { switchRpcDefaultSettings } from '@home/components/widget/lib/settings/control/switch-rpc-settings.component'; @@ -29,10 +29,10 @@ import { deepClone } from '@core/utils'; }) export class RoundSwitchWidgetSettingsComponent extends WidgetSettingsComponent { - roundSwitchWidgetSettingsForm: FormGroup; + roundSwitchWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } @@ -44,7 +44,7 @@ export class RoundSwitchWidgetSettingsComponent extends WidgetSettingsComponent return null; } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.roundSwitchWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-button-style.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-button-style.component.html index a8153c68fe..3e330e78ac 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-button-style.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-button-style.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.rpc-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-shell-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-shell-widget-settings.component.ts index d901ad2636..849c8d415a 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-shell-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-shell-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; @@ -27,14 +27,14 @@ import { AppState } from '@core/core.state'; }) export class RpcShellWidgetSettingsComponent extends WidgetSettingsComponent { - rpcShellWidgetSettingsForm: FormGroup; + rpcShellWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.rpcShellWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.html index 79c34bfdea..445e69394f 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.rpc-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.ts index 906c0c71b3..60fa562558 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/rpc-terminal-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; @@ -27,14 +27,14 @@ import { AppState } from '@core/core.state'; }) export class RpcTerminalWidgetSettingsComponent extends WidgetSettingsComponent { - rpcTerminalWidgetSettingsForm: FormGroup; + rpcTerminalWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.rpcTerminalWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.html index c36a21c349..1e1ee3cd03 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.ts index 051b780ca9..16bb854edd 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/send-rpc-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { ContentType } from '@shared/models/constants'; @@ -28,16 +28,16 @@ import { ContentType } from '@shared/models/constants'; }) export class SendRpcWidgetSettingsComponent extends WidgetSettingsComponent { - sendRpcWidgetSettingsForm: FormGroup; + sendRpcWidgetSettingsForm: UntypedFormGroup; contentTypes = ContentType; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.sendRpcWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.html index 37a15b90f4..927bcf65c7 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.ts index f95473dbb9..8315d7eaf4 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/slide-toggle-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { switchRpcDefaultSettings } from '@home/components/widget/lib/settings/control/switch-rpc-settings.component'; @@ -29,10 +29,10 @@ import { deepClone } from '@core/utils'; }) export class SlideToggleWidgetSettingsComponent extends WidgetSettingsComponent { - slideToggleWidgetSettingsForm: FormGroup; + slideToggleWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } @@ -44,7 +44,7 @@ export class SlideToggleWidgetSettingsComponent extends WidgetSettingsComponent return null; } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.slideToggleWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.html index da0b4237db..5556540f4d 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.ts index 65f09f2dd8..a95cea4628 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-control-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { switchRpcDefaultSettings } from '@home/components/widget/lib/settings/control/switch-rpc-settings.component'; @@ -29,10 +29,10 @@ import { deepClone } from '@core/utils'; }) export class SwitchControlWidgetSettingsComponent extends WidgetSettingsComponent { - switchControlWidgetSettingsForm: FormGroup; + switchControlWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } @@ -44,7 +44,7 @@ export class SwitchControlWidgetSettingsComponent extends WidgetSettingsComponen return null; } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.switchControlWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-rpc-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-rpc-settings.component.html index ec2228cc78..0e9911508b 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-rpc-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/switch-rpc-settings.component.html @@ -1,6 +1,6 @@ -
widgets.rpc.common-settings diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/update-device-attribute-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/update-device-attribute-widget-settings.component.ts index 6689112bf7..0397ca2bf5 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/update-device-attribute-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/control/update-device-attribute-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { ContentType } from '@shared/models/constants'; @@ -28,16 +28,16 @@ import { ContentType } from '@shared/models/constants'; }) export class UpdateDeviceAttributeWidgetSettingsComponent extends WidgetSettingsComponent { - updateDeviceAttributeWidgetSettingsForm: FormGroup; + updateDeviceAttributeWidgetSettingsForm: UntypedFormGroup; contentTypes = ContentType; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.updateDeviceAttributeWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/date/date-range-navigator-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/date/date-range-navigator-widget-settings.component.html index 519ef6bafa..2a666ef1f5 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/date/date-range-navigator-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/date/date-range-navigator-widget-settings.component.html @@ -1,6 +1,6 @@ -
, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.updateDateAttributeWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.html index be0c4a2b3b..59de0ec2aa 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.html @@ -1,6 +1,6 @@ -
diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.ts index ef71992aef..20e747b52a 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-double-attribute-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { deepClone } from '@core/utils'; @@ -31,14 +31,14 @@ import { }) export class UpdateDoubleAttributeWidgetSettingsComponent extends WidgetSettingsComponent { - updateDoubleAttributeWidgetSettingsForm: FormGroup; + updateDoubleAttributeWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.updateDoubleAttributeWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-image-attribute-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-image-attribute-widget-settings.component.html index ee86c62870..1e570ae27e 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-image-attribute-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-image-attribute-widget-settings.component.html @@ -1,6 +1,6 @@ -
diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-integer-attribute-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-integer-attribute-widget-settings.component.ts index d06601b468..46ce869e5f 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-integer-attribute-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-integer-attribute-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { deepClone } from '@core/utils'; @@ -31,14 +31,14 @@ import { }) export class UpdateIntegerAttributeWidgetSettingsComponent extends WidgetSettingsComponent { - updateIntegerAttributeWidgetSettingsForm: FormGroup; + updateIntegerAttributeWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.updateIntegerAttributeWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-json-attribute-widget-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-json-attribute-widget-settings.component.html index fd76c980ac..5834916d67 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-json-attribute-widget-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-json-attribute-widget-settings.component.html @@ -1,6 +1,6 @@ -
diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-string-attribute-widget-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-string-attribute-widget-settings.component.ts index 13dd1ec453..1328d4b0eb 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-string-attribute-widget-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/input/update-string-attribute-widget-settings.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ import { Component } from '@angular/core'; import { WidgetSettings, WidgetSettingsComponent } from '@shared/models/widget.models'; -import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms'; import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { deepClone } from '@core/utils'; @@ -31,14 +31,14 @@ import { }) export class UpdateStringAttributeWidgetSettingsComponent extends WidgetSettingsComponent { - updateStringAttributeWidgetSettingsForm: FormGroup; + updateStringAttributeWidgetSettingsForm: UntypedFormGroup; constructor(protected store: Store, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { super(store); } - protected settingsForm(): FormGroup { + protected settingsForm(): UntypedFormGroup { return this.updateStringAttributeWidgetSettingsForm; } diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/map/circle-settings.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/settings/map/circle-settings.component.html index 827fb44129..06162001a2 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/map/circle-settings.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/map/circle-settings.component.html @@ -1,6 +1,6 @@ +
+ +

info_outline + {{ 'edge.install-connect-instructions' | translate }}

+ + +
+ + +
+
+ +
+
+ +
+
diff --git a/ui-ngx/src/app/modules/home/pages/edge/edge-instructions-dialog.component.ts b/ui-ngx/src/app/modules/home/pages/edge/edge-instructions-dialog.component.ts new file mode 100644 index 0000000000..a4dfe4345b --- /dev/null +++ b/ui-ngx/src/app/modules/home/pages/edge/edge-instructions-dialog.component.ts @@ -0,0 +1,46 @@ +/// +/// Copyright © 2016-2023 The Thingsboard Authors +/// +/// Licensed under the Apache License, Version 2.0 (the "License"); +/// you may not use this file except in compliance with the License. +/// You may obtain a copy of the License at +/// +/// http://www.apache.org/licenses/LICENSE-2.0 +/// +/// Unless required by applicable law or agreed to in writing, software +/// distributed under the License is distributed on an "AS IS" BASIS, +/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +/// See the License for the specific language governing permissions and +/// limitations under the License. +/// + +import { Component, Inject } from '@angular/core'; +import { MAT_DIALOG_DATA, MatDialogRef } from "@angular/material/dialog"; +import { DialogComponent } from "@shared/components/dialog.component"; +import { Store } from "@ngrx/store"; +import { AppState } from "@core/core.state"; +import { Router } from "@angular/router"; + +export interface EdgeInstructionsData { + instructions: string; +} + +@Component({ + selector: 'tb-edge-instructions', + templateUrl: './edge-instructions-dialog.component.html' +}) +export class EdgeInstructionsDialogComponent extends DialogComponent { + + instructions: string = this.data.instructions; + + constructor(protected store: Store, + protected router: Router, + public dialogRef: MatDialogRef, + @Inject(MAT_DIALOG_DATA) public data: EdgeInstructionsData) { + super(store, router, dialogRef); + } + + cancel(): void { + this.dialogRef.close(null); + } +} diff --git a/ui-ngx/src/app/modules/home/pages/edge/edge-routing.module.ts b/ui-ngx/src/app/modules/home/pages/edge/edge-routing.module.ts index 297669002a..44e0c9c00f 100644 --- a/ui-ngx/src/app/modules/home/pages/edge/edge-routing.module.ts +++ b/ui-ngx/src/app/modules/home/pages/edge/edge-routing.module.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -296,6 +296,7 @@ const routes: Routes = [ children: [ { path: '', + children: [], data: { auth: [Authority.TENANT_ADMIN, Authority.CUSTOMER_USER], redirectTo: '/edgeManagement/ruleChains' diff --git a/ui-ngx/src/app/modules/home/pages/edge/edge-table-header.component.html b/ui-ngx/src/app/modules/home/pages/edge/edge-table-header.component.html index 2b2d8a1e4c..2c4b13114e 100644 --- a/ui-ngx/src/app/modules/home/pages/edge/edge-table-header.component.html +++ b/ui-ngx/src/app/modules/home/pages/edge/edge-table-header.component.html @@ -1,6 +1,6 @@ -
@@ -29,12 +28,12 @@
- {{ label | translate }} + {{ label }} diff --git a/ui-ngx/src/app/shared/components/phone-input.component.scss b/ui-ngx/src/app/shared/components/phone-input.component.scss index 432c9d21f2..c9413827cf 100644 --- a/ui-ngx/src/app/shared/components/phone-input.component.scss +++ b/ui-ngx/src/app/shared/components/phone-input.component.scss @@ -1,5 +1,5 @@ /** - * Copyright © 2016-2022 The Thingsboard Authors + * Copyright © 2016-2023 The Thingsboard Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/ui-ngx/src/app/shared/components/phone-input.component.ts b/ui-ngx/src/app/shared/components/phone-input.component.ts index 77f9e21f65..f5383405c3 100644 --- a/ui-ngx/src/app/shared/components/phone-input.component.ts +++ b/ui-ngx/src/app/shared/components/phone-input.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -17,9 +17,9 @@ import { Component, forwardRef, Input, OnInit } from '@angular/core'; import { ControlValueAccessor, - FormBuilder, - FormControl, - FormGroup, + UntypedFormBuilder, + UntypedFormControl, + UntypedFormGroup, NG_VALIDATORS, NG_VALUE_ACCESSOR, ValidationErrors, @@ -31,7 +31,7 @@ import { TranslateService } from '@ngx-translate/core'; import { Country, CountryData } from '@shared/models/country.models'; import examples from 'libphonenumber-js/examples.mobile.json'; import { Subscription } from 'rxjs'; -import { FloatLabelType, MatFormFieldAppearance } from '@angular/material/form-field/form-field'; +import { FloatLabelType, MatFormFieldAppearance } from '@angular/material/form-field'; @Component({ selector: 'tb-phone-input', @@ -75,7 +75,7 @@ export class PhoneInputComponent implements OnInit, ControlValueAccessor, Valida placeholder; @Input() - label = 'phone-input.phone-input-label'; + label = this.translate.instant('phone-input.phone-input-label'); get showFlagSelect(): boolean { return this.enableFlagsSelect && !this.isLegacy; @@ -84,7 +84,7 @@ export class PhoneInputComponent implements OnInit, ControlValueAccessor, Valida allCountries: Array = this.countryCodeData.allCountries; phonePlaceholder = '+12015550123'; flagIcon: string; - phoneFormGroup: FormGroup; + phoneFormGroup: UntypedFormGroup; private isLoading = true; get isLoad(): boolean { @@ -116,7 +116,7 @@ export class PhoneInputComponent implements OnInit, ControlValueAccessor, Valida private propagateChange = (v: any) => { }; constructor(private translate: TranslateService, - private fb: FormBuilder, + private fb: UntypedFormBuilder, private countryCodeData: CountryData) { import('libphonenumber-js/max').then((libphonenubmer) => { this.parsePhoneNumberFromString = libphonenubmer.parsePhoneNumberFromString; @@ -194,7 +194,7 @@ export class PhoneInputComponent implements OnInit, ControlValueAccessor, Valida } validatePhoneNumber(): ValidatorFn { - return (c: FormControl) => { + return (c: UntypedFormControl) => { const phoneNumber = c.value; if (phoneNumber && this.parsePhoneNumberFromString) { const parsedPhoneNumber = this.parsePhoneNumberFromString(phoneNumber); @@ -274,6 +274,7 @@ export class PhoneInputComponent implements OnInit, ControlValueAccessor, Valida if (phoneNumber.value === '+' || phoneNumber.value === this.countryCallingCode) { this.propagateChange(null); } else if (phoneNumber.valid) { + this.modelValue = phoneNumber.value; if (parsedPhoneNumber) { this.updateModelValueInFormat(parsedPhoneNumber); } diff --git a/ui-ngx/src/app/shared/components/popover.component.scss b/ui-ngx/src/app/shared/components/popover.component.scss index 2ef8e8bb34..bc06c50e6e 100644 --- a/ui-ngx/src/app/shared/components/popover.component.scss +++ b/ui-ngx/src/app/shared/components/popover.component.scss @@ -1,5 +1,5 @@ /** - * Copyright © 2016-2022 The Thingsboard Authors + * Copyright © 2016-2023 The Thingsboard Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/ui-ngx/src/app/shared/components/popover.component.ts b/ui-ngx/src/app/shared/components/popover.component.ts index 20815fd5fb..59fd8fd313 100644 --- a/ui-ngx/src/app/shared/components/popover.component.ts +++ b/ui-ngx/src/app/shared/components/popover.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -70,7 +70,7 @@ export type TbPopoverTrigger = 'click' | 'focus' | 'hover' | null; }) export class TbPopoverDirective implements OnChanges, OnDestroy, AfterViewInit { - // tslint:disable:no-input-rename + /* eslint-disable @angular-eslint/no-input-rename */ @Input('tbPopoverContent') content?: string | TemplateRef; @Input('tbPopoverTrigger') trigger?: TbPopoverTrigger = 'hover'; @Input('tbPopoverPlacement') placement?: string | string[] = 'top'; @@ -82,7 +82,7 @@ export class TbPopoverDirective implements OnChanges, OnDestroy, AfterViewInit { @Input('tbPopoverOverlayStyle') overlayStyle?: { [klass: string]: any }; @Input() tbPopoverBackdrop = false; - // tslint:disable-next-line:no-output-rename + // eslint-disable-next-line @angular-eslint/no-output-rename @Output('tbPopoverVisibleChange') readonly visibleChange = new EventEmitter(); componentFactory: ComponentFactory = this.resolver.resolveComponentFactory(TbPopoverComponent); @@ -149,7 +149,7 @@ export class TbPopoverDirective implements OnChanges, OnDestroy, AfterViewInit { this.renderer.parentNode(this.elementRef.nativeElement), componentRef.location.nativeElement ); - this.component.setOverlayOrigin({ elementRef: this.origin || this.elementRef }); + this.component.setOverlayOrigin(new CdkOverlayOrigin(this.origin || this.elementRef)); this.initProperties(); diff --git a/ui-ngx/src/app/shared/components/popover.models.ts b/ui-ngx/src/app/shared/components/popover.models.ts index 20f0125a98..b9ca5e9d59 100644 --- a/ui-ngx/src/app/shared/components/popover.models.ts +++ b/ui-ngx/src/app/shared/components/popover.models.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. diff --git a/ui-ngx/src/app/shared/components/popover.service.ts b/ui-ngx/src/app/shared/components/popover.service.ts index 3f05ed02a6..f547200316 100644 --- a/ui-ngx/src/app/shared/components/popover.service.ts +++ b/ui-ngx/src/app/shared/components/popover.service.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -30,6 +30,7 @@ import { PopoverPlacement, PopoverWithTrigger } from '@shared/components/popover import { TbPopoverComponent } from '@shared/components/popover.component'; import { ComponentType } from '@angular/cdk/portal'; import { HELP_MARKDOWN_COMPONENT_TOKEN } from '@shared/components/tokens'; +import { CdkOverlayOrigin } from '@angular/cdk/overlay'; @Injectable() export class TbPopoverService { @@ -84,7 +85,7 @@ export class TbPopoverService { componentRef.location.nativeElement ); const originElementRef = new ElementRef(trigger); - component.setOverlayOrigin({ elementRef: originElementRef }); + component.setOverlayOrigin(new CdkOverlayOrigin(originElementRef)); component.tbPlacement = preferredPlacement; component.tbComponentFactory = this.resolver.resolveComponentFactory(componentType); component.tbComponentInjector = injector; @@ -132,7 +133,7 @@ export class TbPopoverService { const originElementRef = new ElementRef(trigger); component.tbAnimationState = 'void'; component.tbOverlayStyle = {...overlayStyle, opacity: '0' }; - component.setOverlayOrigin({ elementRef: originElementRef }); + component.setOverlayOrigin(new CdkOverlayOrigin(originElementRef)); component.tbPlacement = preferredPlacement; component.tbComponentFactory = this.resolver.resolveComponentFactory(this.helpMarkdownComponent); component.tbComponentInjector = injector; diff --git a/ui-ngx/src/app/shared/components/protobuf-content.component.html b/ui-ngx/src/app/shared/components/protobuf-content.component.html index 1e7403182f..20c504d4e4 100644 --- a/ui-ngx/src/app/shared/components/protobuf-content.component.html +++ b/ui-ngx/src/app/shared/components/protobuf-content.component.html @@ -1,6 +1,6 @@ - + + {{ autocompleteHint | translate }} {{ 'queue.queue-required' | translate }} diff --git a/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.scss b/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.scss index 45a4ab9808..30f2d26466 100644 --- a/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.scss +++ b/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.scss @@ -1,5 +1,5 @@ /** - * Copyright © 2016-2022 The Thingsboard Authors + * Copyright © 2016-2023 The Thingsboard Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,12 +13,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - ::ng-deep { .queue-option { .mat-option-text { display: inline; } + .queue-option-description { display: block; overflow: hidden; @@ -27,3 +27,27 @@ } } } + +:host ::ng-deep { + .mat-form-field { + .mat-form-field-wrapper { + padding-bottom: 0px; + + .mat-form-field-underline { + position: initial !important; + display: block; + margin-top: -1px; + } + + .mat-form-field-subscript-wrapper, + .mat-form-field-ripple { + position: initial !important; + display: table; + } + + .mat-form-field-subscript-wrapper { + min-height: calc(1em + 1px); + } + } + } +} diff --git a/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.ts b/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.ts index 4b445b5175..4821494258 100644 --- a/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.ts +++ b/ui-ngx/src/app/shared/components/queue/queue-autocomplete.component.ts @@ -1,5 +1,5 @@ /// -/// Copyright © 2016-2022 The Thingsboard Authors +/// Copyright © 2016-2023 The Thingsboard Authors /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except in compliance with the License. @@ -15,7 +15,7 @@ /// import { Component, ElementRef, forwardRef, Input, OnInit, ViewChild } from '@angular/core'; -import { ControlValueAccessor, FormBuilder, FormGroup, NG_VALUE_ACCESSOR } from '@angular/forms'; +import { ControlValueAccessor, UntypedFormBuilder, UntypedFormGroup, NG_VALUE_ACCESSOR } from '@angular/forms'; import { Observable, of } from 'rxjs'; import { catchError, debounceTime, distinctUntilChanged, map, share, switchMap, tap } from 'rxjs/operators'; import { Store } from '@ngrx/store'; @@ -44,7 +44,7 @@ import { emptyPageData } from '@shared/models/page/page-data'; }) export class QueueAutocompleteComponent implements ControlValueAccessor, OnInit { - selectQueueFormGroup: FormGroup; + selectQueueFormGroup: UntypedFormGroup; modelValue: string | null; @@ -54,6 +54,9 @@ export class QueueAutocompleteComponent implements ControlValueAccessor, OnInit @Input() requiredText: string; + @Input() + autocompleteHint: string; + private requiredValue: boolean; get required(): boolean { return this.requiredValue; @@ -84,7 +87,7 @@ export class QueueAutocompleteComponent implements ControlValueAccessor, OnInit public truncate: TruncatePipe, private entityService: EntityService, private queueService: QueueService, - private fb: FormBuilder) { + private fb: UntypedFormBuilder) { this.selectQueueFormGroup = this.fb.group({ queueName: [null] }); diff --git a/ui-ngx/src/app/shared/components/relation/relation-type-autocomplete.component.html b/ui-ngx/src/app/shared/components/relation/relation-type-autocomplete.component.html index 096d06c1ee..0dc0d8189e 100644 --- a/ui-ngx/src/app/shared/components/relation/relation-type-autocomplete.component.html +++ b/ui-ngx/src/app/shared/components/relation/relation-type-autocomplete.component.html @@ -1,6 +1,6 @@