basics for automation
This commit is contained in:
35
cookbook/migrations/0152_automation.py
Normal file
35
cookbook/migrations/0152_automation.py
Normal file
@ -0,0 +1,35 @@
|
||||
# Generated by Django 3.2.7 on 2021-09-15 10:12
|
||||
|
||||
import cookbook.models
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
('cookbook', '0151_auto_20210915_1037'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Automation',
|
||||
fields=[
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('type', models.CharField(choices=[('FOOD_ALIAS', 'Food Alias'), ('UNIT_ALIAS', 'Unit Alias'), ('KEYWORD_ALIAS', 'Keyword Alias')], max_length=128)),
|
||||
('name', models.CharField(default='', max_length=128)),
|
||||
('description', models.TextField(blank=True, null=True)),
|
||||
('param_1', models.CharField(blank=True, max_length=128, null=True)),
|
||||
('param_2', models.CharField(blank=True, max_length=128, null=True)),
|
||||
('param_3', models.CharField(blank=True, max_length=128, null=True)),
|
||||
('disabled', models.BooleanField(default=False)),
|
||||
('updated_at', models.DateTimeField(auto_now=True)),
|
||||
('created_at', models.DateTimeField(auto_now_add=True)),
|
||||
('created_by', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
|
||||
('space', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='cookbook.space')),
|
||||
],
|
||||
bases=(models.Model, cookbook.models.PermissionModelMixin),
|
||||
),
|
||||
]
|
Reference in New Issue
Block a user