Browse Source

Reset migrations using django 1.7 migration feature.
Have to replace a lambda function in billing model for a default value which is not compatible with django migration.

Fabs 10 years ago
parent
commit
90f59c2645
43 changed files with 434 additions and 3906 deletions
  1. 0 86
      coin/billing/migrations/0001_001.py
  2. 60 0
      coin/billing/migrations/0001_initial.py
  3. 0 67
      coin/billing/migrations/0002_001.py
  4. 30 0
      coin/billing/migrations/0002_auto_20140919_2158.py
  5. 0 80
      coin/billing/migrations/0003_auto__add_field_invoice_number__chg_field_invoice_date__chg_field_paym.py
  6. 0 80
      coin/billing/migrations/0004_auto__add_field_invoicedetail_offer__del_field_invoice_offer.py
  7. 0 88
      coin/billing/migrations/0005_auto__add_field_invoice_member.py
  8. 0 96
      coin/billing/migrations/0006_auto__del_field_payment_payment_means__add_field_payment_payment_mean.py
  9. 0 91
      coin/billing/migrations/0007_auto__del_field_invoice_amount.py
  10. 0 85
      coin/billing/migrations/0008_auto__chg_field_invoicedetail_tax.py
  11. 0 117
      coin/billing/migrations/0009_auto__add_field_invoicedetail_period_from__add_field_invoicedetail_per.py
  12. 0 105
      coin/billing/migrations/0010_auto__chg_field_invoice_member__del_field_payment_invoce__add_field_pa.py
  13. 0 85
      coin/billing/migrations/0011_auto__chg_field_payment_invoice.py
  14. 0 97
      coin/billing/migrations/0012_auto__add_field_invoicedetail_offersubscription.py
  15. 0 96
      coin/billing/migrations/0013_auto__del_field_invoicedetail_offer.py
  16. 0 94
      coin/billing/migrations/0014_auto__chg_field_invoicedetail_quantity.py
  17. 0 94
      coin/billing/migrations/0015_auto__chg_field_payment_amount.py
  18. 9 9
      coin/billing/models.py
  19. 17 102
      coin/configuration/migrations/0001_initial.py
  20. 28 0
      coin/configuration/migrations/0002_auto_20140919_2158.py
  21. 96 165
      coin/members/migrations/0001_initial.py
  22. 44 95
      coin/offers/migrations/0001_initial.py
  23. 0 75
      coin/offers/migrations/0002_auto__del_field_offer_biling_priod__add_field_offer_billing_priod.py
  24. 0 75
      coin/offers/migrations/0003_auto__del_field_offer_billing_priod__add_field_offer_billing_period.py
  25. 0 65
      coin/offers/migrations/0004_auto__chg_field_offersubscription_commitment.py
  26. 0 121
      coin/offers/migrations/0005_auto__del_service__del_field_offer_service__add_field_offer_type.py
  27. 0 100
      coin/offers/migrations/0006_auto__add_field_offer_backend.py
  28. 0 123
      coin/offers/migrations/0007_auto__del_field_offer_type__del_field_offer_backend__add_field_offer_c.py
  29. 39 96
      coin/resources/migrations/0001_initial.py
  30. 28 0
      coin/resources/migrations/0002_auto_20140919_2158.py
  31. 0 89
      coin/resources/migrations/0002_auto__del_field_ippool_description__add_field_ippool_default_subnetsiz.py
  32. 0 105
      coin/resources/migrations/0003_auto__add_field_ipsubnet_delegate_reverse_dns.py
  33. 42 91
      coin/reverse_dns/migrations/0001_initial.py
  34. 0 106
      coin/reverse_dns/migrations/0002_auto__add_unique_reversednsentry_ip.py
  35. 0 129
      coin/reverse_dns/migrations/0003_auto__add_field_nameserver_owner.py
  36. 0 134
      coin/reverse_dns/migrations/0004_auto__add_field_reversednsentry_ttl.py
  37. 41 115
      coin/vpn/migrations/0001_initial.py
  38. 0 114
      coin/vpn/migrations/0002_auto__add_field_vpnsubscription_comment.py
  39. 0 142
      coin/vpn/migrations/0003_auto__add_testsubscription__chg_field_vpnsubscription_ipv6_endpoint__c.py
  40. 0 118
      coin/vpn/migrations/0004_auto__add_unique_vpnsubscription_login.py
  41. 0 117
      coin/vpn/migrations/0005_auto__del_testsubscription.py
  42. 0 117
      coin/vpn/migrations/0006_auto__chg_field_vpnsubscription_password.py
  43. 0 142
      coin/vpn/migrations/0007_auto__del_vpnsubscription__add_vpnconfiguration.py

+ 0 - 86
coin/billing/migrations/0001_001.py

@@ -1,86 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'Invoice'
-        db.create_table(u'billing_invoice', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('status', self.gf('django.db.models.fields.CharField')(default='open', max_length=50)),
-            ('amount', self.gf('django.db.models.fields.DecimalField')(max_digits=5, decimal_places=2)),
-            ('date', self.gf('django.db.models.fields.DateField')(auto_now_add=True, null=True, blank=True)),
-            ('period_from', self.gf('django.db.models.fields.DateField')(null=True)),
-            ('period_to', self.gf('django.db.models.fields.DateField')(null=True)),
-            ('date_due', self.gf('django.db.models.fields.DateField')(null=True)),
-        ))
-        db.send_create_signal(u'billing', ['Invoice'])
-
-        # Adding model 'InvoiceDetail'
-        db.create_table(u'billing_invoicedetail', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('label', self.gf('django.db.models.fields.CharField')(max_length=100)),
-            ('amount', self.gf('django.db.models.fields.DecimalField')(max_digits=5, decimal_places=2)),
-            ('quantity', self.gf('django.db.models.fields.IntegerField')(null=True)),
-            ('tax', self.gf('django.db.models.fields.IntegerField')(null=True)),
-            ('invoice', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['billing.Invoice'])),
-        ))
-        db.send_create_signal(u'billing', ['InvoiceDetail'])
-
-        # Adding model 'Payment'
-        db.create_table(u'billing_payment', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('payment_means', self.gf('django.db.models.fields.CharField')(max_length=100, null=True)),
-            ('amount', self.gf('django.db.models.fields.DecimalField')(null=True, max_digits=7, decimal_places=2)),
-            ('date', self.gf('django.db.models.fields.DateField')(auto_now_add=True, blank=True)),
-            ('invoce', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['billing.Invoice'])),
-        ))
-        db.send_create_signal(u'billing', ['Payment'])
-
-
-    def backwards(self, orm):
-        # Deleting model 'Invoice'
-        db.delete_table(u'billing_invoice')
-
-        # Deleting model 'InvoiceDetail'
-        db.delete_table(u'billing_invoicedetail')
-
-        # Deleting model 'Payment'
-        db.delete_table(u'billing_payment')
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'auto_now_add': 'True', 'null': 'True', 'blank': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'auto_now_add': 'True', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_means': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 60 - 0
coin/billing/migrations/0001_initial.py

@@ -0,0 +1,60 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+import coin.billing.models
+import datetime
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='Invoice',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('number', models.CharField(default=coin.billing.models.next_invoice_number, unique=True, max_length=25, verbose_name=b'Num\xc3\xa9ro')),
+                ('status', models.CharField(default=b'open', max_length=50, verbose_name=b'Statut', choices=[(b'open', 'A payer'), (b'closed', 'Regl\xe9e'), (b'trouble', 'Litige')])),
+                ('date', models.DateField(default=datetime.date.today, null=True)),
+                ('date_due', models.DateField(default=datetime.date(2014, 9, 30), null=True, verbose_name="Date d'\xe9ch\xe9ance de paiement")),
+            ],
+            options={
+                'verbose_name': 'facture',
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='InvoiceDetail',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('label', models.CharField(max_length=100)),
+                ('amount', models.DecimalField(verbose_name=b'Montant', max_digits=5, decimal_places=2)),
+                ('quantity', models.DecimalField(default=1.0, null=True, verbose_name='Quantit\xe9', max_digits=4, decimal_places=2)),
+                ('tax', models.DecimalField(decimal_places=2, default=0.0, max_digits=4, help_text=b'en %', null=True, verbose_name=b'TVA')),
+                ('period_from', models.DateField(default=datetime.date(2014, 9, 1), help_text='Date de d\xe9but de p\xe9riode sur laquelle est factur\xe9 cet item', null=True, verbose_name='D\xe9but de p\xe9riode', blank=True)),
+                ('period_to', models.DateField(default=datetime.date(2014, 9, 30), help_text='Date de fin de p\xe9riode sur laquelle est factur\xe9 cet item', null=True, verbose_name='Fin de p\xe9riode', blank=True)),
+                ('invoice', models.ForeignKey(related_name=b'details', verbose_name=b'Facture', to='billing.Invoice')),
+            ],
+            options={
+                'verbose_name': 'd\xe9tail de facture',
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='Payment',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('payment_mean', models.CharField(default=b'transfer', max_length=100, null=True, verbose_name=b'Moyen de paiement', choices=[(b'cash', 'Esp\xe8ces'), (b'check', 'Ch\xe8que'), (b'transfer', 'Virement'), (b'other', 'Autre')])),
+                ('amount', models.DecimalField(null=True, verbose_name=b'Montant', max_digits=5, decimal_places=2)),
+                ('date', models.DateField(default=datetime.date.today)),
+                ('invoice', models.ForeignKey(related_name=b'payments', verbose_name=b'Facture', to='billing.Invoice')),
+            ],
+            options={
+                'verbose_name': 'paiement',
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 0 - 67
coin/billing/migrations/0002_001.py

@@ -1,67 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'Invoice.offer'
-        db.add_column(u'billing_invoice', 'offer',
-                      self.gf('django.db.models.fields.related.ForeignKey')(default=1, to=orm['offers.Offer']),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'Invoice.offer'
-        db.delete_column(u'billing_invoice', 'offer_id')
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'auto_now_add': 'True', 'null': 'True', 'blank': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'period_from': ('django.db.models.fields.DateField', [], {'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'auto_now_add': 'True', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_means': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 30 - 0
coin/billing/migrations/0002_auto_20140919_2158.py

@@ -0,0 +1,30 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+import django.db.models.deletion
+from django.conf import settings
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('offers', '0001_initial'),
+        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
+        ('billing', '0001_initial'),
+    ]
+
+    operations = [
+        migrations.AddField(
+            model_name='invoicedetail',
+            name='offersubscription',
+            field=models.ForeignKey(default=None, blank=True, to='offers.OfferSubscription', null=True, verbose_name=b'Abonnement'),
+            preserve_default=True,
+        ),
+        migrations.AddField(
+            model_name='invoice',
+            name='member',
+            field=models.ForeignKey(related_name=b'invoices', on_delete=django.db.models.deletion.SET_NULL, default=None, blank=True, to=settings.AUTH_USER_MODEL, null=True, verbose_name=b'Membre'),
+            preserve_default=True,
+        ),
+    ]

+ 0 - 80
coin/billing/migrations/0003_auto__add_field_invoice_number__chg_field_invoice_date__chg_field_paym.py

@@ -1,80 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'Invoice.number'
-        db.add_column(u'billing_invoice', 'number',
-                      self.gf('django.db.models.fields.CharField')(default=0, max_length=25),
-                      keep_default=False)
-
-
-        # Changing field 'Invoice.date'
-        db.alter_column(u'billing_invoice', 'date', self.gf('django.db.models.fields.DateField')(null=True))
-
-        # Changing field 'Payment.date'
-        db.alter_column(u'billing_payment', 'date', self.gf('django.db.models.fields.DateField')())
-
-    def backwards(self, orm):
-        # Deleting field 'Invoice.number'
-        db.delete_column(u'billing_invoice', 'number')
-
-
-        # Changing field 'Invoice.date'
-        db.alter_column(u'billing_invoice', 'date', self.gf('django.db.models.fields.DateField')(auto_now_add=True, null=True))
-
-        # Changing field 'Payment.date'
-        db.alter_column(u'billing_payment', 'date', self.gf('django.db.models.fields.DateField')(auto_now_add=True))
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'max_length': '25'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'default': '0', 'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_means': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 80
coin/billing/migrations/0004_auto__add_field_invoicedetail_offer__del_field_invoice_offer.py

@@ -1,80 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'InvoiceDetail.offer'
-        db.add_column(u'billing_invoicedetail', 'offer',
-                      self.gf('django.db.models.fields.related.ForeignKey')(to=orm['offers.Offer'], null=True),
-                      keep_default=False)
-
-        # Deleting field 'Invoice.offer'
-        db.delete_column(u'billing_invoice', 'offer_id')
-
-
-    def backwards(self, orm):
-        # Deleting field 'InvoiceDetail.offer'
-        db.delete_column(u'billing_invoicedetail', 'offer_id')
-
-
-        # User chose to not deal with backwards NULL issues for 'Invoice.offer'
-        raise RuntimeError("Cannot reverse this migration. 'Invoice.offer' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration        # Adding field 'Invoice.offer'
-        db.add_column(u'billing_invoice', 'offer',
-                      self.gf('django.db.models.fields.related.ForeignKey')(to=orm['offers.Offer']),
-                      keep_default=False)
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'max_length': '25'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']", 'null': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'default': '0', 'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_means': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 88
coin/billing/migrations/0005_auto__add_field_invoice_member.py

@@ -1,88 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'Invoice.member'
-        db.add_column(u'billing_invoice', 'member',
-                      self.gf('django.db.models.fields.related.ForeignKey')(default=None, to=orm['members.Member'], null=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'Invoice.member'
-        db.delete_column(u'billing_invoice', 'member_id')
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'max_length': '25'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']", 'null': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'default': '0', 'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_means': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 96
coin/billing/migrations/0006_auto__del_field_payment_payment_means__add_field_payment_payment_mean.py

@@ -1,96 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'Payment.payment_means'
-        db.delete_column(u'billing_payment', 'payment_means')
-
-        # Adding field 'Payment.payment_mean'
-        db.add_column(u'billing_payment', 'payment_mean',
-                      self.gf('django.db.models.fields.CharField')(max_length=100, null=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Adding field 'Payment.payment_means'
-        db.add_column(u'billing_payment', 'payment_means',
-                      self.gf('django.db.models.fields.CharField')(max_length=100, null=True),
-                      keep_default=False)
-
-        # Deleting field 'Payment.payment_mean'
-        db.delete_column(u'billing_payment', 'payment_mean')
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'max_length': '25'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'default': '0', 'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 91
coin/billing/migrations/0007_auto__del_field_invoice_amount.py

@@ -1,91 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'Invoice.amount'
-        db.delete_column(u'billing_invoice', 'amount')
-
-
-    def backwards(self, orm):
-
-        # User chose to not deal with backwards NULL issues for 'Invoice.amount'
-        raise RuntimeError("Cannot reverse this migration. 'Invoice.amount' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration        # Adding field 'Invoice.amount'
-        db.add_column(u'billing_invoice', 'amount',
-                      self.gf('django.db.models.fields.DecimalField')(max_digits=5, decimal_places=2),
-                      keep_default=False)
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'2014-2'", 'max_length': '25'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'null': 'True'}),
-            'tax': ('django.db.models.fields.IntegerField', [], {'default': '0', 'null': 'True'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 85
coin/billing/migrations/0008_auto__chg_field_invoicedetail_tax.py

@@ -1,85 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'InvoiceDetail.tax'
-        db.alter_column(u'billing_invoicedetail', 'tax', self.gf('django.db.models.fields.DecimalField')(null=True, max_digits=4, decimal_places=2))
-
-    def backwards(self, orm):
-
-        # Changing field 'InvoiceDetail.tax'
-        db.alter_column(u'billing_invoicedetail', 'tax', self.gf('django.db.models.fields.IntegerField')(null=True))
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201402-356-412'", 'max_length': '25'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'default': '1', 'null': 'True'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 117
coin/billing/migrations/0009_auto__add_field_invoicedetail_period_from__add_field_invoicedetail_per.py

@@ -1,117 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'InvoiceDetail.period_from'
-        db.add_column(u'billing_invoicedetail', 'period_from',
-                      self.gf('django.db.models.fields.DateField')(default=datetime.datetime(2014, 2, 1, 0, 0), null=True, blank=True),
-                      keep_default=False)
-
-        # Adding field 'InvoiceDetail.period_to'
-        db.add_column(u'billing_invoicedetail', 'period_to',
-                      self.gf('django.db.models.fields.DateField')(default=datetime.datetime(2014, 2, 28, 0, 0), null=True, blank=True),
-                      keep_default=False)
-
-        # Deleting field 'Invoice.period_from'
-        db.delete_column(u'billing_invoice', 'period_from')
-
-        # Deleting field 'Invoice.period_to'
-        db.delete_column(u'billing_invoice', 'period_to')
-
-        # Adding unique constraint on 'Invoice', fields ['number']
-        db.create_unique(u'billing_invoice', ['number'])
-
-
-    def backwards(self, orm):
-        # Removing unique constraint on 'Invoice', fields ['number']
-        db.delete_unique(u'billing_invoice', ['number'])
-
-        # Deleting field 'InvoiceDetail.period_from'
-        db.delete_column(u'billing_invoicedetail', 'period_from')
-
-        # Deleting field 'InvoiceDetail.period_to'
-        db.delete_column(u'billing_invoicedetail', 'period_to')
-
-        # Adding field 'Invoice.period_from'
-        db.add_column(u'billing_invoice', 'period_from',
-                      self.gf('django.db.models.fields.DateField')(default=datetime.datetime(2014, 2, 1, 0, 0), null=True),
-                      keep_default=False)
-
-        # Adding field 'Invoice.period_to'
-        db.add_column(u'billing_invoice', 'period_to',
-                      self.gf('django.db.models.fields.DateField')(default=datetime.datetime(2014, 2, 28, 0, 0), null=True),
-                      keep_default=False)
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201402-545-398'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'default': '1', 'null': 'True'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoce': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 105
coin/billing/migrations/0010_auto__chg_field_invoice_member__del_field_payment_invoce__add_field_pa.py

@@ -1,105 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'Invoice.member'
-        db.alter_column(u'billing_invoice', 'member_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['members.Member'], null=True, on_delete=models.SET_NULL))
-        # Deleting field 'Payment.invoce'
-        db.delete_column(u'billing_payment', 'invoce_id')
-
-        # Adding field 'Payment.invoice'
-        db.add_column(u'billing_payment', 'invoice',
-                      self.gf('django.db.models.fields.related.ForeignKey')(to=orm['billing.Invoice'], null=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-
-        # Changing field 'Invoice.member'
-        db.alter_column(u'billing_invoice', 'member_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['members.Member'], null=True))
-
-        # User chose to not deal with backwards NULL issues for 'Payment.invoce'
-        raise RuntimeError("Cannot reverse this migration. 'Payment.invoce' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration        # Adding field 'Payment.invoce'
-        db.add_column(u'billing_payment', 'invoce',
-                      self.gf('django.db.models.fields.related.ForeignKey')(to=orm['billing.Invoice']),
-                      keep_default=False)
-
-        # Deleting field 'Payment.invoice'
-        db.delete_column(u'billing_payment', 'invoice_id')
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'on_delete': 'models.SET_NULL', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201402-672-116'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'default': '1', 'null': 'True'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']", 'null': 'True'}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 85
coin/billing/migrations/0011_auto__chg_field_payment_invoice.py

@@ -1,85 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'Payment.invoice'
-        db.alter_column(u'billing_payment', 'invoice_id', self.gf('django.db.models.fields.related.ForeignKey')(default=1, to=orm['billing.Invoice']))
-
-    def backwards(self, orm):
-
-        # Changing field 'Payment.invoice'
-        db.alter_column(u'billing_payment', 'invoice_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['billing.Invoice'], null=True))
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'on_delete': 'models.SET_NULL', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201402-683-441'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'default': '1', 'null': 'True'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 97
coin/billing/migrations/0012_auto__add_field_invoicedetail_offersubscription.py

@@ -1,97 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'InvoiceDetail.offersubscription'
-        db.add_column(u'billing_invoicedetail', 'offersubscription',
-                      self.gf('django.db.models.fields.related.ForeignKey')(default=None, to=orm['offers.OfferSubscription'], null=True, blank=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'InvoiceDetail.offersubscription'
-        db.delete_column(u'billing_invoicedetail', 'offersubscription_id')
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'on_delete': 'models.SET_NULL', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201402-183-523'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.Offer']", 'null': 'True', 'blank': 'True'}),
-            'offersubscription': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.OfferSubscription']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 2, 28, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'default': '1', 'null': 'True'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 96
coin/billing/migrations/0013_auto__del_field_invoicedetail_offer.py

@@ -1,96 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'InvoiceDetail.offer'
-        db.delete_column(u'billing_invoicedetail', 'offer_id')
-
-
-    def backwards(self, orm):
-        # Adding field 'InvoiceDetail.offer'
-        db.add_column(u'billing_invoicedetail', 'offer',
-                      self.gf('django.db.models.fields.related.ForeignKey')(default=None, to=orm['offers.Offer'], null=True, blank=True),
-                      keep_default=False)
-
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 31, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'on_delete': 'models.SET_NULL', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201403-453-235'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offersubscription': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.OfferSubscription']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 31, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.IntegerField', [], {'default': '1', 'null': 'True'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 94
coin/billing/migrations/0014_auto__chg_field_invoicedetail_quantity.py

@@ -1,94 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'InvoiceDetail.quantity'
-        db.alter_column(u'billing_invoicedetail', 'quantity', self.gf('django.db.models.fields.DecimalField')(null=True, max_digits=4, decimal_places=2))
-
-    def backwards(self, orm):
-
-        # Changing field 'InvoiceDetail.quantity'
-        db.alter_column(u'billing_invoicedetail', 'quantity', self.gf('django.db.models.fields.IntegerField')(null=True))
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 31, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'on_delete': 'models.SET_NULL', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201403-872-331'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offersubscription': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.OfferSubscription']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 31, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.DecimalField', [], {'default': '1.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '7', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 0 - 94
coin/billing/migrations/0015_auto__chg_field_payment_amount.py

@@ -1,94 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'Payment.amount'
-        db.alter_column(u'billing_payment', 'amount', self.gf('django.db.models.fields.DecimalField')(null=True, max_digits=5, decimal_places=2))
-
-    def backwards(self, orm):
-
-        # Changing field 'Payment.amount'
-        db.alter_column(u'billing_payment', 'amount', self.gf('django.db.models.fields.DecimalField')(null=True, max_digits=7, decimal_places=2))
-
-    models = {
-        u'billing.invoice': {
-            'Meta': {'object_name': 'Invoice'},
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today', 'null': 'True'}),
-            'date_due': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 31, 0, 0)', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['members.Member']", 'null': 'True', 'on_delete': 'models.SET_NULL', 'blank': 'True'}),
-            'number': ('django.db.models.fields.CharField', [], {'default': "u'201403-241-114'", 'unique': 'True', 'max_length': '25'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'open'", 'max_length': '50'})
-        },
-        u'billing.invoicedetail': {
-            'Meta': {'object_name': 'InvoiceDetail'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'details'", 'to': u"orm['billing.Invoice']"}),
-            'label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'offersubscription': ('django.db.models.fields.related.ForeignKey', [], {'default': 'None', 'to': u"orm['offers.OfferSubscription']", 'null': 'True', 'blank': 'True'}),
-            'period_from': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 1, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'period_to': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2014, 3, 31, 0, 0)', 'null': 'True', 'blank': 'True'}),
-            'quantity': ('django.db.models.fields.DecimalField', [], {'default': '1.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'}),
-            'tax': ('django.db.models.fields.DecimalField', [], {'default': '0.0', 'null': 'True', 'max_digits': '4', 'decimal_places': '2'})
-        },
-        u'billing.payment': {
-            'Meta': {'object_name': 'Payment'},
-            'amount': ('django.db.models.fields.DecimalField', [], {'null': 'True', 'max_digits': '5', 'decimal_places': '2'}),
-            'date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'invoice': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'payments'", 'to': u"orm['billing.Invoice']"}),
-            'payment_mean': ('django.db.models.fields.CharField', [], {'default': "'transfer'", 'max_length': '100', 'null': 'True'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['billing']

+ 9 - 9
coin/billing/models.py

@@ -9,6 +9,14 @@ from coin.offers.models import OfferSubscription
 from coin.members.models import Member
 
 
+def next_invoice_number():
+    "Détermine un numéro de facture aléatoire"
+    return u'%s%02i-%i-%i' % (datetime.date.today().year,
+                              datetime.date.today().month,
+                              random.randrange(100, 999),
+                              random.randrange(100, 999))
+
+
 class Invoice(models.Model):
 
     INVOICES_STATUS_CHOICES = (
@@ -18,7 +26,7 @@ class Invoice(models.Model):
     )
 
     number = models.CharField(max_length=25,
-                              default=lambda: Invoice.next_invoice_number(),
+                              default=next_invoice_number,
                               unique=True,
                               verbose_name='Numéro')
     status = models.CharField(max_length=50, choices=INVOICES_STATUS_CHOICES,
@@ -67,14 +75,6 @@ class Invoice(models.Model):
         return (self.member and self.member.ldap_cn and
                 self.member.ldap_cn == uid)
 
-    @staticmethod
-    def next_invoice_number():
-        "Détermine un numéro de facture aléatoire"
-        return u'%s%02i-%i-%i' % (datetime.date.today().year,
-                                  datetime.date.today().month,
-                                  random.randrange(100, 999),
-                                  random.randrange(100, 999))
-
     def __unicode__(self):
         return u'#%s %0.2f€ %s' % (self.number, self.amount(), self.date_due)
 

+ 17 - 102
coin/configuration/migrations/0001_initial.py

@@ -1,108 +1,23 @@
 # -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
+from __future__ import unicode_literals
 
+from django.db import models, migrations
 
-class Migration(SchemaMigration):
 
-    def forwards(self, orm):
-        # Adding model 'Configuration'
-        db.create_table(u'configuration_configuration', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('polymorphic_ctype', self.gf('django.db.models.fields.related.ForeignKey')(related_name=u'polymorphic_configuration.configuration_set', null=True, to=orm['contenttypes.ContentType'])),
-            ('offersubscription', self.gf('django.db.models.fields.related.OneToOneField')(blank=True, related_name='configuration', unique=True, null=True, to=orm['offers.OfferSubscription'])),
-        ))
-        db.send_create_signal(u'configuration', ['Configuration'])
+class Migration(migrations.Migration):
 
+    dependencies = [
+    ]
 
-    def backwards(self, orm):
-        # Deleting model 'Configuration'
-        db.delete_table(u'configuration_configuration')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'configuration.configuration': {
-            'Meta': {'object_name': 'Configuration'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'offersubscription': ('django.db.models.fields.related.OneToOneField', [], {'blank': 'True', 'related_name': "'configuration'", 'unique': 'True', 'null': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            'polymorphic_ctype': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "u'polymorphic_configuration.configuration_set'", 'null': 'True', 'to': u"orm['contenttypes.ContentType']"})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            'configuration_type': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        }
-    }
-
-    complete_apps = ['configuration']
+    operations = [
+        migrations.CreateModel(
+            name='Configuration',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+            ],
+            options={
+                'abstract': False,
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 28 - 0
coin/configuration/migrations/0002_auto_20140919_2158.py

@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('offers', '0001_initial'),
+        ('contenttypes', '0001_initial'),
+        ('configuration', '0001_initial'),
+    ]
+
+    operations = [
+        migrations.AddField(
+            model_name='configuration',
+            name='offersubscription',
+            field=models.OneToOneField(related_name=b'configuration', null=True, blank=True, to='offers.OfferSubscription', verbose_name=b'Abonnement'),
+            preserve_default=True,
+        ),
+        migrations.AddField(
+            model_name='configuration',
+            name='polymorphic_ctype',
+            field=models.ForeignKey(related_name=b'polymorphic_configuration.configuration_set', editable=False, to='contenttypes.ContentType', null=True),
+            preserve_default=True,
+        ),
+    ]

+ 96 - 165
coin/members/migrations/0001_initial.py

@@ -1,166 +1,97 @@
 # -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'Member'
-        db.create_table(u'members_member', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('password', self.gf('django.db.models.fields.CharField')(max_length=128)),
-            ('last_login', self.gf('django.db.models.fields.DateTimeField')(default=datetime.datetime.now)),
-            ('is_superuser', self.gf('django.db.models.fields.BooleanField')(default=False)),
-            ('username', self.gf('django.db.models.fields.CharField')(unique=True, max_length=30)),
-            ('first_name', self.gf('django.db.models.fields.CharField')(max_length=30, blank=True)),
-            ('last_name', self.gf('django.db.models.fields.CharField')(max_length=30, blank=True)),
-            ('email', self.gf('django.db.models.fields.EmailField')(max_length=75, blank=True)),
-            ('is_staff', self.gf('django.db.models.fields.BooleanField')(default=False)),
-            ('is_active', self.gf('django.db.models.fields.BooleanField')(default=True)),
-            ('date_joined', self.gf('django.db.models.fields.DateTimeField')(default=datetime.datetime.now)),
-            ('status', self.gf('django.db.models.fields.CharField')(default='pending', max_length=50)),
-            ('type', self.gf('django.db.models.fields.CharField')(default='natural_person', max_length=20)),
-            ('organization_name', self.gf('django.db.models.fields.CharField')(max_length=200, blank=True)),
-            ('home_phone_number', self.gf('django.db.models.fields.CharField')(max_length=25, blank=True)),
-            ('mobile_phone_number', self.gf('django.db.models.fields.CharField')(max_length=25, blank=True)),
-            ('address', self.gf('django.db.models.fields.TextField')(null=True, blank=True)),
-            ('postal_code', self.gf('django.db.models.fields.CharField')(max_length=15, null=True, blank=True)),
-            ('city', self.gf('django.db.models.fields.CharField')(max_length=200, null=True, blank=True)),
-            ('country', self.gf('django.db.models.fields.CharField')(default='France', max_length=200, null=True, blank=True)),
-            ('entry_date', self.gf('django.db.models.fields.DateField')(default=datetime.date.today)),
-            ('resign_date', self.gf('django.db.models.fields.DateField')(null=True, blank=True)),
-        ))
-        db.send_create_signal(u'members', ['Member'])
-
-        # Adding M2M table for field groups on 'Member'
-        m2m_table_name = db.shorten_name(u'members_member_groups')
-        db.create_table(m2m_table_name, (
-            ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)),
-            ('member', models.ForeignKey(orm[u'members.member'], null=False)),
-            ('group', models.ForeignKey(orm[u'auth.group'], null=False))
-        ))
-        db.create_unique(m2m_table_name, ['member_id', 'group_id'])
-
-        # Adding M2M table for field user_permissions on 'Member'
-        m2m_table_name = db.shorten_name(u'members_member_user_permissions')
-        db.create_table(m2m_table_name, (
-            ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)),
-            ('member', models.ForeignKey(orm[u'members.member'], null=False)),
-            ('permission', models.ForeignKey(orm[u'auth.permission'], null=False))
-        ))
-        db.create_unique(m2m_table_name, ['member_id', 'permission_id'])
-
-        # Adding model 'CryptoKey'
-        db.create_table(u'members_cryptokey', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('type', self.gf('django.db.models.fields.CharField')(max_length=3)),
-            ('key', self.gf('django.db.models.fields.TextField')()),
-            ('member', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['members.Member'])),
-        ))
-        db.send_create_signal(u'members', ['CryptoKey'])
-
-        # Adding model 'MembershipFee'
-        db.create_table(u'members_membershipfee', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('member', self.gf('django.db.models.fields.related.ForeignKey')(related_name='membership_fees', to=orm['members.Member'])),
-            ('amount', self.gf('django.db.models.fields.IntegerField')(default='20')),
-            ('start_date', self.gf('django.db.models.fields.DateField')(default=datetime.date.today)),
-            ('end_date', self.gf('django.db.models.fields.DateField')(default=datetime.datetime(2015, 9, 2, 0, 0))),
-        ))
-        db.send_create_signal(u'members', ['MembershipFee'])
-
-
-    def backwards(self, orm):
-        # Deleting model 'Member'
-        db.delete_table(u'members_member')
-
-        # Removing M2M table for field groups on 'Member'
-        db.delete_table(db.shorten_name(u'members_member_groups'))
-
-        # Removing M2M table for field user_permissions on 'Member'
-        db.delete_table(db.shorten_name(u'members_member_user_permissions'))
-
-        # Deleting model 'CryptoKey'
-        db.delete_table(u'members_cryptokey')
-
-        # Deleting model 'MembershipFee'
-        db.delete_table(u'members_membershipfee')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.cryptokey': {
-            'Meta': {'object_name': 'CryptoKey'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'key': ('django.db.models.fields.TextField', [], {}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '3'})
-        },
-        u'members.ldapgroup': {
-            'Meta': {'object_name': 'LdapGroup', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'members.ldapuser': {
-            'Meta': {'object_name': 'LdapUser', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {'null': 'True', 'blank': 'True'}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200', 'null': 'True', 'blank': 'True'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200', 'null': 'True', 'blank': 'True'}),
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15', 'null': 'True', 'blank': 'True'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'pending'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'natural_person'", 'max_length': '20'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'members.membershipfee': {
-            'Meta': {'object_name': 'MembershipFee'},
-            'amount': ('django.db.models.fields.IntegerField', [], {'default': "'20'"}),
-            'end_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.datetime(2015, 9, 2, 0, 0)'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'membership_fees'", 'to': u"orm['members.Member']"}),
-            'start_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        }
-    }
-
-    complete_apps = ['members']
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+import datetime
+from django.conf import settings
+import django.utils.timezone
+import coin.mixins
+import django.core.validators
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('auth', '0001_initial'),
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='Member',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('password', models.CharField(max_length=128, verbose_name='password')),
+                ('last_login', models.DateTimeField(default=django.utils.timezone.now, verbose_name='last login')),
+                ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')),
+                ('username', models.CharField(help_text='Required. 30 characters or fewer. Letters, digits and @/./+/-/_ only.', unique=True, max_length=30, verbose_name='username', validators=[django.core.validators.RegexValidator('^[\\w.@+-]+$', 'Enter a valid username.', 'invalid')])),
+                ('first_name', models.CharField(max_length=30, verbose_name='first name')),
+                ('last_name', models.CharField(max_length=30, verbose_name='last name')),
+                ('email', models.EmailField(unique=True, max_length=75, verbose_name='email address')),
+                ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')),
+                ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')),
+                ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')),
+                ('status', models.CharField(default=b'pending', max_length=50, choices=[(b'member', b'Adh\xc3\xa9rent'), (b'not_member', b'Non adh\xc3\xa9rent'), (b'pending', b"Demande d'adh\xc3\xa9sion")])),
+                ('type', models.CharField(default=b'natural_person', max_length=20, choices=[(b'natural_person', b'Personne physique'), (b'legal_entity', b'Personne morale')])),
+                ('organization_name', models.CharField(help_text=b'Pour une personne morale', max_length=200, verbose_name=b"Nom de l'organisme", blank=True)),
+                ('home_phone_number', models.CharField(max_length=25, verbose_name='T\xe9l\xe9phone fixe', blank=True)),
+                ('mobile_phone_number', models.CharField(max_length=25, verbose_name='T\xe9l\xe9phone mobile', blank=True)),
+                ('address', models.TextField(null=True, verbose_name='Adresse', blank=True)),
+                ('postal_code', models.CharField(max_length=15, null=True, verbose_name='Code postal', blank=True)),
+                ('city', models.CharField(max_length=200, null=True, verbose_name='Commune', blank=True)),
+                ('country', models.CharField(default=b'France', max_length=200, null=True, verbose_name='Pays', blank=True)),
+                ('entry_date', models.DateField(default=datetime.date.today, verbose_name=b'Date de premi\xc3\xa8re adh\xc3\xa9sion')),
+                ('resign_date', models.DateField(null=True, verbose_name=b"Date de d\xc3\xa9part de l'association", blank=True)),
+                ('groups', models.ManyToManyField(related_query_name='user', related_name='user_set', to='auth.Group', blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of his/her group.', verbose_name='groups')),
+                ('user_permissions', models.ManyToManyField(related_query_name='user', related_name='user_set', to='auth.Permission', blank=True, help_text='Specific permissions for this user.', verbose_name='user permissions')),
+            ],
+            options={
+                'verbose_name': 'membre',
+            },
+            bases=(coin.mixins.CoinLdapSyncMixin, models.Model),
+        ),
+        migrations.CreateModel(
+            name='CryptoKey',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('type', models.CharField(max_length=3, choices=[(b'RSA', b'RSA'), (b'GPG', b'GPG')])),
+                ('key', models.TextField(verbose_name='Cl\xe9')),
+                ('member', models.ForeignKey(verbose_name='Membre', to=settings.AUTH_USER_MODEL)),
+            ],
+            options={
+                'verbose_name': 'cl\xe9',
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='MembershipFee',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('amount', models.IntegerField(default=b'20', help_text=b'en \xe2\x82\xac', verbose_name='Montant')),
+                ('start_date', models.DateField(default=datetime.date.today, verbose_name=b'Date de d\xc3\xa9but de cotisation')),
+                ('end_date', models.DateField(default=datetime.date(2015, 9, 19), verbose_name=b'Date de fin de cotisation')),
+                ('member', models.ForeignKey(related_name=b'membership_fees', verbose_name='Membre', to=settings.AUTH_USER_MODEL)),
+            ],
+            options={
+                'verbose_name': 'cotisation',
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='LdapGroup',
+            fields=[
+            ],
+            options={
+                'managed': False,
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='LdapUser',
+            fields=[
+            ],
+            options={
+                'managed': False,
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 44 - 95
coin/offers/migrations/0001_initial.py

@@ -1,97 +1,46 @@
 # -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'Service'
-        db.create_table(u'offers_service', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('name', self.gf('django.db.models.fields.CharField')(max_length=255)),
-        ))
-        db.send_create_signal(u'offers', ['Service'])
-
-        # Adding model 'Offer'
-        db.create_table(u'offers_offer', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('name', self.gf('django.db.models.fields.CharField')(max_length=255)),
-            ('biling_priod', self.gf('django.db.models.fields.IntegerField')(default=1)),
-            ('period_fees', self.gf('django.db.models.fields.DecimalField')(max_digits=5, decimal_places=2)),
-            ('initial_fees', self.gf('django.db.models.fields.DecimalField')(max_digits=5, decimal_places=2)),
-            ('service', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['offers.Service'])),
-        ))
-        db.send_create_signal(u'offers', ['Offer'])
-
-        # Adding model 'OfferSubscription'
-        db.create_table(u'offers_offersubscription', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('subscription_date', self.gf('django.db.models.fields.DateField')(default=datetime.date.today)),
-            ('resign_date', self.gf('django.db.models.fields.DateField')(null=True, blank=True)),
-            ('commitment', self.gf('django.db.models.fields.IntegerField')(null=True, blank=True)),
-            ('member', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['members.Member'])),
-            ('offer', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['offers.Offer'])),
-        ))
-        db.send_create_signal(u'offers', ['OfferSubscription'])
-
+from __future__ import unicode_literals
 
-    def backwards(self, orm):
-        # Deleting model 'Service'
-        db.delete_table(u'offers_service')
-
-        # Deleting model 'Offer'
-        db.delete_table(u'offers_offer')
-
-        # Deleting model 'OfferSubscription'
-        db.delete_table(u'offers_offersubscription')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'biling_priod': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['offers']
+from django.db import models, migrations
+import datetime
+from django.conf import settings
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='Offer',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('name', models.CharField(max_length=255, verbose_name=b"Nom de l'offre")),
+                ('configuration_type', models.CharField(help_text=b'Type of configuration to use with this offer', max_length=50, null=True, choices=[(b'', b'')])),
+                ('billing_period', models.IntegerField(default=1, help_text=b'en mois', verbose_name=b'P\xc3\xa9riode de facturation')),
+                ('period_fees', models.DecimalField(help_text=b'en \xe2\x82\xac', verbose_name=b'Montant par p\xc3\xa9riode de facturation', max_digits=5, decimal_places=2)),
+                ('initial_fees', models.DecimalField(help_text=b'en \xe2\x82\xac', verbose_name=b'Frais de mise en service', max_digits=5, decimal_places=2)),
+            ],
+            options={
+                'verbose_name': 'offre',
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='OfferSubscription',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('subscription_date', models.DateField(default=datetime.date.today, verbose_name=b"Date de souscription \xc3\xa0 l'offre")),
+                ('resign_date', models.DateField(null=True, verbose_name=b'Date de r\xc3\xa9siliation', blank=True)),
+                ('commitment', models.IntegerField(default=0, help_text=b'en mois', verbose_name=b"P\xc3\xa9riode d'engagement")),
+                ('member', models.ForeignKey(verbose_name=b'Membre', to=settings.AUTH_USER_MODEL)),
+                ('offer', models.ForeignKey(verbose_name=b'Offre', to='offers.Offer')),
+            ],
+            options={
+                'verbose_name': 'abonnement',
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 0 - 75
coin/offers/migrations/0002_auto__del_field_offer_biling_priod__add_field_offer_billing_priod.py

@@ -1,75 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'Offer.biling_priod'
-        db.delete_column(u'offers_offer', 'biling_priod')
-
-        # Adding field 'Offer.billing_priod'
-        db.add_column(u'offers_offer', 'billing_priod',
-                      self.gf('django.db.models.fields.IntegerField')(default=1),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Adding field 'Offer.biling_priod'
-        db.add_column(u'offers_offer', 'biling_priod',
-                      self.gf('django.db.models.fields.IntegerField')(default=1),
-                      keep_default=False)
-
-        # Deleting field 'Offer.billing_priod'
-        db.delete_column(u'offers_offer', 'billing_priod')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_priod': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['offers']

+ 0 - 75
coin/offers/migrations/0003_auto__del_field_offer_billing_priod__add_field_offer_billing_period.py

@@ -1,75 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'Offer.billing_priod'
-        db.delete_column(u'offers_offer', 'billing_priod')
-
-        # Adding field 'Offer.billing_period'
-        db.add_column(u'offers_offer', 'billing_period',
-                      self.gf('django.db.models.fields.IntegerField')(default=1),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Adding field 'Offer.billing_priod'
-        db.add_column(u'offers_offer', 'billing_priod',
-                      self.gf('django.db.models.fields.IntegerField')(default=1),
-                      keep_default=False)
-
-        # Deleting field 'Offer.billing_period'
-        db.delete_column(u'offers_offer', 'billing_period')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['offers']

+ 0 - 65
coin/offers/migrations/0004_auto__chg_field_offersubscription_commitment.py

@@ -1,65 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'OfferSubscription.commitment'
-        db.alter_column(u'offers_offersubscription', 'commitment', self.gf('django.db.models.fields.IntegerField')())
-
-    def backwards(self, orm):
-
-        # Changing field 'OfferSubscription.commitment'
-        db.alter_column(u'offers_offersubscription', 'commitment', self.gf('django.db.models.fields.IntegerField')(null=True))
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['offers']

+ 0 - 121
coin/offers/migrations/0005_auto__del_service__del_field_offer_service__add_field_offer_type.py

@@ -1,121 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting model 'Service'
-        db.delete_table(u'offers_service')
-
-        # Deleting field 'Offer.service'
-        db.delete_column(u'offers_offer', 'service_id')
-
-        # Adding field 'Offer.type'
-        db.add_column(u'offers_offer', 'type',
-                      self.gf('django.db.models.fields.CharField')(default='other', max_length=50),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Adding model 'Service'
-        db.create_table(u'offers_service', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('name', self.gf('django.db.models.fields.CharField')(max_length=255)),
-        ))
-        db.send_create_signal(u'offers', ['Service'])
-
-
-        # User chose to not deal with backwards NULL issues for 'Offer.service'
-        raise RuntimeError("Cannot reverse this migration. 'Offer.service' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration        # Adding field 'Offer.service'
-        db.add_column(u'offers_offer', 'service',
-                      self.gf('django.db.models.fields.related.ForeignKey')(to=orm['offers.Service']),
-                      keep_default=False)
-
-        # Deleting field 'Offer.type'
-        db.delete_column(u'offers_offer', 'type')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        }
-    }
-
-    complete_apps = ['offers']

+ 0 - 100
coin/offers/migrations/0006_auto__add_field_offer_backend.py

@@ -1,100 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'Offer.backend'
-        db.add_column(u'offers_offer', 'backend',
-                      self.gf('django.db.models.fields.CharField')(default='none', max_length=50),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'Offer.backend'
-        db.delete_column(u'offers_offer', 'backend')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'backend': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        }
-    }
-
-    complete_apps = ['offers']

+ 0 - 123
coin/offers/migrations/0007_auto__del_field_offer_type__del_field_offer_backend__add_field_offer_c.py

@@ -1,123 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'Offer.type'
-        db.delete_column(u'offers_offer', 'type')
-
-        # Deleting field 'Offer.backend'
-        db.delete_column(u'offers_offer', 'backend')
-
-        # Adding field 'Offer.configuration_type'
-        db.add_column(u'offers_offer', 'configuration_type',
-                      self.gf('django.db.models.fields.CharField')(max_length=50, null=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-
-        # User chose to not deal with backwards NULL issues for 'Offer.type'
-        raise RuntimeError("Cannot reverse this migration. 'Offer.type' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration        # Adding field 'Offer.type'
-        db.add_column(u'offers_offer', 'type',
-                      self.gf('django.db.models.fields.CharField')(max_length=50),
-                      keep_default=False)
-
-
-        # User chose to not deal with backwards NULL issues for 'Offer.backend'
-        raise RuntimeError("Cannot reverse this migration. 'Offer.backend' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration        # Adding field 'Offer.backend'
-        db.add_column(u'offers_offer', 'backend',
-                      self.gf('django.db.models.fields.CharField')(max_length=50),
-                      keep_default=False)
-
-        # Deleting field 'Offer.configuration_type'
-        db.delete_column(u'offers_offer', 'configuration_type')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            'configuration_type': ('django.db.models.fields.CharField', [], {'max_length': '50', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        }
-    }
-
-    complete_apps = ['offers']

+ 39 - 96
coin/resources/migrations/0001_initial.py

@@ -1,97 +1,40 @@
 # -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'IPPool'
-        db.create_table(u'resources_ippool', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('name', self.gf('django.db.models.fields.CharField')(max_length=255)),
-            ('description', self.gf('django.db.models.fields.TextField')(blank=True)),
-            ('inet', self.gf('netfields.fields.CidrAddressField')(max_length=43)),
-        ))
-        db.send_create_signal(u'resources', ['IPPool'])
-
-        # Adding model 'IPSubnet'
-        db.create_table(u'resources_ipsubnet', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('inet', self.gf('netfields.fields.CidrAddressField')(max_length=43)),
-            ('ip_pool', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['resources.IPPool'])),
-            ('offer_subscription', self.gf('django.db.models.fields.related.ForeignKey')(related_name='ip_subnet', to=orm['offers.OfferSubscription'])),
-        ))
-        db.send_create_signal(u'resources', ['IPSubnet'])
-
-
-    def backwards(self, orm):
-        # Deleting model 'IPPool'
-        db.delete_table(u'resources_ippool')
-
-        # Deleting model 'IPSubnet'
-        db.delete_table(u'resources_ipsubnet')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'description': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        }
-    }
-
-    complete_apps = ['resources']
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+import netfields.fields
+import coin.resources.models
+import django.core.validators
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='IPPool',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('name', models.CharField(help_text=b'Name of the IP pool', max_length=255)),
+                ('default_subnetsize', models.PositiveSmallIntegerField(help_text=b'Default subnet size to allocate to subscribers in this pool', verbose_name=b'default subnet size', validators=[django.core.validators.MaxValueValidator(64)])),
+                ('inet', netfields.fields.CidrAddressField(help_text=b'Address space to use', max_length=43, validators=[coin.resources.models.validate_subnet])),
+            ],
+            options={
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='IPSubnet',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('inet', netfields.fields.CidrAddressField(blank=True, help_text=b'Leave empty for automatic allocation', max_length=43, verbose_name=b'subnet', validators=[coin.resources.models.validate_subnet])),
+                ('delegate_reverse_dns', models.BooleanField(default=False)),
+                ('ip_pool', models.ForeignKey(verbose_name=b'IP pool', to='resources.IPPool')),
+            ],
+            options={
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 28 - 0
coin/resources/migrations/0002_auto_20140919_2158.py

@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('offers', '0001_initial'),
+        ('resources', '0001_initial'),
+        ('reverse_dns', '0001_initial'),
+    ]
+
+    operations = [
+        migrations.AddField(
+            model_name='ipsubnet',
+            name='name_server',
+            field=models.ManyToManyField(help_text=b'Nameserver to use for the delegation of reverse DNS', to='reverse_dns.NameServer', blank=True),
+            preserve_default=True,
+        ),
+        migrations.AddField(
+            model_name='ipsubnet',
+            name='offer_subscription',
+            field=models.ForeignKey(related_name=b'ip_subnet', verbose_name=b'subscription', to='offers.OfferSubscription'),
+            preserve_default=True,
+        ),
+    ]

+ 0 - 89
coin/resources/migrations/0002_auto__del_field_ippool_description__add_field_ippool_default_subnetsiz.py

@@ -1,89 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting field 'IPPool.description'
-        db.delete_column(u'resources_ippool', 'description')
-
-        # Adding field 'IPPool.default_subnetsize'
-        db.add_column(u'resources_ippool', 'default_subnetsize',
-                      self.gf('django.db.models.fields.PositiveSmallIntegerField')(default=56),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Adding field 'IPPool.description'
-        db.add_column(u'resources_ippool', 'description',
-                      self.gf('django.db.models.fields.TextField')(default='', blank=True),
-                      keep_default=False)
-
-        # Deleting field 'IPPool.default_subnetsize'
-        db.delete_column(u'resources_ippool', 'default_subnetsize')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'default_subnetsize': ('django.db.models.fields.PositiveSmallIntegerField', [], {}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43', 'blank': 'True'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        }
-    }
-
-    complete_apps = ['resources']

+ 0 - 105
coin/resources/migrations/0003_auto__add_field_ipsubnet_delegate_reverse_dns.py

@@ -1,105 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    depends_on = (
-        ("reverse_dns", "0001_initial"),
-    )
-
-    def forwards(self, orm):
-        # Adding field 'IPSubnet.delegate_reverse_dns'
-        db.add_column(u'resources_ipsubnet', 'delegate_reverse_dns',
-                      self.gf('django.db.models.fields.BooleanField')(default=False),
-                      keep_default=False)
-
-        # Adding M2M table for field name_server on 'IPSubnet'
-        m2m_table_name = db.shorten_name(u'resources_ipsubnet_name_server')
-        db.create_table(m2m_table_name, (
-            ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)),
-            ('ipsubnet', models.ForeignKey(orm[u'resources.ipsubnet'], null=False)),
-            ('nameserver', models.ForeignKey(orm[u'reverse_dns.nameserver'], null=False))
-        ))
-        db.create_unique(m2m_table_name, ['ipsubnet_id', 'nameserver_id'])
-
-
-    def backwards(self, orm):
-        # Deleting field 'IPSubnet.delegate_reverse_dns'
-        db.delete_column(u'resources_ipsubnet', 'delegate_reverse_dns')
-
-        # Removing M2M table for field name_server on 'IPSubnet'
-        db.delete_table(db.shorten_name(u'resources_ipsubnet_name_server'))
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'default_subnetsize': ('django.db.models.fields.PositiveSmallIntegerField', [], {}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            'delegate_reverse_dns': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43', 'blank': 'True'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'name_server': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['reverse_dns.NameServer']", 'symmetrical': 'False'}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        },
-        u'reverse_dns.nameserver': {
-            'Meta': {'object_name': 'NameServer'},
-            'description': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'dns_name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
-        }
-    }
-
-    complete_apps = ['resources']

+ 42 - 91
coin/reverse_dns/migrations/0001_initial.py

@@ -1,92 +1,43 @@
 # -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'NameServer'
-        db.create_table(u'reverse_dns_nameserver', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('dns_name', self.gf('django.db.models.fields.CharField')(max_length=255)),
-            ('description', self.gf('django.db.models.fields.CharField')(max_length=255)),
-        ))
-        db.send_create_signal(u'reverse_dns', ['NameServer'])
-
-
-    def backwards(self, orm):
-        # Deleting model 'NameServer'
-        db.delete_table(u'reverse_dns_nameserver')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'default_subnetsize': ('django.db.models.fields.PositiveSmallIntegerField', [], {}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            'delegate_reverse_dns': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43', 'blank': 'True'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'name_server': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['reverse_dns.NameServer']", 'symmetrical': 'False', 'blank': 'True'}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        },
-        u'reverse_dns.nameserver': {
-            'Meta': {'object_name': 'NameServer'},
-            'description': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'dns_name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
-        }
-    }
-
-    complete_apps = ['reverse_dns']
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+from django.conf import settings
+import django.core.validators
+import netfields.fields
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
+        ('resources', '0001_initial'),
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='NameServer',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('dns_name', models.CharField(help_text=b'Example: ns1.example.com', max_length=255)),
+                ('description', models.CharField(help_text=b'Example: My first name server', max_length=255, verbose_name=b'human-readable name of the nameserver', blank=True)),
+                ('owner', models.ForeignKey(to=settings.AUTH_USER_MODEL, null=True)),
+            ],
+            options={
+            },
+            bases=(models.Model,),
+        ),
+        migrations.CreateModel(
+            name='ReverseDNSEntry',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('ip', netfields.fields.InetAddressField(unique=True, max_length=39)),
+                ('reverse', models.CharField(max_length=255, verbose_name=b'hostname to associate to the IP')),
+                ('ttl', models.IntegerField(default=3600, help_text=b'in seconds', verbose_name=b'TTL', validators=[django.core.validators.MinValueValidator(60)])),
+                ('ip_subnet', models.ForeignKey(to='resources.IPSubnet')),
+            ],
+            options={
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 0 - 106
coin/reverse_dns/migrations/0002_auto__add_unique_reversednsentry_ip.py

@@ -1,106 +0,0 @@
-# -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'ReverseDNSEntry'
-        db.create_table(u'reverse_dns_reversednsentry', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('ip', self.gf('netfields.fields.InetAddressField')(max_length=39)),
-            ('reverse', self.gf('django.db.models.fields.CharField')(max_length=255)),
-            ('ip_subnet', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['resources.IPSubnet'])),
-        ))
-        db.send_create_signal(u'reverse_dns', ['ReverseDNSEntry'])
-
-        # Adding unique constraint on 'ReverseDNSEntry', fields ['ip']
-        db.create_unique(u'reverse_dns_reversednsentry', ['ip'])
-
-
-    def backwards(self, orm):
-        # Removing unique constraint on 'ReverseDNSEntry', fields ['ip']
-        db.delete_unique(u'reverse_dns_reversednsentry', ['ip'])
-
-        # Deleting model 'ReverseDNSEntry'
-        db.delete_table(u'reverse_dns_reversednsentry')
-
-
-    models = {
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'service': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Service']"})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'offers.service': {
-            'Meta': {'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'default_subnetsize': ('django.db.models.fields.PositiveSmallIntegerField', [], {}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            'delegate_reverse_dns': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43', 'blank': 'True'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'name_server': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['reverse_dns.NameServer']", 'symmetrical': 'False', 'blank': 'True'}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        },
-        u'reverse_dns.nameserver': {
-            'Meta': {'object_name': 'NameServer'},
-            'description': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'dns_name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
-        },
-        u'reverse_dns.reversednsentry': {
-            'Meta': {'object_name': 'ReverseDNSEntry'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ip': ('netfields.fields.InetAddressField', [], {'unique': 'True', 'max_length': '39'}),
-            'ip_subnet': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPSubnet']"}),
-            'reverse': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['reverse_dns']

+ 0 - 129
coin/reverse_dns/migrations/0003_auto__add_field_nameserver_owner.py

@@ -1,129 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'NameServer.owner'
-        db.add_column(u'reverse_dns_nameserver', 'owner',
-                      self.gf('django.db.models.fields.related.ForeignKey')(to=orm['members.Member'], null=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'NameServer.owner'
-        db.delete_column(u'reverse_dns_nameserver', 'owner_id')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'default_subnetsize': ('django.db.models.fields.PositiveSmallIntegerField', [], {}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            'delegate_reverse_dns': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43', 'blank': 'True'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'name_server': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['reverse_dns.NameServer']", 'symmetrical': 'False', 'blank': 'True'}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        },
-        u'reverse_dns.nameserver': {
-            'Meta': {'object_name': 'NameServer'},
-            'description': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'}),
-            'dns_name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'owner': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']", 'null': 'True'})
-        },
-        u'reverse_dns.reversednsentry': {
-            'Meta': {'object_name': 'ReverseDNSEntry'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ip': ('netfields.fields.InetAddressField', [], {'unique': 'True', 'max_length': '39'}),
-            'ip_subnet': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPSubnet']"}),
-            'reverse': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        }
-    }
-
-    complete_apps = ['reverse_dns']

+ 0 - 134
coin/reverse_dns/migrations/0004_auto__add_field_reversednsentry_ttl.py

@@ -1,134 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'ReverseDNSEntry.ttl'
-        db.add_column(u'reverse_dns_reversednsentry', 'ttl',
-                      self.gf('django.db.models.fields.IntegerField')(default=3600),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'ReverseDNSEntry.ttl'
-        db.delete_column(u'reverse_dns_reversednsentry', 'ttl')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'resources.ippool': {
-            'Meta': {'object_name': 'IPPool'},
-            'default_subnetsize': ('django.db.models.fields.PositiveSmallIntegerField', [], {}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'})
-        },
-        u'resources.ipsubnet': {
-            'Meta': {'object_name': 'IPSubnet'},
-            'delegate_reverse_dns': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'inet': ('netfields.fields.CidrAddressField', [], {'max_length': '43', 'blank': 'True'}),
-            'ip_pool': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPPool']"}),
-            'name_server': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['reverse_dns.NameServer']", 'symmetrical': 'False', 'blank': 'True'}),
-            'offer_subscription': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'ip_subnet'", 'to': u"orm['offers.OfferSubscription']"})
-        },
-        u'reverse_dns.ldapreversednsentry': {
-            'Meta': {'object_name': 'LdapReverseDNSEntry', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'reverse_dns.nameserver': {
-            'Meta': {'object_name': 'NameServer'},
-            'description': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'}),
-            'dns_name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'owner': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"})
-        },
-        u'reverse_dns.reversednsentry': {
-            'Meta': {'object_name': 'ReverseDNSEntry'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ip': ('netfields.fields.InetAddressField', [], {'unique': 'True', 'max_length': '39'}),
-            'ip_subnet': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['resources.IPSubnet']"}),
-            'reverse': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'ttl': ('django.db.models.fields.IntegerField', [], {'default': '3600'})
-        }
-    }
-
-    complete_apps = ['reverse_dns']

+ 41 - 115
coin/vpn/migrations/0001_initial.py

@@ -1,116 +1,42 @@
 # -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'VPNSubscription'
-        db.create_table(u'vpn_vpnsubscription', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('administrative_subscription', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['offers.OfferSubscription'], unique=True)),
-            ('activated', self.gf('django.db.models.fields.BooleanField')(default=False)),
-            ('login', self.gf('django.db.models.fields.CharField')(max_length=50)),
-            ('password', self.gf('django.db.models.fields.CharField')(max_length=256)),
-            ('ipv4_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, blank=True)),
-            ('ipv6_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, blank=True)),
-        ))
-        db.send_create_signal(u'vpn', ['VPNSubscription'])
-
-
-    def backwards(self, orm):
-        # Deleting model 'VPNSubscription'
-        db.delete_table(u'vpn_vpnsubscription')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.vpnsubscription': {
-            'Meta': {'object_name': 'VPNSubscription'},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'to': u"orm['offers.OfferSubscription']", 'unique': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'blank': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'blank': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256'})
-        }
-    }
-
-    complete_apps = ['vpn']
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+import netfields.fields
+import coin.validation
+import coin.mixins
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('configuration', '0001_initial'),
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='VPNConfiguration',
+            fields=[
+                ('configuration_ptr', models.OneToOneField(parent_link=True, auto_created=True, primary_key=True, serialize=False, to='configuration.Configuration')),
+                ('activated', models.BooleanField(default=False)),
+                ('login', models.CharField(help_text=b'leave empty for automatic generation', unique=True, max_length=50, blank=True)),
+                ('password', models.CharField(max_length=256, null=True, blank=True)),
+                ('ipv4_endpoint', netfields.fields.InetAddressField(blank=True, max_length=39, null=True, validators=[coin.validation.validate_v4])),
+                ('ipv6_endpoint', netfields.fields.InetAddressField(blank=True, max_length=39, null=True, validators=[coin.validation.validate_v6])),
+                ('comment', models.CharField(max_length=512, blank=True)),
+            ],
+            options={
+                'verbose_name': 'VPN',
+            },
+            bases=(coin.mixins.CoinLdapSyncMixin, 'configuration.configuration'),
+        ),
+        migrations.CreateModel(
+            name='LdapVPNConfig',
+            fields=[
+            ],
+            options={
+                'managed': False,
+            },
+            bases=(models.Model,),
+        ),
+    ]

+ 0 - 114
coin/vpn/migrations/0002_auto__add_field_vpnsubscription_comment.py

@@ -1,114 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding field 'VPNSubscription.comment'
-        db.add_column(u'vpn_vpnsubscription', 'comment',
-                      self.gf('django.db.models.fields.CharField')(default='', max_length=512, blank=True),
-                      keep_default=False)
-
-
-    def backwards(self, orm):
-        # Deleting field 'VPNSubscription.comment'
-        db.delete_column(u'vpn_vpnsubscription', 'comment')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.ldapvpnconfig': {
-            'Meta': {'object_name': 'LdapVPNConfig', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'vpn.vpnsubscription': {
-            'Meta': {'object_name': 'VPNSubscription'},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'to': u"orm['offers.OfferSubscription']", 'unique': 'True'}),
-            'comment': ('django.db.models.fields.CharField', [], {'max_length': '512', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'blank': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'blank': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256'})
-        }
-    }
-
-    complete_apps = ['vpn']

+ 0 - 142
coin/vpn/migrations/0003_auto__add_testsubscription__chg_field_vpnsubscription_ipv6_endpoint__c.py

@@ -1,142 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'TestSubscription'
-        db.create_table(u'vpn_testsubscription', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('administrative_subscription', self.gf('django.db.models.fields.related.OneToOneField')(related_name='dsl', unique=True, to=orm['offers.OfferSubscription'])),
-        ))
-        db.send_create_signal(u'vpn', ['TestSubscription'])
-
-
-        # Changing field 'VPNSubscription.ipv6_endpoint'
-        db.alter_column(u'vpn_vpnsubscription', 'ipv6_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, null=True))
-
-        # Changing field 'VPNSubscription.ipv4_endpoint'
-        db.alter_column(u'vpn_vpnsubscription', 'ipv4_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, null=True))
-
-    def backwards(self, orm):
-        # Deleting model 'TestSubscription'
-        db.delete_table(u'vpn_testsubscription')
-
-
-        # User chose to not deal with backwards NULL issues for 'VPNSubscription.ipv6_endpoint'
-        raise RuntimeError("Cannot reverse this migration. 'VPNSubscription.ipv6_endpoint' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration
-        # Changing field 'VPNSubscription.ipv6_endpoint'
-        db.alter_column(u'vpn_vpnsubscription', 'ipv6_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39))
-
-        # User chose to not deal with backwards NULL issues for 'VPNSubscription.ipv4_endpoint'
-        raise RuntimeError("Cannot reverse this migration. 'VPNSubscription.ipv4_endpoint' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration
-        # Changing field 'VPNSubscription.ipv4_endpoint'
-        db.alter_column(u'vpn_vpnsubscription', 'ipv4_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39))
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'backend': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.ldapvpnconfig': {
-            'Meta': {'object_name': 'LdapVPNConfig', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'vpn.testsubscription': {
-            'Meta': {'object_name': 'TestSubscription'},
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'related_name': "'dsl'", 'unique': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
-        },
-        u'vpn.vpnsubscription': {
-            'Meta': {'object_name': 'VPNSubscription'},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'related_name': "'vpn'", 'unique': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            'comment': ('django.db.models.fields.CharField', [], {'max_length': '512', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256'})
-        }
-    }
-
-    complete_apps = ['vpn']

+ 0 - 118
coin/vpn/migrations/0004_auto__add_unique_vpnsubscription_login.py

@@ -1,118 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding unique constraint on 'VPNSubscription', fields ['login']
-        db.create_unique(u'vpn_vpnsubscription', ['login'])
-
-
-    def backwards(self, orm):
-        # Removing unique constraint on 'VPNSubscription', fields ['login']
-        db.delete_unique(u'vpn_vpnsubscription', ['login'])
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'backend': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.ldapvpnconfig': {
-            'Meta': {'object_name': 'LdapVPNConfig', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'vpn.testsubscription': {
-            'Meta': {'object_name': 'TestSubscription'},
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'related_name': "'dsl'", 'unique': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
-        },
-        u'vpn.vpnsubscription': {
-            'Meta': {'object_name': 'VPNSubscription'},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'related_name': "'vpn'", 'unique': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            'comment': ('django.db.models.fields.CharField', [], {'max_length': '512', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '50'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256'})
-        }
-    }
-
-    complete_apps = ['vpn']

+ 0 - 117
coin/vpn/migrations/0005_auto__del_testsubscription.py

@@ -1,117 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting model 'TestSubscription'
-        db.delete_table(u'vpn_testsubscription')
-
-
-    def backwards(self, orm):
-        # Adding model 'TestSubscription'
-        db.create_table(u'vpn_testsubscription', (
-            ('administrative_subscription', self.gf('django.db.models.fields.related.OneToOneField')(related_name='dsl', unique=True, to=orm['offers.OfferSubscription'])),
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-        ))
-        db.send_create_signal(u'vpn', ['TestSubscription'])
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'backend': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.ldapvpnconfig': {
-            'Meta': {'object_name': 'LdapVPNConfig', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'vpn.vpnsubscription': {
-            'Meta': {'object_name': 'VPNSubscription'},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'related_name': "'openvpn_ldap'", 'unique': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            'comment': ('django.db.models.fields.CharField', [], {'max_length': '512', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '50'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256'})
-        }
-    }
-
-    complete_apps = ['vpn']

+ 0 - 117
coin/vpn/migrations/0006_auto__chg_field_vpnsubscription_password.py

@@ -1,117 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-
-        # Changing field 'VPNSubscription.password'
-        db.alter_column(u'vpn_vpnsubscription', 'password', self.gf('django.db.models.fields.CharField')(max_length=256, null=True))
-
-    def backwards(self, orm):
-
-        # User chose to not deal with backwards NULL issues for 'VPNSubscription.password'
-        raise RuntimeError("Cannot reverse this migration. 'VPNSubscription.password' and its values cannot be restored.")
-        
-        # The following code is provided here to aid in writing a correct migration
-        # Changing field 'VPNSubscription.password'
-        db.alter_column(u'vpn_vpnsubscription', 'password', self.gf('django.db.models.fields.CharField')(max_length=256))
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'backend': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'type': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.ldapvpnconfig': {
-            'Meta': {'object_name': 'LdapVPNConfig', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'vpn.vpnsubscription': {
-            'Meta': {'object_name': 'VPNSubscription'},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'administrative_subscription': ('django.db.models.fields.related.OneToOneField', [], {'related_name': "'openvpn_ldap'", 'unique': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            'comment': ('django.db.models.fields.CharField', [], {'max_length': '512', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '50'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256', 'null': 'True', 'blank': 'True'})
-        }
-    }
-
-    complete_apps = ['vpn']

+ 0 - 142
coin/vpn/migrations/0007_auto__del_vpnsubscription__add_vpnconfiguration.py

@@ -1,142 +0,0 @@
-# -*- coding: utf-8 -*-
-from south.utils import datetime_utils as datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Deleting model 'VPNSubscription'
-        db.delete_table(u'vpn_vpnsubscription')
-
-        # Adding model 'VPNConfiguration'
-        db.create_table(u'vpn_vpnconfiguration', (
-            (u'configuration_ptr', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['configuration.Configuration'], unique=True, primary_key=True)),
-            ('activated', self.gf('django.db.models.fields.BooleanField')(default=False)),
-            ('login', self.gf('django.db.models.fields.CharField')(unique=True, max_length=50, blank=True)),
-            ('password', self.gf('django.db.models.fields.CharField')(max_length=256, null=True, blank=True)),
-            ('ipv4_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, null=True, blank=True)),
-            ('ipv6_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, null=True, blank=True)),
-            ('comment', self.gf('django.db.models.fields.CharField')(max_length=512, blank=True)),
-        ))
-        db.send_create_signal(u'vpn', ['VPNConfiguration'])
-
-
-    def backwards(self, orm):
-        # Adding model 'VPNSubscription'
-        db.create_table(u'vpn_vpnsubscription', (
-            ('comment', self.gf('django.db.models.fields.CharField')(max_length=512, blank=True)),
-            ('administrative_subscription', self.gf('django.db.models.fields.related.OneToOneField')(related_name='openvpn_ldap', unique=True, to=orm['offers.OfferSubscription'])),
-            ('ipv6_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, null=True, blank=True)),
-            ('ipv4_endpoint', self.gf('netfields.fields.InetAddressField')(max_length=39, null=True, blank=True)),
-            ('password', self.gf('django.db.models.fields.CharField')(max_length=256, null=True, blank=True)),
-            ('activated', self.gf('django.db.models.fields.BooleanField')(default=False)),
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('login', self.gf('django.db.models.fields.CharField')(max_length=50, unique=True)),
-        ))
-        db.send_create_signal(u'vpn', ['VPNSubscription'])
-
-        # Deleting model 'VPNConfiguration'
-        db.delete_table(u'vpn_vpnconfiguration')
-
-
-    models = {
-        u'auth.group': {
-            'Meta': {'object_name': 'Group'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
-            'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
-        },
-        u'auth.permission': {
-            'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
-            'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
-        },
-        u'auth.user': {
-            'Meta': {'object_name': 'User'},
-            'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'groups': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Group']"}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
-            'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
-            'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'related_name': "u'user_set'", 'blank': 'True', 'to': u"orm['auth.Permission']"}),
-            'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
-        },
-        u'configuration.configuration': {
-            'Meta': {'object_name': 'Configuration'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'offersubscription': ('django.db.models.fields.related.OneToOneField', [], {'blank': 'True', 'related_name': "'configuration'", 'unique': 'True', 'null': 'True', 'to': u"orm['offers.OfferSubscription']"}),
-            'polymorphic_ctype': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "u'polymorphic_configuration.configuration_set'", 'null': 'True', 'to': u"orm['contenttypes.ContentType']"})
-        },
-        u'contenttypes.contenttype': {
-            'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
-            'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
-        },
-        u'members.member': {
-            'Meta': {'object_name': 'Member'},
-            'address': ('django.db.models.fields.TextField', [], {}),
-            'city': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'country': ('django.db.models.fields.CharField', [], {'default': "'France'", 'max_length': '200'}),
-            'email': ('django.db.models.fields.EmailField', [], {'max_length': '254'}),
-            'entry_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'}),
-            'first_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'home_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'last_name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
-            'ldap_cn': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'mobile_phone_number': ('django.db.models.fields.CharField', [], {'max_length': '25', 'blank': 'True'}),
-            'organization_name': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
-            'postal_code': ('django.db.models.fields.CharField', [], {'max_length': '15'}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'status': ('django.db.models.fields.CharField', [], {'default': "'non_adherent'", 'max_length': '50'}),
-            'type': ('django.db.models.fields.CharField', [], {'default': "'personne_physique'", 'max_length': '20'}),
-            'user': ('django.db.models.fields.related.OneToOneField', [], {'default': 'None', 'to': u"orm['auth.User']", 'unique': 'True', 'null': 'True', 'on_delete': 'models.SET_NULL'})
-        },
-        u'offers.offer': {
-            'Meta': {'object_name': 'Offer'},
-            'billing_period': ('django.db.models.fields.IntegerField', [], {'default': '1'}),
-            'configuration_type': ('django.db.models.fields.CharField', [], {'max_length': '50', 'null': 'True'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'initial_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'period_fees': ('django.db.models.fields.DecimalField', [], {'max_digits': '5', 'decimal_places': '2'})
-        },
-        u'offers.offersubscription': {
-            'Meta': {'object_name': 'OfferSubscription'},
-            'commitment': ('django.db.models.fields.IntegerField', [], {'default': '0'}),
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'member': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['members.Member']"}),
-            'offer': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['offers.Offer']"}),
-            'resign_date': ('django.db.models.fields.DateField', [], {'null': 'True', 'blank': 'True'}),
-            'subscription_date': ('django.db.models.fields.DateField', [], {'default': 'datetime.date.today'})
-        },
-        u'vpn.ldapvpnconfig': {
-            'Meta': {'object_name': 'LdapVPNConfig', 'managed': 'False'},
-            'dn': ('django.db.models.fields.CharField', [], {'max_length': '200'})
-        },
-        u'vpn.vpnconfiguration': {
-            'Meta': {'object_name': 'VPNConfiguration', '_ormbases': [u'configuration.Configuration']},
-            'activated': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
-            'comment': ('django.db.models.fields.CharField', [], {'max_length': '512', 'blank': 'True'}),
-            u'configuration_ptr': ('django.db.models.fields.related.OneToOneField', [], {'to': u"orm['configuration.Configuration']", 'unique': 'True', 'primary_key': 'True'}),
-            'ipv4_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'ipv6_endpoint': ('netfields.fields.InetAddressField', [], {'max_length': '39', 'null': 'True', 'blank': 'True'}),
-            'login': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '50', 'blank': 'True'}),
-            'password': ('django.db.models.fields.CharField', [], {'max_length': '256', 'null': 'True', 'blank': 'True'})
-        }
-    }
-
-    complete_apps = ['vpn']