Skip to content

Commit

Permalink
Changing TextField Size for #111
Browse files Browse the repository at this point in the history
This commit applies the field change size for several TextFields
  • Loading branch information
ryancheley committed Mar 6, 2022
1 parent 858d714 commit 5463558
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Generated by Django 4.0.3 on 2022-03-06 16:43

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('grid', '0003_alter_element_text_alter_feature_description_and_more'),
]

operations = [
migrations.AlterField(
model_name='element',
name='text',
field=models.TextField(blank=True, help_text="\nLinebreaks are turned into 'br' tags<br />\nUrls are turned into links<br />\nYou can use just 'check', 'yes', 'good' to place a checkmark icon.<br />\nYou can use 'bad', 'negative', 'evil', 'sucks', 'no' to place a negative icon.<br />\nPlus just '+' or '-' signs can be used but cap at 3 multiples to protect layout<br/>\n\n", max_length=1000, verbose_name='text'),
),
migrations.AlterField(
model_name='feature',
name='description',
field=models.TextField(blank=True, max_length=1000, verbose_name='Description'),
),
migrations.AlterField(
model_name='grid',
name='description',
field=models.TextField(blank=True, help_text='Lines are broken and urls are urlized', max_length=1000, verbose_name='Description'),
),
]
6 changes: 3 additions & 3 deletions grid/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class Grid(BaseModel):
_("Slug"), help_text="Slugs will be lowercased", unique=True
)
description = models.TextField(
_("Description"), blank=True, help_text="Lines are broken and urls are urlized", max_length=500
_("Description"), blank=True, help_text="Lines are broken and urls are urlized", max_length=1000
)
is_locked = models.BooleanField(
_("Is Locked"), default=False, help_text="Moderators can lock grid access"
Expand Down Expand Up @@ -124,7 +124,7 @@ class Feature(BaseModel):

grid = models.ForeignKey(Grid, on_delete=models.CASCADE)
title = models.CharField(_("Title"), max_length=100)
description = models.TextField(_("Description"), blank=True, max_length=500)
description = models.TextField(_("Description"), blank=True, max_length=1000)

def save(self, *args, **kwargs):
self.grid.grid_packages # fire the cache
Expand Down Expand Up @@ -156,7 +156,7 @@ class Element(BaseModel):

grid_package = models.ForeignKey(GridPackage, on_delete=models.CASCADE)
feature = models.ForeignKey(Feature, models.CASCADE)
text = models.TextField(_("text"), blank=True, help_text=help_text, max_length=500)
text = models.TextField(_("text"), blank=True, help_text=help_text, max_length=1000)

class Meta:

Expand Down
14 changes: 14 additions & 0 deletions package/migrations/0013_merge_20220306_1620.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Generated by Django 4.0.3 on 2022-03-06 16:20

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('package', '0011_package_date_repo_archived'),
('package', '0012_alter_category_description_alter_package_commit_list_and_more'),
]

operations = [
]
18 changes: 18 additions & 0 deletions package/migrations/0014_alter_package_repo_description.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 4.0.3 on 2022-03-06 16:43

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('package', '0013_merge_20220306_1620'),
]

operations = [
migrations.AlterField(
model_name='package',
name='repo_description',
field=models.TextField(blank=True, max_length=500, verbose_name='Repo Description'),
),
]
2 changes: 1 addition & 1 deletion package/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class Package(BaseModel):
category = models.ForeignKey(
Category, verbose_name="Installation", on_delete=models.PROTECT
)
repo_description = models.TextField(_("Repo Description"), blank=True)
repo_description = models.TextField(_("Repo Description"), blank=True, max_length=500)
repo_url = models.URLField(
_("repo URL"), help_text=repo_url_help_text, blank=True, unique=True
)
Expand Down

0 comments on commit 5463558

Please sign in to comment.