Skip to content

Commit

Permalink
Deprecate portfolio and analytics views (#321)
Browse files Browse the repository at this point in the history
Unlink that which wasn't made compatible at this point with the new data model, and is therefore essentially broken.


* Remove portfolio and analytics from default menu views

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Unlink portfolio and analytics from UI documentation

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Unlink control page from UI documentation

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Comment out links to analytics page on dashboard

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Comment out links to analytics page on asset pages

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Changelog entry

Signed-off-by: F.N. Claessen <felix@seita.nl>
  • Loading branch information
Flix6x committed Jan 19, 2022
1 parent 279a3be commit 93e481a
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 32 deletions.
4 changes: 4 additions & 0 deletions documentation/changelog.rst
Expand Up @@ -16,6 +16,10 @@ New features
* Schedulers take into account round-trip efficiency if set [see `PR #291 <http://www.github.com/FlexMeasures/flexmeasures/pull/291>`_]
* Fallback policies for charging schedules of batteries and Charge Points, in cases where the solver is presented with an infeasible problem [see `PR #267 <http://www.github.com/FlexMeasures/flexmeasures/pull/267>`_ and `PR #270 <http://www.github.com/FlexMeasures/flexmeasures/pull/270>`_]

Deprecations
------------
* The Portfolio and Analytics views are deprecated [see `PR #321 <http://www.github.com/FlexMeasures/flexmeasures/pull/321>`_]

Bugfixes
-----------
* Fix recording time of schedules triggered by UDI events [see `PR #300 <http://www.github.com/FlexMeasures/flexmeasures/pull/300>`_]
Expand Down
3 changes: 0 additions & 3 deletions documentation/index.rst
Expand Up @@ -89,9 +89,6 @@ The platform operator of FlexMeasures can be an Aggregator.
:maxdepth: 1

views/dashboard
views/portfolio
views/control
views/analytics
views/admin

.. toctree::
Expand Down
12 changes: 6 additions & 6 deletions flexmeasures/ui/templates/crud/asset.html
Expand Up @@ -8,12 +8,12 @@

<div class="container-fluid">
<div class="row">
<div class="col-sm-1">
<form action="../../analytics" method="get">
<input type="hidden" name="resource" value="{{ asset.name }}">
<button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this asset</button>
</form>
</div>
<!-- <div class="col-sm-1">-->
<!-- <form action="../../analytics" method="get">-->
<!-- <input type="hidden" name="resource" value="{{ asset.name }}">-->
<!-- <button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this asset</button>-->
<!-- </form>-->
<!-- </div>-->
{% if user_is_admin %}
<div class="col-sm-1">
<form action="/assets/new" method="get" style="float:right">
Expand Down
10 changes: 5 additions & 5 deletions flexmeasures/ui/templates/crud/assets.html
Expand Up @@ -52,11 +52,11 @@ <h2>All assets owned by account {{account.name}}</h2>
{{ asset.sensors | length }}
</td>
<td class="text-right">
<form action="../../analytics" method="get">
<input type="hidden" name="resource" value="{{ asset.name }}">
<button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this
asset</button>
</form>
<!-- <form action="../../analytics" method="get">-->
<!-- <input type="hidden" name="resource" value="{{ asset.name }}">-->
<!-- <button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this-->
<!-- asset</button>-->
<!-- </form>-->
</td>

</tr>
Expand Down
18 changes: 10 additions & 8 deletions flexmeasures/ui/templates/views/dashboard.html
Expand Up @@ -87,8 +87,10 @@ <h3>
{% if (FLEXMEASURES_MODE == "demo" and asset_groups[asset_group].count_all > 0) or (FLEXMEASURES_MODE != "demo" and asset_groups[asset_group].count > 0)%}
<th {% if asset_groups[asset_group].hover_label %}
title="{{ asset_groups[asset_group].hover_label | capitalize }}" {% endif %}
class="text-center{% if asset_group in aggregate_groups %} agg-group{% endif %}"><a
href="analytics?resource={{ asset_group }}">{{ asset_group | capitalize }}</a>
class="text-center{% if asset_group in aggregate_groups %} agg-group{% endif %}">
<!-- <a href="analytics?resource={{ asset_group }}">-->
{{ asset_group | capitalize }}
<!-- </a>-->
</th>
{% endif %}
{% endfor %}
Expand Down Expand Up @@ -214,12 +216,12 @@ <h4>{{ asset.display_name }}</h4>
<div class="col-sm-5 bokeh-state-plot"></div>
<div class="col-sm-7">
<div class="row top-buffer">
<div class="col-sm-12">
<form action="analytics" method="get">
<input type="hidden" name="resource" value="{{ asset.name }}">
<button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this asset</button>
</form>
</div>
<!-- <div class="col-sm-12">-->
<!-- <form action="analytics" method="get">-->
<!-- <input type="hidden" name="resource" value="{{ asset.name }}">-->
<!-- <button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this asset</button>-->
<!-- </form>-->
<!-- </div>-->
</div>
<div class="row top-buffer">
<div class="col-sm-12">
Expand Down
18 changes: 10 additions & 8 deletions flexmeasures/ui/templates/views/new_dashboard.html
Expand Up @@ -24,8 +24,10 @@ <h3>
{# On demo, show all non-empty groups, otherwise show all groups that are non-empty for the current user #}
<th {% if asset_groups[asset_group_name].hover_label %}
title="{{ asset_groups[asset_group_name].hover_label | capitalize }}" {% endif %}
class="text-center{% if asset_group_name in aggregate_groups %} agg-group{% endif %}"><a
href="analytics?resource={{ asset_group_name }}">{{ asset_group_name | capitalize }}</a>
class="text-center{% if asset_group_name in aggregate_groups %} agg-group{% endif %}">
<!-- <a href="analytics?resource={{ asset_group_name }}">-->
{{ asset_group_name | capitalize }}
<!-- </a>-->
</th>
{% endfor %}
</tr>
Expand Down Expand Up @@ -142,12 +144,12 @@ <h4>{{ asset.name }}</h4>
<div class="col-sm-5 bokeh-state-plot"></div>
<div class="col-sm-7">
<div class="row top-buffer">
<div class="col-sm-12">
<form action="analytics" method="get">
<input type="hidden" name="resource" value="{{ asset.name }}">
<button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this asset</button>
</form>
</div>
<!-- <div class="col-sm-12">-->
<!-- <form action="analytics" method="get">-->
<!-- <input type="hidden" name="resource" value="{{ asset.name }}">-->
<!-- <button class="btn btn-sm btn-responsive btn-info" type="submit">Analyse this asset</button>-->
<!-- </form>-->
<!-- </div>-->
</div>
<div class="row top-buffer">
<div class="col-sm-12">
Expand Down
2 changes: 0 additions & 2 deletions flexmeasures/utils/config_defaults.py
Expand Up @@ -102,8 +102,6 @@ class Config(object):
FLEXMEASURES_ROOT_VIEW: Union[str, List[Union[str, Tuple[str, List[str]]]]] = []
FLEXMEASURES_MENU_LISTED_VIEWS: List[Union[str, Tuple[str, List[str]]]] = [
"dashboard",
"analytics",
"portfolio",
"assets",
"users",
]
Expand Down

0 comments on commit 93e481a

Please sign in to comment.