Commit a0c504ade6ff4871fca8155f9374e718bfb1ef7e

Authored by Vladyslav_Prykhodko
Committed by Andrew Shvayka
1 parent eb9b0f84

UI: LwM2M device profile add new setting compositeOperationsSupport

@@ -168,6 +168,8 @@ @@ -168,6 +168,8 @@
168 </mat-select> 168 </mat-select>
169 </mat-form-field> 169 </mat-form-field>
170 </fieldset> 170 </fieldset>
  171 + <mat-slide-toggle class="mat-slider"
  172 + formControlName="compositeOperationsSupport">{{ 'device-profile.lwm2m.composite-operations-support' | translate }}</mat-slide-toggle>
171 <!-- <mat-accordion multi="true">--> 173 <!-- <mat-accordion multi="true">-->
172 <!-- <div *ngIf="false">--> 174 <!-- <div *ngIf="false">-->
173 <!-- <mat-expansion-panel>--> 175 <!-- <mat-expansion-panel>-->
@@ -24,4 +24,8 @@ @@ -24,4 +24,8 @@
24 color: rgba(0, 0, 0, .7); 24 color: rgba(0, 0, 0, .7);
25 } 25 }
26 } 26 }
  27 +
  28 + .mat-slider {
  29 + margin: 8px 0 8px 10px;
  30 + }
27 } 31 }
@@ -117,7 +117,8 @@ export class Lwm2mDeviceProfileTransportConfigurationComponent implements Contro @@ -117,7 +117,8 @@ export class Lwm2mDeviceProfileTransportConfigurationComponent implements Contro
117 swUpdateStrategy: [1, []], 117 swUpdateStrategy: [1, []],
118 fwUpdateResource: [{value: '', disabled: true}, []], 118 fwUpdateResource: [{value: '', disabled: true}, []],
119 swUpdateResource: [{value: '', disabled: true}, []], 119 swUpdateResource: [{value: '', disabled: true}, []],
120 - powerMode: [null, Validators.required] 120 + powerMode: [PowerMode.DRX, Validators.required],
  121 + compositeOperationsSupport: [false]
121 }) 122 })
122 }); 123 });
123 this.lwm2mDeviceConfigFormGroup = this.fb.group({ 124 this.lwm2mDeviceConfigFormGroup = this.fb.group({
@@ -258,7 +259,8 @@ export class Lwm2mDeviceProfileTransportConfigurationComponent implements Contro @@ -258,7 +259,8 @@ export class Lwm2mDeviceProfileTransportConfigurationComponent implements Contro
258 swUpdateStrategy: this.configurationValue.clientLwM2mSettings.swUpdateStrategy || 1, 259 swUpdateStrategy: this.configurationValue.clientLwM2mSettings.swUpdateStrategy || 1,
259 fwUpdateResource: fwResource, 260 fwUpdateResource: fwResource,
260 swUpdateResource: swResource, 261 swUpdateResource: swResource,
261 - powerMode: this.configurationValue.clientLwM2mSettings.powerMode 262 + powerMode: this.configurationValue.clientLwM2mSettings.powerMode || PowerMode.DRX,
  263 + compositeOperationsSupport: this.configurationValue.clientLwM2mSettings.compositeOperationsSupport || false
262 } 264 }
263 }, 265 },
264 {emitEvent: false}); 266 {emitEvent: false});
@@ -175,6 +175,7 @@ export interface ClientLwM2mSettings { @@ -175,6 +175,7 @@ export interface ClientLwM2mSettings {
175 fwUpdateResource: string; 175 fwUpdateResource: string;
176 swUpdateResource: string; 176 swUpdateResource: string;
177 powerMode: PowerMode; 177 powerMode: PowerMode;
  178 + compositeOperationsSupport: boolean;
178 } 179 }
179 180
180 export interface ObservableAttributes { 181 export interface ObservableAttributes {
@@ -231,7 +232,8 @@ export function getDefaultProfileClientLwM2mSettingsConfig(): ClientLwM2mSetting @@ -231,7 +232,8 @@ export function getDefaultProfileClientLwM2mSettingsConfig(): ClientLwM2mSetting
231 swUpdateStrategy: 1, 232 swUpdateStrategy: 1,
232 fwUpdateResource: DEFAULT_FW_UPDATE_RESOURCE, 233 fwUpdateResource: DEFAULT_FW_UPDATE_RESOURCE,
233 swUpdateResource: DEFAULT_SW_UPDATE_RESOURCE, 234 swUpdateResource: DEFAULT_SW_UPDATE_RESOURCE,
234 - powerMode: PowerMode.DRX 235 + powerMode: PowerMode.DRX,
  236 + compositeOperationsSupport: false
235 }; 237 };
236 } 238 }
237 239
@@ -1328,7 +1328,8 @@ @@ -1328,7 +1328,8 @@
1328 "step": "Step", 1328 "step": "Step",
1329 "min-evaluation-period": "Minimum evaluation period", 1329 "min-evaluation-period": "Minimum evaluation period",
1330 "max-evaluation-period": "Maximum evaluation period" 1330 "max-evaluation-period": "Maximum evaluation period"
1331 - } 1331 + },
  1332 + "composite-operations-support": "Supports composite Read/Write/Observe operations"
1332 }, 1333 },
1333 "snmp": { 1334 "snmp": {
1334 "add-communication-config": "Add communication config", 1335 "add-communication-config": "Add communication config",