mirror of
https://github.com/openhab/openhab-addons.git
synced 2025-01-27 07:41:39 +01:00
[energidataservice] Fix JRuby tabs (#17005)
* Fix JRuby tabs * Fix Rule DSL example after breaking changes in PersistenceExtensions Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk> Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
This commit is contained in:
parent
250955a7a4
commit
f09d0d7a1e
@ -440,7 +440,7 @@ var result = edsActions.calculateCheapestPeriod(time.Instant.now(), time.Instant
|
|||||||
|
|
||||||
:::
|
:::
|
||||||
|
|
||||||
::: tabs JRuby
|
::: tab JRuby
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
duration_phases = [37, 8, 4, 2, 4, 36, 41, 104].map { |duration| duration.minutes }
|
duration_phases = [37, 8, 4, 2, 4, 36, 41, 104].map { |duration| duration.minutes }
|
||||||
@ -528,7 +528,7 @@ var result = edsActions.calculateCheapestPeriod(time.Instant.now(), time.Instant
|
|||||||
|
|
||||||
:::
|
:::
|
||||||
|
|
||||||
::: tabs JRuby
|
::: tab JRuby
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
duration_phases = [37, 8, 4, 2, 4, 36, 41].map { |duration| duration.minutes }
|
duration_phases = [37, 8, 4, 2, 4, 36, 41].map { |duration| duration.minutes }
|
||||||
@ -899,7 +899,7 @@ result = eds.calculate_cheapest_period(ZonedDateTime.now.to_instant,
|
|||||||
|
|
||||||
```java
|
```java
|
||||||
var hourStart = now.plusHours(2).truncatedTo(ChronoUnit.HOURS)
|
var hourStart = now.plusHours(2).truncatedTo(ChronoUnit.HOURS)
|
||||||
var price = SpotPrice.historicState(hourStart).state
|
var price = SpotPrice.persistedState(hourStart).state
|
||||||
logInfo("Spot price two hours from now", price.toString)
|
logInfo("Spot price two hours from now", price.toString)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user