# Generated by Django 4.1 on 2022-11-03 22:20

import django.db.models.deletion
from django.db import migrations, models


class Migration(migrations.Migration):
    dependencies = [
        ("website", "0003_ownsite_delete_mysite_website_hr_website_sign_in_and_more"),
    ]

    operations = [
        migrations.AlterModelOptions(
            name="ownsite",
            options={
                "ordering": ["sort_id"],
                "verbose_name": "我的站点",
                "verbose_name_plural": "我的站点",
            },
        ),
        migrations.AddField(
            model_name="ownsite",
            name="user_agent",
            field=models.CharField(
                default="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.28",
                max_length=256,
                verbose_name="User-Agent",
            ),
        ),
        migrations.AddField(
            model_name="signin",
            name="method_sign",
            field=models.CharField(
                choices=[("post", "post"), ("get", "get")],
                default="get",
                max_length=1024,
                verbose_name="请求方式",
            ),
        ),
        migrations.AddField(
            model_name="signin",
            name="params_name_xpath",
            field=models.CharField(
                default="", max_length=1024, verbose_name="签到参数名称，使用英文逗号‘,’分割"
            ),
        ),
        migrations.AddField(
            model_name="signin",
            name="params_sign",
            field=models.CharField(default="", max_length=1024, verbose_name="签到参数"),
        ),
        migrations.AddField(
            model_name="signin",
            name="params_value_xpath",
            field=models.CharField(
                default="", max_length=1024, verbose_name="签到参数Value，使用英文逗号‘,’分割"
            ),
        ),
        migrations.AddField(
            model_name="signin",
            name="res_sign_xpath",
            field=models.CharField(
                default="", max_length=1024, verbose_name="签到信息Xpath"
            ),
        ),
        migrations.AddField(
            model_name="signin",
            name="site",
            field=models.OneToOneField(
                default="",
                on_delete=django.db.models.deletion.CASCADE,
                to="website.website",
                verbose_name="站点",
            ),
            preserve_default=False,
        ),
        migrations.AddField(
            model_name="signin",
            name="url_check",
            field=models.CharField(
                default="attendance.php", max_length=128, verbose_name="签到检测链接"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="assist",
            field=models.BooleanField(
                default=True, help_text="是否支持辅种", verbose_name="辅种"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="auto_login",
            field=models.BooleanField(
                default=False, help_text="是否支持自动登录并获取Cookie", verbose_name="自动登录"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="examine",
            field=models.BooleanField(
                default=True, help_text="是否支持新手考核信息比对", verbose_name="新手考核"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="info_capture",
            field=models.BooleanField(
                default=True, help_text="是否支持抓取信息", verbose_name="抓取信息"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="invite",
            field=models.BooleanField(
                default=True, help_text="是否支持邀请", verbose_name="邀请"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="search",
            field=models.BooleanField(
                default=True, help_text="是否支持聚合搜索", verbose_name="聚合搜索"
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="tags",
            field=models.CharField(
                default="",
                help_text="定义站点资源标签，使用英文逗号‘,’分割",
                max_length=128,
                verbose_name="标签",
            ),
        ),
        migrations.AddField(
            model_name="website",
            name="torrent_capture",
            field=models.BooleanField(
                default=True, help_text="是否支持抓取种子", verbose_name="抓取种子"
            ),
        ),
        migrations.AlterField(
            model_name="ownsite",
            name="cookie",
            field=models.TextField(verbose_name="Cookie"),
        ),
        migrations.AlterField(
            model_name="ownsite",
            name="passkey",
            field=models.CharField(
                blank=True, max_length=128, null=True, verbose_name="Passkey"
            ),
        ),
        migrations.CreateModel(
            name="AutoLogin",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "created_at",
                    models.DateTimeField(auto_now_add=True, verbose_name="创建时间"),
                ),
                (
                    "updated_at",
                    models.DateTimeField(auto_now=True, verbose_name="更新时间"),
                ),
                ("username", models.CharField(max_length=32, verbose_name="用户名")),
                ("password", models.CharField(max_length=32, verbose_name="密码")),
                ("captcha", models.CharField(max_length=16, verbose_name="验证码字段名")),
                (
                    "captcha_xpath",
                    models.CharField(max_length=128, verbose_name="验证码Xpath"),
                ),
                (
                    "site",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        to="website.website",
                        verbose_name="站点",
                    ),
                ),
            ],
            options={
                "verbose_name": "自动登录",
                "verbose_name_plural": "自动登录",
                "ordering": ["site"],
            },
        ),
    ]
