from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('config', '0011_clubminiappicon_is_uploaded'),
    ]

    operations = [
        migrations.CreateModel(
            name='MiniappScriptScene',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('club_id', models.CharField(db_index=True, default='xq', max_length=16, verbose_name='俱乐部ID')),
                ('scene_key', models.CharField(db_index=True, max_length=64, verbose_name='场景键')),
                ('title', models.CharField(blank=True, default='', max_length=128, verbose_name='标题')),
                ('content', models.TextField(blank=True, default='', verbose_name='正文')),
                ('confirm_text', models.CharField(blank=True, default='', max_length=16, verbose_name='确认按钮')),
                ('cancel_text', models.CharField(blank=True, default='', max_length=16, verbose_name='取消按钮')),
                ('enabled', models.BooleanField(default=True, verbose_name='启用')),
                ('CreateTime', models.DateTimeField(auto_now_add=True, verbose_name='创建时间')),
                ('UpdateTime', models.DateTimeField(auto_now=True, verbose_name='更新时间')),
            ],
            options={
                'verbose_name': '小程序场景话术',
                'verbose_name_plural': '小程序场景话术',
                'db_table': 'miniapp_script_scene',
                'unique_together': {('club_id', 'scene_key')},
            },
        ),
        migrations.CreateModel(
            name='MiniappScriptAutoReply',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('club_id', models.CharField(db_index=True, default='xq', max_length=16, verbose_name='俱乐部ID')),
                ('keyword', models.CharField(max_length=200, verbose_name='关键词')),
                ('reply_type', models.CharField(choices=[('text', '文本'), ('image', '图片')], default='text', max_length=16, verbose_name='回复类型')),
                ('reply_content', models.TextField(verbose_name='回复内容(文本或图片URL)')),
                ('sort_order', models.IntegerField(default=0, verbose_name='排序(大优先)')),
                ('enabled', models.BooleanField(default=True, verbose_name='启用')),
                ('CreateTime', models.DateTimeField(auto_now_add=True, verbose_name='创建时间')),
                ('UpdateTime', models.DateTimeField(auto_now=True, verbose_name='更新时间')),
            ],
            options={
                'verbose_name': '客服自动回复规则',
                'verbose_name_plural': '客服自动回复规则',
                'db_table': 'miniapp_script_auto_reply',
                'ordering': ['-sort_order', 'id'],
            },
        ),
    ]
