Ticket #35176: 0001_initial.py

File 0001_initial.py, 1.0 KB (added by Corentin Bettiol, 8 months ago)

First migration: create the model in db, with 2 fields.

Line 
1# Generated by Django 4.2.10 on 2024-02-08 10:44
2
3from django.db import migrations, models
4
5
6class Migration(migrations.Migration):
7
8 initial = True
9
10 dependencies = []
11
12 operations = [
13 migrations.CreateModel(
14 name="MyModel",
15 fields=[
16 (
17 "id",
18 models.BigAutoField(
19 auto_created=True,
20 primary_key=True,
21 serialize=False,
22 verbose_name="ID",
23 ),
24 ),
25 (
26 "a_field",
27 models.BooleanField(
28 null=True, verbose_name="the verbose name of the field"
29 ),
30 ),
31 (
32 "another_field",
33 models.BooleanField(
34 null=True, verbose_name="another verbose name"
35 ),
36 ),
37 ],
38 ),
39 ]
Back to Top