♻️ refactor + location conditions
This commit is contained in:
parent
ce9cdc4256
commit
3076ebe6a0
19 changed files with 1228 additions and 520 deletions
12
docs/Item.md
12
docs/Item.md
|
@ -75,3 +75,15 @@ variants:
|
|||
name: "Regular Water"
|
||||
barcodes: [12345678]
|
||||
```
|
||||
|
||||
### Need Conditions
|
||||
Some items prefer or need to be stored under some conditions. These conditions can be configured and warn you when locations dont match the required conditions.
|
||||
|
||||
```yml
|
||||
name: "Water"
|
||||
variants:
|
||||
regular:
|
||||
name: "Regular Water"
|
||||
needs:
|
||||
temperature: [5.0, 10.0]
|
||||
```
|
||||
|
|
|
@ -50,7 +50,20 @@ Example: Freezer
|
|||
{
|
||||
"name": "Freezer",
|
||||
"conditions": {
|
||||
"temperature": -10
|
||||
"temperature": -10.0
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
#### Fetch temperature from Home Assistant
|
||||
You can fetch the temperature from a sensor via Home Assistant.
|
||||
You need to setup a API Token for Home Assistant. After that you can enter the sensors API route in the location definition:
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "Freezer",
|
||||
"conditions": {
|
||||
"temperature_sensor": "https://homeassistant.local/api/states/sensor.freezer_temperature"
|
||||
}
|
||||
}
|
||||
```
|
Loading…
Add table
Add a link
Reference in a new issue