<commit_before>from django.contrib.auth.models import User
from django.db import models


class ConferenceOptionGroup(models.Model):
    """Used to manage relationships"""
    name = models.CharField(max_length=255)

    def __unicode__(self):
        return u'%s' % self.name


class ConferenceOption(models.Model):

    name = models.CharField(max_length=255)
    price = models.DecimalField(max_digits=12, decimal_places=2)
    groups = models.ManyToManyField(
            ConferenceOptionGroup, related_name='members',
            help_text='Groups this option belongs to.')
    requirements = models.ManyToManyField(
            ConferenceOptionGroup, related_name='enables',
            help_text='Option groups that this relies on',
            blank=True)

    def __unicode__(self):
        return u'%s (%.2f)' % (self.name, self.price)


class RegisteredAttendee(models.Model):

    name = models.CharField(max_length=255)
    email = models.CharField(max_length=255)
    items = models.ManyToManyField(
            ConferenceOption, related_name='attendees')
    registered_by = models.ForeignKey(
            User, related_name='registerations')<commit_msg>Reorganise model structure<commit_after>from django.contrib.auth.models import User
from django.db import models


class ConferenceOptionGroup(models.Model):
    """Used to manage relationships"""
    name = models.CharField(max_length=255)

    def __unicode__(self):
        return u'%s' % self.name


class ConferenceOption(models.Model):

    name = models.CharField(max_length=255)
    price = models.DecimalField(max_digits=12, decimal_places=2)
    groups = models.ManyToManyField(
            ConferenceOptionGroup, related_name='members',
            help_text='Groups this option belongs to.')
    requirements = models.ManyToManyField(
            ConferenceOptionGroup, related_name='enables',
            help_text='Option groups that this relies on',
            blank=True)

    def __unicode__(self):
        return u'%s (%.2f)' % (self.name, self.price)


class RegisteredAttendee(models.Model):

    name = models.CharField(max_length=255)
    email = models.CharField(max_length=255)
    items = models.ManyToManyField(
            ConferenceOption, related_name='attendees')


class Registration(models.Model):
    """Manages a unified registration of several attendees"""

    attendees = models.ManyToManyField(
            RegisteredAttendee, related_name='attendees')
    registered_by = models.ForeignKey(
            User, related_name='registeration')
{'fraction_non_alphanumeric': 0.1005104043973302, 'fraction_numerical': 0.012563800549666274, 'mean_word_length': 3.5663082437275984, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6519932', 'n_tokens_mistral': 749, 'n_tokens_neox': 710, 'n_words': 152}