first model in postgresql base

This commit is contained in:
Alicja Cięciwa
2020-11-13 12:46:10 +01:00
parent e19cde9660
commit d5de4155b6
46 changed files with 4178 additions and 11 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,22 @@
# Generated by Django 3.1.2 on 2020-11-13 11:22
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='HoursInput',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('hours_number', models.IntegerField()),
('workplace', models.CharField(max_length=100)),
],
),
]

View File

@@ -0,0 +1,19 @@
# Generated by Django 3.1.2 on 2020-11-13 11:29
import datetime
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('work', '0001_initial'),
]
operations = [
migrations.AddField(
model_name='hoursinput',
name='date',
field=models.DateField(default=datetime.date.today),
),
]

View File

Binary file not shown.

View File

@@ -8,8 +8,8 @@ import datetime
# ('MS', 'Ms.'),
# ]
#
# class HoursInput(models.Model):
# date = models.DateField(default=datetime.date.today)
# hours_number = models.IntegerField()
# # workplace = models.CharField(required=True, max_length=100, choices=TITLE_CHOICES)
#
class HoursInput(models.Model):
date = models.DateField(default=datetime.date.today)
hours_number = models.IntegerField()
workplace = models.CharField(max_length=100)