fiche d'inscription du chercheur.
class DisciplineForm(forms.ModelForm):
class Meta:
model = Chercheur
- fields = ('discipline', 'theme_recherche', 'mots_cles', 'url_site_web', 'url_blog',)
+ fields = ('discipline', 'theme_recherche', 'mots_cles', 'url_site_web', 'url_blog', 'url_reseau_social')
class PersonneEditForm(forms.ModelForm):
class Meta:
verbose_name='Adresse site Internet')
url_blog = models.URLField(max_length=255, null=True, blank=True,
verbose_name='Blog')
- url_facebook = models.URLField(max_length=255, null=True, blank=True,
- verbose_name='Facebook')
- url_linkedin = models.URLField(max_length=255, null=True, blank=True,
- verbose_name='Linkedin')
+ url_reseau_social = models.URLField(
+ max_length=255, null=True, blank=True, verbose_name='Réseau social',
+ help_text=u"Vous pouvez indiquer ici l'adresse de votre page personnelle dans votre réseau social préféré (e.g. Facebook, LinkedIn, Twitter, Identica, ...)"
+ )
groupes = models.ManyToManyField('Groupe', through='ChercheurGroupe', blank=True, verbose_name = 'Domaines de recherche')
def retrieve(request, id):
"""Fiche du chercheur"""
- #chercheur = Chercheur.objects.get(id=id)
chercheur = get_object_or_404(Chercheur, id=id)
variables = { 'chercheur': chercheur }
return render_to_response ("chercheurs/retrieve.html", \
dd{margin:0.25em 0 0.5em 2.5em;}
sup{font-size: smaller; vertical-align: 0.5em; line-height: 1px;}
+form td { vertical-align: top }
+form th { width: 20em; text-align: left; font-weight: bold }
+form table { width: 100% }
+form input[type=text] { width: 20em }
+form input.date { width: auto }
+form select { width: 80%; overflow: hidden }
+form p { margin-bottom: 2px }
+
.box { padding:0 0 20px 0; }
.lbl {color: #97012c; }
#edit-form tr { border-top: 1px black solid; }
#edit-form tr:first-child { border-top: none; }
-.form td { vertical-align: top; }
-.form th { font-weight: bold; }
-.form td:first-child { width: 150px; text-align: left; }
-.form table { width: 100%; }
-.form input[type=text], .form textarea, .form select { width: 80%; }
-.form textarea { height: 100px; }
-.form p { margin-bottom: 2px; }
-.form tr:first-child { border-top: none; }
-
.odd { background: #ddd; }
#repertoire { border:1px solid #bbb; padding:20px; margin: 10px; width:95% }
.errorlist {color:red}
-select { width:100%; overflow:hidden }
.publications_autre {border:1px solid #CCC; background:#FAFAFA; margin:10px; padding:10px; display:none;}
--- /dev/null
+ALTER TABLE chercheurs_chercheur CHANGE COLUMN url_facebook url_reseau_social varchar(255);
+ALTER TABLE chercheurs_chercheur DROP COLUMN url_linkedin;
<td><a href="{{chercheur.url_blog}}">{{chercheur.url_blog}}</a></td>
</tr>
{% endif %}
- {% if chercheur.url_facebook %}
+ {% if chercheur.url_reseau_social %}
<tr>
- <td class="label">Facebook:</td>
- <td><a href="{{chercheur.url_facebook}}">{{chercheur.url_facebook}}</a></td>
- </tr>
- {% endif %}
- {% if chercheur.url_linkedin %}
- <tr>
- <td class="label">Linkedin:</td>
- <td><a href="{{chercheur.url_linkedin}}">{{chercheur.url_linkedin}}</a></td>
+ <td class="label">Réseau social:</td>
+ <td><a href="{{chercheur.url_reseau_social}}">{{chercheur.url_reseau_social }}</a></td>
</tr>
{% endif %}
</table>