Browse Source
Fix [object Object] in Execute RPC action summary for JSON parameters (#16622)
pull/16697/head
Maksym Tsymbarov
3 weeks ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
4 additions and
1 deletions
-
ui-ngx/src/app/modules/home/components/widget/lib/settings/common/action/set-value-action-settings.component.ts
|
|
|
@ -18,7 +18,7 @@ import { SetValueAction, SetValueSettings, ValueToDataType } from '@shared/model |
|
|
|
import { TranslateService } from '@ngx-translate/core'; |
|
|
|
import { IAliasController } from '@core/api/widget-api.models'; |
|
|
|
import { TargetDevice, widgetType } from '@shared/models/widget.models'; |
|
|
|
import { isDefinedAndNotNull } from '@core/utils'; |
|
|
|
import { isDefinedAndNotNull, isObject } from '@core/utils'; |
|
|
|
import { |
|
|
|
SetValueActionSettingsPanelComponent |
|
|
|
} from '@home/components/widget/lib/settings/common/action/set-value-action-settings-panel.component'; |
|
|
|
@ -136,6 +136,9 @@ export class SetValueActionSettingsComponent implements OnInit, ControlValueAcce |
|
|
|
break; |
|
|
|
case ValueToDataType.CONSTANT: |
|
|
|
value = this.modelValue.valueToData.constantValue; |
|
|
|
if (isObject(value)) { |
|
|
|
value = JSON.stringify(value); |
|
|
|
} |
|
|
|
break; |
|
|
|
case ValueToDataType.FUNCTION: |
|
|
|
value = 'f(value)'; |
|
|
|
|