Skip to content

Commit

Permalink
Merge branch 'release/0.5.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
JackMorganNZ committed May 28, 2018
2 parents 576f591 + 43cbba9 commit 44b7573
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 5 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 0.5.1 (Pre-release)

- Fix bug where slug max length was too short for titles.

## 0.5.0 (Pre-release)

- Show pīkau titles on pathway diagram when required. (fixes #49)
Expand Down
2 changes: 1 addition & 1 deletion config/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""Module for Django system configuration."""

__version__ = "0.5.0"
__version__ = "0.5.1"
38 changes: 38 additions & 0 deletions pikau/migrations/0030_auto_20180529_0956.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Generated by Django 2.0.5 on 2018-05-28 21:56

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('pikau', '0029_auto_20180529_0726'),
]

operations = [
migrations.AlterField(
model_name='glossaryterm',
name='slug',
field=models.SlugField(help_text='A unique readable identifier', max_length=200, unique=True),
),
migrations.AlterField(
model_name='goal',
name='slug',
field=models.SlugField(max_length=200, unique=True),
),
migrations.AlterField(
model_name='pikaucourse',
name='slug',
field=models.SlugField(max_length=200, unique=True),
),
migrations.AlterField(
model_name='pikauunit',
name='slug',
field=models.SlugField(max_length=200),
),
migrations.AlterField(
model_name='tag',
name='slug',
field=models.SlugField(max_length=200, unique=True),
),
]
9 changes: 5 additions & 4 deletions pikau/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ class GlossaryTerm(models.Model):
# Auto-incrementing 'id' field is automatically set by Django
slug = models.SlugField(
unique=True,
max_length=200,
help_text="A unique readable identifier",
)
term = models.CharField(max_length=200, unique=True)
Expand Down Expand Up @@ -99,7 +100,7 @@ class Goal(models.Model):
"""Model for goal."""

# Auto-incrementing 'id' field is automatically set by Django
slug = models.SlugField(unique=True)
slug = models.SlugField(unique=True, max_length=200)
description = models.CharField(max_length=500, unique=True)

def __str__(self):
Expand All @@ -115,7 +116,7 @@ class Tag(models.Model):
"""Model for tag."""

# Auto-incrementing 'id' field is automatically set by Django
slug = models.SlugField(unique=True)
slug = models.SlugField(unique=True, max_length=200)
name = models.CharField(max_length=100, unique=True)
description = models.CharField(max_length=300, blank=True)

Expand Down Expand Up @@ -191,7 +192,7 @@ class PikauCourse(models.Model):
"""Model for Pikau Course."""

# Auto-incrementing 'id' field is automatically set by Django
slug = models.SlugField(unique=True)
slug = models.SlugField(unique=True, max_length=200)
name = models.CharField(max_length=200, unique=True)
language = models.CharField(max_length=20, choices=LANGUAGE_CHOICES)
readiness_level = models.IntegerField(
Expand Down Expand Up @@ -291,7 +292,7 @@ def __str__(self):
class PikauUnit(models.Model):
"""Model for Pikau Unit."""

slug = models.SlugField()
slug = models.SlugField(max_length=200)
number = models.PositiveSmallIntegerField()
pikau_course = models.ForeignKey(
PikauCourse,
Expand Down

0 comments on commit 44b7573

Please sign in to comment.