# -*- coding: utf-8 -*-
# Generated by Django 1.10.6 on 2017-04-27 05:37
from __future__ import unicode_literals

from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('experchat', '0005_ecsession_card'),
    ]

    operations = [
        migrations.CreateModel(
            name='PromoCode',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_timestamp', models.DateTimeField(auto_now_add=True, verbose_name='created timestamp')),
                ('modified_timestamp', models.DateTimeField(auto_now=True, verbose_name='modified timestamp')),
                ('promo_code_type', models.CharField(choices=[('promo', 'Promo'), ('credit', 'Credit')], max_length=20, verbose_name='promo code type')),
                ('value_type', models.CharField(choices=[('percent%', 'Percentage(%) Offer'), ('fixed price', 'Fixed Price Offer')], max_length=20, verbose_name='value type')),
                ('value', models.IntegerField(verbose_name='value')),
                ('start_datetime', models.DateTimeField(blank=True, null=True, verbose_name='start datetime')),
                ('expiry_datetime', models.DateTimeField(blank=True, null=True, verbose_name='expiry datetime')),
                ('usage_limit', models.PositiveIntegerField(default=1, verbose_name='usage limit')),
                ('description', models.TextField(blank=True, max_length=500, null=True, verbose_name='description')),
                ('coupon_code', models.CharField(max_length=20, unique=True, verbose_name='coupon code')),
                ('status', models.PositiveIntegerField(choices=[(1, 'Active'), (2, 'Inactive')], default=1, verbose_name='status')),
                ('is_deleted', models.BooleanField(default=False, verbose_name='is deleted')),
                ('allowed_experts', models.ManyToManyField(blank=True, related_name='promo_codes', to='experchat.Expert', verbose_name='allowed experts')),
                ('allowed_users', models.ManyToManyField(blank=True, related_name='promo_codes', to='experchat.User', verbose_name='allowed users')),
            ],
            options={
                'verbose_name': 'Promo Codes',
            },
        ),
    ]
