add initial migration

This commit is contained in:
Pierre-antoine Comby 2019-07-08 16:11:53 +02:00
parent 9db72d4f34
commit 898ed2c23a
1 changed files with 63 additions and 0 deletions

View File

@ -0,0 +1,63 @@
# Generated by Django 2.2.3 on 2019-07-08 14:08
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='NoteClub',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('solde', models.IntegerField(help_text="en centime, l' argent crédité pour cette instance", verbose_name='solde du compte')),
('active', models.BooleanField(default=True, verbose_name='etat du compte')),
],
options={
'abstract': False,
},
),
migrations.CreateModel(
name='NoteSpec',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('solde', models.IntegerField(help_text="en centime, l' argent crédité pour cette instance", verbose_name='solde du compte')),
('active', models.BooleanField(default=True, verbose_name='etat du compte')),
('account_type', models.CharField(choices=[('CH', 'chèques'), ('CB', 'Carte Bancaire'), ('VB', 'Virement Bancaire'), ('CA', 'Cash'), ('RB', 'Remboursement')], max_length=2, unique=True)),
],
options={
'abstract': False,
},
),
migrations.CreateModel(
name='NoteUser',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('solde', models.IntegerField(help_text="en centime, l' argent crédité pour cette instance", verbose_name='solde du compte')),
('active', models.BooleanField(default=True, verbose_name='etat du compte')),
('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
options={
'verbose_name': "One's Note",
'verbose_name_plural': 'Users Note',
},
),
migrations.CreateModel(
name='Alias',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('alias', models.TextField(unique=True, verbose_name='alias')),
('owner_id', models.PositiveIntegerField()),
('owner_type', models.ForeignKey(limit_choices_to=models.Q(models.Q(('app_label', 'note'), ('model', 'NoteUser')), models.Q(('app_label', 'note'), ('model', 'NoteClub')), _connector='OR'), on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
],
),
]