Skip to content

Commit 9eef7b6

Browse files
authored
Merge pull request #86 from jwhitlock/choice-char-81
Change frequency.exact_times to character choices
2 parents ca19ee6 + 6a8b765 commit 9eef7b6

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# -*- coding: utf-8 -*-
2+
# Generated by Django 1.11.15 on 2018-08-26 20:41
3+
from __future__ import unicode_literals
4+
5+
from django.db import migrations, models
6+
7+
8+
class Migration(migrations.Migration):
9+
10+
dependencies = [
11+
('multigtfs', '0002_add_on_delete'),
12+
]
13+
14+
operations = [
15+
migrations.AlterField(
16+
model_name='frequency',
17+
name='exact_times',
18+
field=models.CharField(blank=True, choices=[('0', 'Trips are not exactly scheduled'), ('1', 'Trips are exactly scheduled from start time')], help_text='Should frequency-based trips be exactly scheduled?', max_length=1),
19+
),
20+
]

multigtfs/models/frequency.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ class Frequency(Base):
3333
help_text="Time in seconds before returning to same stop")
3434
exact_times = models.CharField(
3535
max_length=1, blank=True,
36-
choices=((0, 'Trips are not exactly scheduled'),
37-
(1, 'Trips are exactly scheduled from start time')),
36+
choices=(('0', 'Trips are not exactly scheduled'),
37+
('1', 'Trips are exactly scheduled from start time')),
3838
help_text="Should frequency-based trips be exactly scheduled?")
3939
extra_data = JSONField(default={}, blank=True, null=True)
4040

0 commit comments

Comments
 (0)