mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-10 03:49:24 +00:00
Club model implementation, various other changes
This commit is contained in:
@ -9,64 +9,64 @@ import accounting.models
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('core', '0005_auto_20160128_0842'),
|
||||
('core', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Customer',
|
||||
fields=[
|
||||
('user', models.OneToOneField(to=settings.AUTH_USER_MODEL, primary_key=True, serialize=False)),
|
||||
('account_id', models.CharField(unique=True, verbose_name='account id', max_length=10)),
|
||||
('user', models.OneToOneField(primary_key=True, to=settings.AUTH_USER_MODEL, serialize=False)),
|
||||
('account_id', models.CharField(max_length=10, unique=True, verbose_name='account id')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': 'customer',
|
||||
'verbose_name_plural': 'customers',
|
||||
'verbose_name': 'customer',
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='GeneralJournal',
|
||||
fields=[
|
||||
('id', models.AutoField(verbose_name='ID', auto_created=True, primary_key=True, serialize=False)),
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('start_date', models.DateField(verbose_name='start date')),
|
||||
('end_date', models.DateField(null=True, verbose_name='end date', blank=True, default=None)),
|
||||
('name', models.CharField(verbose_name='name', max_length=30)),
|
||||
('end_date', models.DateField(blank=True, default=None, null=True, verbose_name='end date')),
|
||||
('name', models.CharField(max_length=30, verbose_name='name')),
|
||||
('closed', models.BooleanField(default=False, verbose_name='is closed')),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='GenericInvoice',
|
||||
fields=[
|
||||
('id', models.AutoField(verbose_name='ID', auto_created=True, primary_key=True, serialize=False)),
|
||||
('name', models.CharField(verbose_name='name', max_length=100)),
|
||||
('journal', models.ForeignKey(to='accounting.GeneralJournal', related_name='invoices')),
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=100, verbose_name='name')),
|
||||
('journal', models.ForeignKey(related_name='invoices', to='accounting.GeneralJournal')),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='Product',
|
||||
fields=[
|
||||
('id', models.AutoField(verbose_name='ID', auto_created=True, primary_key=True, serialize=False)),
|
||||
('name', models.CharField(verbose_name='name', max_length=30)),
|
||||
('description', models.TextField(verbose_name='description')),
|
||||
('code', models.CharField(verbose_name='code', max_length=10)),
|
||||
('purchase_price', accounting.models.CurrencyField(max_digits=12, decimal_places=2, verbose_name='purchase price')),
|
||||
('selling_price', accounting.models.CurrencyField(max_digits=12, decimal_places=2, verbose_name='selling price')),
|
||||
('special_selling_price', accounting.models.CurrencyField(max_digits=12, decimal_places=2, verbose_name='special selling price')),
|
||||
('icon', models.ImageField(null=True, upload_to='products')),
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=30, verbose_name='name')),
|
||||
('description', models.TextField(blank=True, verbose_name='description')),
|
||||
('code', models.CharField(max_length=10, verbose_name='code')),
|
||||
('purchase_price', accounting.models.CurrencyField(decimal_places=2, max_digits=12, verbose_name='purchase price')),
|
||||
('selling_price', accounting.models.CurrencyField(decimal_places=2, max_digits=12, verbose_name='selling price')),
|
||||
('special_selling_price', accounting.models.CurrencyField(decimal_places=2, max_digits=12, verbose_name='special selling price')),
|
||||
('icon', models.ImageField(blank=True, upload_to='products', null=True)),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='ProductType',
|
||||
fields=[
|
||||
('id', models.AutoField(verbose_name='ID', auto_created=True, primary_key=True, serialize=False)),
|
||||
('name', models.CharField(verbose_name='name', max_length=30)),
|
||||
('description', models.TextField(verbose_name='description')),
|
||||
('icon', models.ImageField(null=True, upload_to='products')),
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=30, verbose_name='name')),
|
||||
('description', models.TextField(blank=True, null=True, verbose_name='description')),
|
||||
('icon', models.ImageField(blank=True, upload_to='products', null=True)),
|
||||
],
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='product',
|
||||
name='product_type',
|
||||
field=models.ForeignKey(null=True, to='accounting.ProductType', related_name='products'),
|
||||
field=models.ForeignKey(related_name='products', blank=True, to='accounting.ProductType', null=True),
|
||||
),
|
||||
]
|
||||
|
@ -1,39 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('accounting', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='product',
|
||||
name='description',
|
||||
field=models.TextField(verbose_name='description', blank=True),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='product',
|
||||
name='icon',
|
||||
field=models.ImageField(null=True, upload_to='products', blank=True),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='product',
|
||||
name='product_type',
|
||||
field=models.ForeignKey(to='accounting.ProductType', null=True, blank=True, related_name='products'),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='producttype',
|
||||
name='description',
|
||||
field=models.TextField(verbose_name='description', null=True, blank=True),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='producttype',
|
||||
name='icon',
|
||||
field=models.ImageField(null=True, upload_to='products', blank=True),
|
||||
),
|
||||
]
|
Reference in New Issue
Block a user