Hello, I have the following Model :
class Summary(models.Model): who = models.ForeignKey(User, unique=True, verbose_name='Personne') job_profile = models.CharField('Profil de poste', maxlength=100) summary = models.TextField('Résumé',) intervention_level = models.ManyToManyField(Interventionlevel, verbose_name='Niveau d\'intervention', filter_interface=models.HORIZONTAL) expert_domain = models.ManyToManyField(Expertdomain, verbose_name='Domaine d\'expertise', filter_interface=models.HORIZONTAL) functionnal_skill = models.ManyToManyField(Funcskill, verbose_name='Compétences fonctionnelles', filter_interface=models.HORIZONTAL) technical_skill = models.ManyToManyField(Techskill, verbose_name='Compétences techniques', filter_interface=models.HORIZONTAL) and for ex I have : class Techskill(models.Model): name = models.CharField('Compétences techniques', maxlength=100, core=True) domain = models.ForeignKey(DomainTechSkill, verbose_name='Domaine de compétences techniques',) In my template, I use : {% regroup item.technical_skill.all by domain as grouped %} <ul> {% for group in grouped %} <li> {{ group.grouper }} : {% for item in group.list %} {{ item.name }}, {% endfor %} </li> {% endfor %} </ul> If I input in the following order (with a domain / name presentation) : - Technology : HTML - Technology : CSS - Webserver : Apache - Webserver : Lighttpd I will have the right order : <ul> <li>Technology : HTML, CSS,</li> <li>Webserver : Apache, Lighttpd</li> </ul> but if I had a new technology, like XML, I will have : <ul> <li>Technology : HTML, CSS,</li> <li>Webserver : Apache, Lighttpd,</li> <li>Technology : XML, </ul> How can I get the correct result which would be : <ul> <li>Technology : HTML, CSS, XML,</li> <li>Webserver : Apache, Lighttpd,</li> </ul> Regards, Nicolas --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---