fix error in ceck data
This commit is contained in:
parent
9a18080db9
commit
97489af723
@ -26,7 +26,7 @@ class DeskAdminForm(forms.ModelForm):
|
|||||||
|
|
||||||
def clean_desk_no(self):
|
def clean_desk_no(self):
|
||||||
id = self.instance.id
|
id = self.instance.id
|
||||||
client = self.instance.client
|
client = self.cleaned_data['client']
|
||||||
desk_no = self.cleaned_data['desk_no']
|
desk_no = self.cleaned_data['desk_no']
|
||||||
t = Desk.objects.filter(desk_no=desk_no, client=client).exclude(id=id)
|
t = Desk.objects.filter(desk_no=desk_no, client=client).exclude(id=id)
|
||||||
if t.count() > 0:
|
if t.count() > 0:
|
||||||
|
20
billard/migrations/0014_auto_20170211_2008.py
Normal file
20
billard/migrations/0014_auto_20170211_2008.py
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
# Generated by Django 1.10.5 on 2017-02-11 20:08
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('billard', '0013_accounting'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='desk',
|
||||||
|
name='prize',
|
||||||
|
field=models.DecimalField(decimal_places=2, default=0.0, max_digits=5, verbose_name='Normelpreis'),
|
||||||
|
),
|
||||||
|
]
|
@ -63,7 +63,7 @@ class Desk(models.Model):
|
|||||||
desk_no = models.IntegerField(verbose_name='Tischnummer')
|
desk_no = models.IntegerField(verbose_name='Tischnummer')
|
||||||
name = models.CharField(max_length=32, blank=True, null=True, verbose_name='Tischbezeichnung')
|
name = models.CharField(max_length=32, blank=True, null=True, verbose_name='Tischbezeichnung')
|
||||||
enabled = models.BooleanField(verbose_name='Tisch aktiv')
|
enabled = models.BooleanField(verbose_name='Tisch aktiv')
|
||||||
prize = models.DecimalField(max_digits=5, decimal_places=2, blank=True, null=True, verbose_name="Normelpreis")
|
prize = models.DecimalField(max_digits=5, decimal_places=2, default=0.0, verbose_name="Normelpreis")
|
||||||
prize_hh = models.DecimalField(max_digits=5, decimal_places=2, blank=True, null=True,
|
prize_hh = models.DecimalField(max_digits=5, decimal_places=2, blank=True, null=True,
|
||||||
verbose_name="Preis Happy Hour")
|
verbose_name="Preis Happy Hour")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user