Skip to content

Lovelace ws: add card#17730

Merged
balloob merged 3 commits intohome-assistant:devfrom
bramkragten:lovelace-add-card
Oct 23, 2018
Merged

Lovelace ws: add card#17730
balloob merged 3 commits intohome-assistant:devfrom
bramkragten:lovelace-add-card

Conversation

@bramkragten
Copy link
Copy Markdown
Member

@bramkragten bramkragten commented Oct 23, 2018

Description:

Add the command to add a card to a view

Related issue (if applicable): fixes #

Pull request in home-assistant.io with documentation (if applicable): home-assistant/home-assistant.io#<home-assistant.io PR number goes here>

Example entry for configuration.yaml (if applicable):

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • New dependencies have been added to the REQUIREMENTS variable (example).
  • New dependencies are only imported inside functions that use them (example).
  • New or updated dependencies have been added to requirements_all.txt by running script/gen_requirements_all.py.
  • New files were added to .coveragerc.

If the code does not interact with devices:

  • Tests have been added to verify that the new code works.

cards = view.get('cards', [])
if data_format == FORMAT_YAML:
card_config = yaml_to_object(card_config)
if position != None:
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comparison to None should be 'if cond is not None:'

@balloob balloob merged commit 0f69be1 into home-assistant:dev Oct 23, 2018
@ghost ghost removed the in progress label Oct 23, 2018
@balloob balloob added this to the 0.81 milestone Oct 24, 2018
@bramkragten bramkragten deleted the lovelace-add-card branch October 24, 2018 09:17
balloob pushed a commit that referenced this pull request Oct 24, 2018
* Change set to update

* Add 'add card'

* Woof.
@balloob balloob mentioned this pull request Oct 26, 2018
iantrich pushed a commit to iantrich/home-assistant that referenced this pull request Oct 27, 2018
* Change set to update

* Add 'add card'

* Woof.
@home-assistant home-assistant locked and limited conversation to collaborators Feb 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants