mirror of
https://github.com/daniviga/django-ram.git
synced 2025-08-05 05:37:50 +02:00
Migrate some models in a new app
This commit is contained in:
42
dcc/metadata/migrations/0001_initial.py
Normal file
42
dcc/metadata/migrations/0001_initial.py
Normal file
@@ -0,0 +1,42 @@
|
||||
# Generated by Django 4.0 on 2021-12-20 21:37
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
import django_countries.fields
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
initial = True
|
||||
|
||||
dependencies = [
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Company',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=128, unique=True)),
|
||||
('country', django_countries.fields.CountryField(max_length=2)),
|
||||
],
|
||||
options={
|
||||
'verbose_name_plural': 'Companies',
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='Manufacturer',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=128, unique=True)),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='Decoder',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=128, unique=True)),
|
||||
('manufacturer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='metadata.manufacturer')),
|
||||
],
|
||||
),
|
||||
]
|
18
dcc/metadata/migrations/0002_decoder_version.py
Normal file
18
dcc/metadata/migrations/0002_decoder_version.py
Normal file
@@ -0,0 +1,18 @@
|
||||
# Generated by Django 4.0 on 2021-12-20 21:42
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('metadata', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='decoder',
|
||||
name='version',
|
||||
field=models.CharField(blank=True, max_length=64),
|
||||
),
|
||||
]
|
0
dcc/metadata/migrations/__init__.py
Normal file
0
dcc/metadata/migrations/__init__.py
Normal file
Reference in New Issue
Block a user