update model
This commit is contained in:
parent
ea2ed0d6a1
commit
943ff5ad21
33
billard/migrations/0018_auto_20170302_2058.py
Normal file
33
billard/migrations/0018_auto_20170302_2058.py
Normal file
@ -0,0 +1,33 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.10.5 on 2017-03-02 20:58
|
||||
from __future__ import unicode_literals
|
||||
|
||||
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),
|
||||
('billard', '0017_accounting_reporter_uuid'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='accounting',
|
||||
name='prize_hh',
|
||||
field=models.DecimalField(blank=True, decimal_places=2, max_digits=5, null=True, verbose_name='Preis Happy Hour'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='accounting',
|
||||
name='prize_normal',
|
||||
field=models.DecimalField(blank=True, decimal_places=2, max_digits=5, null=True, verbose_name='Preis Normalzeit'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='client',
|
||||
name='report_user',
|
||||
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='reporting_clients', to=settings.AUTH_USER_MODEL, verbose_name='Reporting Benutzer'),
|
||||
),
|
||||
]
|
@ -53,7 +53,7 @@ class Location(models.Model):
|
||||
class Client(models.Model):
|
||||
uuid = models.UUIDField(unique=True, default=uuid.uuid4, verbose_name="Identifier")
|
||||
location = models.ForeignKey(Location, verbose_name="Standort")
|
||||
report_user = models.ForeignKey(User, verbose_name="Reporting Benutzer", related_name='reporting_clients')
|
||||
report_user = models.ForeignKey(User, blank=True, null=True, verbose_name="Reporting Benutzer", related_name='reporting_clients')
|
||||
|
||||
def __str__(self):
|
||||
return '{}, {}'.format(self.location.name, self.uuid)
|
||||
|
Loading…
Reference in New Issue
Block a user