Repository navigation
|
Hi, I'm trying to use additional costs template to calculate the price that I will pay in the end. The price structure is roughly:
I see from the code that the integration calculates VAT (if set to true) before current_prices is passed to the template, which I can adjust for, but I still get values which are too high - for example for current_price = 1, FACTOR of 1.30, offset of 0.67, I was expecting to get 2.3 (VAT is 1.25) but instead the result was around 4. Any suggestions how to set the template to get this right? I know I could create an additional template sensor in Hass to do that, but since this is already in place... :) Thanks, |
Replies: 3 comments 3 replies
|
I reread the section on Additional costs, what I thought should be:
additional_cost is added on top of the current_price, does not replace it completely as I thought. |
|
i try to integrate seasonal additional costs with vary periods a day and dont get it right. for expample: etc. |
|
Check the readme example 5 |
I reread the section on Additional costs, what I thought should be:
{{ ( current_price * 1.30 + 0.67 ) | float }}is actually{{ current_price * 0.30 + 0.67 * 1.25 | float }}additional_cost is added on top of the current_price, does not replace it completely as I thought.