old_contents: # -*- coding: utf-8 -*-
  # vim: set ts=4
  from django.db import models
  
  from benevole import Benevole
  from DPS import Dimensionnement
  
  from dulsine_commons import TEAM_TYPES, DIPLOME_SECOURS
  
  
  class Team(models.Model):
      class Meta:
          app_label = 'DUlSine'
  
      dimensionnement = models.ForeignKey(Dimensionnement)
      team_type = models.IntegerField(choices = TEAM_TYPES)
      taille = models.IntegerField()
  
      def __unicode__(self):
          return u"%s (%s)" %(self.dimensionnement, TEAM_TYPES[self.team_type][1])
  
  
  
  class Souhait(models.Model):
      class Meta:
          app_label = 'DUlSine'
  
      benevole = models.ForeignKey(Benevole)
      dimensionnement = models.ForeignKey(Dimensionnement)
      fonction = models.IntegerField(choices = DIPLOME_SECOURS)
      date = models.DateTimeField(auto_now_add = True)
  
      def __unicode__(self):
          return u"%s => %s : %s" %(self.dimensionnement,  self.fonction, self.benevole)
  
  
  
  class Inscription(models.Model):
      class Meta:
          app_label = 'DUlSine'
  
      benevole = models.ForeignKey(Benevole)
      team = models.ForeignKey(Team)
      fonction = models.IntegerField(choices = DIPLOME_SECOURS)
  
      def __unicode__(self):
          return u"%s => %s : %s" %(self.team, self.fonction, self.benevole)
  
  
new_contents: # -*- coding: utf-8 -*-
  # vim: set ts=4
  from django.db import models
  
  from benevole import Benevole
  from DPS import Dimensionnement
  
  from dulsine_commons import TEAM_TYPES, DIPLOME_SECOURS
  
  
  class Team(models.Model):
      class Meta:
          app_label = 'DUlSine'
  
      dimensionnement = models.ForeignKey(Dimensionnement)
      team_type = models.IntegerField(choices = TEAM_TYPES)
      taille = models.IntegerField()
  
      def __unicode__(self):
          return u"%s (%s)" %(self.dimensionnement, TEAM_TYPES[self.team_type][1])
  
  
  
  class Souhait(models.Model):
      class Meta:
          app_label = 'DUlSine'
  
      benevole = models.ForeignKey(Benevole)
      dimensionnement = models.ForeignKey(Dimensionnement)
      fonction = models.IntegerField(choices = DIPLOME_SECOURS)
      date = models.DateTimeField(auto_now_add = True)
  
      def __unicode__(self):
          return u"%s => %s : %s" %(self.dimensionnement,  DIPLOME_SECOURS[self.fonction][1], self.benevole)
  
  
  
  class Inscription(models.Model):
      class Meta:
          app_label = 'DUlSine'
  
      benevole = models.ForeignKey(Benevole)
      team = models.ForeignKey(Team)
      fonction = models.IntegerField(choices = DIPLOME_SECOURS)
  
      def __unicode__(self):
          return u"%s => %s : %s" %(self.team, DIPLOME_SECOURS[self.fonction][1], self.benevole)
  
  
subject: build corerctly the unicode string