Use textfield for some things rather than char field

This commit is contained in:
Christopher Neugebauer 2016-09-05 19:45:44 +10:00
parent 17dd91d56b
commit 878da1f2d8
2 changed files with 39 additions and 6 deletions

View file

@ -0,0 +1,35 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2016-09-05 09:45
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('registrasion', '0004_groupmemberdiscount_groupmemberflag'),
]
operations = [
migrations.AlterField(
model_name='category',
name='description',
field=models.TextField(verbose_name='Description'),
),
migrations.AlterField(
model_name='category',
name='name',
field=models.CharField(max_length=255, verbose_name='Name'),
),
migrations.AlterField(
model_name='product',
name='description',
field=models.TextField(blank=True, null=True, verbose_name='Description'),
),
migrations.AlterField(
model_name='product',
name='name',
field=models.CharField(max_length=255, verbose_name='Name'),
),
]

View file

@ -71,11 +71,10 @@ class Category(models.Model):
]
name = models.CharField(
max_length=65,
max_length=255,
verbose_name=_("Name"),
)
description = models.CharField(
max_length=255,
description = models.TextField(
verbose_name=_("Description"),
)
limit_per_user = models.PositiveIntegerField(
@ -143,11 +142,10 @@ class Product(models.Model):
return "%s - %s" % (self.category.name, self.name)
name = models.CharField(
max_length=65,
max_length=255,
verbose_name=_("Name"),
)
description = models.CharField(
max_length=255,
description = models.TextField(
verbose_name=_("Description"),
null=True,
blank=True,