question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

call service input_select.select_option

See original GitHub issue

Hi,

i’m quite new to hass and i need some help to setup a serie of buttons to select an input_select option here is what i tried, without success so far

entities:
  - entity: input_select.mode_chauffage_general
  - type: 'custom:paper-buttons-row'
    buttons:
      - icon: 'mdi:radiator-off'
        tap_action: call_service
        service: input_select.select_option
        entity_id: input_select.mode_chauffage_general
        service_data: 
          option: "Arrêt"
      - icon: 'mdi:snowflake'
        tap_action: call_service
        service: input_select.select_option
        service_data: 
          entity_id: input_select.mode_chauffage_general
          option: "Hors-Gel"
      - icon: 'mdi:moon-waxing-crescent'
        tap_action: call_service
        service: input_select.mode_chauffage_general
        service_data: { "option": "Eco" }
      - icon: 'mdi:white-balance-sunny'
        tap_action: call_service
        service: input_select.select_option
        service_data: 
          entity_id: input_select.mode_chauffage_general
          option: Confort

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
jcwilloxcommented, Oct 24, 2020

I had a closer look at your config and noticed you are using action: call_service with an underscore, it should be action: call-service with a dash. Like in you did in your custom:button-card example, I also updated my example above. I should probably display an error if you enter an invalid action.

Also what I said above is wrong, when using the call-service action, the entity_id will not be automatically added to the service data, only the more-info and toggle actions have that functionality.

0reactions
bachycommented, Oct 24, 2020

yes ! my rookie mistake thank you for your help and for your great hass add-on !

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error Using template calling service input_select. ...
Hello, I try to change an Input select according to a sensor value. It will be used in an automation but I want...
Read more >
Unable to call the input_select.select_option service from a ...
It is impossible to call the input_select.select_option service from a button. Using the UI designer first, and then dropping to manual as data: ......
Read more >
Blazor InputSelect binds to option text instead of Value
I use Blazor serverside and I have this: <InputSelect class="form-control" id= ...
Read more >
lightning:select - example
Represents a select input. Descriptor. lightning:select. Targets. Lightning Experience, Experience Builder Sites, Salesforce Mobile App, Lightning Out / ...
Read more >
How do I retrieve a selected value of the select control?
To retrieve a selected value from the select control, you can use either the @bind or @onchange event. //using @bind @page "/dropdown" ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found