From 0c2699190021340a72717e61181985d15b2a73fc Mon Sep 17 00:00:00 2001 From: Daniel Martin Gonzalez Date: Fri, 1 Apr 2022 17:16:12 +0200 Subject: [PATCH] Minor Fixes --- README.md | 14 +++++++------- dist/pvpc-hourly-pricing-card.js | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 03c7890..22db365 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +# PVPC Hourly Pricing Card + ![GitHub release (latest by date)](https://img.shields.io/github/v/release/danimart1991/pvpc-hourly-pricing-card) ![GitHub last commit](https://img.shields.io/github/last-commit/danimart1991/pvpc-hourly-pricing-card) ![License](https://img.shields.io/github/license/danimart1991/pvpc-hourly-pricing-card.svg) @@ -6,8 +8,6 @@ [![Tip Me via PayPal](https://img.shields.io/badge/PayPal-tip%20me-blue.svg?logo=paypal&style=flat)](https://www.paypal.me/danimart1991) [![Sponsor Me via GitHub](https://img.shields.io/badge/GitHub-sponsor%20me-blue.svg?logo=github&style=flat)](https://github.com/sponsors/danimart1991) -# PVPC Hourly Pricing Card - Home Assistant Lovelace custom card to use with [Spain electricity hourly pricing (PVPC) integration](https://www.home-assistant.io/integrations/pvpc_hourly_pricing/). ![Card Example](https://raw.githubusercontent.com/danimart1991/pvpc-hourly-pricing-card/master/docs/images/card-example.png) @@ -31,7 +31,7 @@ You could use [HACS](https://hacs.xyz/) or follow this [guide](https://www.danie ```yaml resources: - url: /local/pvpc-hourly-pricing-card.js?v=1.5.1 + url: /local/pvpc-hourly-pricing-card.js?v=1.6.0 type: module ``` @@ -61,8 +61,8 @@ If this doesn't work, another option is to add it manually from your Lovelace Da ```yaml type: custom:pvpc-hourly-pricing-card -name: "PVPC 2.0 DHA" -entity: sensor.pvpc_2_0_dha +name: "PVPC 2.0 DT" +entity: sensor.pvpc_2_0_dt ``` ### Mode YAML @@ -74,7 +74,7 @@ Add this lines of code to your Lovelace Dashboard YAML file: cards: ... - type: custom:pvpc-hourly-pricing-card - name: "PVPC 2.0 DHA" - entity: sensor.pvpc_2_0_dha + name: "PVPC 2.0 DT" + entity: sensor.pvpc_2_0_dt ... ``` diff --git a/dist/pvpc-hourly-pricing-card.js b/dist/pvpc-hourly-pricing-card.js index c69518a..a55d91a 100644 --- a/dist/pvpc-hourly-pricing-card.js +++ b/dist/pvpc-hourly-pricing-card.js @@ -211,7 +211,7 @@ class PVPCHourlyPricingCard extends LitElement { static getStubConfig(hass, entities, entitiesFallback) { const entity = Object.keys(hass.states).find((eid) => - Object.keys(hass.states[eid].attributes).some((aid) => aid == 'min_price_at') + Object.keys(hass.states[eid].attributes).some((aid) => aid == 'attribution') ); return { entity: entity }; } @@ -781,7 +781,7 @@ export class PVPCHourlyPricingCardEditor extends LitElement { this.lang = this.hass.selectedLanguage || this.hass.language; const entities = Object.keys(this.hass.states).filter((eid) => - Object.keys(this.hass.states[eid].attributes).some((aid) => aid == 'min_price_at') + Object.keys(this.hass.states[eid].attributes).some((aid) => aid == 'attribution') ); return html`