Charging plan: show strategy settings without dynamic tariff (#33168)
This commit is contained in:
parent
f693454502
commit
0d0815963c
36 changed files with 71 additions and 77 deletions
|
|
@ -1,13 +1,7 @@
|
|||
<template>
|
||||
<div data-testid="plan-strategy" class="mb-5 mb-lg-4">
|
||||
<div :class="{ 'mb-2': open }">
|
||||
<div v-if="disabled">
|
||||
<span class="fw-bold evcc-gray">{{ $t("main.chargingPlan.strategy.label") }}:</span>
|
||||
{{ " " }}
|
||||
<span class="small">{{ summary }}</span>
|
||||
</div>
|
||||
<button
|
||||
v-else
|
||||
type="button"
|
||||
class="btn btn-link btn-sm text-gray p-0 border-0 d-flex align-items-center text-start"
|
||||
:class="{ 'text-primary': open }"
|
||||
|
|
@ -22,13 +16,7 @@
|
|||
</div>
|
||||
<div class="collapsible-wrapper" :class="{ open }">
|
||||
<div class="collapsible-content ring-space">
|
||||
<div v-if="disabled" class="row mb-4">
|
||||
<div class="small text-muted">
|
||||
<strong class="text-primary">{{ $t("general.note") }}</strong>
|
||||
{{ $t("main.chargingPlan.strategyDisabledDescription") }}
|
||||
</div>
|
||||
</div>
|
||||
<div v-else class="row">
|
||||
<div class="row">
|
||||
<div class="col-12 col-lg-6 mb-3">
|
||||
<div class="row">
|
||||
<label
|
||||
|
|
@ -39,6 +27,15 @@
|
|||
</label>
|
||||
<div class="col-7 col-lg-12">
|
||||
<select
|
||||
v-if="disabled"
|
||||
:id="formId('continuous')"
|
||||
class="form-select"
|
||||
disabled
|
||||
>
|
||||
<option>{{ $t("general.none") }}</option>
|
||||
</select>
|
||||
<select
|
||||
v-else
|
||||
:id="formId('continuous')"
|
||||
v-model="localContinuous"
|
||||
class="form-select"
|
||||
|
|
@ -67,6 +64,17 @@
|
|||
</label>
|
||||
<div class="col-7 col-lg-12">
|
||||
<select
|
||||
v-if="disabled"
|
||||
:id="formId('precondition')"
|
||||
class="form-select"
|
||||
disabled
|
||||
>
|
||||
<option>
|
||||
{{ $t("main.chargingPlan.precondition.optionAll") }}
|
||||
</option>
|
||||
</select>
|
||||
<select
|
||||
v-else
|
||||
:id="formId('precondition')"
|
||||
v-model="localPrecondition"
|
||||
class="form-select"
|
||||
|
|
@ -86,7 +94,11 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="small text-muted mt-1">
|
||||
{{ $t("main.chargingPlan.precondition.description") }}
|
||||
{{
|
||||
$t(
|
||||
`main.chargingPlan.precondition.${disabled ? "disabledDescription" : "description"}`
|
||||
)
|
||||
}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -101,6 +113,13 @@ import formatter from "@/mixins/formatter";
|
|||
import { SMART_COST_TYPE, type PlanStrategy } from "@/types/evcc";
|
||||
import DropdownIcon from "../MaterialIcon/Dropdown.vue";
|
||||
|
||||
const HOUR = 60 * 60;
|
||||
const QUARTER_HOUR = 0.25 * HOUR;
|
||||
const HALF_HOUR = 0.5 * HOUR;
|
||||
const ONE_HOUR = 1 * HOUR;
|
||||
const TWO_HOURS = 2 * HOUR;
|
||||
const EVERYTHING = 7 * 24 * HOUR;
|
||||
|
||||
export default defineComponent({
|
||||
name: "ChargingPlanStrategy",
|
||||
components: { DropdownIcon },
|
||||
|
|
@ -109,7 +128,6 @@ export default defineComponent({
|
|||
id: [String, Number],
|
||||
precondition: { type: Number, default: 0 },
|
||||
continuous: { type: Boolean, default: false },
|
||||
disabled: Boolean,
|
||||
smartCostType: String as PropType<SMART_COST_TYPE>,
|
||||
},
|
||||
emits: ["update"],
|
||||
|
|
@ -121,6 +139,10 @@ export default defineComponent({
|
|||
};
|
||||
},
|
||||
computed: {
|
||||
disabled(): boolean {
|
||||
// options only make sense with a dynamic planner tariff
|
||||
return !this.smartCostType || this.smartCostType === SMART_COST_TYPE.PRICE_STATIC;
|
||||
},
|
||||
isCo2(): boolean {
|
||||
return this.smartCostType === SMART_COST_TYPE.CO2;
|
||||
},
|
||||
|
|
@ -129,14 +151,16 @@ export default defineComponent({
|
|||
},
|
||||
summary(): string {
|
||||
if (this.disabled) {
|
||||
return this.$t("main.chargingPlan.strategyDisabledDescription");
|
||||
return this.$t("main.chargingPlan.precondition.summaryAll");
|
||||
}
|
||||
const parts = [
|
||||
this.$t(
|
||||
`main.chargingPlan.optimization.${this.continuous ? "continuous" : this.cheapestKey}`
|
||||
),
|
||||
];
|
||||
if (this.precondition) {
|
||||
if (this.precondition >= EVERYTHING) {
|
||||
parts.push(this.$t("main.chargingPlan.precondition.summaryAll"));
|
||||
} else if (this.precondition) {
|
||||
parts.push(
|
||||
this.$t("main.chargingPlan.precondition.summary", {
|
||||
precondition: this.fmtDurationLong(this.precondition),
|
||||
|
|
@ -146,6 +170,9 @@ export default defineComponent({
|
|||
return parts.join(", ");
|
||||
},
|
||||
optimizationDescription(): string {
|
||||
if (this.disabled) {
|
||||
return this.$t("main.chargingPlan.optimization.disabledDescription");
|
||||
}
|
||||
const variant = this.localContinuous
|
||||
? this.isCo2
|
||||
? "continuousCo2"
|
||||
|
|
@ -154,13 +181,6 @@ export default defineComponent({
|
|||
return this.$t(`main.chargingPlan.optimization.${variant}Description`);
|
||||
},
|
||||
preconditionOptions() {
|
||||
const HOUR = 60 * 60;
|
||||
const QUARTER_HOUR = 0.25 * HOUR;
|
||||
const HALF_HOUR = 0.5 * HOUR;
|
||||
const ONE_HOUR = 1 * HOUR;
|
||||
const TWO_HOURS = 2 * HOUR;
|
||||
const EVERYTHING = 7 * 24 * HOUR;
|
||||
|
||||
const options = [QUARTER_HOUR, HALF_HOUR, ONE_HOUR, TWO_HOURS, EVERYTHING];
|
||||
|
||||
// support custom values (via API)
|
||||
|
|
|
|||
|
|
@ -36,7 +36,6 @@
|
|||
:id="id"
|
||||
:precondition="effectivePlanStrategy?.precondition"
|
||||
:continuous="effectivePlanStrategy?.continuous"
|
||||
:disabled="strategyDisabled"
|
||||
:smart-cost-type="smartCostType"
|
||||
@update="updatePlanStrategy"
|
||||
/>
|
||||
|
|
@ -162,13 +161,6 @@ export default defineComponent({
|
|||
nextPlanTitle(): string {
|
||||
return `${this.$t("main.targetCharge.nextPlan")}: #${this.nextPlanId}`;
|
||||
},
|
||||
strategyDisabled(): boolean {
|
||||
// options only make sense if there are variable prices
|
||||
// TODO: make this logic more robust (api fails, missing data)
|
||||
const slots = this.forecast?.planner || [];
|
||||
const values = new Set(slots.map(({ value }) => value));
|
||||
return values.size <= 1;
|
||||
},
|
||||
},
|
||||
watch: {
|
||||
effectivePlanTime(newValue: string) {
|
||||
|
|
|
|||
|
|
@ -1,18 +1,18 @@
|
|||
<template>
|
||||
<p class="mb-3 root" data-testid="plan-warnings">
|
||||
<span v-if="targetIsAboveLimit" class="d-block evcc-gray mb-1">
|
||||
<p class="mb-0 root" data-testid="plan-warnings">
|
||||
<span v-if="targetIsAboveLimit" class="d-block evcc-gray mt-1">
|
||||
{{ $t("main.targetCharge.targetIsAboveLimit", { limit: limitFmt }) }}
|
||||
</span>
|
||||
<span v-if="mode && ['off', 'now'].includes(mode)" class="d-block text-warning mb-1">
|
||||
<span v-if="mode && ['off', 'now'].includes(mode)" class="d-block text-warning mt-1">
|
||||
{{ $t("main.targetCharge.onlyInPvMode") }}
|
||||
</span>
|
||||
<span v-if="timeTooFarInTheFuture" class="d-block evcc-gray mb-1">
|
||||
<span v-if="timeTooFarInTheFuture" class="d-block evcc-gray mt-1">
|
||||
{{ $t("main.targetCharge.targetIsTooFarInTheFuture") }}
|
||||
</span>
|
||||
<span v-if="notReachableInTime" class="d-block text-warning mb-1">
|
||||
<span v-if="notReachableInTime" class="d-block text-warning mt-1">
|
||||
{{ $t("main.targetCharge.notReachableInTime", { overrun: overrunFmt }) }}
|
||||
</span>
|
||||
<span v-if="targetIsAboveVehicleLimit" class="d-block text-warning mb-1">
|
||||
<span v-if="targetIsAboveVehicleLimit" class="d-block text-warning mt-1">
|
||||
{{ $t("main.targetCharge.targetIsAboveVehicleLimit") }}
|
||||
</span>
|
||||
</p>
|
||||
|
|
|
|||
|
|
@ -535,6 +535,7 @@ export enum SMART_COST_TYPE {
|
|||
CO2 = "co2",
|
||||
PRICE_DYNAMIC = "pricedynamic",
|
||||
PRICE_FORECAST = "priceforecast",
|
||||
PRICE_STATIC = "pricestatic",
|
||||
}
|
||||
|
||||
export enum LENGTH_UNIT {
|
||||
|
|
|
|||
|
|
@ -855,7 +855,6 @@
|
|||
"repeating": "повтарящ се",
|
||||
"repeatingPlans": "Повтарящи се планове",
|
||||
"selectAll": "Изберете всички",
|
||||
"strategyDisabledDescription": "Зареждането започва възможно най-късно, за да приключи точно навреме за тръгване. С динамични цени на електроенергията или тарифа за CO₂, тук са налице повече опции.",
|
||||
"time": "Време",
|
||||
"title": "План",
|
||||
"unsavedChanges": "Има незаписани промени. Приложи сега?",
|
||||
|
|
|
|||
|
|
@ -1343,7 +1343,6 @@
|
|||
"strategy": {
|
||||
"label": "Estratègia"
|
||||
},
|
||||
"strategyDisabledDescription": "La càrrega comença tan tard com sigui possible per a acabar just a temps de la sortida. Amb preus dinàmics de xarxa o tarifa de CO₂, hi ha més opcions disponibles.",
|
||||
"time": "Hora",
|
||||
"title": "Pla",
|
||||
"unsavedChanges": "Hi ha canvis sense aplicar. Voleu aplicar-los ara?",
|
||||
|
|
|
|||
|
|
@ -1343,7 +1343,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategie nabíjení"
|
||||
},
|
||||
"strategyDisabledDescription": "Nabíjení začíná co nejpozději, aby bylo dokončeno právě včas před odjezdem. S dynamickými cenami elektřiny nebo tarifem CO₂ je zde k dispozici více možností.",
|
||||
"time": "Čas",
|
||||
"title": "Plán",
|
||||
"unsavedChanges": "Jsou zde neuložené změny. Použít nyní?",
|
||||
|
|
|
|||
|
|
@ -1328,7 +1328,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategi"
|
||||
},
|
||||
"strategyDisabledDescription": "Opladningen påbegyndes så sent som muligt og afsluttes præcis ved afgang. Med dynamiske elpriser eller CO₂-tariffer er der flere valgmuligheder.",
|
||||
"time": "Tid",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Der er ændringer som ikke er gemt. Skal de benyttes nu?",
|
||||
|
|
|
|||
|
|
@ -1326,15 +1326,18 @@
|
|||
"continuous": "kontinuierlich",
|
||||
"continuousCo2Description": "Wählt die sauberste unterbrechungsfreie Folge von Zeitfenstern.",
|
||||
"continuousPriceDescription": "Wählt die günstigste unterbrechungsfreie Folge von Zeitfenstern.",
|
||||
"disabledDescription": "Benötigt einen dynamischen Tarif oder eine CO₂-Prognose.",
|
||||
"label": "Optimierung"
|
||||
},
|
||||
"planNumber": "Plan {number}",
|
||||
"precondition": {
|
||||
"description": "Verlagert einen Teil des Ladens direkt vor die Abfahrt: warme Batterie, weniger Zeit mit hohem Ladestand.",
|
||||
"disabledDescription": "Das gesamte Laden erfolgt direkt vor der Abfahrt.",
|
||||
"label": "Spätes Laden",
|
||||
"optionAll": "alles",
|
||||
"optionNo": "nein",
|
||||
"summary": "{precondition} vorher"
|
||||
"summary": "{precondition} vorher",
|
||||
"summaryAll": "direkt vor der Abfahrt"
|
||||
},
|
||||
"remove": "Entfernen",
|
||||
"repeating": "wiederholend",
|
||||
|
|
@ -1343,7 +1346,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategie"
|
||||
},
|
||||
"strategyDisabledDescription": "Das Laden startet so spät wie möglich und wird rechtzeitig zur Abfahrt abgeschlossen. Mit dynamischen Netzpreisen oder einem CO₂-Tarif stehen hier weitere Optionen zur Verfügung.",
|
||||
"time": "Zeit",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Ungespeicherte Änderungen vorhanden. Jetzt anwenden?",
|
||||
|
|
|
|||
|
|
@ -855,7 +855,6 @@
|
|||
"repeating": "επαναλαμβανόμενο",
|
||||
"repeatingPlans": "Επαναλαμβανόμενα προγράμματα",
|
||||
"selectAll": "Επιλογή όλων",
|
||||
"strategyDisabledDescription": "Η φόρτιση ξεκινά όσο το δυνατόν αργότερα, ώστε να ολοκληρωθεί ακριβώς πριν την αναχώρηση. Με τις δυναμικές τιμές δικτύου ή το τιμολόγιο CO₂, υπάρχουν περισσότερες επιλογές διαθέσιμες εδώ.",
|
||||
"time": "Ώρα",
|
||||
"title": "Πρόγραμμα",
|
||||
"unsavedChanges": "Υπάρχουν μη αποθηκευμένες αλλαγές. Υποβολή τώρα;",
|
||||
|
|
|
|||
|
|
@ -1326,15 +1326,18 @@
|
|||
"continuous": "continuous",
|
||||
"continuousCo2Description": "Selects the cleanest uninterrupted series of slots.",
|
||||
"continuousPriceDescription": "Selects the cheapest uninterrupted series of slots.",
|
||||
"disabledDescription": "Requires a dynamic tariff or CO₂ forecast.",
|
||||
"label": "Optimization"
|
||||
},
|
||||
"planNumber": "Plan {number}",
|
||||
"precondition": {
|
||||
"description": "Moves part of the charging right before departure: warm battery, less time at high charge level.",
|
||||
"disabledDescription": "All charging happens right before departure.",
|
||||
"label": "Late Charging",
|
||||
"optionAll": "everything",
|
||||
"optionNo": "no",
|
||||
"summary": "{precondition} before"
|
||||
"summary": "{precondition} before",
|
||||
"summaryAll": "right before departure"
|
||||
},
|
||||
"remove": "Remove",
|
||||
"repeating": "repeating",
|
||||
|
|
@ -1343,7 +1346,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategy"
|
||||
},
|
||||
"strategyDisabledDescription": "Charging starts as late as possible to finish just in time for departure. With dynamic grid prices or CO₂ tariff, more options are available here.",
|
||||
"time": "Time",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "There are unsaved changes. Apply now?",
|
||||
|
|
|
|||
|
|
@ -986,7 +986,6 @@
|
|||
"repeating": "repitiendo",
|
||||
"repeatingPlans": "Planes recurrentes",
|
||||
"selectAll": "Seleccionar todo",
|
||||
"strategyDisabledDescription": "La recarga comienza lo más tarde posible para terminar justo a tiempo para la salida. Con los precios dinámicos de la red o la tarifa de CO₂, hay más opciones disponibles aquí.",
|
||||
"time": "Tiempo",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Hay cambios sin guardar. ¿Aplicar ahora?",
|
||||
|
|
|
|||
|
|
@ -1328,7 +1328,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategia"
|
||||
},
|
||||
"strategyDisabledDescription": "Lataus aloitetaan mahdollisimman myöhään, jotta se valmistuu juuri ennen lähtöä. Jos dynaaminen sähköverkkohinnoittelu tai CO₂-tariffit ovat asetetut, on tässä tarjolla enemmän valintoja.",
|
||||
"time": "Aika",
|
||||
"title": "Suunnitelma",
|
||||
"unsavedChanges": "Tallentamattomia muutoksia. Asetetaanko nyt?",
|
||||
|
|
|
|||
|
|
@ -1320,7 +1320,6 @@
|
|||
"strategy": {
|
||||
"label": "Stratégie"
|
||||
},
|
||||
"strategyDisabledDescription": "La charge commence le plus tard possible afin de se terminer juste à temps pour le départ. Avec les prix dynamiques du réseau ou la tarification CO₂, davantage d'options sont disponibles ici.",
|
||||
"time": "Heure",
|
||||
"title": "Planification",
|
||||
"unsavedChanges": "Il y a des modifications non sauvegardées. Appliquer ?",
|
||||
|
|
|
|||
|
|
@ -855,7 +855,6 @@
|
|||
"repeating": "ponavljanje",
|
||||
"repeatingPlans": "Ponavljajući planovi",
|
||||
"selectAll": "Odaberi sve",
|
||||
"strategyDisabledDescription": "Punjenje počinje što kasnije kako bi se završilo upravo na vrijeme za polazak. Uz dinamične cijene mreže ili CO₂ tarifu ovdje su dostupne dodatne opcije.",
|
||||
"time": "Vrijeme",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Postoje promjene koje nisu spremljene. Spremiti odmah?",
|
||||
|
|
|
|||
|
|
@ -866,7 +866,6 @@
|
|||
"repeating": "ismétlődő",
|
||||
"repeatingPlans": "Ismétlődő tervek",
|
||||
"selectAll": "Összes kiválasztása",
|
||||
"strategyDisabledDescription": "A töltés a lehető legkésőbb kezdődik, hogy pontosan az indulás előtt befejeződjön. Dinamikus hálózati árak vagy CO₂-tarifa esetén itt több lehetőség áll rendelkezésre.",
|
||||
"time": "Idő",
|
||||
"title": "Terv",
|
||||
"unsavedChanges": "Vannak nem mentett módosítások. Alkalmazza most?",
|
||||
|
|
|
|||
|
|
@ -1222,7 +1222,6 @@
|
|||
"repeating": "ricorrente",
|
||||
"repeatingPlans": "Piani ricorrenti",
|
||||
"selectAll": "Seleziona tutti",
|
||||
"strategyDisabledDescription": "La ricarica inizia il più tardi possibile per terminare appena in tempo per la partenza. Con i prezzi dinamici della rete elettrica o la tariffa CO₂, sono disponibili ulteriori opzioni.",
|
||||
"time": "Ora",
|
||||
"title": "Piano",
|
||||
"unsavedChanges": "Ci sono modifiche non salvate. Vuoi salvarle adesso?",
|
||||
|
|
|
|||
|
|
@ -1109,7 +1109,6 @@
|
|||
"repeating": "繰り返し",
|
||||
"repeatingPlans": "繰り返しプラン",
|
||||
"selectAll": "すべて選択",
|
||||
"strategyDisabledDescription": "出発時刻に間に合うよう、できるだけ遅い時間帯に充電を開始します。市場連動型の料金プランやCO₂データが設定されている場合、さらに高度なオプションが利用可能になります。",
|
||||
"time": "時間",
|
||||
"title": "プラン",
|
||||
"unsavedChanges": "保存されていない変更があります。今すぐ適用しますか?",
|
||||
|
|
|
|||
|
|
@ -1320,7 +1320,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategie"
|
||||
},
|
||||
"strategyDisabledDescription": "D'Laden fänkt sou spéit wéi méiglech un, fir grad rechtzäiteg virum Depart ofzeschléissen. Mat dynamesche Netzpräisser oder engem CO₂-Tarif stinn hei nach méi Optiounen zur Verfügung.",
|
||||
"time": "Zäit",
|
||||
"title": "Planifikatioun",
|
||||
"unsavedChanges": "Net gespäichert Ännerungen leie vir. Elo uwennen?",
|
||||
|
|
|
|||
|
|
@ -1343,7 +1343,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategija"
|
||||
},
|
||||
"strategyDisabledDescription": "Įkrovimas pradedamas kuo vėliau, kad būtų baigtas prieš pat išvykimą. Jei naudojate 15 minučių biržos planą (arba CO₂ tarifą), čia galite rinktis iš daugiau variantų.",
|
||||
"time": "Laikas",
|
||||
"title": "Planas",
|
||||
"unsavedChanges": "Yra neišsaugotų pakeitimų. Išsaugoti dabar?",
|
||||
|
|
|
|||
|
|
@ -1343,7 +1343,6 @@
|
|||
"strategy": {
|
||||
"label": "Stratēģija"
|
||||
},
|
||||
"strategyDisabledDescription": "Uzlāde sākas cik vien vēlu iespējams, lai pabeigtu tieši pirms izbraukšanas. Ar dinamiskiem tīkla tarifiem vai CO₂ tarifu šeit ir pieejamas papildus iespējas.",
|
||||
"time": "Laiks",
|
||||
"title": "Plāns",
|
||||
"unsavedChanges": "Ir nesaglabātas izmaiņas. Piemērot tagad?",
|
||||
|
|
|
|||
|
|
@ -1331,7 +1331,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategie"
|
||||
},
|
||||
"strategyDisabledDescription": "Het opladen begint zo laat mogelijk, zodat het precies op tijd voor vertrek klaar is. Met dynamische netprijzen of een CO₂-tarief zijn er meer mogelijkheden.",
|
||||
"time": "Tijd",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Wijzigingen nog niet opgeslagen. Nu toepassen?",
|
||||
|
|
|
|||
|
|
@ -904,7 +904,6 @@
|
|||
"repeating": "gjentagende",
|
||||
"repeatingPlans": "Gjentatte planer",
|
||||
"selectAll": "Velg alt",
|
||||
"strategyDisabledDescription": "Ladingen starter så sent som mulig for å være ferdig akkurat i tide til avreise. Med dynamiske nettpriser eller CO₂-tariff er det flere alternativer tilgjengelig her.",
|
||||
"time": "Tid",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Det er ubehandlede endringer. Vil du bruke dem nå?",
|
||||
|
|
|
|||
|
|
@ -1138,7 +1138,6 @@
|
|||
"repeating": "powtórzenie",
|
||||
"repeatingPlans": "Powtarzające się plany",
|
||||
"selectAll": "Wybierz wszystko",
|
||||
"strategyDisabledDescription": "Ładowanie rozpoczyna się jak najpóźniej, aby zakończyć się tuż przed wyjazdem. Dzięki dynamicznym cenom energii elektrycznej lub taryfie CO₂ dostępnych jest więcej opcji.",
|
||||
"time": "Czas",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Są niezapisane zmiany. Zastosować teraz?",
|
||||
|
|
|
|||
|
|
@ -1320,7 +1320,6 @@
|
|||
"strategy": {
|
||||
"label": "Estratégia"
|
||||
},
|
||||
"strategyDisabledDescription": "O carregamento começa o mais tarde possível para terminar a tempo da partida. Com preços dinâmicos da rede ou tarifa de CO₂, há mais opções disponíveis aqui.",
|
||||
"time": "Hora",
|
||||
"title": "Plano",
|
||||
"unsavedChanges": "Há alterações não salvas. Aplicar agora?",
|
||||
|
|
|
|||
|
|
@ -1019,7 +1019,6 @@
|
|||
"repeating": "repetând",
|
||||
"repeatingPlans": "Planuri repetitive",
|
||||
"selectAll": "Selectați tot",
|
||||
"strategyDisabledDescription": "Încărcarea începe cât mai târziu posibil, pentru a se termina chiar înainte de plecare. Cu prețuri dinamice la rețea sau tariful CO₂, aici sunt disponibile mai multe opțiuni.",
|
||||
"time": "Timp",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Există modificări nesalvate. Doriți să le aplicați acum?",
|
||||
|
|
|
|||
|
|
@ -1325,7 +1325,6 @@
|
|||
"strategy": {
|
||||
"label": "Стратегия"
|
||||
},
|
||||
"strategyDisabledDescription": "Зарядка начинается как можно позже, чтобы закончиться как раз к моменту отправления. С динамическими ценами на электроэнергию или тарифом на выбросы CO₂ здесь доступно больше вариантов.",
|
||||
"time": "Время",
|
||||
"title": "План",
|
||||
"unsavedChanges": "Есть несохраненные изменения. Применить сейчас?",
|
||||
|
|
|
|||
|
|
@ -1328,7 +1328,6 @@
|
|||
"strategy": {
|
||||
"label": "Stratégia"
|
||||
},
|
||||
"strategyDisabledDescription": "Nabíjanie začína čo najneskôr, aby sa skončilo presne včas pred odchodom. S dynamickými sieťovými cenami alebo tarifom CO₂ je tu viac možností k dispozícii.",
|
||||
"time": "Čas",
|
||||
"title": "Plán",
|
||||
"unsavedChanges": "Existujú neuložené zmeny. Uložiť teraz?",
|
||||
|
|
|
|||
|
|
@ -872,7 +872,6 @@
|
|||
"repeating": "ponavljajoči",
|
||||
"repeatingPlans": "Ponavljajoči načrti",
|
||||
"selectAll": "Izberi vse",
|
||||
"strategyDisabledDescription": "Polnjenje se začne čim pozneje, da se konča ravno pravočasno za odhod. Z dinamičnimi cenami omrežja ali tarifo CO₂ je na voljo več možnosti.",
|
||||
"time": "Čas",
|
||||
"title": "Načrt",
|
||||
"unsavedChanges": "Obstajajo neshranjene spremembe. Želite uporabiti zdaj?",
|
||||
|
|
|
|||
|
|
@ -1342,7 +1342,6 @@
|
|||
"strategy": {
|
||||
"label": "Strategi"
|
||||
},
|
||||
"strategyDisabledDescription": "Laddningen startar så sent som möjligt för att avslutas precis i tid före avfärd. Med dynamiska elpriser eller CO₂-avgifter finns fler möjligheter här.",
|
||||
"time": "Tid",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Det finns ej sparade ändringar. Spara nu?",
|
||||
|
|
|
|||
|
|
@ -1195,7 +1195,6 @@
|
|||
"repeating": "மறுநிகழ்தல்",
|
||||
"repeatingPlans": "மறுநிகழ்வு திட்டங்கள்",
|
||||
"selectAll": "அனைத்தையும் தேர்ந்தெடு",
|
||||
"strategyDisabledDescription": "புறப்படும் நேரத்தில் முடிவதற்காக சார்சிங் முடிந்தவரை தாமதமாகத் தொடங்குகிறது. மாறும் கிரிட் விலைகள் அல்லது CO₂ கட்டணத்துடன், கூடுதல் விருப்பங்கள் இங்கே கிடைக்கின்றன.",
|
||||
"time": "நேரம்",
|
||||
"title": "திட்டம்",
|
||||
"unsavedChanges": "There அரே unsaved changes. இடு now?",
|
||||
|
|
|
|||
|
|
@ -1162,7 +1162,6 @@
|
|||
"repeating": "“tekrarlanan”",
|
||||
"repeatingPlans": "“Tekrarlanan planlar”",
|
||||
"selectAll": "“Tümünü seç”",
|
||||
"strategyDisabledDescription": "Şarj işlemi, kalkış saatine tam zamanında bitmek üzere mümkün olduğunca geç başlar. Dinamik şebeke fiyatları veya CO₂ tarifesi ile burada daha fazla seçenek mevcuttur.",
|
||||
"time": "Zaman",
|
||||
"title": "Plan",
|
||||
"unsavedChanges": "Kaydedilmemiş değişiklikler var. Şimdi uygulansın mı?",
|
||||
|
|
|
|||
|
|
@ -857,7 +857,6 @@
|
|||
"repeating": "повторення",
|
||||
"repeatingPlans": "Повторювані плани",
|
||||
"selectAll": "Вибрати все",
|
||||
"strategyDisabledDescription": "Зарядка починається якомога пізніше, щоб завершитися якраз вчасно до відправлення. Завдяки динамічним цінам мережі або тарифу на викиди CO₂ тут доступні додаткові опції.",
|
||||
"time": "Час",
|
||||
"title": "План",
|
||||
"unsavedChanges": "Є незбережені зміни. Застосувати зараз?",
|
||||
|
|
|
|||
3
server/mcp/openapi.json
generated
3
server/mcp/openapi.json
generated
|
|
@ -4517,7 +4517,8 @@
|
|||
"enum": [
|
||||
"co2",
|
||||
"pricedynamic",
|
||||
"priceforecast"
|
||||
"priceforecast",
|
||||
"pricestatic"
|
||||
]
|
||||
},
|
||||
"DeviceColorEntry": {
|
||||
|
|
|
|||
1
server/openapi.state.yaml
generated
1
server/openapi.state.yaml
generated
|
|
@ -1636,6 +1636,7 @@ components:
|
|||
- co2
|
||||
- pricedynamic
|
||||
- priceforecast
|
||||
- pricestatic
|
||||
SolarDetails:
|
||||
description: Solar production forecast.
|
||||
type: object
|
||||
|
|
|
|||
|
|
@ -687,9 +687,8 @@ test.describe("repeating", async () => {
|
|||
});
|
||||
});
|
||||
|
||||
// add test for precondition, start with basic.evcc.yaml and verify that precondition toggle element is not visible. make dedicated describe block
|
||||
test.describe("plan strategy", async () => {
|
||||
test("only if dynamic tariff exists", async ({ page }) => {
|
||||
test("no dynamic tariff: options disabled", async ({ page }) => {
|
||||
await restart(CONFIG_NO_TARIFF);
|
||||
await page.goto("/");
|
||||
const lp1 = await page.getByTestId("loadpoint").first();
|
||||
|
|
@ -697,11 +696,14 @@ test.describe("plan strategy", async () => {
|
|||
const modal = page.getByTestId("charging-plan-modal");
|
||||
await expect(modal.getByTestId("static-plan-active")).toBeVisible();
|
||||
|
||||
// Strategy line shows informational note only, not clickable
|
||||
await expect(modal.getByTestId("plan-strategy")).toContainText("just in time for departure");
|
||||
await expect(modal.getByTestId("plan-strategy").getByRole("button")).toHaveCount(0);
|
||||
await expect(modal.getByLabel("Optimization")).not.toBeVisible();
|
||||
await expect(modal.getByLabel("Late Charging")).not.toBeVisible();
|
||||
const strategy = modal.getByTestId("plan-strategy");
|
||||
await expect(strategy).toContainText("right before departure");
|
||||
await strategy.getByRole("button").click();
|
||||
await expect(modal.getByLabel("Optimization")).toBeDisabled();
|
||||
await expect(modal.getByLabel("Optimization")).toHaveText("none");
|
||||
await expect(modal.getByLabel("Late Charging")).toBeDisabled();
|
||||
await expect(modal.getByLabel("Late Charging")).toHaveText("everything");
|
||||
await expect(strategy).toContainText("Requires a dynamic tariff or CO₂ forecast.");
|
||||
});
|
||||
|
||||
test("co2 tariff: cleanest instead of cheapest", async ({ page }) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue