Vous avez reçu un message "Your GitLab account has been locked ..." ? Pas d'inquiétude : lisez cet article https://docs.gricad-pages.univ-grenoble-alpes.fr/help/unlock/

Commit 329f5c90 authored by Samuel's avatar Samuel
Browse files

WIP

parent 479f4a8c
......@@ -280,10 +280,7 @@ class SharedComponent():
slider = self.get_daterange_slider(date, vertical=True)
slider_component = dbc.Col(
width=4,
children=[
html.Label("Years between"),
slider
]
children=[ slider ]
)
options_component = dbc.Row(
children=[
......@@ -293,7 +290,7 @@ class SharedComponent():
html.Div(
id="nb_sample",
children=[
html.Label("""# sample > to"""),
html.Label("# >"),
dcc.Input(
id='nbsample-slider',
min=0,
......@@ -307,12 +304,12 @@ class SharedComponent():
id='options_check',
className='options-select-items',
options=[
{'label': 'PM₁₀', 'value': 'PM10'},
{'label': 'PM₂.₅', 'value': 'PM2.5'},
{'label': 'PM₁', 'value': 'PM1'},
{'label': 'PM?', 'value': 'PMX'},
{'label': 'With OP', 'value': 'hasOP'},
{'label': 'Use labels to group by', 'value': 'uselabel'},
{'label': 'PM10 fraction', 'value': 'PM10'},
{'label': 'PM2.5 fraction', 'value': 'PM2.5'},
{'label': 'PM1 fraction', 'value': 'PM1'},
{'label': 'PM fraction unknown', 'value': 'PMX'},
],
value=["PM10", "PM2.5", "PM1", "PMX"],
)
......@@ -322,38 +319,6 @@ class SharedComponent():
)
return options_component
options_component = dbc.Row(children=[
dbc.Col(
id="nb_sample",
children=[
"""# sample > to""",
dcc.Input(
id='nbsample-slider',
min=0,
max=300,
value=1,
style={"width": "40px"}
),
dcc.Checklist(
id='options_check',
className='options-select-items',
options=[
{'label': 'With OP', 'value': 'hasOP'},
{'label': 'Use labels to group by', 'value': 'uselabel'},
{'label': 'PM10 fraction', 'value': 'PM10'},
{'label': 'PM2.5 fraction', 'value': 'PM2.5'},
{'label': 'PM1 fraction', 'value': 'PM1'},
{'label': 'PM fraction unknown', 'value': 'PMX'},
],
value=["PM10", "PM2.5", "PM1", "PMX"],
labelStyle={'display': 'inline-block',
'margin': '0 5px'}
)
],
style={'display': 'inline-block',
'margin': '0 10px'}
)
])
datatable_component = html.Div(
id="datatable-component",
......
......@@ -2,6 +2,7 @@
from dash.dependencies import Input, Output, State
import dash_core_components as dcc
import dash_html_components as html
import dash_bootstrap_components as dbc
# import dash_table_experiments as dt
import plotly.graph_objs as go
import plotly.express as px
......@@ -107,14 +108,15 @@ app.layout = html.Div(
]),
html.Div([
html.Div(
sc.get_daterange_slider(df["Date"]),
style={'margin': '0 20px 20px 20px'}
),
html.Div(
dbc.Col(
width=8,
children=sc.get_map_component(list_station)
),
dbc.Col(
id="options",
children=[sc.options_component],
),
width=4,
children=[sc.get_options_component(date=df["Date"])],
),
], style={'display':'inline-block', 'width':'100%'}),
sc.get_map_component(list_station),
......
......@@ -4,23 +4,22 @@
{% block title %}PMALL: capture'them all!{% endblock %}
{% block specific_css %}
<link rel="stylesheet" type="text/css" href="{% static 'css/apps.css' %}"/>
<link rel="stylesheet" type="text/css" href="{% static 'css/apps.css' %}"/>
{% endblock specific_css %}
{%load plotly_dash%}
{% block content %}
{% with request.get_full_path|slice:"1:-1" as appname %}
{% if user.is_authenticated or appname in settings.NO_LOGIN_APPS %}
{# {% plotly_app name="app_"|add:appname ratio=0.9%} #}
{% plotly_direct name="app_"|add:appname%}
{% plotly_direct name="app_"|add:appname%}
{% else %}
<div class="container default-text">
<div class="container default-text">
<p class="registration-needed">You must be login in order to acces this
page.
</br>
<a href="{% url 'login' %}?next={{ request.path }}" class="button alt" >login</a>
</p>
</div>
</div>
{% endif %}
{% endwith %}
{% endblock %}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment