flexmeasures.ui.views.assets.views
Classes
- class flexmeasures.ui.views.assets.views.AssetCrudUI
These views help us offer a Jinja2-based UI. If endpoints create/change data, we aim to use the logic and authorization in the actual API, so these views simply call the API functions,and deal with the response.
- auditlog(id: str)
/assets/<id>/auditlog
- automations(id: str)
GET from /assets/<id>/automations to show the automations defined on the asset.
- context(id: str, **kwargs)
/assets/<id>/context
- create_sensor(id: str)
GET to /assets/<id>/sensors/new
- delete_with_data(id: str)
Delete via /assets/delete_with_data/<id>
- get(id: str, **kwargs)
/assets/<id>
- graphs(id: str, start_time=None, end_time=None)
/assets/<id>/graphs
- index(msg='', **kwargs)
GET from /assets
List the user’s assets. For admins, list across all accounts.
- owned_by(account_id: str)
GET /assets/owned_by/<account_id>
- post(id: str)
Either “create” a new asset from POST data. Or, if an actual ID is given, patch the existing asset with POST data.
- properties(id: str)
/assets/<id>/properties
- status(id: str)
GET from /assets/<id>/status to show the staleness of the asset’s sensors.