Skip to content
Snippets Groups Projects
Commit 3b440733 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

db migration including color change for flying team

parent 2bfc316e
No related branches found
No related tags found
1 merge request!37Custom calendar colors for appointment location and appointment status
Pipeline #
# -*- coding: utf-8 -*-
# Generated by Django 1.10.3 on 2017-04-04 09:43
from __future__ import unicode_literals
from django.db import migrations
def configuration_item_color_fields(apps, schema_editor):
# We can't import the Location model directly as it may be a newer
# version than this migration expects. We use the historical version.
Location = apps.get_model("web", "Location")
locations = Location.objects.filter(name="Flying Team")
for location in locations:
location.color = "#FF8000"
class Migration(migrations.Migration):
dependencies = [
('web', '0027_auto_20170404_1505'),
]
operations = [
migrations.RunPython(configuration_item_color_fields),
]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment