add visitor model and api
This commit is contained in:
25
api/migrations/0002_auto_20200426_1517.py
Normal file
25
api/migrations/0002_auto_20200426_1517.py
Normal file
@@ -0,0 +1,25 @@
|
||||
# Generated by Django 3.0.5 on 2020-04-26 15:17
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('api', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Visitor',
|
||||
fields=[
|
||||
('name', models.CharField(max_length=255, primary_key=True, serialize=False)),
|
||||
('clicked', models.IntegerField(blank=True, default=0)),
|
||||
('first_pressed', models.DateTimeField(auto_now_add=True)),
|
||||
('last_pressed', models.DateTimeField(auto_now=True)),
|
||||
],
|
||||
),
|
||||
migrations.DeleteModel(
|
||||
name='Snippet',
|
||||
),
|
||||
]
|
||||
23
api/migrations/0003_auto_20200426_1526.py
Normal file
23
api/migrations/0003_auto_20200426_1526.py
Normal file
@@ -0,0 +1,23 @@
|
||||
# Generated by Django 3.0.5 on 2020-04-26 15:26
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('api', '0002_auto_20200426_1517'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='visitor',
|
||||
name='first_pressed',
|
||||
field=models.DateTimeField(blank=True, null=True),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='visitor',
|
||||
name='last_pressed',
|
||||
field=models.DateTimeField(blank=True, null=True),
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user