8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-22 11:23:10 +00:00

Merge branch 'master' into 'clean_api_duplicate'

# Conflicts:
#   CHANGELOG.md
This commit is contained in:
klafyvel 2018-06-24 22:57:15 +02:00
commit 17f3867371
14 changed files with 7706 additions and 68 deletions

View file

@ -46,6 +46,14 @@ install_re2o.sh help
## MR 176: Add awesome Logo
Add the logo and fix somme issues on the navbar and home page. Only collecting the statics is needed:
```
python3 manage.py collectstatic
```
## MR 172: Refactor API ## MR 172: Refactor API
Creates a new (nearly) REST API to expose all models of Re2o. See [the dedicated wiki page](https://gitlab.federez.net/federez/re2o/wikis/API/Raw-Usage) for more details on how to use it. Creates a new (nearly) REST API to expose all models of Re2o. See [the dedicated wiki page](https://gitlab.federez.net/federez/re2o/wikis/API/Raw-Usage) for more details on how to use it.
@ -63,6 +71,4 @@ OPTIONAL_APPS = (
... ...
'api', 'api',
... ...
) )
```

View file

@ -42,6 +42,8 @@ def context_user(request):
return { return {
'request_user': user, 'request_user': user,
'interfaces': interfaces, 'interfaces': interfaces,
'site_name': GeneralOption.get_cached_value('site_name'), # Must takes a different name because djang.auth.contrib.views.login()
# overrides 'site_name' context variable.
'name_website': GeneralOption.get_cached_value('site_name'),
'ipv6_enabled': OptionalMachine.get_cached_value('ipv6'), 'ipv6_enabled': OptionalMachine.get_cached_value('ipv6'),
} }

Binary file not shown.

View file

@ -21,7 +21,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: 2.5\n" "Project-Id-Version: 2.5\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-03-31 14:05+0000\n" "POT-Creation-Date: 2018-06-23 18:26+0200\n"
"PO-Revision-Date: 2018-03-31 16:09+0002\n" "PO-Revision-Date: 2018-03-31 16:09+0002\n"
"Last-Translator: Maël Kervella <dev@maelkervella.eu>\n" "Last-Translator: Maël Kervella <dev@maelkervella.eu>\n"
"Language-Team: \n" "Language-Team: \n"
@ -77,17 +77,17 @@ msgstr ""
"\n" "\n"
" Re2o est un outil d'administration initié par\n" " Re2o est un outil d'administration initié par\n"
" <a href=\"https://rezometz.org/\">Rezo Supelec Metz</a> et quelques\n" " <a href=\"https://rezometz.org/\">Rezo Supelec Metz</a> et quelques\n"
" membres d'autres assocations de " " membres d'autres assocations de <a href=\"https://federez.net"
"<a href=\"https://federez.net\">FedeRez</a>\n" "\">FedeRez</a>\n"
" autour de l'été 2016.<br />\n" " autour de l'été 2016.<br />\n"
" Il se veut être un outil idépendant de toute infrastructure réseau\n" " Il se veut être un outil idépendant de toute infrastructure réseau\n"
" pour pouvoir être installé en \"quelques étapes\". Cet outil est " " pour pouvoir être installé en \"quelques étapes\". Cet outil est "
"entièrement gratuit et\n" "entièrement gratuit et\n"
" est disponible sous license GNU Public License v2 (GPLv2) sur le\n" " est disponible sous license GNU Public License v2 (GPLv2) sur le\n"
" <a href=\"https://gitlab.federez.net/federez/re2o/\">gitlab de FedeRez" " <a href=\"https://gitlab.federez.net/federez/re2o/\">gitlab de "
"</a>.<br />\n" "FedeRez</a>.<br />\n"
" Les mainteneurs de Re2o sont de fiers bénévoles venant principalement " " Les mainteneurs de Re2o sont de fiers bénévoles venant "
"d'écoles d'ingénieurs françaises\n" "principalement d'écoles d'ingénieurs françaises\n"
" (mais pas seulement) qui ont donné beaucoup de leur temps pour faire " " (mais pas seulement) qui ont donné beaucoup de leur temps pour faire "
"en sorte que\n" "en sorte que\n"
" ce projet soit possible. Donc s'il vous plait soyez gentils avez eux." " ce projet soit possible. Donc s'il vous plait soyez gentils avez eux."
@ -155,14 +155,19 @@ msgstr ""
msgid "Dependencies" msgid "Dependencies"
msgstr "Dépendances" msgstr "Dépendances"
#: templates/re2o/buttons/setlang.html:34 #: templates/re2o/index.html:30
msgid "Translation in development" msgid "Home"
msgstr "Traduction en développement" msgstr "Accueil"
#: views.py:172 #: templates/re2o/index.html:33
msgid "No Git repository configured" #, python-format
msgstr "Aucun repository git configuré" msgid "Welcome to %(name_website)s !"
msgstr "Bienvenue sur %(name_website)s !"
#: views.py:178 #: templates/re2o/index.html:47
msgid "Go there"
msgstr "Accéder"
#: views.py:205
msgid "Unable to get the information" msgid "Unable to get the information"
msgstr "Impossible d'obtenir l'information" msgstr "Impossible d'obtenir l'information"

View file

@ -25,11 +25,12 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% load bootstrap3 %} {% load bootstrap3 %}
{% load staticfiles %} {% load staticfiles %}
{% load i18n %}
{% block title %}Accueil{% endblock %} {% block title %}{% trans "Home" %}{% endblock %}
{% block content %} {% block content %}
<h1>Bienvenue sur {{ request.get_host }} !</h1> <h1>{% blocktrans %}Welcome to {{ name_website }} !{% endblocktrans %}</h1>
<div class="row"> <div class="row">
{% for service_list in services_urls %} {% for service_list in services_urls %}
@ -38,12 +39,12 @@ with this program; if not, write to the Free Software Foundation, Inc.,
<div class="col-12"> <div class="col-12">
<div class="thumbnail"> <div class="thumbnail">
{% if service.image %} {% if service.image %}
<a href="{{ service.url }}"><img src="{{ service.image.url }}" alt="{{ service.name }}"></a> <a href="{{ service.url }}"><img src="{{ service.image.url }}" alt="{{ service.name }}"></a>
{% endif %} {% endif %}
<div class="caption"> <div class="caption">
<h3>{{ service.name }}</h3> <h3>{{ service.name }}</h3>
<p>{{ service.description }}</p> <p>{{ service.description }}</p>
<p><a href="{{ service.url }}" class="btn btn-primary" role="button">Accéder</a></p> <p><a href="{{ service.url }}" class="btn btn-primary" role="button">{% trans "Go there" %}</a></p>
</div> </div>
</div> </div>
</div> </div>

View file

@ -35,6 +35,18 @@ footer a {
border-radius: 0; border-radius: 0;
} }
/* Reduce the padding for the logo in the navbar-brand so the 32px-high logo
* is centered in the navbar */
.navbar-brand {
padding-top: 9px;
padding-bottom: 9px;
}
/* Display logo and site name side by side and not on top of each other */
.navbar-brand img {
display: initial;
}
/* Add right colors for buttons in dropdown in navbar-inverse (else it is light /* Add right colors for buttons in dropdown in navbar-inverse (else it is light
* gray on white bg and white when hovered */ * gray on white bg and white when hovered */
.navbar-inverse .dropdown-menu .btn-link { .navbar-inverse .dropdown-menu .btn-link {

3618
static/images/logo_re2o.ai Executable file

File diff suppressed because one or more lines are too long

3597
static/images/logo_re2o.pdf Executable file

File diff suppressed because one or more lines are too long

120
static/images/logo_re2o.svg Executable file
View file

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Generator: Adobe Illustrator 22.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
version="1.1"
id="Calque_1"
x="0px"
y="0px"
viewBox="0 0 128 128"
xml:space="preserve"
sodipodi:docname="logo_re2o.svg"
width="128"
height="128"
inkscape:version="0.92.3 (2405546, 2018-03-11)"><metadata
id="metadata3852"><rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
id="defs3850" /><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1853"
inkscape:window-height="1025"
id="namedview3848"
showgrid="false"
inkscape:zoom="1.4177726"
inkscape:cx="214.81788"
inkscape:cy="184.70713"
inkscape:window-x="67"
inkscape:window-y="27"
inkscape:window-maximized="1"
inkscape:current-layer="Calque_1" />
<style
type="text/css"
id="style3821">
.st0{fill:#ED2024;}
.st1{stroke:#000000;stroke-miterlimit:10;}
.st2{fill:#F9A01B;}
.st3{fill:#FFFFFF;}
.st4{fill:#E64F25;}
</style>
<path
class="st0"
d="M 84.261307,119.9821 H 16.72362 c -4.716918,0 -8.5762149,-3.86577 -8.5762149,-8.5906 V 43.812082 c 2.9302069,1.07383 6.0748189,1.57494 9.3623679,1.57494 2.429927,0 4.859854,-0.28635 7.075376,-0.93064 v 50.39821 c 0,4.72483 3.859297,8.590598 8.576215,8.590598 h 50.242321 c -0.571748,2.21924 -0.857621,4.51007 -0.857621,6.94407 0,3.43624 0.643216,6.58613 1.715243,9.59284 z"
id="path3823"
inkscape:connector-curvature="0"
style="fill:#ed2024;stroke-width:0.71528381" />
<path
class="st0"
d="m 119.8526,16.751682 v 67.36465 c -2.93021,-1.07382 -6.07482,-1.57494 -9.36237,-1.57494 -2.42993,0 -4.85986,0.28635 -7.07538,0.93065 v -50.18345 c 0,-4.72483 -3.859294,-8.5906 -8.576212,-8.5906 h -50.31379 c 0.571748,-2.29083 0.92909,-4.65325 0.92909,-7.08725 0,-3.29307 -0.571748,-6.44295 -1.572306,-9.3780798 h 67.466218 c 4.64545,-0.0716 8.50475,3.7941898 8.50475,8.5190198 z"
id="path3825"
inkscape:connector-curvature="0"
style="fill:#ed2024;stroke-width:0.71528381" />
<path
class="st1"
d="m 104.55835,96.214772 c -3.8593,1.57494 -6.860974,4.724828 -8.43328,8.590598 L 73.255165,81.897092 45.954217,54.550342 23.084312,31.642062 c 3.859296,-1.57495 6.93244,-4.65325 8.504746,-8.51902 l 24.084869,24.12528 24.87102,24.91275 z"
id="path3827"
inkscape:connector-curvature="0"
style="stroke:#000000;stroke-width:0.71528381;stroke-miterlimit:10" />
<g
id="g3833"
transform="matrix(0.71468453,0,0,0.71588367,-231.27192,-117.61969)">
<path
class="st2"
d="m 478.2,341.5 c -12.7,0 -23,-10.3 -23,-23 0,-2.9 0.5,-5.7 1.6,-8.3 2.2,-5.8 6.8,-10.5 12.6,-12.9 2.8,-1.2 5.8,-1.8 8.8,-1.8 12.7,0 23,10.3 23,23 0,12.7 -10.3,23 -23,23 z"
id="path3829"
inkscape:connector-curvature="0"
style="fill:#f9a01b" />
<path
class="st3"
d="m 478.2,297.1 c 11.9,0 21.5,9.6 21.5,21.5 0,11.9 -9.6,21.5 -21.5,21.5 -11.9,0 -21.5,-9.6 -21.5,-21.5 0,-2.8 0.5,-5.4 1.5,-7.8 2.1,-5.4 6.4,-9.8 11.8,-12 2.5,-1.1 5.3,-1.7 8.2,-1.7 m 0,-3 c -3.3,0 -6.5,0.6 -9.4,1.9 -6.1,2.5 -11,7.5 -13.4,13.7 -1.1,2.8 -1.7,5.8 -1.7,8.9 0,13.5 11,24.5 24.5,24.5 13.5,0 24.5,-11 24.5,-24.5 0,-13.5 -11,-24.5 -24.5,-24.5 z"
id="path3831"
inkscape:connector-curvature="0"
style="fill:#ffffff" />
</g>
<g
id="g3839"
transform="matrix(0.71468453,0,0,0.71588367,-231.27192,-117.61969)">
<path
class="st2"
d="m 348.1,211.7 c -12.7,0 -23,-10.3 -23,-23 0,-12.7 10.3,-23 23,-23 12.7,0 23,10.3 23,23 0,3 -0.6,5.9 -1.7,8.6 -2.3,5.7 -7,10.4 -12.7,12.7 -2.8,1.2 -5.7,1.7 -8.6,1.7 z"
id="path3835"
inkscape:connector-curvature="0"
style="fill:#f9a01b" />
<path
class="st3"
d="m 348.1,167.3 c 11.9,0 21.5,9.6 21.5,21.5 0,2.9 -0.5,5.6 -1.6,8.1 -2.2,5.4 -6.5,9.7 -11.9,11.9 -2.5,1 -5.2,1.5 -8,1.5 -11.9,0 -21.5,-9.6 -21.5,-21.5 0,-11.9 9.6,-21.5 21.5,-21.5 m 0,-3 c -13.5,0 -24.5,11 -24.5,24.5 0,13.5 11,24.5 24.5,24.5 3.2,0 6.2,-0.6 9.1,-1.8 6.1,-2.5 11.1,-7.4 13.6,-13.5 1.2,-2.9 1.8,-6 1.8,-9.2 -0.1,-13.6 -11,-24.5 -24.5,-24.5 z"
id="path3837"
inkscape:connector-curvature="0"
style="fill:#ffffff" />
</g>
<g
id="g3845"
transform="matrix(0.71468453,0,0,0.71588367,-231.27192,-117.61969)">
<path
class="st4"
d="m 413,283.3 c -16.2,0 -29.5,-13.2 -29.5,-29.5 0,-16.2 13.2,-29.5 29.5,-29.5 16.3,0 29.5,13.2 29.5,29.5 0,3.9 -0.7,7.6 -2.2,11.1 -3,7.4 -8.9,13.3 -16.3,16.3 -3.5,1.3 -7.2,2.1 -11,2.1 z"
id="path3841"
inkscape:connector-curvature="0"
style="fill:#e64f25" />
<path
class="st3"
d="m 413,225.3 c 15.7,0 28.5,12.7 28.5,28.5 0,3.8 -0.7,7.4 -2.1,10.7 -2.9,7.2 -8.6,12.9 -15.8,15.7 -3.3,1.3 -6.9,2.1 -10.6,2.1 -15.7,0 -28.5,-12.8 -28.5,-28.5 0,-15.7 12.8,-28.5 28.5,-28.5 m 0,-2 c -16.8,0 -30.5,13.7 -30.5,30.5 0,16.8 13.7,30.5 30.5,30.5 3.9,0 7.8,-0.7 11.4,-2.2 7.6,-3.1 13.8,-9.2 16.9,-16.8 1.5,-3.6 2.2,-7.5 2.2,-11.4 0,-16.9 -13.7,-30.6 -30.5,-30.6 z"
id="path3843"
inkscape:connector-curvature="0"
style="fill:#ffffff" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 5.5 KiB

View file

@ -0,0 +1,133 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Generator: Adobe Illustrator 22.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
version="1.1"
id="Calque_1"
x="0px"
y="0px"
viewBox="0 0 128 128"
xml:space="preserve"
sodipodi:docname="logo_re2o_navbar.svg"
width="128"
height="128"
inkscape:version="0.92.3 (2405546, 2018-03-11)"><metadata
id="metadata137"><rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
id="defs135" /><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1853"
inkscape:window-height="1025"
id="namedview133"
showgrid="false"
inkscape:zoom="1.4177726"
inkscape:cx="267.64168"
inkscape:cy="26.667212"
inkscape:window-x="67"
inkscape:window-y="27"
inkscape:window-maximized="1"
inkscape:current-layer="Calque_1" />
<style
type="text/css"
id="style102">
.st0{fill:#ED2024;}
.st1{stroke:#000000;stroke-miterlimit:10;}
.st2{fill:#F9A01B;}
.st3{fill:#FFFFFF;}
.st4{fill:none;}
.st5{font-family:'RobotoSlab-Regular';}
.st6{font-size:58.0541px;}
.st7{fill:#E64F25;}
</style>
<path
class="st0"
d="M 84.261307,119.98209 H 16.723618 c -4.716918,0 -8.5762143,-3.86577 -8.5762143,-8.5906 V 43.812084 c 2.9302063,1.07382 6.0748183,1.574934 9.3623673,1.574934 2.429927,0 4.859855,-0.286354 7.075377,-0.930654 V 94.85459 c 0,4.72483 3.859296,8.59059 8.576214,8.59059 h 50.242323 c -0.571747,2.21924 -0.857621,4.51007 -0.857621,6.94407 0,3.43624 0.643216,6.58613 1.715243,9.59284 z"
id="path104"
inkscape:connector-curvature="0"
style="fill:#ed2024;stroke-width:0.71528387" />
<path
class="st0"
d="M 119.8526,16.751673 V 84.11633 c -2.93021,-1.07382 -6.07482,-1.57494 -9.36237,-1.57494 -2.42993,0 -4.85986,0.28636 -7.07538,0.93065 V 33.28859 c 0,-4.724832 -3.859294,-8.590604 -8.576212,-8.590604 H 44.524846 c 0.571748,-2.290827 0.92909,-4.653248 0.92909,-7.087252 0,-3.293055 -0.571747,-6.442953 -1.572306,-9.37807 h 67.46622 c 4.64545,-0.07163 8.50475,3.794187 8.50475,8.519009 z"
id="path106"
inkscape:connector-curvature="0"
style="fill:#ed2024;stroke-width:0.71528387" />
<path
class="st1"
d="m 104.55835,96.21477 c -3.8593,1.57494 -6.860974,4.72481 -8.43328,8.59059 L 73.255165,81.8971 45.954216,54.550338 23.084311,31.642052 c 3.859296,-1.574934 6.932439,-4.653238 8.504745,-8.51901 l 24.08487,24.125273 24.871021,24.912765 z"
id="path108"
inkscape:connector-curvature="0"
style="fill:#ffffff;stroke:#ffffff;stroke-width:0.71528387;stroke-miterlimit:10" />
<g
id="g114"
transform="matrix(0.71468453,0,0,0.71588367,-231.27192,-117.61969)">
<path
class="st2"
d="m 478.2,341.5 c -12.7,0 -23,-10.3 -23,-23 0,-2.9 0.5,-5.7 1.6,-8.3 2.2,-5.8 6.8,-10.5 12.6,-12.9 2.8,-1.2 5.8,-1.8 8.8,-1.8 12.7,0 23,10.3 23,23 0,12.7 -10.3,23 -23,23 z"
id="path110"
inkscape:connector-curvature="0"
style="fill:#f9a01b" />
<path
class="st3"
d="m 478.2,297.1 c 11.9,0 21.5,9.6 21.5,21.5 0,11.9 -9.6,21.5 -21.5,21.5 -11.9,0 -21.5,-9.6 -21.5,-21.5 0,-2.8 0.5,-5.4 1.5,-7.8 2.1,-5.4 6.4,-9.8 11.8,-12 2.5,-1.1 5.3,-1.7 8.2,-1.7 m 0,-3 c -3.3,0 -6.5,0.6 -9.4,1.9 -6.1,2.5 -11,7.5 -13.4,13.7 -1.1,2.8 -1.7,5.8 -1.7,8.9 0,13.5 11,24.5 24.5,24.5 13.5,0 24.5,-11 24.5,-24.5 0,-13.5 -11,-24.5 -24.5,-24.5 z"
id="path112"
inkscape:connector-curvature="0"
style="fill:#000000" />
</g>
<g
id="g120"
transform="matrix(0.71468453,0,0,0.71588367,-231.27192,-117.61969)">
<path
class="st2"
d="m 348.1,211.7 c -12.7,0 -23,-10.3 -23,-23 0,-12.7 10.3,-23 23,-23 12.7,0 23,10.3 23,23 0,3 -0.6,5.9 -1.7,8.6 -2.3,5.7 -7,10.4 -12.7,12.7 -2.8,1.2 -5.7,1.7 -8.6,1.7 z"
id="path116"
inkscape:connector-curvature="0"
style="fill:#f9a01b" />
<path
class="st3"
d="m 348.1,167.3 c 11.9,0 21.5,9.6 21.5,21.5 0,2.9 -0.5,5.6 -1.6,8.1 -2.2,5.4 -6.5,9.7 -11.9,11.9 -2.5,1 -5.2,1.5 -8,1.5 -11.9,0 -21.5,-9.6 -21.5,-21.5 0,-11.9 9.6,-21.5 21.5,-21.5 m 0,-3 c -13.5,0 -24.5,11 -24.5,24.5 0,13.5 11,24.5 24.5,24.5 3.2,0 6.2,-0.6 9.1,-1.8 6.1,-2.5 11.1,-7.4 13.6,-13.5 1.2,-2.9 1.8,-6 1.8,-9.2 -0.1,-13.6 -11,-24.5 -24.5,-24.5 z"
id="path118"
inkscape:connector-curvature="0"
style="fill:#000000" />
</g>
<rect
x="263.89999"
y="-117.79999"
class="st4"
width="286.60001"
height="78.5"
id="rect122"
style="fill:none" />
<g
id="g130"
transform="matrix(0.71468453,0,0,0.71588367,-231.27192,-117.61969)">
<path
class="st7"
d="m 413,283.3 c -16.2,0 -29.5,-13.2 -29.5,-29.5 0,-16.2 13.2,-29.5 29.5,-29.5 16.3,0 29.5,13.2 29.5,29.5 0,3.9 -0.7,7.6 -2.2,11.1 -3,7.4 -8.9,13.3 -16.3,16.3 -3.5,1.3 -7.2,2.1 -11,2.1 z"
id="path126"
inkscape:connector-curvature="0"
style="fill:#e64f25" />
<path
class="st3"
d="m 413,225.3 c 15.7,0 28.5,12.7 28.5,28.5 0,3.8 -0.7,7.4 -2.1,10.7 -2.9,7.2 -8.6,12.9 -15.8,15.7 -3.3,1.3 -6.9,2.1 -10.6,2.1 -15.7,0 -28.5,-12.8 -28.5,-28.5 0,-15.7 12.8,-28.5 28.5,-28.5 m 0,-2 c -16.8,0 -30.5,13.7 -30.5,30.5 0,16.8 13.7,30.5 30.5,30.5 3.9,0 7.8,-0.7 11.4,-2.2 7.6,-3.1 13.8,-9.2 16.9,-16.8 1.5,-3.6 2.2,-7.5 2.2,-11.4 0,-16.9 -13.7,-30.6 -30.5,-30.6 z"
id="path128"
inkscape:connector-curvature="0"
style="fill:#000000" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 5.8 KiB

View file

@ -33,12 +33,14 @@ with this program; if not, write to the Free Software Foundation, Inc.,
<!DOCTYPE html> <!DOCTYPE html>
<html lang="fr"> <html lang="fr">
<head prefix="og: http://ogp.me/ns#"> <head prefix="og: http://ogp.me/ns#">
<meta property="og:title" content="Re2o" /> <meta property="og:title" content="Re2o" />
<meta property="og:type" content="website" /> <meta property="og:type" content="website" />
<meta property="og:url" content="\\{{request.get_host}}" /> <meta property="og:url" content="{{ request.scheme }}://{{ request.get_host }}/" />
<meta property="og:image" content="\\{{request.get_host}}/static/logo/re2o.png"/> <meta property="og:image" content="{% static 'images/logo_re2o.svg' %}"/>
<meta property="og:description" content="Site de gestion de réseau supporté par FedeRez." /> <meta property="og:image:type" content="image/svg"/>
<script defer src="https://use.fontawesome.com/releases/v5.0.8/js/all.js"></script> <meta property="og:image:alt" content="The Re2o logo"/>
<meta property="og:description" content="Site de gestion de réseau supporté par FedeRez." />
<script defer src="https://use.fontawesome.com/releases/v5.0.8/js/all.js"></script>
{# Load CSS and JavaScript #} {# Load CSS and JavaScript #}
{% bootstrap_css %} {% bootstrap_css %}
<link href="/static/css/typeaheadjs.css" rel="stylesheet"> <link href="/static/css/typeaheadjs.css" rel="stylesheet">
@ -50,10 +52,11 @@ with this program; if not, write to the Free Software Foundation, Inc.,
<script src="/static/js/konami/konami.js"></script> <script src="/static/js/konami/konami.js"></script>
<script src="/static/js/sapphire.js"> var s=Sapphire(); Konami(s.activate); </script> <script src="/static/js/sapphire.js"> var s=Sapphire(); Konami(s.activate); </script>
<script src="/static/js/bootstrap-tokenfield/bootstrap-tokenfield.js"></script> <script src="/static/js/bootstrap-tokenfield/bootstrap-tokenfield.js"></script>
<script src="/static/js/shortcuts.js"></script> <script src="/static/js/shortcuts.js"></script>
<link rel="stylesheet" href="{% static "/css/base.css" %}"> <link rel="stylesheet" href="{% static 'css/base.css' %}">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{ site_name }} : {% block title %}Accueil{% endblock %}</title> <link rel="shortcut icon" type="image/svg" href="{% static 'images/logo_re2o.svg' %}">
<title>{{ name_website }} : {% block title %}{% trans "Home" %}{% endblock %}</title>
</head> </head>
<body> <body>
@ -66,7 +69,10 @@ with this program; if not, write to the Free Software Foundation, Inc.,
<span class="icon-bar"></span> <span class="icon-bar"></span>
<span class="icon-bar"></span> <span class="icon-bar"></span>
</button> </button>
<a class="navbar-brand" href="/">{{ site_name }}</a> <a class="navbar-brand" href="/">
<img src="{% static 'images/logo_re2o_navbar.svg' %}" height=32>
{{ name_website }}
</a>
</div> </div>
<div class="collapse navbar-collapse" id="myNavbar"> <div class="collapse navbar-collapse" id="myNavbar">
<ul class="nav navbar-nav"> <ul class="nav navbar-nav">
@ -74,47 +80,47 @@ with this program; if not, write to the Free Software Foundation, Inc.,
<li class="dropdown"> <li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-user-circle"></i> {{request.user.pseudo|slice:":15"}} <span class="caret"></span></a> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-user-circle"></i> {{request.user.pseudo|slice:":15"}} <span class="caret"></span></a>
<ul class="dropdown-menu"> <ul class="dropdown-menu">
<li><a href="{% url "users:mon-profil" %}"><i class="fa fa-user"></i> Mon profil</a></li> <li><a href="{% url "users:mon-profil" %}"><i class="fa fa-user"></i> {% trans "My profile" %}</a></li>
<li><a id="toggle_login" href="{% url 'logout' %}"><i class="fa fa-sign-out-alt"></i> Se déconnecter</a></li> <li><a id="toggle_login" href="{% url 'logout' %}"><i class="fa fa-sign-out-alt"></i> {% trans "Log out" %}</a></li>
</ul> </ul>
</li> </li>
{% endif %} {% endif %}
{% can_view_any_app users machines cotisations %} {% can_view_any_app users machines cotisations %}
<li class="dropdown"> <li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-users"></i> Adhérents<span class="caret"></span></a> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-users"></i> {% trans "Members" %}<span class="caret"></span></a>
<ul class="dropdown-menu"> <ul class="dropdown-menu">
{% can_view_app users %} {% can_view_app users %}
<li><a href="{% url 'users:index' %}"><i class="fa fa-user"></i> Gérer les adhérents</a></li> <li><a href="{% url 'users:index' %}"><i class="fa fa-user"></i> {% trans "Manage members" %}</a></li>
<li><a href="{% url 'users:index-clubs' %}"><i class="fa fa-users"></i> Gérer les clubs</a></li> <li><a href="{% url 'users:index-clubs' %}"><i class="fa fa-users"></i> {% trans "Manage clubs" %}</a></li>
{% acl_end %} {% acl_end %}
{% can_view_app machines %} {% can_view_app machines %}
<li><a href="{% url 'machines:index' %}"><i class="fa fa-desktop"></i> Gérer les machines</a></li> <li><a href="{% url 'machines:index' %}"><i class="fa fa-desktop"></i> {% trans "Manage machines" %}</a></li>
{% acl_end %} {% acl_end %}
{% can_view_app cotisations %} {% can_view_app cotisations %}
<li><a href="{% url 'cotisations:index' %}"><i class="fa fa-dollar-sign"></i> Gérer les cotisations</a></li> <li><a href="{% url 'cotisations:index' %}"><i class="fa fa-dollar-sign"></i> {% trans "Manage cotisations" %}</a></li>
{% acl_end %} {% acl_end %}
</ul> </ul>
</li> </li>
{% acl_end %} {% acl_end %}
{% can_view_app topologie %} {% can_view_app topologie %}
<li class="dropdown"> <li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-sitemap"></i> Topologie<span class="caret"></span></a> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-sitemap"></i> {% trans "Topology" %}<span class="caret"></span></a>
<ul class="dropdown-menu"> <ul class="dropdown-menu">
<li><a href="{% url "topologie:index" %}"><i class="fa fa-microchip"></i> Switchs</a></li> <li><a href="{% url "topologie:index" %}"><i class="fa fa-microchip"></i> {% trans "Switches" %}</a></li>
<li><a href="{% url "topologie:index-ap" %}"><i class="fa fa-wifi"></i> Bornes WiFi</a></li> <li><a href="{% url "topologie:index-ap" %}"><i class="fa fa-wifi"></i> {% trans "Wi-Fi access points" %}</a></li>
<li><a href="{% url "topologie:index-room" %}"><i class="fa fa-home"></i> Chambres et locaux</a></li> <li><a href="{% url "topologie:index-room" %}"><i class="fa fa-home"></i> {% trans "Rooms" %}</a></li>
</ul> </ul>
</li> </li>
{% acl_end %} {% acl_end %}
{% can_view_app logs %} {% can_view_app logs %}
<li><a href="{% url "logs:index" %}"><i class="fa fa-chart-area"></i> Statistiques</a></li> <li><a href="{% url "logs:index" %}"><i class="fa fa-chart-area"></i> {% trans "Statistics" %}</a></li>
{% acl_end %} {% acl_end %}
</ul> </ul>
<ul class="nav navbar-nav navbar-right"> <ul class="nav navbar-nav navbar-right">
{% can_view_app preferences %} {% can_view_app preferences %}
<li> <li>
<a href="{% url 'preferences:display-options' %}"> <a href="{% url 'preferences:display-options' %}">
<i class="fa fa-cogs"></i> Preferences <i class="fa fa-cogs"></i> {% trans "Preferences" %}
</a> </a>
</li> </li>
{% acl_end %} {% acl_end %}
@ -125,14 +131,14 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% if var_sa %} {% if var_sa %}
<li> <li>
<a href="{% url 'users:new-user' %}"> <a href="{% url 'users:new-user' %}">
<i class="fa fa-user-plus"></i> Créer un compte <i class="fa fa-user-plus"></i> {% trans "Sign in" %}
</a> </a>
</li> </li>
{% endif %} {% endif %}
<li> <li>
<a id="toggle_login" href="{% url 'login' %}"> <a id="toggle_login" href="{% url 'login' %}">
<i class="fa fa-sign-in-alt"></i> Login <i class="fa fa-sign-in-alt"></i> {% trans "Log in" %}
</a> </a>
</li> </li>
{% else %} {% else %}
<li> <li>
@ -179,30 +185,30 @@ with this program; if not, write to the Free Software Foundation, Inc.,
</div> </div>
<table class="table"> <table class="table">
<tr> <tr>
<th scope="row">Pseudo</th> <th scope="row">{% trans "Username" %}</th>
<td class="text-right">{{ request_user.pseudo }}</td> <td class="text-right">{{ request_user.pseudo }}</td>
</tr> </tr>
<tr> <tr>
<th scope="row">Chambre</th> <th scope="row">{% trans "Room" %}</th>
<td class="text-right">{{ request_user.room }}</td> <td class="text-right">{{ request_user.room }}</td>
</tr> </tr>
<tr> <tr>
<th scope="row">Connexion</th> <th scope="row">{% trans "Connexion" %}</th>
<td class="text-right"> <td class="text-right">
{% if request_user.has_access %} {% if request_user.has_access %}
<i class="text-success">jusqu'au {{ request.user.end_access|date:"d b Y" }}</i> <i class="text-success">{% blocktrans with request.user.end_access|date:"d b Y" as date %}Until {{ date }}{% endblocktrans %}</i>
{% else %} {% else %}
<i class="text-danger">Désactivée</i> <i class="text-danger">{% trans "Deactivated" %}</i>
{% endif %} {% endif %}
</td> </td>
</tr> </tr>
<tr> <tr>
<th scope="row">Adhésion</th> <th scope="row">{% trans "Membership" %}</th>
<td class="text-right"> <td class="text-right">
{% if request_user.is_adherent %} {% if request_user.is_adherent %}
<i class="text-success">jusqu'au {{ request_user.end_adhesion|date:"d b Y" }}</i> <i class="text-success">{% blocktrans with request_user.end_adhesion|date:"d b Y" as date %}Until {{ date }}{% endblocktrans %}</i>
{% else %} {% else %}
<i class="text-danger">Non adhérent</i> <i class="text-danger">{% trans "Not a member" %}</i>
{% endif %} {% endif %}
</td> </td>
</tr> </tr>
@ -210,17 +216,17 @@ with this program; if not, write to the Free Software Foundation, Inc.,
<div class="list-group"> <div class="list-group">
<a class="list-group-item list-group-item-info" role="button"href="{% url "users:mon-profil" %}"> <a class="list-group-item list-group-item-info" role="button"href="{% url "users:mon-profil" %}">
<i class="fa fa-user-circle"></i> <i class="fa fa-user-circle"></i>
Voir mon profil {% trans "See my profile" %}
</a> </a>
</div> </div>
{% else %} {% else %}
<p>Vous n'êtes pas authentifié</p> <p>{% trans "You are not logged in" %}</p>
{% endif %} {% endif %}
</div> </div>
{% if request_user.is_authenticated %} {% if request_user.is_authenticated %}
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h4>{{ interfaces|length }} machines actives</h4> <h4>{% blocktrans count interfaces|length as nb %}{{ nb }} machine active{% plural %}{{ nb }} machines active{% endblocktrans %}</h4>
</div> </div>
<ul class="list-group"> <ul class="list-group">
{% for interface in interfaces|slice:":5" %} {% for interface in interfaces|slice:":5" %}
@ -229,7 +235,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% if interfaces|length > 5 %} {% if interfaces|length > 5 %}
<a class="list-group-item list-group-item-info" role="button" href="{% url "users:mon-profil" %}"> <a class="list-group-item list-group-item-info" role="button" href="{% url "users:mon-profil" %}">
<i class="fa fa-plus"></i> <i class="fa fa-plus"></i>
Voir mes machines {% trans "See my machines" %}
</a> </a>
{% endif %} {% endif %}
</ul> </ul>

View file

@ -21,7 +21,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: 2.5\n" "Project-Id-Version: 2.5\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-03-31 14:05+0000\n" "POT-Creation-Date: 2018-06-23 18:44+0200\n"
"PO-Revision-Date: 2018-03-31 16:09+0002\n" "PO-Revision-Date: 2018-03-31 16:09+0002\n"
"Last-Translator: Maël Kervella <dev@maelkervella.eu>\n" "Last-Translator: Maël Kervella <dev@maelkervella.eu>\n"
"Language-Team: \n" "Language-Team: \n"
@ -30,6 +30,145 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
#: base.html:121 #: templates/base.html:59
msgid "Home"
msgstr "Accueil"
#: templates/base.html:83
msgid "My profile"
msgstr "Mon profil"
#: templates/base.html:84
msgid "Log out"
msgstr "Se déconnecter"
#: templates/base.html:90
msgid "Members"
msgstr "Adhérents"
#: templates/base.html:93
msgid "Manage members"
msgstr "Gérer les adhérents"
#: templates/base.html:94
msgid "Manage clubs"
msgstr "Gérer les clubs"
#: templates/base.html:97
msgid "Manage machines"
msgstr "Gérer les machines"
#: templates/base.html:100
msgid "Manage cotisations"
msgstr "Gérer les cotisations"
#: templates/base.html:107
msgid "Topology"
msgstr "Topologie"
#: templates/base.html:109
msgid "Switches"
msgstr "Commutateurs"
#: templates/base.html:110
msgid "Wi-Fi access points"
msgstr "Bornes Wi-Fi"
#: templates/base.html:111
msgid "Rooms"
msgstr "Chambres & locaux"
#: templates/base.html:116
msgid "Statistics"
msgstr "Statistiques"
#: templates/base.html:123
msgid "Preferences"
msgstr "Préférences"
#: templates/base.html:128
msgid "About" msgid "About"
msgstr "A propos" msgstr "A propos"
#: templates/base.html:134
msgid "Sign in"
msgstr "Créer un compte"
#: templates/base.html:140
msgid "Log in"
msgstr "Se connecter"
#: templates/base.html:188
msgid "Username"
msgstr "Pseudo"
#: templates/base.html:192
msgid "Room"
msgstr "Chambre"
#: templates/base.html:196
msgid "Connexion"
msgstr "Connexion"
#: templates/base.html:199 templates/base.html:209
#, python-format
msgid "Until %(date)s"
msgstr "Jusqu'à %(date)s"
#: templates/base.html:201
msgid "Deactivated"
msgstr "Désactivée"
#: templates/base.html:206
msgid "Membership"
msgstr "Adhésion"
#: templates/base.html:211
msgid "Not a member"
msgstr "Non adhérent"
#: templates/base.html:219
msgid "See my profile"
msgstr "Voir mon profil"
#: templates/base.html:223
msgid "You are not logged in"
msgstr "Vous n'êtes pas connecté"
#: templates/base.html:229
#, python-format
msgid "%(nb)s machine active"
msgstr "%(nb)s machine actives"
#: templates/base.html:229
#, python-format
msgid "%(nb)s machines active"
msgstr "%(nb)s machines actives"
#: templates/base.html:238
msgid "See my machines"
msgstr "Voir mes machines"
#: templates/buttons/setlang.html:34
msgid "Translation in development"
msgstr "Traduction en développement"
#: users/widgets.py:35
msgid "Close"
msgstr "Fermer"
#: users/widgets.py:36
msgid "Today"
msgstr "Aujourd'hui"
#: users/widgets.py:44
msgid "Next"
msgstr "Suivant"
#: users/widgets.py:45
msgid "Previous"
msgstr "Précédent"
#: users/widgets.py:46
msgid "Wk"
msgstr "Sem"

View file

@ -1005,11 +1005,10 @@ class Club(User):
def user_post_save(**kwargs): def user_post_save(**kwargs):
""" Synchronisation post_save : envoie le mail de bienvenue si creation """ Synchronisation post_save : envoie le mail de bienvenue si creation
Synchronise le ldap""" Synchronise le ldap"""
# is_created = kwargs['created'] is_created = kwargs['created']
user = kwargs['instance'] user = kwargs['instance']
# TODO : remove if unnecessary if is_created:
# if is_created: user.notif_inscription()
# user.notif_inscription()
user.ldap_sync( user.ldap_sync(
base=True, base=True,
access_refresh=True, access_refresh=True,