Supprimé TinyMCE
[auf_savoirs_en_partage_django.git] / auf_savoirs_en_partage_django / savoirs / models.py
CommitLineData
d15017b2
CR
1from django.db import models
2
3
4class Discipline(models.Model):
5 id = models.IntegerField(primary_key=True, db_column='id_discipline')
6 nom = models.CharField(max_length=765, db_column='nom_discipline')
6ef8ead4
CR
7
8 def __unicode__ (self):
9 return "Discipline: %s" % self.nom
10
d15017b2
CR
11 class Meta:
12 db_table = u'discipline'
13 ordering = ["nom",]
14
15class Actualite(models.Model):
16 id = models.IntegerField(primary_key=True, db_column='id_actualite')
17 titre = models.CharField(max_length=765, db_column='titre_actualite')
18 texte = models.TextField(db_column='texte_actualite')
19 url = models.CharField(max_length=765, db_column='url_actualite')
20 logo = models.CharField(max_length=765, db_column='logo_actualite')
21 date = models.DateField(db_column='date_actualite')
22 visible = models.CharField(max_length=3, db_column='visible_actualite')
23 ancienid = models.IntegerField(db_column='ancienId_actualite') # Field name made lowercase.
6ef8ead4
CR
24
25 def __unicode__ (self):
26 return "Actualite %d: %s" % (self.id, self.titre)
27
d15017b2
CR
28 class Meta:
29 db_table = u'actualite'
30 ordering = ["-date",]
31