--- a/src/hdalab/forms.py Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/forms.py Tue Mar 10 18:41:29 2015 +0100
@@ -6,8 +6,10 @@
'''
from django import forms
+
from hdalab.models import HdalabRenkan
+
class HdalabRenkanStateForm(forms.ModelForm):
class Meta:
model = HdalabRenkan
@@ -20,3 +22,4 @@
class Meta:
model = HdalabRenkan
fields = ['favorite']
+
Binary file src/hdalab/locale/en/LC_MESSAGES/django.mo has changed
--- a/src/hdalab/locale/en/LC_MESSAGES/django.po Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/locale/en/LC_MESSAGES/django.po Tue Mar 10 18:41:29 2015 +0100
@@ -215,6 +215,10 @@
"Web.<br><br>\n"
"\t\t\t\t\t\t\tÀ partir de l’onglet \"recherche\", cliquez sur le logo "
msgstr ""
+"This tool allows you to represent, arrange, and organise groups of "
+"resources of the portal \"Histoire des Art\" with other websites.<br><br>\n"
+"\t\t\t\t\t\t\tFrom the \"search\" tab, click on the icon "
+
#: templates/help_popup.html:13
msgid ""
@@ -222,6 +226,10 @@
"\t\t\t\t\t\t\tVous pouvez déplacer chaque élément en cliquant dessus et en "
"déplaçant votre curseur."
msgstr ""
+" to create your RENKAN.<br><br>\n"
+"\t\t\t\t\t\t\tYou can move each element by clicking on it and "
+"moving your cursor."
+
#: templates/help_popup.html:18
msgid "Légende"
@@ -245,14 +253,16 @@
"éditer, supprimer, agrandir, rétrécir, modifier en utilisant le menu "
"circulaire comme ci-dessous."
msgstr ""
+"By clicking on each node or link you can move, edit, delete, enlarge, shrink, "
+"or modify them using the circular menu as you can see below."
#: templates/help_popup.html:30
msgid "Aide : Organiser, Ajouter !"
-msgstr ""
+msgstr "Organise, Add!"
#: templates/help_popup.html:32
msgid "1. Organiser"
-msgstr ""
+msgstr "1. Organise"
#: templates/help_popup.html:33
msgid ""
@@ -263,16 +273,24 @@
"n’est plus disponible si le RENKAN a été modifié.\n"
"\t\t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\tBefore any modification you can change the arrangement "
+"of your RENKAN: column, line or circle.<br><br>\n"
+"\t\t\t\t\t\tThe graph is laid out as a circle by default. the layout change "
+"is no longer available as soon as the RENKAN has been modified.\n"
+"\t\t\t\t\t"
#: templates/help_popup.html:39
msgid "2. Ajouter"
-msgstr ""
+msgstr "2. Add"
#: templates/help_popup.html:40
msgid ""
"Vous pouvez ajouter des ressources en faisant \"Glisser – déposer\" à partir "
"de n’importe quelle fenêtre de navigation web."
msgstr ""
+"You'll be able to add resources dragging "
+"and dropping any elements from any web page."
#: templates/help_popup.html:43
msgid ""
@@ -283,6 +301,11 @@
"\t\t \t\t\t\t\tRelâchez sur le graphe, le lien est ajouté.\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tMove this icon in your bookmark toolbar. Drag "
+"elements from a website towrds the RENKAN tab until your graph appears<br>\n"
+"\t\t \t\t\t\t\tRelease on the graph, the link has been added.\n"
+"\t\t \t\t\t\t"
#: templates/help_popup.html:52
msgid ""
@@ -292,6 +315,11 @@
"ressources supplémentaires en lien avec votre recherche.\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tThe icon opens a search panel allowing the search of resources from "
+"the HDA website or Wikipedia. Also it allows to find additionnal resources related to your search.\n"
+"\t\t \t\t\t\t"
+
#: templates/help_popup.html:57
msgid ""
@@ -300,21 +328,25 @@
"graphe.\n"
" \t\t\t\t\t\t"
msgstr ""
+"\n"
+"\t\t\t\t\t\t\tDrag and drop the chosen resource, it is added to the graph.\n"
+" \t\t\t\t\t\t"
+
#: templates/help_popup.html:61
msgid ""
"En cliquant sur l’icone à gauche vous pouvez ouvrir le panel de recherche "
"pour retrouver des ressources du site HDA ou Wikipédia."
msgstr "Clicking the icon on the left will show the search panel to find resources "
-"onthe HDA website or Wikipedia."
+"on the HDA website or Wikipedia."
#: templates/help_popup.html:65
msgid "Aide : Editer, Enregistrer, Gérer !"
-msgstr ""
+msgstr "Help: Edit, Save, Manage!"
#: templates/help_popup.html:67
msgid "3. Éditer"
-msgstr ""
+msgstr "3. Edit"
#: templates/help_popup.html:69
msgid ""
@@ -325,10 +357,15 @@
"précédemment.\n"
"\t \t\t\t"
msgstr ""
+"\n"
+"\t \t\t\t\tYou can edit each resource, tag, link: you can personalize the title, "
+"description, size, color, image (URL) and form of these element with the circular menu.\n"
+"\t \t\t\t"
+
#: templates/help_popup.html:74
msgid "4. Enregistrer"
-msgstr ""
+msgstr "4. Save"
#: templates/help_popup.html:75
msgid ""
@@ -339,10 +376,16 @@
"\t\t \t\t\t\tSi elle est verte : c’est OK.<br>\n"
"\t\t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\tPlease remember to save your RENKAN !<br>\n"
+"\t\t \t\t\t\tIf the disk is red, your changes are not yet saved.<br>\n"
+"\t\t \t\t\t\tIt is ok if the disk is green.<br>\n"
+"\t\t\t\t\t"
+
#: templates/help_popup.html:82
msgid "5. Gérer mes RENKAN"
-msgstr ""
+msgstr "5. Manage my RENKAN"
#: templates/help_popup.html:84
msgid ""
@@ -350,6 +393,10 @@
"\t\t \t\t\t\t\tVous pouvez publier votre RENKAN : cliquez sur l’icône\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tYou can pusblish your RENKAN : click on the following icon\n"
+"\t\t \t\t\t\t"
+
#: templates/help_popup.html:91
msgid ""
@@ -357,26 +404,30 @@
"\t\t \t\t\t\t\tPour modifier un RENKAN enregistré, cliquez sur\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tTo modify a saved RENKAN, clik on\n"
+"\t\t \t\t\t\t"
+
#: templates/help_popup.html:98
msgid "Vous pouvez aussi :"
-msgstr ""
+msgstr "You can also:"
#: templates/help_popup.html:99
msgid "voir un RENKAN (lecture seule)"
-msgstr ""
+msgstr "Display a RENKAN (read-only)"
#: templates/help_popup.html:100
msgid "copier un RENKAN"
-msgstr ""
+msgstr "copy a RENKAN"
#: templates/help_popup.html:101
msgid "supprimer un RENKAN"
-msgstr ""
+msgstr "delete a RENKAN"
#: templates/help_popup.html:102
msgid "dépublier un RENKAN"
-msgstr ""
+msgstr "unpublish a RENKAN"
#: templates/index.html:47
msgid ""
@@ -635,7 +686,7 @@
#: templates/renkan_edit.html:198
msgid "(Indisponible si modification du RENKAN)"
-msgstr "(Not allowed if renkan has been modified)"
+msgstr "(Not allowed if RENKAN has been modified)"
#: templates/renkan_edit.html:201
#: templates/renkan_edit.html.py:205
@@ -829,7 +880,7 @@
#: templates/registration/password_change_form.html:26
msgid "Nouveau mot de passe (Verification)"
-msgstr "New password (vérification)"
+msgstr "New password (verification)"
#: templates/registration/password_change_form.html:30
#: templates/registration/password_reset_form.html:27
@@ -878,7 +929,7 @@
#: templates/registration/password_reset_form.html:23
msgid "Email du compte:"
-msgstr "Accoun email:"
+msgstr "Account email:"
#: templates/registration/registration_complete.html:14
msgid "You are now registered. Activation email sent."
Binary file src/hdalab/locale/fr/LC_MESSAGES/django.mo has changed
--- a/src/hdalab/locale/fr/LC_MESSAGES/django.po Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/locale/fr/LC_MESSAGES/django.po Tue Mar 10 18:41:29 2015 +0100
@@ -66,7 +66,7 @@
#: templates/base.html:38
msgid "Accueil"
-msgstr ""
+msgstr "Accueil"
#: templates/base.html:39
#: templates/base.html.py:92
@@ -77,12 +77,12 @@
#: templates/base.html:40
#: templates/base.html.py:93
msgid "Domaines Artistiques"
-msgstr ""
+msgstr "Domaines Artistiques"
#: templates/base.html:41
#: templates/base.html.py:94
msgid "Thésaurus"
-msgstr ""
+msgstr "Thésaurus"
#: templates/base.html:50
#: templates/ajax_identification/ajax_login_ok.html:4
@@ -108,7 +108,7 @@
#: templates/envelope/contact.html:6
#: templates/envelope/contact.html.py:16
msgid "Contact"
-msgstr ""
+msgstr "Contact"
#: templates/base.html:91
msgid "Rubriques"
@@ -133,11 +133,11 @@
#: templates/categories.html:61
msgid "Voir plus ou moins de catégories"
-msgstr ""
+msgstr "Voir plus ou moins de catégories"
#: templates/categories.html:65
msgid "Entrez une catégorie"
-msgstr ""
+msgstr "Entrez une catégorie"
#: templates/credits.html:5
msgid "Credits"
@@ -150,7 +150,7 @@
#: templates/facettes.html:61
msgid "Ce logo vous permet de créer un Renkan"
-msgstr ""
+msgstr "Ce logo vous permet de créer un Renkan"
#: templates/facettes.html:69
msgid "Filtres :"
@@ -194,7 +194,7 @@
#: templates/facettes.html:137
msgid "Domaines artistiques"
-msgstr ""
+msgstr "Domaines artistiques"
#: templates/facettes.html:143
msgid "Resultats de recherche"
@@ -215,6 +215,10 @@
"Web.<br><br>\n"
"\t\t\t\t\t\t\tÀ partir de l’onglet \"recherche\", cliquez sur le logo "
msgstr ""
+"Cet outil vous permet de représenter, spatialiser et organiser des "
+"collections de ressources du portail histoire des arts avec d’autres sites "
+"Web.<br><br>\n"
+"\t\t\t\t\t\t\tÀ partir de l’onglet \"recherche\", cliquez sur le logo "
#: templates/help_popup.html:13
msgid ""
@@ -222,6 +226,10 @@
"\t\t\t\t\t\t\tVous pouvez déplacer chaque élément en cliquant dessus et en "
"déplaçant votre curseur."
msgstr ""
+" pour créer votre RENKAN.<br><br>\n"
+"\t\t\t\t\t\t\tVous pouvez déplacer chaque élément en cliquant dessus et en "
+"déplaçant votre curseur."
+
#: templates/help_popup.html:18
msgid "Légende"
@@ -245,14 +253,18 @@
"éditer, supprimer, agrandir, rétrécir, modifier en utilisant le menu "
"circulaire comme ci-dessous."
msgstr ""
+"En cliquant sur chaque ressource, tag ou lien, vous pouvez les déplacer, "
+"éditer, supprimer, agrandir, rétrécir, modifier en utilisant le menu "
+"circulaire comme ci-dessous."
+
#: templates/help_popup.html:30
msgid "Aide : Organiser, Ajouter !"
-msgstr ""
+msgstr "Aide : Organiser, Ajouter !"
#: templates/help_popup.html:32
msgid "1. Organiser"
-msgstr ""
+msgstr "1. Organiser"
#: templates/help_popup.html:33
msgid ""
@@ -263,16 +275,26 @@
"n’est plus disponible si le RENKAN a été modifié.\n"
"\t\t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\tAvant toute modification, vous pouvez changer la disposition "
+"de votre RENKAN : en colonne, en ligne ou en cercle.<br><br>\n"
+"\t\t\t\t\t\tLe graphe est en cercle par défaut. Le changement de disposition "
+"n’est plus disponible si le RENKAN a été modifié.\n"
+"\t\t\t\t\t"
+
#: templates/help_popup.html:39
msgid "2. Ajouter"
-msgstr ""
+msgstr "2. Ajouter"
#: templates/help_popup.html:40
msgid ""
"Vous pouvez ajouter des ressources en faisant \"Glisser – déposer\" à partir "
"de n’importe quelle fenêtre de navigation web."
msgstr ""
+"Vous pouvez ajouter des ressources en faisant \"Glisser – déposer\" à partir "
+"de n’importe quelle fenêtre de navigation web."
+
#: templates/help_popup.html:43
msgid ""
@@ -283,6 +305,12 @@
"\t\t \t\t\t\t\tRelâchez sur le graphe, le lien est ajouté.\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tDéplacez cette icône dans votre barre de signets. Glisser "
+"des éléments d'un site web, vers l’onglet de votre RENKAN jusqu’à ce que "
+"votre graphe apparaisse.<br>\n"
+"\t\t \t\t\t\t\tRelâchez sur le graphe, le lien est ajouté.\n"
+"\t\t \t\t\t\t"
#: templates/help_popup.html:52
msgid ""
@@ -292,6 +320,11 @@
"ressources supplémentaires en lien avec votre recherche.\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tL'icone ouvre un panel de recherche permettant de "
+"rechercher des ressources du site HDA ou Wikipédia, ainsi que retrouver des "
+"ressources supplémentaires en lien avec votre recherche.\n"
+"\t\t \t\t\t\t"
#: templates/help_popup.html:57
msgid ""
@@ -300,20 +333,26 @@
"graphe.\n"
" \t\t\t\t\t\t"
msgstr ""
+"\n"
+"\t\t\t\t\t\t\tGlissez – déposez la ressource choisie, elle est ajoutée au "
+"graphe.\n"
+" \t\t\t\t\t\t"
#: templates/help_popup.html:61
msgid ""
"En cliquant sur l’icone à gauche vous pouvez ouvrir le panel de recherche "
"pour retrouver des ressources du site HDA ou Wikipédia."
msgstr ""
+"En cliquant sur l’icone à gauche vous pouvez ouvrir le panel de recherche "
+"pour retrouver des ressources du site HDA ou Wikipédia."
#: templates/help_popup.html:65
msgid "Aide : Editer, Enregistrer, Gérer !"
-msgstr ""
+msgstr "Aide : Editer, Enregistrer, Gérer !"
#: templates/help_popup.html:67
msgid "3. Éditer"
-msgstr ""
+msgstr "3. Éditer"
#: templates/help_popup.html:69
msgid ""
@@ -324,6 +363,12 @@
"précédemment.\n"
"\t \t\t\t"
msgstr ""
+"\n"
+"\t \t\t\t\tChaque ressource, tag, lien, peut être édité : le titre, "
+"la description, la taille, la couleur, l’image (URL) et la forme de chacun "
+"de ces éléments peuvent être personnalisés, grâce au menu circulaire décrit "
+"précédemment.\n"
+"\t \t\t\t"
#: templates/help_popup.html:74
msgid "4. Enregistrer"
@@ -338,10 +383,16 @@
"\t\t \t\t\t\tSi elle est verte : c’est OK.<br>\n"
"\t\t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\tPensez à enregistrer votre RENKAN !<br>\n"
+"\t\t \t\t\t\tSi la disquette est rouge : vos modifications n’ont pas encore "
+"été enregistrées.<br>\n"
+"\t\t \t\t\t\tSi elle est verte : c’est OK.<br>\n"
+"\t\t\t\t\t"
#: templates/help_popup.html:82
msgid "5. Gérer mes RENKAN"
-msgstr ""
+msgstr "5. Gérer mes RENKAN"
#: templates/help_popup.html:84
msgid ""
@@ -349,6 +400,9 @@
"\t\t \t\t\t\t\tVous pouvez publier votre RENKAN : cliquez sur l’icône\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tVous pouvez publier votre RENKAN : cliquez sur l’icône\n"
+"\t\t \t\t\t\t"
#: templates/help_popup.html:91
msgid ""
@@ -356,38 +410,45 @@
"\t\t \t\t\t\t\tPour modifier un RENKAN enregistré, cliquez sur\n"
"\t\t \t\t\t\t"
msgstr ""
+"\n"
+"\t\t \t\t\t\t\tPour modifier un RENKAN enregistré, cliquez sur\n"
+"\t\t \t\t\t\t"
#: templates/help_popup.html:98
msgid "Vous pouvez aussi :"
-msgstr ""
+msgstr "Vous pouvez aussi :"
#: templates/help_popup.html:99
msgid "voir un RENKAN (lecture seule)"
-msgstr ""
+msgstr "voir un RENKAN (lecture seule)"
#: templates/help_popup.html:100
msgid "copier un RENKAN"
-msgstr ""
+msgstr "copier un RENKAN"
#: templates/help_popup.html:101
msgid "supprimer un RENKAN"
-msgstr ""
+msgstr "supprimer un RENKAN"
#: templates/help_popup.html:102
msgid "dépublier un RENKAN"
-msgstr ""
+msgstr "dépublier un RENKAN"
#: templates/index.html:47
msgid ""
"Intuitive, la recherche d’Histoire des arts ‘Lab propose plusieurs points "
"d’entrée : pays, périodes historiques, disciplines artistiques et mots-clés."
msgstr ""
+"Intuitive, la recherche d’Histoire des arts ‘Lab propose plusieurs points "
+"d’entrée : pays, périodes historiques, disciplines artistiques et mots-clés."
#: templates/index.html:48
msgid ""
"Ces différentes facettes se mettent à jour au fur et à mesure de vos "
"recherches."
msgstr ""
+"Ces différentes facettes se mettent à jour au fur et à mesure de vos "
+"recherches."
#: templates/index.html:59
msgid "Navigation <strong>à travers les Arts</strong> "
@@ -398,6 +459,8 @@
"Explorez 9 grands domaines artistiques à travers des arborescences enrichies "
"de ressources du portail Histoire des Arts."
msgstr ""
+"Explorez 9 grands domaines artistiques à travers des arborescences enrichies "
+"de ressources du portail Histoire des Arts."
#: templates/index.html:76
#: templates/renkan_list.html:35
@@ -405,6 +468,8 @@
"Construisez votre carte de connaissances à partir des ressources Histoires "
"des arts et Wikipedia."
msgstr ""
+"Construisez votre carte de connaissances à partir des ressources Histoires "
+"des arts et Wikipedia."
#: templates/index.html:91
msgid "Bienvenue sur Histoire des arts‘Lab !"
@@ -414,7 +479,8 @@
msgid ""
"Naviguez autrement à travers les 5000 ressources du Portail Histoire des "
"arts :"
-msgstr "Naviguez autrement à travers les 5000 ressources du Portail Histoire des "
+msgstr ""
+"Naviguez autrement à travers les 5000 ressources du Portail Histoire des "
"arts :"
#: templates/index.html:95
@@ -423,7 +489,7 @@
#: templates/index.html:96
msgid "Explorez les arts de ressource en ressource"
-msgstr ""
+msgstr "Explorez les arts de ressource en ressource"
#: templates/index.html:97
msgid "Construisez vos cartes de connaissances"
@@ -435,11 +501,11 @@
#: templates/profile_home.html:7
msgid "Compte utilisateur"
-msgstr ""
+msgstr "Compte utilisateur"
#: templates/profile_home.html:30
msgid "Mon compte"
-msgstr ""
+msgstr "Mon compte"
#: templates/profile_home.html:34
msgid "Adminsitration du Site"
--- a/src/hdalab/static/hdalab/css/contact.css Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/static/hdalab/css/contact.css Tue Mar 10 18:41:29 2015 +0100
@@ -4,85 +4,3 @@
margin-bottom: 20px;
}
-#contact-div {
- width: 500px;
- padding: 10px;
- background-color: rgb(230, 230, 230);
- border-radius: 2px;
- margin: auto;
-}
-
-#contact-div p {
- color: #4f5451;
- font-size: 14px;
- font-size: 1.4rem;
- margin: 10px 30px;
- clear: right;
-}
-#contact-div label{
- font-size: 14px;
- font-size: 1.4rem;
- line-height: 3.4;
- display: block;
-}
-#contact-div .error input, #contact-div .error select {
- border: 2px red solid;
-}
-
-#contact-div input[type="text"],
-#contact-div input[type="email"],
-#contact-div textarea {
- border:0;
- box-sizing: border-box;
- color: #4f5451;
- font-size: 12px;
- font-size: 1.2rem;
- font-weight: 300;
- width: 100%;
- border-radius: 2px;
-}
-
-#contact-div input[type="text"],
-#contact-div input[type="email"] {
- height: 50px;
- padding: 0 20px;
-}
-
-#contact-div textarea {
- height: 200px;
- padding: 5px 5px;
-}
-
-
-#contact-div input[type="text"]:focus,
-#contact-div input[type="email"]:focus,
-#contact-div textarea:focus {
- background-color: rgba(255, 255, 255, 1);
- border:1px solid #7cb0bd;
-}
-#contact-div input[type="submit"] {
- content: " ";
- height: 30px;
- border: 0;
- color: #fff;
- font-size: 14px;
- font-size: 1.4rem;
- font-weight: 300;
- background-color: #7cb0bd;
- border-radius: 2px;
- transition: background-color 0.3s ease;
- cursor:pointer;
- margin: 10px 0;
-/* float: right; */
-}
-#contact-div input[type="submit"]:hover {
- background-color: #4f5451;
-}
-
-#contact-div .btn-submit {
- text-align: right;
-}
-
-#contact-div fieldset {
- border: none;
-}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/hdalab/static/hdalab/css/forms.css Tue Mar 10 18:41:29 2015 +0100
@@ -0,0 +1,91 @@
+@CHARSET "UTF-8";
+
+.hdalab-form {
+ width: 500px;
+ padding: 10px;
+ background-color: rgb(230, 230, 230);
+ border-radius: 2px;
+ margin: auto;
+}
+
+.hdalab-form h1::before {
+ content: "/ ";
+}
+
+.hdalab-form p {
+ color: #4f5451;
+ font-size: 14px;
+ font-size: 1.4rem;
+ margin: 10px 30px;
+ clear: right;
+}
+.hdalab-form label{
+ font-size: 14px;
+ font-size: 1.4rem;
+ line-height: 3.4;
+ display: block;
+}
+.hdalab-form .error input, .hdalab-form .error select {
+ border: 2px red solid;
+}
+
+.hdalab-form input[type="text"],
+.hdalab-form input[type="email"],
+.hdalab-form input[type="password"],
+.hdalab-form textarea {
+ border:0;
+ box-sizing: border-box;
+ color: #4f5451;
+ font-size: 12px;
+ font-size: 1.2rem;
+ font-weight: 300;
+ width: 100%;
+ border-radius: 2px;
+}
+
+.hdalab-form input[type="text"],
+.hdalab-form input[type="password"],
+.hdalab-form input[type="email"] {
+ height: 50px;
+ padding: 0 20px;
+}
+
+.hdalab-form textarea {
+ height: 200px;
+ padding: 5px 5px;
+}
+
+
+.hdalab-form input[type="text"]:focus,
+.hdalab-form input[type="email"]:focus,
+.hdalab-form input[type="password"]:focus,
+.hdalab-form textarea:focus {
+ background-color: rgba(255, 255, 255, 1);
+ border:1px solid #7cb0bd;
+}
+.hdalab-form input[type="submit"] {
+ content: " ";
+ height: 30px;
+ border: 0;
+ color: #fff;
+ font-size: 14px;
+ font-size: 1.4rem;
+ font-weight: 300;
+ background-color: #7cb0bd;
+ border-radius: 2px;
+ transition: background-color 0.3s ease;
+ cursor:pointer;
+ margin: 10px 0;
+/* float: right; */
+}
+.hdalab-form input[type="submit"]:hover {
+ background-color: #4f5451;
+}
+
+.hdalab-form .btn-submit {
+ text-align: right;
+}
+
+.hdalab-form .btn-previous {
+ margin-right: 10px;
+}
--- a/src/hdalab/static/hdalab/css/login.css Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/static/hdalab/css/login.css Tue Mar 10 18:41:29 2015 +0100
@@ -1,80 +1,3 @@
-.register{
- width: 500px;
- padding: 10px;
- background-color: rgb(230, 230, 230);
- border-radius: 2px;
- margin: auto;
-}
-.register p {
- color: #4f5451;
- font-size: 14px;
- font-size: 1.4rem;
- margin: 10px 30px;
- clear: right;
-}
-.register label{
- font-size: 14px;
- font-size: 1.4rem;
- line-height: 3.4;
-}
-.register .error input, .register .error select {
- border: 2px red solid;
-}
-.register input[type="text"],
-.register input[type="password"],
-.register input[type="email"] {
-/* background-color: rgba(255, 255, 255, 0.90); */
- border:0;
- box-sizing: border-box;
- color: #4f5451;
- font-size: 12px;
- font-size: 1.2rem;
- font-weight: 300;
- height: 50px;
- padding: 0 20px;
- width: 100%;
- border-radius: 2px;
-}
-.register input[type="text"]:focus,
-.register input[type="password"]:focus,
-.register input[type="email"]:focus {
- background-color: rgba(255, 255, 255, 1);
- border:1px solid #7cb0bd;
-}
-.register input[type="submit"] {
- content: " ";
- height: 30px;
- border: 0;
- color: #fff;
- font-size: 14px;
- font-size: 1.4rem;
- font-weight: 300;
- background-color: #7cb0bd;
- border-radius: 2px;
- transition: background-color 0.3s ease;
- cursor:pointer;
- margin: 10px 0;
-/* float: right; */
-}
-.register input[type="submit"]:hover {
- background-color: #4f5451;
-}
-
-.register h1:before{
- content: "/ ";
-}
-
-.register h1{
- margin: 10px 19px;
-}
-
-.register .btn-submit{
- text-align: right;
-}
-
-.btn-previous{
- margin-right:10px;
-}
/* MODAL POPUP */
--- a/src/hdalab/templates/envelope/contact.html Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/templates/envelope/contact.html Tue Mar 10 18:41:29 2015 +0100
@@ -8,20 +8,19 @@
{% block css_import %}
{{block.super}}
<link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/contact.css' %}" />
+ <link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/forms.css' %}" />
{% endblock %}
{% block main_content %}
- <div class="all-title">
- <h1><strong>{% trans "Contact" %}</strong></h1>
- </div>
+ <div id="contact-div" class="hdalab-form">
+ <h1><strong>{% trans "Contact" %}</strong></h1>
<div id="contact-description" class="description">
{% blocktrans %}
<p>Vous souhaitez poser une question sur Histoire des arts' Lab ?</p>
<p>Remplissez le formulaire suivant :</p>
{% endblocktrans %}
- </div>
- <div id="contact-div">
+ </div>
<form action="{% url 'envelope-contact' %}" method="post">
{% csrf_token %}
{% antispam_fields %}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/hdalab/templates/hdabo/user_update_form.html Tue Mar 10 18:41:29 2015 +0100
@@ -0,0 +1,24 @@
+
+{% extends "base.html" %}
+{% load static %}
+{% load i18n %}
+
+{% block title %}{% trans "Profile change" %}{% endblock %}
+
+{% block css_import %}
+{{block.super}}
+ <link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/forms.css' %}" >
+{% endblock %}
+
+{% block main_content %}
+<div class="user-update hdalab-form">
+ <h1>{% trans "Change user profile" %}</h1>
+ <form method="post" action="{% url 'profile_update' %}">
+ {% csrf_token %}
+ {{ form.as_p }}
+ <div class="btn-submit">
+ <p><a class="btn-previous" href="{% url 'profile_home' %}">{% trans "Precedent" %}</a><input type="submit" value="{% trans 'Submit' %}" /></p>
+ </div>
+ </form>
+</div>
+{% endblock %}
\ No newline at end of file
--- a/src/hdalab/templates/profile_home.html Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/templates/profile_home.html Tue Mar 10 18:41:29 2015 +0100
@@ -43,7 +43,8 @@
<div class="sub-content">
<h2>/ {% trans 'Modifier mon profil' %}</h2>
<p>
- <a href="{% url 'auth_password_change' %}">Modification du mot de passe</a>
+ <a href="{% url 'auth_password_change' %}">{% trans 'Modification du mot de passe' %}</a>
+ / <a href="{% url 'profile_update' %}">{% trans 'Modification des informations du compte' %}</a>
</p>
</div>
<div class="sub-content">
--- a/src/hdalab/templates/registration/login.html Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/templates/registration/login.html Tue Mar 10 18:41:29 2015 +0100
@@ -7,12 +7,13 @@
{% block css_import %}
{{block.super}}
<link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/login.css' %}" />
+ <link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/forms.css' %}" />
{% endblock %}
{% block login_actif %}actif{% endblock %}
{% block main_content %}
- <div class="register">
+ <div class="register hdalab-form">
<h1>{% trans "Authentication" %}</h1>
{% if form.errors %}
<p class="error">{% trans "Sorry, that's not a valid username or password." %}</p>
--- a/src/hdalab/templates/registration/registration_form.html Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/templates/registration/registration_form.html Tue Mar 10 18:41:29 2015 +0100
@@ -6,13 +6,14 @@
{% block css_import %}
{{block.super}}
+ <link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/forms.css' %}" />
<link rel="stylesheet" type="text/css" href="{% static 'hdalab/css/login.css' %}" />
{% endblock %}
{% block login_actif %}actif{% endblock %}
{% block main_content %}
-<div class="register">
+<div class="register hdalab-form">
<h1>{% trans "Nouvel Utilisateur" %}</h1>
{% if form.errors %}
<p class="error">{% trans "Oups ! Il y a un problème dans les données du nouvel utilisateur" %}</p>
--- a/src/hdalab/urls.py Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/urls.py Tue Mar 10 18:41:29 2015 +0100
@@ -3,7 +3,8 @@
from django.views.generic import TemplateView
from hdalab.views.profile import ProfileHome, RenkanEdit, HdalabRenkanGetPut,\
RenkanNew, RenkanPublicList, HdalabRenkanCopy, HdalabRenkanDelete,\
- HdalabRenkanModerate, HdalabRenkanFavorite, RenkanFavoriteList
+ HdalabRenkanModerate, HdalabRenkanFavorite, RenkanFavoriteList,\
+ UserProfileUpdate
from django.contrib.auth.decorators import login_required
from django.contrib.admin.views.decorators import staff_member_required
from hdalab.views.editorial import HdalabFolders, HdalabAddOrUpdateFolder,\
@@ -46,6 +47,7 @@
url(r'^renkan/moderate/(?P<rk_id>.+)$', login_required(HdalabRenkanModerate.as_view()), name='renkan_moderate'),
url(r'^renkan/favorite/(?P<rk_id>.+)$', login_required(HdalabRenkanFavorite.as_view()), name='renkan_favorite'),
url(r'^profile/$', login_required(ProfileHome.as_view()), name='profile_home'),
+ url(r'^profile/update/$', login_required(UserProfileUpdate.as_view()), name='profile_update'),
url(r'^renkan/public/$', RenkanPublicList.as_view(), name='renkan_public_list'),
url(r'^renkan/favorite/$', RenkanFavoriteList.as_view(), name='renkan_favorite_list'),
url(r'^ajaxlogin/$', "hdalab.views.profile.ajax_login", name='ajax_login'),
--- a/src/hdalab/views/profile.py Tue Mar 10 16:06:06 2015 +0100
+++ b/src/hdalab/views/profile.py Tue Mar 10 18:41:29 2015 +0100
@@ -15,11 +15,12 @@
import uuid
from django.conf import settings
-from django.contrib.auth import REDIRECT_FIELD_NAME, login as auth_login
+from django.contrib.auth import REDIRECT_FIELD_NAME, login as auth_login, \
+ get_user_model
from django.contrib.auth.forms import AuthenticationForm
from django.contrib.sites.models import get_current_site
from django.core.paginator import Paginator, PageNotAnInteger, EmptyPage
-from django.core.urlresolvers import reverse
+from django.core.urlresolvers import reverse, reverse_lazy
from django.db.models import Q
from django.http import HttpResponse, HttpResponseBadRequest
from django.http import HttpResponseRedirect
@@ -34,6 +35,7 @@
from django.views.decorators.csrf import csrf_exempt, csrf_protect
from django.views.decorators.debug import sensitive_post_parameters
from django.views.generic import TemplateView, View
+from django.views.generic.edit import UpdateView
from hdabo.models import Tag, Datasheet, TaggedSheet, Folder
from hdalab.forms import HdalabRenkanStateForm, HdalabRenkanFavoriteForm
@@ -43,6 +45,8 @@
from hdalab.views.ajax import filter_generic
+User = get_user_model()
+
logger = logging.getLogger(__name__)
@@ -691,6 +695,18 @@
)
+class UserProfileUpdate(UpdateView):
+ model = User
+ fields = ['email']
+ template_name_suffix = '_update_form'
+
+ def get_object(self, queryset=None):
+ return self.request.user
+
+ def get_success_url(self):
+ return reverse('profile_home')
+
+
# Function copied from django.contrib.auth.views to simplify ajax login
@sensitive_post_parameters()
@csrf_protect