summaryrefslogtreecommitdiff
path: root/ishtar_common/migrations/0045_auto_20180418_1231.py
blob: 6b017e19444b581349716a484dc6b8cd8cb14356 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# -*- coding: utf-8 -*-
# Generated by Django 1.11.10 on 2018-04-18 12:31
from __future__ import unicode_literals

import django.core.validators
from django.db import migrations, models
import django.db.models.deletion
import ishtar_common.models
import re


class Migration(migrations.Migration):

    dependencies = [
        ('ishtar_common', '0044_add_import_group'),
    ]

    operations = [
        migrations.CreateModel(
            name='Area',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('label', models.TextField(verbose_name='Label')),
                ('txt_idx', models.TextField(help_text='The slug is the standardized version of the name. It contains only lowercase letters, numbers and hyphens. Each slug must be unique.', unique=True, validators=[django.core.validators.RegexValidator(re.compile('^[-a-zA-Z0-9_]+\\Z'), "Enter a valid 'slug' consisting of letters, numbers, underscores or hyphens.", 'invalid')], verbose_name='Textual ID')),
                ('comment', models.TextField(blank=True, null=True, verbose_name='Comment')),
                ('available', models.BooleanField(default=True, verbose_name='Available')),
                ('parent', models.ForeignKey(blank=True, help_text='Be careful, only three level of parent are managed.', null=True, on_delete=django.db.models.deletion.CASCADE, to='ishtar_common.Area', verbose_name='Parent')),
                ('towns', models.ManyToManyField(blank=True, to='ishtar_common.Town', verbose_name='Towns')),
            ],
            options={
                'verbose_name': 'Area',
                'verbose_name_plural': 'Areas',
            },
            bases=(ishtar_common.models.Cached, models.Model),
        ),
        migrations.AlterModelOptions(
            name='operationtype',
            options={'ordering': ['judiciary', '-preventive', 'order', 'label'], 'verbose_name': 'Operation type', 'verbose_name_plural': 'Operation types'},
        ),
    ]