class ComputeInterface(models.Model): ip = models.GenericIPAddressField(default='0.0.0.0', null=True) netmask = models.GenericIPAddressField(default='0.0.0.0', null=True) mac = models.CharField(max_length=17, default='', unique=True) compute = models.ForeignKey(Compute, related_name='interface') iface = models.CharField(max_length=64, default='') subnet = models.CharField(max_length=64, null=True) class Meta: managed = True
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='Usuario', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(default='', max_length=30, unique=True, verbose_name='Nome do Usuario')), ('name', models.CharField(blank=True, max_length=50, verbose_name='Nome')), ('email', models.EmailField(default='', max_length=254, verbose_name='Email')), ('is_active', models.BooleanField(blank=True, default=True, verbose_name='Esta ativo')), ('is_staff', models.BooleanField(blank=True, default=False, verbose_name='Master')), ('access', models.IntegerField(blank=True, null=True)), ('ip_last', models.GenericIPAddressField(blank=True, null=True)), ('ip_actual', models.GenericIPAddressField(blank=True, null=True)), ('date_joined', models.DateTimeField(auto_now_add=True, verbose_name='Criando em')), ('update_at', models.DateTimeField(auto_now=True, verbose_name='Atualizado em')), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'Usuário', 'verbose_name_plural': 'Usuários', 'ordering': ['name'], }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='PasswordReset', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('key', models.CharField(max_length=100, unique=True, verbose_name='Chave')), ('created_at', models.DateTimeField(auto_now_add=True, verbose_name='Criado em')), ('confirmed', models.BooleanField(blank=True, default=False, verbose_name='Confirmado')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='resets', to=settings.AUTH_USER_MODEL, verbose_name='Usuario')), ], options={ 'verbose_name': 'Nova Senha', 'verbose_name_plural': 'Novas Senhas', 'ordering': ['-created_at'], }, ), ]
class Comment(models.Model): comment = models.TextField(max_length=80) user = models.ForeignKey(User, blank=True, null=True, related_name="commenter") comment_author = models.CharField(max_length=30) article = models.ForeignKey(Article) parent = models.ForeignKey("self", on_delete=models.CASCADE, blank=True, null=True, related_name="children") comment_date = models.DateTimeField(auto_now_add=True) comment_author_ip = models.GenericIPAddressField(blank=True, null=True) comment_author_email = models.EmailField(blank=True, null=True) comment_modify_date = models.DateTimeField(auto_now=True) comment_status_choice = ( ('1', 'open'), ('2', 'close'), ) comment_status = models.CharField( max_length=1, choices=comment_status_choice, default='2', )
class DataSetDownloadLog(models.Model): """Logs archive downloads""" user = models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=models.DO_NOTHING) dataset = models.ForeignKey(DataSet, on_delete=models.DO_NOTHING) dataset_status = models.IntegerField( choices=STATUS_CHOICES) # (draft [DEFAULT], submitted, approved) request_url = models.CharField(max_length=256) datetime = models.DateTimeField(editable=False, auto_now_add=True) ip_address = models.GenericIPAddressField(blank=True, null=True)
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('last_login_ip', models.GenericIPAddressField(blank=True, null=True, unpack_ipv4=True, verbose_name='最近一次登陆IP')), ('ip_joined', models.GenericIPAddressField(blank=True, null=True, unpack_ipv4=True, verbose_name='注册IP')), ('nickname', models.CharField(max_length=50, unique=True, verbose_name='昵称')), ('mugshot', models.ImageField(upload_to=users.models.user_mugshot_path, verbose_name='头像')), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('username', models.CharField(max_length=32, unique=True)), ('password', models.CharField(max_length=32)), ('name', models.CharField(max_length=32)), ('role', models.IntegerField(choices=[(1, 'admin'), (2, 'user')], default=1)), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Host', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('host_name', models.CharField(max_length=32, unique=True)), ('state', models.IntegerField(choices=[(1, '在线'), (2, '下线')], default=1)), ('kind', models.IntegerField(choices=[(1, '服务器'), (2, '防火墙'), (3, '路由器'), (4, '交换机')], default=1)), ('ip', models.GenericIPAddressField(unique=True)), ('username', models.CharField(max_length=32)), ('password', models.CharField(max_length=32)), ], ), migrations.CreateModel( name='HostGroup', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=32, unique=True)), ], ), migrations.AddField( model_name='host', name='group_id', field=models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, to='host_manage.HostGroup'), ), migrations.AddField( model_name='user', name='host', field=models.ManyToManyField(blank=True, to='host_manage.Host'), ), migrations.AddField( model_name='user', name='host_group', field=models.ManyToManyField(blank=True, to='host_manage.HostGroup'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('cellphone', models.CharField(blank=True, max_length=11, null=True, verbose_name='手机号码')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Group_Permission', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(default='x', max_length=40, verbose_name='权限操作名')), ('codename', models.CharField(default='x', max_length=40, verbose_name='操作名')), ], ), migrations.CreateModel( name='Host', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('client_id', models.CharField(max_length=40, verbose_name='主机ID')), ('host_ip', models.GenericIPAddressField(default='0.0.0.0', verbose_name='IP地址')), ('active_time', models.IntegerField(default='x', verbose_name='激活时间')), ], ), migrations.CreateModel( name='Host_Group', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=40, verbose_name='组名')), ], ), migrations.CreateModel( name='Accesstoken', fields=[ ('host', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='oauthServer.Host')), ('is_alive', models.IntegerField(default=1, verbose_name='是否生存')), ('access_token', models.CharField(default='x', max_length=40, verbose_name='授权码')), ('exptime', models.IntegerField(default='x', verbose_name='过期时间')), ], ), migrations.CreateModel( name='Authcode_log', fields=[ ('host', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='oauthServer.Host')), ('response_type', models.CharField(max_length=40, verbose_name='')), ('redirect_uri', models.CharField(max_length=40, verbose_name='')), ('scope', models.CharField(max_length=40, verbose_name='')), ('state', models.CharField(default='x', max_length=40, verbose_name='')), ('auth_code', models.CharField(default='x', max_length=40, verbose_name='授权码')), ('exptime', models.IntegerField(default='x', verbose_name='过期时间')), ], ), migrations.CreateModel( name='Host_Group_Permissions', fields=[ ('host_group', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='oauthServer.Host_Group')), ('group_permissions', models.ManyToManyField(to='oauthServer.Group_Permission')), ], ), migrations.CreateModel( name='Refreshtoken', fields=[ ('host', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='oauthServer.Host')), ('is_alive', models.IntegerField(default=1, verbose_name='是否生存')), ('refresh_token', models.CharField(default='x', max_length=40, verbose_name='刷新码')), ('exptime', models.IntegerField(default='x', verbose_name='过期时间')), ], ), migrations.AddField( model_name='host', name='user', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='授权人'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('steamid', models.CharField(max_length=17, null=True)), ('ip', models.GenericIPAddressField(null=True)), ('avatar', models.URLField(null=True)), ('profile', models.URLField(null=True)), ], options={ 'permissions': [('view_user', 'View users'), ('kick_user', 'Kick a user'), ('search_user', 'Search for users')], }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Ban', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('reason', models.CharField(max_length=255)), ('length', models.DurationField()), ('resolved', models.BooleanField(default=False)), ('issuer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='ban_issuer', to=settings.AUTH_USER_MODEL)), ], options={ 'permissions': [('view_ban', 'View bans'), ('modify_ban', 'Edit a ban')], }, ), migrations.CreateModel( name='Chat', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('ip', models.GenericIPAddressField()), ('message', models.CharField(max_length=255)), ('command', models.BooleanField(default=False)), ], options={ 'permissions': [('view_chat', 'View chat logs'), ('view_chat_ip', 'View ip of someone in chat logs'), ('view_chat_server', 'View current server of someone in chat logs'), ('view_chat_time', 'View current time of message in chat logs')], }, ), migrations.CreateModel( name='Country', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('code', models.CharField(max_length=2, unique=True)), ('name', models.CharField(max_length=100, null=True)), ], options={ 'abstract': False, }, ), migrations.CreateModel( name='Log', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('action', models.CharField(max_length=255)), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'permissions': [('view_admin_log', 'View server logs')], }, ), migrations.CreateModel( name='Mutegag', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('type', models.CharField(choices=[('MU', 'mute'), ('GA', 'gag'), ('BO', 'both')], default='MU', max_length=2)), ('reason', models.CharField(max_length=255)), ('length', models.DurationField()), ('resolved', models.BooleanField(default=False)), ('issuer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='mutegag_issuer', to=settings.AUTH_USER_MODEL)), ], options={ 'permissions': [('view_mutegag', 'View mutegags'), ('add_mutegag_mute', 'Add mutegag mutes'), ('add_mutegag_gag', 'Add mutegag gags'), ('modify_mutegag', 'Edit mutegags')], }, ), migrations.CreateModel( name='PanelGroup', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('name', models.CharField(max_length=255)), ('flags', models.CharField(max_length=25)), ('immunity', models.DurationField()), ('usetime', models.DurationField()), ('isadmingroup', models.BooleanField(default=False)), ], options={ 'permissions': [('view_admin_group', 'View server groups'), ('add_admin_group', 'Add server groups'), ('modify_admin_group', 'Edit server groups'), ('delete_admin_group', 'Delete server groups')], }, ), migrations.CreateModel( name='PanelPermission', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('can_reservation', models.BooleanField(default=False)), ('can_generic', models.BooleanField(default=False)), ('can_ban', models.BooleanField(default=False)), ('can_slay', models.BooleanField(default=False)), ('can_map', models.BooleanField(default=False)), ('can_cvar', models.BooleanField(default=False)), ('can_vote', models.BooleanField(default=False)), ('can_password', models.BooleanField(default=False)), ('can_rcon', models.BooleanField(default=False)), ('can_cheat', models.BooleanField(default=False)), ], options={ 'abstract': False, }, ), migrations.CreateModel( name='Server', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('name', models.CharField(max_length=255)), ('ip', models.GenericIPAddressField()), ('port', models.IntegerField()), ('password', models.CharField(max_length=255)), ], options={ 'permissions': [('view_server', 'View the servers'), ('modify_server', 'Edit a server')], }, ), migrations.CreateModel( name='ServerRole', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('group', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.PanelGroup')), ('server', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.Server')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'permissions': [('view_admin_role', 'View server roles'), ('add_admin_role', 'Add server roles'), ('modify_admin_role', 'Edit server roles'), ('delete_admin_role', 'Delete server roles')], }, ), migrations.CreateModel( name='UserLogIP', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('ip', models.GenericIPAddressField()), ('connections', models.IntegerField(default=0)), ('active', models.BooleanField(default=False)), ('last_used', models.DateTimeField(auto_now=True)), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'abstract': False, }, ), migrations.CreateModel( name='UserLogTime', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('connected', models.DateTimeField(auto_now_add=True)), ('disconnected', models.DateTimeField()), ('server', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.Server')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'abstract': False, }, ), migrations.CreateModel( name='UserLogUsername', fields=[ ('id', models.UUIDField(auto_created=True, default=uuid.uuid4, editable=False, primary_key=True, serialize=False, unique=True)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('username', models.CharField(max_length=128)), ('connections', models.IntegerField()), ('last_used', models.DateTimeField()), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'abstract': False, }, ), migrations.AlterUniqueTogether( name='server', unique_together={('ip', 'port')}, ), migrations.AddField( model_name='panelgroup', name='permissions', field=models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, to='core.PanelPermission'), ), migrations.AddField( model_name='mutegag', name='server', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='core.Server'), ), migrations.AddField( model_name='mutegag', name='user', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='chat', name='server', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='core.Server'), ), migrations.AddField( model_name='chat', name='user', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='ban', name='server', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='core.Server'), ), migrations.AddField( model_name='ban', name='user', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='user', name='country', field=models.ForeignKey( null=True, on_delete=django.db.models.deletion.CASCADE, to='core.Country'), ), migrations.AddField( model_name='user', name='groups', field=models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators.ASCIIUsernameValidator( ) ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('department', models.IntegerField(blank=True, choices=[(1, '\u5ba1\u6838\u90e8'), (2, '\u8d22\u52a1\u90e8'), (3, '\u50ac\u6536\u90e8')], help_text='\u90e8\u95e8\u540d\u79f0', null=True, verbose_name='\u90e8\u95e8\u540d\u79f0')), ('name', models.CharField(help_text='\u59d3\u540d', max_length=50, verbose_name='\u59d3\u540d')), ('identity', models.CharField(blank=True, help_text='\u8eab\u4efd\u8bc1\u53f7', max_length=30, null=True, verbose_name='\u8eab\u4efd\u8bc1\u53f7')), ('tel', models.CharField(blank=True, help_text='\u7535\u8bdd', max_length=50, null=True, verbose_name='\u7535\u8bdd')), ('qq', models.CharField(help_text='QQ', max_length=50, verbose_name='QQ')), ('wechat', models.CharField(blank=True, help_text='\u5fae\u4fe1', max_length=50, null=True, verbose_name='\u5fae\u4fe1')), ('is_boss', models.BooleanField(default=False, help_text='\u7ba1\u7406\u5458', verbose_name='\u7ba1\u7406\u5458')), ], options={ 'abstract': False, 'verbose_name': 'user', 'verbose_name_plural': 'users', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='AuditModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('note', models.TextField(blank=True, verbose_name='\u5ba1\u6838\u7b14\u8bb0')), ('time', models.DateTimeField( auto_now=True, verbose_name='\u5ba1\u6838\u65f6\u95f4')), ], ), migrations.CreateModel( name='ChannelModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(help_text='\u6e20\u9053\u540d\u79f0', max_length=50, verbose_name='\u6e20\u9053\u540d\u79f0')), ('identification', models.CharField(default=uuid.uuid1, help_text='\u6807\u8bc6\u7801', max_length=255, unique=True, verbose_name='\u6807\u8bc6\u7801')), ('create_time', models.DateTimeField(auto_now=True)), ], options={ 'verbose_name': '\u6e20\u9053\u4fe1\u606f', 'verbose_name_plural': '\u6e20\u9053\u7ba1\u7406', }, ), migrations.CreateModel( name='CheckWayModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=50, verbose_name='\u540d\u79f0')), ('namecode', models.CharField(max_length=50, verbose_name='\u6e20\u9053\u4ee3\u7801')), ], options={ 'verbose_name': '\u5ba1\u6838\u9014\u5f84', 'verbose_name_plural': '\u5ba1\u6838\u9014\u5f84', }, ), migrations.CreateModel( name='CompanyModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(help_text='\u516c\u53f8\u540d\u79f0', max_length=50, unique=True, verbose_name='\u516c\u53f8\u540d\u79f0')), ('contact', models.CharField(help_text='\u8054\u7cfb\u65b9\u5f0f', max_length=50, verbose_name='\u8054\u7cfb\u65b9\u5f0f')), ('balance', models.FloatField(default=0.0, verbose_name='\u8d26\u6237\u4f59\u989d')), ('possessor', models.CharField(max_length=50, verbose_name='\u6240\u6709\u4eba')), ('identity', models.CharField(help_text='\u8eab\u4efd\u8bc1\u53f7', max_length=30, verbose_name='\u8eab\u4efd\u8bc1\u53f7')), ('status', models.BooleanField(default=True, verbose_name='\u542f\u7528')), ('remark', models.TextField(blank=True, verbose_name='\u5907\u6ce8')), ('create_time', models.DateTimeField( auto_now=True, verbose_name='\u521b\u5efa\u65f6\u95f4')), ('h5_first_background', models.ImageField(default='img/h5/background1.png', upload_to='img/h5', verbose_name='\u4e3b\u80cc\u666f\u56fe')), ('h5_second_background', models.ImageField(default='img/h5/background2.png', upload_to='img/h5', verbose_name='\u6b21\u80cc\u666f\u56fe')), ('check_ways', models.ManyToManyField( related_name='companys', to='yunhu.CheckWayModel', verbose_name='\u5ba1\u67e5\u65b9\u5f0f')), ], options={ 'verbose_name': '\u516c\u53f8\u4fe1\u606f', 'verbose_name_plural': '\u516c\u53f8\u7ba1\u7406', }, ), migrations.CreateModel( name='CustomerLoginInfoModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('ip', models.GenericIPAddressField(verbose_name='IP')), ('login_time', models.DateTimeField(auto_now=True)), ], ), migrations.CreateModel( name='CustomerModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(help_text='\u59d3\u540d', max_length=50, verbose_name='\u59d3\u540d')), ('tel', models.CharField(blank=True, max_length=50, null=True, verbose_name='\u7535\u8bdd')), ('identity', models.CharField(blank=True, help_text='\u8eab\u4efd\u8bc1\u53f7', max_length=30, null=True, verbose_name='\u8eab\u4efd\u8bc1\u53f7')), ('zhima_score', models.CharField( blank=True, max_length=50, verbose_name='\u829d\u9ebb\u4fe1\u7528\u5206')), ('wechat', models.CharField(blank=True, max_length=50, null=True, verbose_name='\u5fae\u4fe1')), ('zone', models.CharField(blank=True, max_length=50, null=True, verbose_name='\u6240\u5728\u5730\u533a')), ('address', models.CharField(blank=True, max_length=50, null=True, verbose_name='\u8be6\u7ec6\u4f4f\u5740')), ('idcard_backpic', models.ImageField( blank=True, help_text='\u8eab\u4efd\u8bc1\u53cd\u9762', null=True, upload_to='customer/idcard', verbose_name='\u8eab\u4efd\u8bc1\u53cd\u9762')), ('idcard_pic', models.ImageField( blank=True, help_text='\u8eab\u4efd\u8bc1\u6b63\u9762', null=True, upload_to='customer/idcard', verbose_name='\u8eab\u4efd\u8bc1\u6b63\u9762')), ('idcard_people_pic', models.ImageField( blank=True, help_text='\u624b\u6301\u8eab\u4efd\u8bc1', null=True, upload_to='customer/idcard', verbose_name='\u624b\u6301\u8eab\u4efd\u8bc1')), ('father_name', models.CharField(blank=True, max_length=50, verbose_name='\u7236\u4eb2\u59d3\u540d')), ('father_tel', models.CharField(blank=True, max_length=50, verbose_name='\u7236\u4eb2\u7535\u8bdd')), ('mother_name', models.CharField(blank=True, max_length=50, verbose_name='\u6bcd\u4eb2\u59d3\u540d')), ('mother_tel', models.CharField(blank=True, max_length=50, verbose_name='\u6bcd\u4eb2\u7535\u8bdd')), ('friend_name', models.CharField(blank=True, max_length=50, verbose_name='\u670b\u53cb\u59d3\u540d')), ('friend_tel', models.CharField(blank=True, max_length=50, verbose_name='\u670b\u53cb\u7535\u8bdd')), ('colleague_name', models.CharField(blank=True, max_length=50, verbose_name='\u540c\u4e8b\u59d3\u540d')), ('colleague_tel', models.CharField(blank=True, max_length=50, verbose_name='\u540c\u4e8b\u7535\u8bdd')), ('company_name', models.CharField(blank=True, max_length=50, verbose_name='\u516c\u53f8\u540d\u79f0')), ('company_tel', models.CharField(blank=True, max_length=50, verbose_name='\u516c\u53f8\u7535\u8bdd')), ('company_address', models.CharField(blank=True, max_length=50, verbose_name='\u516c\u53f8\u5730\u5740')), ('company_salary', models.CharField(blank=True, max_length=50, verbose_name='\u85aa\u6c34')), ('zfb_score_pic', models.ImageField( blank=True, upload_to='customer/zfb', verbose_name= '\u652f\u4ed8\u5b9d\u829d\u9ebb\u4fe1\u7528\u5206\u6570\u9875' )), ('zfb_manage_pic', models.ImageField( blank=True, upload_to='customer/zfb', verbose_name='\u652f\u4ed8\u5b9d\u7ba1\u7406\u9875')), ('chsi', models.BooleanField(default=False, verbose_name='\u5b66\u4fe1\u8ba4\u8bc1')), ('mno', models.BooleanField( default=False, verbose_name='\u8fd0\u8425\u5546\u8ba4\u8bc1')), ('maimai', models.BooleanField(default=False, verbose_name='\u8109\u8109\u8ba4\u8bc1')), ('rhzx', models.BooleanField( default=False, verbose_name='\u4eba\u884c\u5f81\u4fe1\u8ba4\u8bc1')), ('jd', models.BooleanField(default=False, verbose_name='\u4eac\u4e1c\u8ba4\u8bc1')), ('tb', models.BooleanField(default=False, verbose_name='\u6dd8\u5b9d\u8ba4\u8bc1')), ('gjj', models.BooleanField( default=False, verbose_name='\u516c\u79ef\u91d1\u8ba4\u8bc1')), ('create_time', models.DateTimeField( auto_now=True, verbose_name='\u7533\u8bf7\u65f6\u95f4')), ('audit_status', models.IntegerField(choices=[(1, '\u5f85\u5ba1\u6838'), (2, '\u62d2\u7edd\u53d7\u7406'), (3, '\u5ba1\u6838\u901a\u8fc7'), (4, '\u9700\u8981\u590d\u5ba1'), (5, '\u5df2\u653e\u6b3e'), (6, '\u7eed\u671f'), (7, '\u7ed3\u6e05')], default=1, help_text='\u5ba1\u6838\u72b6\u6001', verbose_name='\u5ba1\u6838\u72b6\u6001')), ('is_black', models.BooleanField( default=False, help_text='\u7528\u6237\u8fdb\u5165\u9ed1\u540d\u5355', verbose_name='\u62c9\u9ed1')), ('blcak_reason', models.TextField(blank=True, null=True, verbose_name='\u62c9\u9ed1\u539f\u56e0')), ('channel', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='customer_channel', to='yunhu.ChannelModel', verbose_name='\u6e20\u9053')), ], ), migrations.CreateModel( name='ExpenseModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('detail', models.TextField(verbose_name='\u6d88\u8d39\u8bf4\u660e')), ('create_time', models.DateTimeField( auto_now=True, verbose_name='\u6d88\u8d39\u65f6\u95f4')), ('amount', models.FloatField(verbose_name='\u6d88\u8d39\u91d1\u989d')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='\u6d88\u8d39\u7528\u6237')), ], ), migrations.CreateModel( name='LonasModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('note', models.TextField(blank=True, verbose_name='\u653e\u6b3e\u7b14\u8bb0')), ('practical_blance', models.FloatField(default=0.0, help_text='\u5b9e\u501f\u91d1\u989d', verbose_name='\u5b9e\u501f\u91d1\u989d')), ('lona_time', models.DateField(auto_now=True, verbose_name='\u653e\u6b3e\u65f6\u95f4')), ('refund_time', models.DateField(blank=True, help_text='\u9ed8\u8ba47\u5929', verbose_name='\u8fd8\u6b3e\u65f6\u95f4')), ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='lona_customer', to='yunhu.CustomerModel', verbose_name='\u5ba2\u6237')), ('user', models.ForeignKey(blank=True, help_text='\u653e\u6b3e\u5ba2\u6237', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='loan_user', to=settings.AUTH_USER_MODEL, verbose_name='\u653e\u6b3e\u4eba')), ], ), migrations.CreateModel( name='TelCheckModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('tel', models.CharField(max_length=11, verbose_name='\u624b\u673a\u53f7')), ('code', models.CharField(max_length=50, verbose_name='\u9a8c\u8bc1\u7801')), ('create_time', models.DateTimeField(auto_now=True)), ], ), migrations.CreateModel( name='UrgeModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('note', models.TextField(blank=True, verbose_name='\u50ac\u6b3e\u7b14\u8bb0')), ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='urge_customer', to='yunhu.CustomerModel', verbose_name='\u5ba2\u6237')), ('user', models.ForeignKey(blank=True, help_text='\u50ac\u6b3e\u5ba2\u6237', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='urge_user', to=settings.AUTH_USER_MODEL, verbose_name='\u50ac\u6b3e\u4eba')), ], ), migrations.AddField( model_name='customerlogininfomodel', name='customer', field=models.ForeignKey( help_text='\u5ba2\u6237', on_delete=django.db.models.deletion.CASCADE, related_name='login_info', to='yunhu.CustomerModel', verbose_name='\u5ba2\u6237'), ), migrations.AddField( model_name='channelmodel', name='check_ways', field=models.ManyToManyField( related_name='check_way_channels', to='yunhu.CheckWayModel', verbose_name='\u8ba4\u8bc1\u65b9\u5f0f'), ), migrations.AddField( model_name='channelmodel', name='company', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='company_channels', to='yunhu.CompanyModel', verbose_name='\u6240\u5c5e\u516c\u53f8'), ), migrations.AddField( model_name='auditmodel', name='customer', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='audit_customer', to='yunhu.CustomerModel', verbose_name='\u5ba2\u6237'), ), migrations.AddField( model_name='auditmodel', name='user', field=models.ForeignKey( blank=True, help_text='\u5ba1\u6838\u5ba2\u6237', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='audit_user', to=settings.AUTH_USER_MODEL, verbose_name='\u5ba1\u6838\u4eba'), ), migrations.AddField( model_name='user', name='channels', field=models.ManyToManyField( related_name='channels_users', to='yunhu.ChannelModel', verbose_name='\u8d1f\u8d23\u6e20\u9053'), ), migrations.AddField( model_name='user', name='company', field=models.ForeignKey( help_text='\u6240\u5c5e\u516c\u53f8', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='comany_users', to='yunhu.CompanyModel', verbose_name='\u6240\u5c5e\u516c\u53f8'), ), migrations.AddField( model_name='user', name='groups', field=models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), migrations.AlterUniqueTogether( name='customerlogininfomodel', unique_together=set([('customer', 'ip')]), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('birthday', models.DateField(blank=True, help_text='出生年月', null=True, verbose_name='出生年月')), ('add_time', models.DateField(default=datetime.datetime.now, help_text='添加时间', verbose_name='添加时间')), ('update_time', models.DateField(default=datetime.datetime.now, help_text='更新时间', verbose_name='更新时间')), ('is_delete', models.BooleanField(default=False, help_text='是否删除', verbose_name='是否删除')), ('sex', models.IntegerField(choices=[(1, '男'), (2, '女'), (3, '未知')], default=3, help_text='性别: 1(男),2(女),3(未知)', verbose_name='性别')), ('phone', models.CharField(blank=True, help_text='手机', max_length=11, null=True, verbose_name='手机')), ('icon', models.ImageField(blank=True, default='/static/images/avater.jpg', help_text='头像', null=True, upload_to='static/images/friend', verbose_name='头像')), ('desc', models.CharField(blank=True, default='', help_text='描述', max_length=100, null=True, verbose_name='描述')), ('github', models.CharField(blank=True, default='', help_text='github', max_length=100, null=True, verbose_name='github')), ('qq', models.CharField(blank=True, default='', help_text='qq', max_length=100, null=True, verbose_name='qq')), ('other_link', models.CharField(blank=True, default='', help_text='其他链接', max_length=100, null=True, verbose_name='其他链接')), ('last_login_ip', models.GenericIPAddressField(blank=True, null=True, unpack_ipv4=True, verbose_name='最近ip')), ('ip_joined', models.GenericIPAddressField(blank=True, null=True, unpack_ipv4=True, verbose_name='注册')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': '用户', 'verbose_name_plural': '用户', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('contenttypes', '0002_remove_content_type_name'), ('auth', '0011_update_proxy_permissions'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('user_group', models.CharField(choices=[('Student', 'Student'), ('Admin', 'Admin'), ('SuperAdmin', 'SuperAdmin')], default='Student', max_length=10)), ('last_login_time', models.DateTimeField(auto_now=True)), ('last_login_ip', models.GenericIPAddressField(null=True)), ('is_banned', models.BooleanField(default=False)), ('question_banks', django.contrib.postgres.fields.ArrayField( base_field=models.IntegerField(), size=None)), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='KnowledgeNode', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(default='unnamed node', max_length=200)), ('polymorphic_ctype', models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.knowledgenode_set+', to='contenttypes.ContentType')), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.CreateModel( name='Paper', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('title', models.CharField(default='unmaned paper', max_length=200)), ('total_point', models.IntegerField(default=100)), ('tips', models.CharField(default='', max_length=200)), ('status', models.CharField(default='drafted', max_length=200)), ('is_latest', models.BooleanField(default=True)), ('time_limit', models.IntegerField(default=0)), ('have_brief_ans', models.BooleanField(default=True)), ('polymorphic_ctype', models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.paper_set+', to='contenttypes.ContentType')), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.CreateModel( name='PaperRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('record_time', models.DateTimeField(auto_now=True)), ('need_judging', models.BooleanField(default=True)), ('is_timed', models.BooleanField(default=False)), ('start_time', models.DateTimeField(auto_now=True)), ('time_left', models.IntegerField(default=0)), ('is_active', models.BooleanField(default=True)), ('user_total_points', models.IntegerField(default=0)), ('paper', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='backend.Paper')), ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='Profile', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('school_name', models.CharField(blank=True, max_length=100)), ], ), migrations.CreateModel( name='Question', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('question_name', models.CharField(max_length=200)), ('question_type', models.IntegerField()), ('question_level', models.IntegerField(default=0)), ('question_change_time', models.DateTimeField()), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.CreateModel( name='QuestionBank', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('root_id', models.IntegerField()), ('name', models.CharField(max_length=200)), ('picture', models.CharField(max_length=10000000)), ('brief', models.CharField(max_length=20000)), ('createTime', models.DateTimeField()), ('lastUpdate', models.DateTimeField()), ('authority', models.CharField(max_length=200)), ('question_count', models.IntegerField()), ('invitation_code_count', models.IntegerField()), ('activated_code_count', models.IntegerField()), ('polymorphic_ctype', models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.questionbank_set+', to='contenttypes.ContentType')), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.CreateModel( name='QuestionVersion', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('question_point', models.IntegerField(default=0)), ('point_every_blank', django.contrib.postgres.fields.ArrayField( base_field=models.IntegerField(), default=list, size=None)), ('question_num', models.IntegerField()), ('polymorphic_ctype', models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.questionversion_set+', to='contenttypes.ContentType')), ('question', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='backend.Question')), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.CreateModel( name='UserPermissions', fields=[ ('group_name', models.CharField(max_length=20, primary_key=True, serialize=False)), ('view_students', models.BooleanField(default=False)), ('create_students', models.BooleanField(default=False)), ('ban_students', models.BooleanField(default=False)), ('view_admins', models.BooleanField(default=False)), ('create_admins', models.BooleanField(default=False)), ('ban_admins', models.BooleanField(default=False)), ('change_user_group', models.BooleanField(default=False)), ], ), migrations.CreateModel( name='BriefAnswerQ', fields=[ ('question_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.Question')), ('question_content', models.CharField(default='', max_length=20000)), ('question_image', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(default='', max_length=10000000), size=None)), ('question_ans', models.CharField(default='', max_length=20000)), ('question_solution', models.CharField(default='', max_length=20000)), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, bases=('backend.question', ), ), migrations.CreateModel( name='ChoiceQ', fields=[ ('question_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.Question')), ('question_content', models.CharField(max_length=20000)), ('question_image', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=10000000), size=None)), ('question_choice', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=20000), size=None)), ('question_solution', models.CharField(max_length=20000)), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, bases=('backend.question', ), ), migrations.CreateModel( name='FillBlankQ', fields=[ ('question_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.Question')), ('question_content', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=20000), size=None)), ('question_blank_num', models.IntegerField()), ('question_image', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=10000000), size=None)), ('question_ans', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=20000), size=None)), ('question_solution', models.CharField(max_length=20000)), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, bases=('backend.question', ), ), migrations.CreateModel( name='TrueOrFalseQ', fields=[ ('question_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.Question')), ('question_content', models.CharField(max_length=20000)), ('question_image', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=10000000), size=None)), ('question_ans', models.BooleanField()), ('question_solution', models.CharField(max_length=20000)), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, bases=('backend.question', ), ), migrations.CreateModel( name='Section', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('title', models.CharField(max_length=200)), ('total_point', models.IntegerField()), ('section_num', models.IntegerField()), ('belong_paper', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='backend.Paper')), ('polymorphic_ctype', models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.section_set+', to='contenttypes.ContentType')), ('questions', models.ManyToManyField(through='backend.QuestionVersion', to='backend.Question')), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.AddField( model_name='questionversion', name='section', field=models.ForeignKey( default=None, on_delete=django.db.models.deletion.CASCADE, to='backend.Section'), ), migrations.CreateModel( name='QuestionRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('question_id', models.IntegerField()), ('question_type', models.CharField(default='', max_length=20)), ('record_time', models.DateTimeField(auto_now=True)), ('ans', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(default='', max_length=20000), size=None)), ('score', django.contrib.postgres.fields.ArrayField( base_field=models.IntegerField(), size=None)), ('is_correct', models.BooleanField(blank=True)), ('paper_record', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='backend.PaperRecord')), ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='QuestionGroup', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('current_version', models.DateTimeField()), ('belong_bank', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='backend.QuestionBank')), ('parents_node', models.ManyToManyField(to='backend.KnowledgeNode')), ('polymorphic_ctype', models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.questiongroup_set+', to='contenttypes.ContentType')), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, ), migrations.AddField( model_name='question', name='history_version', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='backend.QuestionGroup'), ), migrations.AddField( model_name='question', name='polymorphic_ctype', field=models.ForeignKey( editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.question_set+', to='contenttypes.ContentType'), ), migrations.AddField( model_name='knowledgenode', name='question_bank', field=models.ForeignKey( null=True, on_delete=django.db.models.deletion.CASCADE, to='backend.QuestionBank'), ), migrations.AddField( model_name='knowledgenode', name='subnodes', field=models.ManyToManyField(to='backend.KnowledgeNode'), ), migrations.CreateModel( name='EmailVerificationRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('token', models.CharField(max_length=50, verbose_name='Code')), ('email', models.EmailField(max_length=50, verbose_name='Email')), ('send_type', models.CharField(choices=[('register', 'Register'), ('forget', 'Reset password')], max_length=10, verbose_name='Veification type')), ('send_time', models.DateTimeField(auto_now=True, verbose_name='Send time')), ('is_valid', models.BooleanField(default=True)), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='User')), ], options={ 'verbose_name': 'Email verification code', 'verbose_name_plural': 'Email verification code', }, ), migrations.CreateModel( name='AuthCode', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('key', models.CharField(max_length=30, unique=True)), ('time_generated', models.DateTimeField(auto_now=True)), ('is_usable', models.BooleanField(default=True)), ('question_bank', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='backend.QuestionBank')), ], ), migrations.AddField( model_name='user', name='profile', field=models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, to='backend.Profile'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='backend.UserPermissions'), ), migrations.CreateModel( name='MultpChoiceQ', fields=[ ('choiceq_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.ChoiceQ')), ('question_ans', django.contrib.postgres.fields.ArrayField( base_field=models.CharField(max_length=10), size=None)), ('question_ans_num', models.IntegerField()), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, bases=('backend.choiceq', ), ), migrations.CreateModel( name='SingleChoiceQ', fields=[ ('choiceq_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.ChoiceQ')), ('question_ans', models.CharField(max_length=10)), ], options={ 'abstract': False, 'base_manager_name': 'objects', }, bases=('backend.choiceq', ), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='NewUser', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators.ASCIIUsernameValidator( ) ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('manage_role', models.CharField(choices=[(b'super', '\u8d85\u7ea7\u7ba1\u7406\u5458'), (b'manage', '\u7ba1\u7406\u5458')], default=b'super', max_length=30, verbose_name='\u89d2\u8272')), ], options={ 'verbose_name': '\u7528\u6237\u7ba1\u7406', 'verbose_name_plural': '\u7528\u6237\u7ba1\u7406', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='cmd_run', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('ip', models.GenericIPAddressField(verbose_name='IP\u5730\u5740')), ('command', models.CharField(max_length=30, verbose_name='\u547d\u4ee4')), ('track_mark', models.IntegerField()), ], options={ 'verbose_name': '\u547d\u4ee4\u7ba1\u7406', 'verbose_name_plural': '\u547d\u4ee4\u7ba1\u7406', }, ), migrations.CreateModel( name='ContainsList', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('contain_id', models.CharField(blank=True, max_length=20, null=True, verbose_name='\u5bb9\u5668ID')), ('contain_ip', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP\u5730\u5740')), ('contain_netmask', models.CharField(blank=True, max_length=20, null=True, verbose_name='\u5bb9\u5668\u63a9\u7801')), ('contain_port', models.CharField( blank=True, max_length=10, null=True, verbose_name='\u5bb9\u5668\u76d1\u542c\u7aef\u53e3')), ('contain_http', models.CharField(blank=True, max_length=10, null=True, verbose_name='\u670d\u52a1url')), ('create_datetime', models.CharField( blank=True, max_length=20, null=True, verbose_name='\u5bb9\u5668\u521b\u5efa\u65f6\u95f4')), ('contain_cpu_core', models.CharField(blank=True, max_length=10, null=True, verbose_name='cpu\u7ed1\u5b9a\u6838\u53f7')), ('contain_host', models.CharField( blank=True, max_length=30, null=True, verbose_name='\u7269\u7406\u673a\u4e3b\u673a\u540d')), ('contain_memory', models.CharField(blank=True, max_length=10, null=True, verbose_name='\u5185\u5b58\u5206\u914d')), ('contain_hostname', models.CharField( blank=True, max_length=30, null=True, verbose_name='\u5bb9\u5668\u4e3b\u673a\u540d')), ('release_application', models.CharField(blank=True, max_length=20, null=True, verbose_name='\u5e94\u7528\u540d\u79f0')), ('service_pack', models.CharField(blank=True, max_length=30, null=True, verbose_name='\u5e94\u7528\u5305\u540d')), ('service_depend', models.CharField(blank=True, max_length=50, null=True, verbose_name='\u5e94\u7528\u4f9d\u8d56')), ('service_env', models.CharField(blank=True, max_length=20, null=True, verbose_name='\u670d\u52a1\u73af\u5883')), ('project_name', models.CharField(blank=True, max_length=20, null=True, verbose_name='\u9879\u76ee\u540d\u79f0')), ('proposer', models.CharField( blank=True, max_length=30, null=True, verbose_name='\u9879\u76ee\u5f00\u53d1\u8005')), ('principal', models.CharField( blank=True, max_length=30, null=True, verbose_name='\u9879\u76ee\u8d1f\u8d23\u4eba')), ('project_section', models.CharField( blank=True, max_length=30, null=True, verbose_name='\u9879\u76ee\u6240\u5c5e\u90e8\u95e8')), ('state', models.CharField(blank=True, max_length=30, null=True, verbose_name='\u5bb9\u5668\u72b6\u6001')), ('flag', models.CharField( blank=True, max_length=5, null=True, verbose_name='\u5bb9\u5668\u6807\u8bb0\u4f4d')), ('x_flag', models.CharField( blank=True, max_length=30, null=True, verbose_name='\u5bb9\u5668\u5904\u7406\u60c5\u51b5')), ], options={ 'verbose_name': '\u5bb9\u5668\u5217\u8868', 'verbose_name_plural': '\u5bb9\u5668\u5217\u8868', }, ), migrations.CreateModel( name='Group', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=50, unique=True)), ], options={ 'verbose_name': '\u4e3b\u673a\u7ec4\u4fe1\u606f', 'verbose_name_plural': '\u4e3b\u673a\u7ec4\u4fe1\u606f\u7ba1\u7406', }, ), migrations.CreateModel( name='HostList', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('ip', models.GenericIPAddressField( unique=True, verbose_name='\u7269\u7406\u673aIP\u5730\u5740')), ('manage_ip', models.GenericIPAddressField( unique=True, verbose_name='\u7ba1\u7406IP\u5730\u5740')), ('hostname', models.CharField(max_length=30, verbose_name='\u4e3b\u673a\u540d')), ('application', models.CharField(max_length=20, verbose_name='\u5e94\u7528')), ('bianhao', models.CharField(max_length=30, verbose_name='\u7f16\u53f7')), ('idc_name', models.CharField(blank=True, max_length=40, null=True, verbose_name='\u6240\u5c5e\u673a\u623f')), ('group', models.ManyToManyField(blank=True, to='app.Group', verbose_name='\u7ec4\u540d')), ], options={ 'verbose_name': '\u4e3b\u673a\u5217\u8868', 'verbose_name_plural': '\u4e3b\u673a\u5217\u8868', }, ), migrations.CreateModel( name='Idc', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('idc_name', models.CharField(max_length=40, verbose_name='\u673a\u623f\u540d\u79f0')), ('idc_address', models.CharField(max_length=80, verbose_name='\u673a\u623f\u5730\u5740')), ('remark', models.CharField(max_length=40, verbose_name='\u5907\u6ce8')), ], options={ 'verbose_name': '\u673a\u623f\u5217\u8868', }, ), migrations.CreateModel( name='salt_return', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('fun', models.CharField(max_length=50)), ('jid', models.CharField(max_length=255)), ('result', models.TextField()), ('host', models.CharField(max_length=255)), ('success', models.CharField(max_length=10)), ('full_ret', models.TextField()), ], options={ 'verbose_name': '\u547d\u4ee4\u8fd4\u56de\u7ed3\u679c', 'verbose_name_plural': '\u547d\u4ee4\u8fd4\u56de\u7ed3\u679c', }, ), migrations.CreateModel( name='ServerAsset', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('manufacturer', models.CharField(max_length=20, verbose_name='\u5382\u5546')), ('productname', models.CharField(max_length=30, verbose_name='\u4ea7\u54c1\u578b\u53f7')), ('service_tag', models.CharField(max_length=80, unique=True, verbose_name='\u5e8f\u5217\u53f7')), ('cpu_model', models.CharField(max_length=50, verbose_name='CPU\u578b\u53f7')), ('cpu_nums', models.PositiveSmallIntegerField( verbose_name='CPU\u7ebf\u7a0b\u6570')), ('cpu_groups', models.PositiveSmallIntegerField( verbose_name='CPU\u7269\u7406\u6838\u6570')), ('mem', models.CharField( max_length=100, verbose_name= b'\xe5\x86\x85\xe5\xad\x98\xe5\xa4\xa7\xe5\xb0\x8f')), ('disk', models.CharField( max_length=300, verbose_name= b'\xe7\xa1\xac\xe7\x9b\x98\xe5\xa4\xa7\xe5\xb0\x8f')), ('hostname', models.CharField(max_length=30, verbose_name='\u4e3b\u673a\u540d')), ('ip', models.CharField(max_length=20, verbose_name='IP\u5730\u5740')), ('os', models.CharField(max_length=20, verbose_name='\u64cd\u4f5c\u7cfb\u7edf')), ], options={ 'verbose_name': '\u4e3b\u673a\u8d44\u4ea7\u4fe1\u606f', 'verbose_name_plural': '\u4e3b\u673a\u8d44\u4ea7\u4fe1\u606f\u7ba1\u7406', }, ), migrations.CreateModel( name='Upload', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('headImg', models.FileField(upload_to=b'./upload/')), ], options={ 'verbose_name': '\u6587\u4ef6\u4e0a\u4f20', 'verbose_name_plural': '\u6587\u4ef6\u4e0a\u4f20', }, ), migrations.AddField( model_name='newuser', name='groups', field=models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups'), ), migrations.AddField( model_name='newuser', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0011_update_proxy_permissions'), ] operations = [ migrations.CreateModel( name='ChinAbout', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('comp_name', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='公司名称(中文)')), ('en_comp_name', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='公司名称(英文)')), ('slug', models.SlugField(blank=True, help_text='根据name生成的,用于生成页面URL,必须唯一', max_length=255, null=True, unique=True, verbose_name='Slug')), ('title', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='公司简介标题(中文)')), ('en_title', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='公司简介标题(英文)')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='公司简介(中文)')), ('en_content', models.TextField(blank=True, default='', null=True, verbose_name='公司简介(英文)')), ('comp_image', models.ImageField(blank=True, max_length=255, null=True, upload_to='company/%Y/%m', verbose_name='公司简介图片')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '品牌介绍', 'verbose_name_plural': '品牌介绍', 'db_table': 'chin_about', }, ), migrations.CreateModel( name='ChinAnimateType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(default='', max_length=30, verbose_name='动画名称')), ('class_name', models.CharField(default='flip', max_length=50, verbose_name='class样式名')), ('descr', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='动画描述')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '动画类型', 'verbose_name_plural': '动画类型', 'db_table': 'chin_animatetype', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='ChinApplyRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='姓名')), ('sex', models.CharField(choices=[('0', '男'), ('1', '女'), ('2', '保密'), ('3', '未知')], default=0, max_length=5, verbose_name='性别')), ('birthday', models.DateField(blank=True, default='', null=True, verbose_name='生日')), ('phone', models.CharField(max_length=11, verbose_name='电话')), ('email', models.EmailField(blank=True, default='', max_length=50, null=True, verbose_name='邮箱')), ('is_get', models.BooleanField(default=False, verbose_name='是否已领取')), ('is_inform', models.BooleanField(default=False, verbose_name='是否已通知')), ('state', models.SmallIntegerField(choices=[(0, '未中奖'), (1, '中奖')], default=0, verbose_name='是否中奖')), ('sort', models.IntegerField(default=1, verbose_name='排序')), ], options={ 'verbose_name': '用户抢券记录', 'verbose_name_plural': '用户抢券记录', 'db_table': 'chin_applyrecord', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinCompanyHistory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('timeline_title', models.CharField(blank=True, default='', max_length=20, null=True, unique=True, verbose_name='时间标题(中文)')), ('en_timeline_title', models.CharField(blank=True, default='', max_length=40, null=True, unique=True, verbose_name='时间标题(英文)')), ('title', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='标题(中文)')), ('en_title', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='标题(英文)')), ('breif', models.CharField(blank=True, default='', max_length=50, null=True, verbose_name='摘要(中文)')), ('en_breif', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='摘要(英文)')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='描述(中文)')), ('en_content', models.TextField(blank=True, default='', null=True, verbose_name='描述(英文)')), ('cover_image_url', models.ImageField(blank=True, max_length=255, null=True, upload_to='company/%Y/%m', verbose_name='图片')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '发展历程', 'verbose_name_plural': '发展历程', 'db_table': 'chin_companyhistory', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinCooperation', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('title', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='名称(中文)')), ('en_title', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='名称(英文)')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='内容(中文)')), ('en_content', models.TextField(blank=True, default='', null=True, verbose_name='内容(英文)')), ('type', models.CharField(choices=[('0', '合作政策'), ('1', '项目优势'), ('2', '经销商问答'), ('3', '支持与服务')], default=0, max_length=10, verbose_name='类型')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '合作共赢', 'verbose_name_plural': '合作共赢', 'db_table': 'chin_cooperation', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinJobRecruit', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('job_name', models.CharField(blank=True, default='', max_length=50, null=True, verbose_name='职位名称(中文)')), ('en_job_name', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='职位名称(英文)')), ('slug', models.SlugField(blank=True, help_text='根据job_name生成的,用于生成页面URL,必须唯一', max_length=255, null=True, unique=True, verbose_name='Slug')), ('work_year', models.CharField(blank=True, default='', max_length=20, null=True, verbose_name='工作经验')), ('education', models.CharField(choices=[('0', '请选择'), ('1', '博士导师'), ('2', '博士后'), ('3', '博士'), ('4', '硕士'), ('5', '研究生'), ('6', '本科'), ('7', '大专'), ('8', '高中'), ('9', '初中'), ('10', '小学'), ('11', '其他')], default=0, max_length=10, verbose_name='学历')), ('work_prop', models.CharField(choices=[('0', '全职'), ('1', '兼职'), ('2', '自由职业'), ('3', '其他')], default=0, max_length=5, verbose_name='工作性质')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='招聘要求(中文)')), ('en_content', models.TextField(blank=True, default='', null=True, verbose_name='招聘要求(英文)')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '工作机会', 'verbose_name_plural': '工作机会', 'db_table': 'chin_jobrecruit', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinKeywords', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('title', models.CharField(blank=True, default='', max_length=80, null=True, verbose_name='标题')), ('keyword', models.TextField(blank=True, default='', null=True, verbose_name='关键字')), ('descr', models.CharField(blank=True, default='', max_length=256, null=True, verbose_name='描述')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('sort', models.IntegerField(default=1, verbose_name='排序')), ], options={ 'verbose_name': '关键字管理', 'verbose_name_plural': '关键字管理', 'db_table': 'chin_keywords', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='ChinNews', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('title', models.CharField(blank=True, default='', max_length=64, null=True, verbose_name='标题(中文)')), ('en_title', models.CharField(blank=True, default='', max_length=128, null=True, verbose_name='标题(英文)')), ('slug', models.SlugField(blank=True, help_text='根据title生成的,用于生成页面URL,必须唯一', max_length=255, null=True, unique=True, verbose_name='Slug')), ('brief', models.CharField(blank=True, default='', max_length=120, null=True, verbose_name='摘要(中文)')), ('en_brief', models.CharField(blank=True, default='', max_length=240, null=True, verbose_name='摘要(英文)')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='内容(中文)')), ('en_content', models.TextField(blank=True, default='', null=True, verbose_name='内容(英文)')), ('read_count', models.IntegerField(default=0, verbose_name='浏览量')), ('cover_image_url', models.ImageField(blank=True, max_length=255, null=True, upload_to='news/%Y/%m', verbose_name='图片')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('type', models.CharField(choices=[('0', '新闻资讯'), ('1', '社会责任')], default=0, max_length=10, verbose_name='类型')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '新闻资讯|社会责任', 'verbose_name_plural': '新闻资讯|社会责任', 'db_table': 'chin_news', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinPartner', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='名称(中文)')), ('en_name', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='名称(英文)')), ('logo', models.ImageField(blank=True, max_length=255, null=True, upload_to='partner/%Y/%m', verbose_name='Logo')), ('brief', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='简介(中文)')), ('en_brief', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='简介(英文)')), ('url', models.URLField(blank=True, max_length=255, null=True, verbose_name='链接')), ('address', models.CharField(max_length=100, verbose_name='地址')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '合作伙伴', 'verbose_name_plural': '合作伙伴', 'db_table': 'chin_partner', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinProductType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(blank=True, default='', max_length=30, null=True, verbose_name='类型名称(中文)')), ('en_name', models.CharField(blank=True, default='', max_length=30, null=True, verbose_name='类型名称(英文)')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('data_filter_name', models.CharField(default='*', max_length=20, verbose_name='数据类型标识')), ], options={ 'verbose_name': '产品类型', 'verbose_name_plural': '产品类型', 'db_table': 'chin_producttype', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinQuestion', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(max_length=200, verbose_name='问题标题')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='问题描述')), ('type', models.SmallIntegerField(choices=[(-1, '不是问题'), (0, '浏览器问题'), (1, '操作系统问题'), (2, 'bug'), (3, '其他问题'), (4, '重复问题'), (5, '第三方问题')], default=-1, verbose_name='问题类型')), ('state', models.SmallIntegerField(choices=[(-1, '待解决'), (0, '未解决'), (1, '已解决'), (2, '延期处理'), (3, '不予处理'), (4, '需第三方处理')], default=-1, verbose_name='问题状态')), ('remark', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='备注')), ], options={ 'verbose_name': '问题汇总列表', 'verbose_name_plural': '问题汇总列表', 'db_table': 'chin_question', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='ChinStory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('short_title', models.CharField(blank=True, default='', max_length=80, null=True, verbose_name='短板故事标题(中文)')), ('en_short_title', models.CharField(blank=True, default='', max_length=160, null=True, verbose_name='短板故事标题(英文)')), ('short_content', models.TextField(blank=True, default='', max_length=1000, null=True, verbose_name='短板故事(中文)')), ('en_short_content', models.TextField(blank=True, default='', max_length=2000, null=True, verbose_name='短板故事(英文)')), ('long_title', models.CharField(blank=True, default='', max_length=80, null=True, verbose_name='长板故事标题(中文)')), ('en_long_title', models.CharField(blank=True, default='', max_length=160, null=True, verbose_name='长板故事标题(英文)')), ('long_content', models.TextField(blank=True, default='', max_length=4000, null=True, verbose_name='长板故事(中文)')), ('en_long_content', models.TextField(blank=True, default='', max_length=8000, null=True, verbose_name='长板故事(英文)')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '秦始皇故事', 'verbose_name_plural': '秦始皇故事', 'db_table': 'chin_story', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='ChinTableTemplate', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(default='', max_length=30, verbose_name='名称')), ('file', models.FileField(max_length=255, upload_to='file/%Y/%m', verbose_name='文件')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '申请表格', 'verbose_name_plural': '申请表格', 'db_table': 'chin_tabletemplate', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='ChinUserWateringRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('client_ip', models.GenericIPAddressField(default='127.0.0.1', verbose_name='客户端IP')), ('client_host', models.CharField(default='', max_length=100, verbose_name='客户端主机名')), ('client_port', models.IntegerField(default=0, verbose_name='客户端端口')), ('client_user_agent', models.CharField(default='', max_length=255, verbose_name='客户端浏览器')), ('server_ip', models.GenericIPAddressField(default='127.0.0.1', verbose_name='服务器IP')), ('server_host', models.CharField(default='', max_length=100, verbose_name='服务器主机名')), ('server_port', models.IntegerField(default=0, verbose_name='服务器端口')), ('init_amount', models.IntegerField(default=0, verbose_name='期初水量')), ('amount', models.IntegerField(default=0, verbose_name='本次水量')), ('final_amount', models.IntegerField(default=0, verbose_name='期末水量')), ], options={ 'verbose_name': '用户浇水记录', 'verbose_name_plural': '用户浇水记录', 'db_table': 'chin_userwateringrecord', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='ChinWateringQty', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('amount', models.IntegerField(default=0, verbose_name='水量余额')), ('total_amount', models.IntegerField(default=0, verbose_name='浇水总量')), ], options={ 'verbose_name': '浇水量余额表', 'verbose_name_plural': '浇水量余额表', 'db_table': 'chin_wateringqty', 'ordering': ['-create_time'], }, ), migrations.CreateModel( name='SysConfig', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('site_name', models.CharField(blank=True, default='', max_length=50, verbose_name='站点名称')), ('site_desc', models.CharField(blank=True, default='', max_length=150, verbose_name='站点描述')), ('site_author', models.CharField(blank=True, default='', max_length=100, verbose_name='作者')), ('site_company', models.CharField(blank=True, default=None, max_length=100, null=True, verbose_name='公司(中文)')), ('en_site_company', models.CharField(blank=True, default=None, max_length=200, null=True, verbose_name='公司(英文)')), ('address', models.CharField(blank=True, default=None, max_length=150, null=True, verbose_name='底部显示地址(中文)')), ('en_address', models.CharField(blank=True, default=None, max_length=300, null=True, verbose_name='底部显示地址(英文)')), ('telephone', models.CharField(max_length=15, verbose_name='底部显示电话')), ('email', models.EmailField(blank=True, default='', max_length=50, verbose_name='邮箱')), ('icp', models.CharField(blank=True, default='', max_length=256, verbose_name='备案号(中文)')), ('en_icp', models.CharField(blank=True, default='', max_length=256, verbose_name='备案号(英文)')), ('remark', models.CharField(blank=True, default='', max_length=200, verbose_name='备注')), ('logo_bottom', models.ImageField(blank=True, default='', null=True, upload_to='sys/%Y/%m', verbose_name='底部logo')), ('qrcode', models.ImageField(blank=True, default='', null=True, upload_to='sys/%Y/%m', verbose_name='二维码')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ], options={ 'verbose_name': '站点配置', 'verbose_name_plural': '站点配置', 'db_table': 'sys_config', }, ), migrations.CreateModel( name='SysNav', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('code', models.CharField(default='', max_length=20, verbose_name='标识')), ('name', models.CharField(blank=True, default='', max_length=50, null=True, verbose_name='名称(中文)')), ('en_name', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='名称(英文)')), ('url', models.CharField(max_length=200, verbose_name='链接')), ('remark', models.CharField(blank=True, max_length=300, verbose_name='描述')), ('is_root', models.BooleanField(default=True, verbose_name='是否一级菜单')), ('is_delete', models.BooleanField(default=False, verbose_name='是否删除')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('parent', models.ForeignKey(blank=True, default=0, limit_choices_to={'is_delete': False, 'is_root': True}, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='children', to='home.SysNav', verbose_name='父级')), ], options={ 'verbose_name': '导航菜单管理', 'verbose_name_plural': '导航菜单管理', 'db_table': 'sys_nav', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinProduct', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('name', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='产品名称(中文)')), ('en_name', models.CharField(blank=True, default='', max_length=200, null=True, verbose_name='产品名称(英文)')), ('slug', models.SlugField(blank=True, help_text='根据name生成的,用于生成页面URL,必须唯一', max_length=255, null=True, unique=True, verbose_name='Slug')), ('brief', models.CharField(blank=True, default='', max_length=40, null=True, verbose_name='产品摘要(中文)')), ('en_brief', models.CharField(blank=True, default='', max_length=80, null=True, verbose_name='产品摘要(英文)')), ('content', models.TextField(blank=True, default='', null=True, verbose_name='产品描述(中文)')), ('en_content', models.TextField(blank=True, default='', null=True, verbose_name='产品描述(英文)')), ('mall_url', models.URLField(blank=True, default='', null=True, verbose_name='在线商城地址')), ('cover_image_url', models.ImageField(blank=True, max_length=255, null=True, upload_to='product/%Y/%m', verbose_name='图片')), ('read_count', models.IntegerField(default=0, verbose_name='浏览量')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_recommand', models.BooleanField(default=True, verbose_name='是否推荐')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('product_type', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='home.ChinProductType', verbose_name='产品类型')), ], options={ 'verbose_name': '品牌产品', 'verbose_name_plural': '品牌产品', 'db_table': 'chin_product', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinIndexPlate', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('title', models.CharField(blank=True, default='', max_length=8, null=True, verbose_name='板块标题(中文)')), ('en_title', models.CharField(blank=True, default='', max_length=16, null=True, verbose_name='板块标题(英文)')), ('plate_image_url', models.ImageField(blank=True, max_length=255, null=True, upload_to='index_plate/%Y/%m', verbose_name='图标')), ('front_image', models.ImageField(blank=True, max_length=255, null=True, upload_to='index_plate/%Y/%m', verbose_name='正面图')), ('back_image', models.ImageField(blank=True, max_length=255, null=True, upload_to='index_plate/%Y/%m', verbose_name='背面图')), ('descr', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='简介(中文)')), ('en_descr', models.CharField(blank=True, default='', max_length=100, null=True, verbose_name='简介(英文)')), ('is_redirect_sub_page', models.BooleanField(default=True, verbose_name='是否跳转到子页面')), ('sub_page_url', models.CharField(blank=True, default='', max_length=150, null=True, verbose_name='子页面地址')), ('video_source', models.FileField(blank=True, default='', max_length=200, null=True, upload_to='media/%Y/%m', verbose_name='视频文件地址')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('animate_type', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='home.ChinAnimateType', verbose_name='动画类型')), ], options={ 'verbose_name': '首页板块', 'verbose_name_plural': '首页板块', 'db_table': 'chin_indexplate', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinBanner', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('image_url', models.ImageField(blank=True, default='', null=True, upload_to='banner/%Y/%m', verbose_name='图片')), ('text', models.CharField(blank=True, default='', max_length=150, null=True, verbose_name='Banner上文本描述(中文)')), ('en_text', models.CharField(blank=True, default='', max_length=300, null=True, verbose_name='Banner上文本描述(英文)')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('nav', models.ForeignKey(blank=True, default='', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='navs', related_query_name='nav_query', to='home.SysNav', verbose_name='Banner页面')), ], options={ 'verbose_name': 'Banner管理', 'verbose_name_plural': 'Banner管理', 'db_table': 'chin_banner', 'ordering': ['nav', 'sort', '-create_time'], }, ), migrations.CreateModel( name='ChinAboutResource', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('operate_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='操作人名称')), ('operate_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='操作人ID')), ('create_username', models.CharField(auto_created=True, default='admin', max_length=30, verbose_name='创建人名称')), ('create_uid', models.IntegerField(auto_created=True, default=123456789, verbose_name='创建人ID')), ('create_time', models.DateTimeField(default=django.utils.timezone.now, verbose_name='创建时间')), ('operate_time', models.DateTimeField(auto_now=True, verbose_name='操作时间')), ('type_code', models.PositiveSmallIntegerField(choices=[(1, '企业文化'), (2, '品牌荣誉'), (3, '企业资质'), (4, '团队风采'), (5, '品牌故事'), (6, '组织架构')], default=0, verbose_name='图片业务类型')), ('image_url', models.ImageField(blank=True, default='', null=True, upload_to='company/%Y/%m', verbose_name='图片')), ('sort', models.IntegerField(default=0, verbose_name='排序')), ('is_enable', models.BooleanField(default=True, verbose_name='是否启用')), ('about', models.ForeignKey(blank=True, default='', null=True, on_delete=django.db.models.deletion.CASCADE, related_name='about_resource', related_query_name='about', to='home.ChinAbout', verbose_name='品牌介绍')), ], options={ 'verbose_name': '品牌介绍图片资源', 'verbose_name_plural': '品牌介绍图片资源', 'db_table': 'chin_aboutresource', 'ordering': ['sort', '-create_time'], }, ), migrations.CreateModel( name='ChinUserProfile', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('avatar', models.ImageField(default='avatar/default.png', max_length=200, upload_to='avatar/%Y/%m', verbose_name='用户头像')), ('qq', models.CharField(blank=True, max_length=20, null=True, verbose_name='QQ')), ('phone', models.CharField(blank=True, max_length=11, null=True, unique=True, verbose_name='手机号')), ('nick_name', models.CharField(max_length=30, verbose_name='昵称')), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': '用户', 'verbose_name_plural': '用户', 'db_table': 'chin_userprofile', 'ordering': ['-id'], 'abstract': False, 'swappable': 'AUTH_USER_MODEL', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='Membre', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('profile', models.IntegerField(choices=[(1, 'Sanabil Admin'), (2, 'Association Responsible')], default=1)), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'Membre', 'verbose_name_plural': 'Membres', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Login', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('ip', models.GenericIPAddressField()), ('membre', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0007_alter_validators_add_error_messages'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('email', models.EmailField(max_length=254, unique=True)), ('first_name', models.CharField(max_length=100, verbose_name='Name')), ('username', models.CharField(blank=True, max_length=100, null=True)), ('is_active', models.BooleanField(default=True)), ('is_staff', models.BooleanField(default=True)), ('is_admin', models.BooleanField(default=False)), ('date_joined', models.DateTimeField(default=django.utils.timezone.now)), ('ssh_pub_key', models.TextField(blank=True, null=True)), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Container', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('hostname', models.CharField(max_length=100)), ('container_id', models.CharField(max_length=200)), ], bases=(models.Model, dockit.utils.ContainerMixin), ), migrations.CreateModel( name='Host', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('hostname', models.CharField(blank=True, max_length=100)), ('is_active', models.BooleanField(default=True)), ('ssh_port', models.CharField(default='22', max_length=10)), ('docker_api_port', models.CharField(max_length=10)), ('docker_network', models.CharField(blank=True, max_length=100)), ], ), migrations.CreateModel( name='Image', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=200)), ('tag', models.CharField(max_length=200)), ('is_snapshot', models.BooleanField(default=False)), ('snapshot', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='backup', to='dockit.Container')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], bases=(models.Model, dockit.utils.ImageMixin), ), migrations.CreateModel( name='IP', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('ip_addr', models.GenericIPAddressField(unique=True)), ('mac_addr', models.CharField(blank=True, max_length=200, null=True)), ('is_routed', models.BooleanField(default=False)), ('is_active', models.BooleanField(default=True)), ('is_available', models.BooleanField(default=True)), ], ), migrations.AddField( model_name='container', name='image', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='dockit.Image'), ), migrations.AddField( model_name='container', name='ip', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='dockit.IP'), ), migrations.AddField( model_name='container', name='user', field=models.ManyToManyField(to=settings.AUTH_USER_MODEL), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='UserProfile', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('nick_name', models.CharField(blank=True, max_length=10, null=True, verbose_name='中文名')), ('qq', models.CharField(blank=True, max_length=20, null=True, verbose_name='QQ号码')), ('wechat', models.CharField(blank=True, max_length=20, null=True, verbose_name='微信号码')), ('mobile', models.CharField(blank=True, max_length=20, null=True, verbose_name='手机号码')), ('avatar', models.ImageField(blank=True, default='users/avatar/default.png', max_length=200, null=True, upload_to='users/avatar/%Y/%m', verbose_name='用户头像')), ('birthday', models.DateField(blank=True, null=True, verbose_name='生日')), ('gender', models.CharField(choices=[('male', '男'), ('female', '女')], default='male', max_length=10, verbose_name='性别')), ('address', models.CharField(blank=True, max_length=200, null=True, verbose_name='地址')), ('desc', models.TextField(blank=True, null=True, verbose_name='其他')), ], options={ 'verbose_name': '用户', 'verbose_name_plural': '用户', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='EmailVerificationCode', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('code', models.CharField(max_length=20, verbose_name='验证码')), ('email', models.EmailField(max_length=254, verbose_name='接收邮箱')), ('use', models.CharField(choices=[('register', '注册'), ('forget', '忘记密码'), ('change_email', '修改邮箱')], max_length=20, verbose_name='用途')), ('is_use', models.BooleanField(default=False, verbose_name='是否使用')), ('add_time', models.DateTimeField(auto_now_add=True, verbose_name='添加时间')), ], options={ 'verbose_name': '邮箱验证码', 'verbose_name_plural': '邮箱验证码', }, ), migrations.CreateModel( name='UserDepartment', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=20, verbose_name='部门名称')), ('desc', models.CharField(blank=True, max_length=200, null=True, verbose_name='部门描述')), ('add_time', models.DateTimeField(auto_now_add=True, verbose_name='添加时间')), ], options={ 'verbose_name': '部门', 'verbose_name_plural': '部门', }, ), migrations.CreateModel( name='UserLoginRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('agent', models.CharField(blank=True, max_length=200, null=True, verbose_name='客户端')), ('city', models.CharField(blank=True, max_length=100, null=True, verbose_name='登录区域')), ('ip', models.GenericIPAddressField(blank=True, null=True, verbose_name='客户端IP')), ('add_time', models.DateTimeField(auto_now_add=True, verbose_name='添加时间')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='用户')), ], options={ 'verbose_name': '用户登录信息', 'verbose_name_plural': '用户登录信息', }, ), migrations.CreateModel( name='UserPosition', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=20, verbose_name='职位名称')), ('desc', models.CharField(blank=True, max_length=200, null=True, verbose_name='职位描述')), ('add_time', models.DateTimeField(auto_now_add=True, verbose_name='添加时间')), ], options={ 'verbose_name': '职位', 'verbose_name_plural': '职位', }, ), migrations.AddField( model_name='userprofile', name='department', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='users.UserDepartment', verbose_name='部门'), ), migrations.AddField( model_name='userprofile', name='groups', field=models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups'), ), migrations.AddField( model_name='userprofile', name='position', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='users.UserPosition', verbose_name='职位'), ), migrations.AddField( model_name='userprofile', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), ('username', models.CharField(max_length=20, unique=True, verbose_name='Username')), ('name', models.CharField(max_length=20, verbose_name='Name')), ('email', models.EmailField(max_length=30, unique=True, verbose_name='Email')), ('role', models.CharField(blank=True, choices=[('Admin', 'Administrator'), ('User', 'User'), ('App', 'Application')], default='User', max_length=10, verbose_name='Role')), ('avatar', models.ImageField(null=True, upload_to='avatar', verbose_name='Avatar')), ('wechat', models.CharField(blank=True, max_length=30, verbose_name='Wechat')), ('phone', models.CharField(blank=True, max_length=20, null=True, verbose_name='Phone')), ('enable_otp', models.BooleanField(default=False, verbose_name='Enable OTP')), ('secret_key_otp', models.CharField(blank=True, max_length=16)), ('_private_key', models.CharField(blank=True, max_length=5000, verbose_name='Private key')), ('_public_key', models.CharField(blank=True, max_length=5000, verbose_name='Public key')), ('comment', models.TextField(blank=True, max_length=200, verbose_name='Comment')), ('is_first_login', models.BooleanField(default=False)), ('date_expired', models.DateTimeField( blank=True, default=common.utils.date_expired_default, null=True, verbose_name='Date expired')), ('created_by', models.CharField(default='', max_length=30, verbose_name='Created by')), ], options={ 'ordering': ['username'], }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='AccessKey', fields=[ ('id', models.UUIDField(default=uuid.uuid4, editable=False, primary_key=True, serialize=False, verbose_name='AccessKeyID')), ('secret', models.UUIDField(default=uuid.uuid4, editable=False, verbose_name='AccessKeySecret')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='access_key', to=settings.AUTH_USER_MODEL, verbose_name='User')), ], ), migrations.CreateModel( name='LoginLog', fields=[ ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), ('username', models.CharField(max_length=20, verbose_name='Username')), ('type', models.CharField(choices=[('W', 'Web'), ('T', 'Terminal')], max_length=2, verbose_name='Login type')), ('ip', models.GenericIPAddressField(verbose_name='Login ip')), ('city', models.CharField(blank=True, max_length=254, null=True, verbose_name='Login city')), ('user_agent', models.CharField(blank=True, max_length=254, null=True, verbose_name='User agent')), ('datetime', models.DateTimeField(auto_now_add=True, verbose_name='Date login')), ], options={ 'ordering': ['-datetime', 'username'], }, ), migrations.CreateModel( name='PrivateToken', fields=[ ('key', models.CharField(max_length=40, primary_key=True, serialize=False, verbose_name='Key')), ('created', models.DateTimeField(auto_now_add=True, verbose_name='Created')), ('user', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, related_name='auth_token', to=settings.AUTH_USER_MODEL, verbose_name='User')), ], options={ 'verbose_name': 'Private Token', }, ), migrations.CreateModel( name='UserGroup', fields=[ ('is_discard', models.BooleanField(default=False, verbose_name='is discard')), ('discard_time', models.DateTimeField(blank=True, null=True, verbose_name='discard time')), ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), ('name', models.CharField(max_length=128, verbose_name='Name')), ('comment', models.TextField(blank=True, verbose_name='Comment')), ('date_created', models.DateTimeField(auto_now_add=True, null=True, verbose_name='Date created')), ('created_by', models.CharField(max_length=100)), ], options={ 'ordering': ['name'], }, ), migrations.AddField( model_name='user', name='groups', field=models.ManyToManyField(blank=True, related_name='users', to='users.UserGroup', verbose_name='User group'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), migrations.RunPython(add_default_group), migrations.RunPython(add_default_admin), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0011_update_proxy_permissions'), ] operations = [ migrations.CreateModel( name='UserProfile', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('phone_number', models.CharField(blank=True, max_length=20, null=True)), ('photo', models.FileField( blank=True, null=True, upload_to=users.tools.get_user_photo_upload_path)), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Category', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100)), ('code', models.CharField(max_length=30)), ], ), migrations.CreateModel( name='Event', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100)), ('description', models.CharField(max_length=1000, null=True)), ('date_start', models.DateTimeField(blank=True, null=True)), ('date_end', models.DateTimeField(blank=True, null=True)), ('created', models.DateTimeField(default=django.utils.timezone.now)), ('latitude', models.CharField(blank=True, max_length=100, null=True)), ('longitude', models.CharField(blank=True, max_length=100, null=True)), ('address', models.CharField(blank=True, max_length=300, null=True)), ('category', models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='events', to='users.Category')), ('host', models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='events', to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='Tag', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(blank=True, max_length=100, null=True)), ], ), migrations.CreateModel( name='UserLocationHistory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('country_code', models.CharField(blank=True, max_length=3, null=True)), ('country_name', models.CharField(blank=True, max_length=100, null=True)), ('city', models.CharField(blank=True, max_length=100, null=True)), ('ip', models.GenericIPAddressField()), ('user', models.ForeignKey(blank=True, default=None, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='location_history', to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='EventFile', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('file', models.FileField( blank=True, null=True, upload_to=users.tools.get_event_file_upload_path)), ('name', models.CharField(blank=True, max_length=300, null=True)), ('upload_time', models.DateTimeField(auto_now=True, null=True)), ('event', models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='files', to='users.Event')), ], ), migrations.AddField( model_name='event', name='tags', field=models.ManyToManyField(to='users.Tag'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='Asset', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('asset_type', models.CharField(choices=[('server', '服务器'), ('networkdevice', '网络设备'), ('storagedevice', '存储设备'), ('securitydevice', '安全设备'), ('securitydevice', '机房设备'), ('software', '软件资产')], default='server', max_length=64)), ('name', models.CharField(max_length=64, unique=True)), ('sn', models.CharField(max_length=128, unique=True, verbose_name='资产SN号')), ('management_ip', models.GenericIPAddressField(blank=True, null=True, verbose_name='管理IP')), ('trade_date', models.DateField(blank=True, null=True, verbose_name='购买时间')), ('expire_date', models.DateField(blank=True, null=True, verbose_name='过保修期')), ('price', models.FloatField(blank=True, null=True, verbose_name='价格')), ('status', models.SmallIntegerField(choices=[(0, '在线'), (1, '已下线'), (2, '未知'), (3, '故障'), (4, '备用')], default=0)), ('memo', models.TextField(blank=True, null=True, verbose_name='备注')), ('create_date', models.DateTimeField(auto_now_add=True)), ('update_date', models.DateTimeField(auto_now=True)), ], options={ 'verbose_name': '资产总表', 'verbose_name_plural': '资产总表', }, ), migrations.CreateModel( name='BusinessUnit', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=64, unique=True, verbose_name='业务线')), ('memo', models.CharField(blank=True, max_length=64, verbose_name='备注')), ('parent_unit', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='parent_level', to='assets.BusinessUnit')), ], options={ 'verbose_name': '业务线', 'verbose_name_plural': '业务线', }, ), migrations.CreateModel( name='Contract', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sn', models.CharField(max_length=128, unique=True, verbose_name='合同号')), ('name', models.CharField(max_length=64, verbose_name='合同名称')), ('memo', models.TextField(blank=True, null=True, verbose_name='备注')), ('price', models.IntegerField(verbose_name='合同金额')), ('detail', models.TextField(blank=True, null=True, verbose_name='合同详细')), ('start_date', models.DateField(blank=True)), ('end_date', models.DateField(blank=True)), ('license_num', models.IntegerField(blank=True, verbose_name='license数量')), ('create_date', models.DateField(auto_now_add=True)), ('update_date', models.DateField(auto_now=True)), ], options={ 'verbose_name': '合同', 'verbose_name_plural': '合同', }, ), migrations.CreateModel( name='CPU', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('cpu_model', models.CharField(blank=True, max_length=128, verbose_name='CPU型号')), ('cpu_count', models.SmallIntegerField(verbose_name='物理cpu个数')), ('cpu_core_count', models.SmallIntegerField(verbose_name='cpu核数')), ('memo', models.TextField(blank=True, null=True, verbose_name='备注')), ('create_date', models.DateTimeField(auto_now_add=True)), ('update_date', models.DateTimeField(blank=True, null=True)), ('asset', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], options={ 'verbose_name': 'CPU部件', 'verbose_name_plural': 'CPU部件', }, ), migrations.CreateModel( name='Disk', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sn', models.CharField(blank=True, max_length=128, null=True, verbose_name='SN号')), ('slot', models.CharField(max_length=64, verbose_name='插槽位')), ('model', models.CharField(blank=True, max_length=128, null=True, verbose_name='磁盘型号')), ('capacity', models.FloatField(verbose_name='磁盘容量GB')), ('iface_type', models.CharField(choices=[('SATA', 'SATA'), ('SAS', 'SAS'), ('SCSI', 'SCSI'), ('SSD', 'SSD')], default='SAS', max_length=64, verbose_name='接口类型')), ('memo', models.TextField(blank=True, null=True, verbose_name='备注')), ('create_date', models.DateTimeField(auto_now_add=True)), ('update_date', models.DateTimeField(blank=True, null=True)), ('asset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], options={ 'verbose_name': '硬盘', 'verbose_name_plural': '硬盘', }, ), migrations.CreateModel( name='EventLog', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100, verbose_name='事件名称')), ('event_type', models.SmallIntegerField(choices=[(1, '硬件变更'), (2, '新增配件'), (3, '设备下线'), (4, '设备上线'), (5, '定期维护'), (6, '业务上线\\更新\\变更'), (7, '其它')], verbose_name='事件类型')), ('component', models.CharField(blank=True, max_length=255, null=True, verbose_name='事件子项')), ('detail', models.TextField(verbose_name='事件详情')), ('date', models.DateTimeField(auto_now_add=True, verbose_name='事件时间')), ('memo', models.TextField(blank=True, null=True, verbose_name='备注')), ('asset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], options={ 'verbose_name': '事件纪录', 'verbose_name_plural': '事件纪录', }, ), migrations.CreateModel( name='IDC', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=64, unique=True, verbose_name='机房名称')), ('memo', models.CharField(blank=True, max_length=128, null=True, verbose_name='备注')), ], options={ 'verbose_name': '机房', 'verbose_name_plural': '机房', }, ), migrations.CreateModel( name='Manufactory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('manufactory', models.CharField(max_length=64, unique=True, verbose_name='厂商名称')), ('support_num', models.CharField(blank=True, max_length=30, verbose_name='支持电话')), ('memo', models.CharField(blank=True, max_length=128, verbose_name='备注')), ], options={ 'verbose_name': '厂商', 'verbose_name_plural': '厂商', }, ), migrations.CreateModel( name='NetworkDevice', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sub_asset_type', models.SmallIntegerField(choices=[(0, '路由器'), (1, '交换机'), (2, '负载均衡'), (4, 'VPN设备')], default=0, verbose_name='服务器类型')), ('vlan_ip', models.GenericIPAddressField(blank=True, null=True, verbose_name='VlanIP')), ('intranet_ip', models.GenericIPAddressField(blank=True, null=True, verbose_name='内网IP')), ('model', models.CharField(blank=True, max_length=128, null=True, verbose_name='型号')), ('port_num', models.SmallIntegerField(blank=True, null=True, verbose_name='端口个数')), ('device_detail', models.TextField(blank=True, null=True, verbose_name='设置详细配置')), ('asset', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], options={ 'verbose_name': '网络设备', 'verbose_name_plural': '网络设备', }, ), migrations.CreateModel( name='NewAssetApprovalZone', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sn', models.CharField(max_length=128, unique=True, verbose_name='资产SN号')), ('asset_type', models.CharField(blank=True, choices=[('server', '服务器'), ('switch', '交换机'), ('router', '路由器'), ('firewall', '防火墙'), ('storage', '存储设备'), ('NLB', 'NetScaler'), ('wireless', '无线AP'), ('software', '软件资产'), ('others', '其它类')], max_length=64, null=True)), ('manufactory', models.CharField(blank=True, max_length=64, null=True)), ('model', models.CharField(blank=True, max_length=128, null=True)), ('ram_size', models.IntegerField(blank=True, null=True)), ('cpu_model', models.CharField(blank=True, max_length=128, null=True)), ('cpu_count', models.IntegerField(blank=True, null=True)), ('cpu_core_count', models.IntegerField(blank=True, null=True)), ('os_distribution', models.CharField(blank=True, max_length=64, null=True)), ('os_type', models.CharField(blank=True, max_length=64, null=True)), ('os_release', models.CharField(blank=True, max_length=64, null=True)), ('data', models.TextField(verbose_name='资产数据')), ('date', models.DateTimeField(auto_now_add=True, verbose_name='汇报日期')), ('approved', models.BooleanField(default=False, verbose_name='已批准')), ('approved_date', models.DateTimeField(blank=True, null=True, verbose_name='批准日期')), ], options={ 'verbose_name': '新上线待批准资产', 'verbose_name_plural': '新上线待批准资产', }, ), migrations.CreateModel( name='NIC', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(blank=True, max_length=64, null=True, verbose_name='网卡名')), ('sn', models.CharField(blank=True, max_length=128, null=True, verbose_name='SN号')), ('model', models.CharField(blank=True, max_length=128, null=True, verbose_name='网卡型号')), ('macaddress', models.CharField(max_length=64, unique=True, verbose_name='MAC')), ('ipaddress', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP')), ('netmask', models.CharField(blank=True, max_length=64, null=True)), ('bonding', models.CharField(blank=True, max_length=64, null=True)), ('memo', models.CharField(blank=True, max_length=128, null=True, verbose_name='备注')), ('create_date', models.DateTimeField(auto_now_add=True)), ('update_date', models.DateTimeField(blank=True, null=True)), ('asset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], options={ 'verbose_name': '网卡', 'verbose_name_plural': '网卡', }, ), migrations.CreateModel( name='RaidAdaptor', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sn', models.CharField(blank=True, max_length=128, null=True, verbose_name='SN号')), ('slot', models.CharField(max_length=64, verbose_name='插口')), ('model', models.CharField(blank=True, max_length=64, null=True, verbose_name='型号')), ('memo', models.TextField(blank=True, null=True, verbose_name='备注')), ('create_date', models.DateTimeField(auto_now_add=True)), ('update_date', models.DateTimeField(blank=True, null=True)), ('asset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], ), migrations.CreateModel( name='RAM', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sn', models.CharField(blank=True, max_length=128, null=True, verbose_name='SN号')), ('model', models.CharField(max_length=128, verbose_name='内存型号')), ('slot', models.CharField(max_length=64, verbose_name='插槽')), ('capacity', models.IntegerField(verbose_name='内存大小(MB)')), ('memo', models.CharField(blank=True, max_length=128, null=True, verbose_name='备注')), ('create_date', models.DateTimeField(auto_now_add=True)), ('update_date', models.DateTimeField(blank=True, null=True)), ('asset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], options={ 'verbose_name': 'RAM', 'verbose_name_plural': 'RAM', }, ), migrations.CreateModel( name='SecurityDevice', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sub_asset_type', models.SmallIntegerField(choices=[(0, '防火墙'), (1, '入侵检测设备'), (2, '互联网网关'), (4, '运维审计系统')], default=0, verbose_name='服务器类型')), ('asset', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ], ), migrations.CreateModel( name='Server', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sub_asset_type', models.SmallIntegerField(choices=[(0, 'PC服务器'), (1, '刀片机'), (2, '小型机')], default=0, verbose_name='服务器类型')), ('created_by', models.CharField(choices=[('auto', 'Auto'), ('manual', 'Manual')], default='auto', max_length=32)), ('model', models.CharField(blank=True, max_length=128, null=True, verbose_name='型号')), ('raid_type', models.CharField(blank=True, max_length=512, null=True, verbose_name='raid类型')), ('os_type', models.CharField(blank=True, max_length=64, null=True, verbose_name='操作系统类型')), ('os_distribution', models.CharField(blank=True, max_length=64, null=True, verbose_name='发型版本')), ('os_release', models.CharField(blank=True, max_length=64, null=True, verbose_name='操作系统版本')), ('asset', models.OneToOneField( on_delete=django.db.models.deletion.CASCADE, to='assets.Asset')), ('hosted_on', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='hosted_on_server', to='assets.Server')), ], options={ 'verbose_name': '服务器', 'verbose_name_plural': '服务器', }, ), migrations.CreateModel( name='Software', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('sub_asset_type', models.SmallIntegerField(choices=[(0, 'OS'), (1, '办公\\开发软件'), (2, '业务软件')], default=0, verbose_name='服务器类型')), ('license_num', models.IntegerField(verbose_name='授权数')), ('version', models.CharField(help_text='eg. CentOS release 6.5 (Final)', max_length=64, unique=True, verbose_name='软件/系统版本')), ], options={ 'verbose_name': '软件/系统', 'verbose_name_plural': '软件/系统', }, ), migrations.CreateModel( name='Tag', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=32, unique=True, verbose_name='Tag name')), ('create_date', models.DateField(auto_now_add=True)), ], ), migrations.CreateModel( name='UserProfile', fields=[ ('user_ptr', models.OneToOneField( auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to=settings.AUTH_USER_MODEL)), ('name', models.CharField(max_length=32, verbose_name='姓名')), ], options={ 'verbose_name': '用户', 'verbose_name_plural': '用户', }, bases=('auth.user', ), managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.AddField( model_name='tag', name='creator', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='assets.UserProfile'), ), migrations.AddField( model_name='newassetapprovalzone', name='approved_by', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.UserProfile', verbose_name='批准人'), ), migrations.AddField( model_name='networkdevice', name='firmware', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.Software'), ), migrations.AddField( model_name='eventlog', name='user', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='assets.UserProfile', verbose_name='事件源'), ), migrations.AddField( model_name='asset', name='admin', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.UserProfile', verbose_name='资产管理员'), ), migrations.AddField( model_name='asset', name='business_unit', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.BusinessUnit', verbose_name='所属业务线'), ), migrations.AddField( model_name='asset', name='contract', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.Contract', verbose_name='合同'), ), migrations.AddField( model_name='asset', name='idc', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.IDC', verbose_name='IDC机房'), ), migrations.AddField( model_name='asset', name='manufactory', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='assets.Manufactory', verbose_name='制造商'), ), migrations.AddField( model_name='asset', name='tags', field=models.ManyToManyField(blank=True, to='assets.Tag'), ), migrations.AlterUniqueTogether( name='ram', unique_together={('asset', 'slot')}, ), migrations.AlterUniqueTogether( name='raidadaptor', unique_together={('asset', 'slot')}, ), migrations.AlterUniqueTogether( name='nic', unique_together={('asset', 'macaddress')}, ), migrations.AlterUniqueTogether( name='disk', unique_together={('asset', 'slot')}, ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('contenttypes', '0002_remove_content_type_name'), ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='Project', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.ASCIIUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('name', models.SlugField(verbose_name=b'account name')), ('contact_person', models.CharField(blank=True, max_length=200, null=True)), ('contact_email', models.EmailField(blank=True, max_length=100, null=True)), ('account_number', models.CharField(blank=True, max_length=50, null=True)), ('department', models.CharField(blank=True, max_length=600, null=True)), ('address', models.CharField(blank=True, max_length=600, null=True)), ('city', models.CharField(blank=True, max_length=180, null=True)), ('province', models.CharField(blank=True, max_length=180, null=True)), ('postal_code', models.CharField(blank=True, max_length=30, null=True)), ('country', models.CharField(blank=True, max_length=180, null=True)), ('contact_phone', models.CharField(blank=True, max_length=60, null=True)), ('contact_fax', models.CharField(blank=True, max_length=60, null=True)), ('organisation', models.CharField(blank=True, max_length=600, null=True)), ('show_archives', models.BooleanField(default=False)), ('key', models.CharField(blank=True, max_length=100, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('updated', models.BooleanField(default=False)), ], options={ 'verbose_name': 'Project Account', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='ActivityLog', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'Date/Time')), ('user_description', models.CharField(blank=True, max_length=60, null=True, verbose_name=b'User name')), ('ip_number', models.GenericIPAddressField(verbose_name=b'IP Address')), ('object_id', models.PositiveIntegerField(blank=True, null=True)), ('action_type', models.IntegerField(choices=[(0, b'Login'), (1, b'Logout'), (2, b'Task'), (3, b'Create'), (4, b'Modify'), (5, b'Delete'), (6, b'Archive')])), ('object_repr', models.CharField(blank=True, max_length=200, null=True, verbose_name=b'Entity')), ('description', models.TextField(blank=True)), ('content_type', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')), ('project', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ('user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='activities', to=settings.AUTH_USER_MODEL)), ], options={ 'ordering': ('-created',), }, ), migrations.CreateModel( name='AnalysisReport', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('staff_comments', models.TextField(blank=True, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('status', models.IntegerField(choices=[(5, 'Active'), (9, 'Archived'), (10, 'Trashed')], default=5)), ('kind', models.CharField(max_length=100)), ('score', models.FloatField()), ('url', models.CharField(max_length=200)), ('details', jsonfield.fields.JSONField(default=[])), ], options={ 'ordering': ['-score'], }, ), migrations.CreateModel( name='Beamline', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=600)), ('acronym', models.CharField(max_length=50)), ('energy_lo', models.FloatField(default=4.0)), ('energy_hi', models.FloatField(default=18.5)), ('contact_phone', models.CharField(max_length=60)), ], ), migrations.CreateModel( name='Carrier', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('url', models.URLField()), ], ), migrations.CreateModel( name='Component', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ], ), migrations.CreateModel( name='ComponentType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=50)), ], ), migrations.CreateModel( name='Container', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('staff_comments', models.TextField(blank=True, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('status', models.IntegerField(choices=[(0, 'Draft'), (1, 'Sent'), (2, 'On-site'), (3, 'Loaded'), (4, 'Returned'), (9, 'Archived')], default=0)), ('comments', models.TextField(blank=True, null=True)), ('priority', models.IntegerField(default=0)), ], options={ 'ordering': ('kind', 'location'), }, ), migrations.CreateModel( name='ContainerLocation', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=5)), ], ), migrations.CreateModel( name='ContainerType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=20)), ('layout', jsonfield.fields.JSONField(blank=True, null=True)), ('envelope', models.CharField(blank=True, max_length=200)), ('container_locations', models.ManyToManyField(blank=True, related_name='containers', to='lims.ContainerLocation')), ], ), migrations.CreateModel( name='Data', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('staff_comments', models.TextField(blank=True, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('status', models.IntegerField(choices=[(5, 'Active'), (9, 'Archived'), (10, 'Trashed')], default=5)), ('file_name', models.CharField(blank=True, max_length=200, null=True)), ('frames', lims.models.FrameField(blank=True, max_length=200, null=True)), ('exposure_time', models.FloatField(blank=True, null=True)), ('attenuation', models.FloatField(default=0.0)), ('energy', models.DecimalField(decimal_places=4, max_digits=10)), ('beam_size', models.FloatField(blank=True, null=True)), ('url', models.CharField(max_length=200)), ('kind', models.CharField(choices=[(b'MX_SCREEN', b'MX Screening'), (b'MX_DATA', b'MX Dataset'), (b'XRD_DATA', b'XRD Dataset'), (b'RASTER', b'Raster'), (b'XAS_SCAN', b'XAS Scan'), (b'XRF_SCAN', b'XRF Scan'), (b'MAD_SCAN', b'MAD Scan')], default=b'MX_SCREEN', max_length=20, verbose_name=b'Data type')), ('download', models.BooleanField(default=False)), ('meta_data', jsonfield.fields.JSONField(default={})), ('beamline', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='lims.Beamline')), ], options={ 'verbose_name': 'Dataset', }, ), migrations.CreateModel( name='Dewar', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('staff_comments', models.TextField(blank=True, null=True)), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('active', models.BooleanField(default=False)), ('beamline', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='lims.Beamline')), ('container', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='dewars', to='lims.Container')), ], ), migrations.CreateModel( name='Group', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('staff_comments', models.TextField(blank=True, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('status', models.IntegerField(choices=[(0, 'Draft'), (5, 'Active'), (6, 'Processing'), (7, 'Complete'), (9, 'Archived')], default=0)), ('energy', models.DecimalField(blank=True, decimal_places=4, max_digits=10, null=True)), ('kind', models.IntegerField(choices=[(0, b'Native'), (1, b'MAD'), (2, b'SAD')], default=0, verbose_name=b'exp. type')), ('absorption_edge', models.CharField(blank=True, max_length=5, null=True)), ('plan', models.IntegerField(choices=[(0, b'Rank and collect best'), (1, b'Collect first good'), (2, b'Screen and confirm'), (3, b'Screen and collect'), (4, b'Just collect')], default=2)), ('comments', models.TextField(blank=True, null=True)), ('priority', models.IntegerField(blank=True, null=True)), ('sample_count', models.PositiveIntegerField(default=1, verbose_name=b'Number of Samples')), ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'ordering': ['priority'], 'verbose_name': 'Group', }, ), migrations.CreateModel( name='LoadHistory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('start', models.DateTimeField(auto_now_add=True)), ('end', models.DateTimeField(blank=True, null=True)), ('child', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='parent_history', to='lims.Container')), ('location', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.ContainerLocation')), ('parent', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='children_history', to='lims.Container')), ], options={ 'ordering': ['-start'], }, ), migrations.CreateModel( name='Sample', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('staff_comments', models.TextField(blank=True, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('barcode', models.SlugField(blank=True, null=True)), ('location', models.CharField(blank=True, max_length=10, null=True, verbose_name=b'port')), ('comments', models.TextField(blank=True, null=True)), ('collect_status', models.BooleanField(default=False)), ('priority', models.IntegerField(blank=True, null=True)), ('container', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.Container')), ('group', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.Group')), ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'ordering': ['priority', 'container__name', 'location', 'name'], }, ), migrations.CreateModel( name='Session', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('name', models.CharField(max_length=100)), ('comments', models.TextField()), ('beamline', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sessions', to='lims.Beamline')), ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sessions', to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='Shipment', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('staff_comments', models.TextField(blank=True, null=True)), ('created', models.DateTimeField(auto_now_add=True, verbose_name=b'date created')), ('modified', models.DateTimeField(auto_now=True, verbose_name=b'date modified')), ('status', models.IntegerField(choices=[(0, 'Draft'), (1, 'Sent'), (2, 'On-site'), (4, 'Returned'), (9, 'Archived')], default=0)), ('comments', models.TextField(blank=True, max_length=200, null=True)), ('tracking_code', models.CharField(blank=True, max_length=60, null=True)), ('return_code', models.CharField(blank=True, max_length=60, null=True)), ('date_shipped', models.DateTimeField(blank=True, null=True)), ('date_received', models.DateTimeField(blank=True, null=True)), ('date_returned', models.DateTimeField(blank=True, null=True)), ('storage_location', models.CharField(blank=True, max_length=60, null=True)), ('carrier', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.Carrier')), ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'abstract': False, }, ), migrations.CreateModel( name='SpaceGroup', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=20)), ('crystal_system', models.CharField(choices=[(b'a', b'triclinic'), (b'm', b'monoclinic'), (b'o', b'orthorombic'), (b't', b'tetragonal'), (b'h', b'hexagonal'), (b'c', b'cubic')], max_length=1)), ('lattice_type', models.CharField(choices=[(b'P', b'primitive'), (b'C', b'side-centered'), (b'I', b'body-centered'), (b'F', b'face-centered'), (b'R', b'rhombohedral')], max_length=1)), ], ), migrations.CreateModel( name='Stretch', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('start', models.DateTimeField()), ('end', models.DateTimeField(blank=True, null=True)), ('session', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='stretches', to='lims.Session')), ], options={ 'ordering': ['-start'], 'verbose_name': 'Beamline Usage', 'verbose_name_plural': 'Beamline Usage', }, ), migrations.AddField( model_name='group', name='shipment', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.Shipment'), ), migrations.AddField( model_name='data', name='group', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='lims.Group'), ), migrations.AddField( model_name='data', name='project', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='data', name='sample', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='lims.Sample'), ), migrations.AddField( model_name='data', name='session', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='lims.Session'), ), migrations.AddField( model_name='containerlocation', name='accepts', field=models.ManyToManyField(blank=True, related_name='locations', to='lims.ContainerType'), ), migrations.AddField( model_name='container', name='kind', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='lims.ContainerType'), ), migrations.AddField( model_name='container', name='location', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.ContainerLocation'), ), migrations.AddField( model_name='container', name='parent', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='children', to='lims.Container'), ), migrations.AddField( model_name='container', name='project', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='container', name='shipment', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.Shipment'), ), migrations.AddField( model_name='component', name='kind', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='lims.ComponentType'), ), migrations.AddField( model_name='component', name='shipment', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='components', to='lims.Shipment'), ), migrations.AddField( model_name='beamline', name='automounters', field=models.ManyToManyField(through='lims.Dewar', to='lims.Container'), ), migrations.AddField( model_name='analysisreport', name='data', field=models.ManyToManyField(blank=True, related_name='reports', to='lims.Data'), ), migrations.AddField( model_name='analysisreport', name='project', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='project', name='carrier', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='lims.Carrier'), ), migrations.AddField( model_name='project', name='groups', field=models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups'), ), migrations.AddField( model_name='project', name='user_permissions', field=models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), migrations.AlterUniqueTogether( name='sample', unique_together=set([('project', 'container', 'location')]), ), migrations.AlterUniqueTogether( name='group', unique_together=set([('project', 'name', 'shipment')]), ), migrations.AlterUniqueTogether( name='container', unique_together=set([('project', 'name', 'shipment')]), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('balance', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, null=True, verbose_name='余额')), ('invitecode', models.CharField(max_length=40, verbose_name='邀请码')), ('level', models.PositiveIntegerField(default=0, validators=[django.core.validators.MaxValueValidator(9), django.core.validators.MinValueValidator(0)], verbose_name='用户等级')), ('level_expire_time', models.DateTimeField(default=django.utils.timezone.now, help_text='等级有效期', verbose_name='等级有效期')), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': '用户', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='AlipayRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('username', models.CharField(max_length=64, verbose_name='用户名')), ('info_code', models.CharField(max_length=64, unique=True, verbose_name='流水号')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='时间')), ('amount', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, null=True, verbose_name='金额')), ('money_code', models.CharField(max_length=64, unique=True, verbose_name='充值码')), ], options={ 'verbose_name_plural': '支付宝转账记录', 'ordering': ('-time',), }, ), migrations.CreateModel( name='AlipayRequest', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('username', models.CharField(max_length=64, verbose_name='用户名')), ('info_code', models.CharField(max_length=64, unique=True, verbose_name='流水号')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='时间')), ('amount', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, null=True, verbose_name='金额')), ], options={ 'verbose_name_plural': '支付宝申请记录', 'ordering': ('-time',), }, ), migrations.CreateModel( name='Aliveip', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('user_name', models.CharField(blank=True, max_length=50, null=True, verbose_name='用户名')), ('ip_address', models.GenericIPAddressField(verbose_name='在线ip')), ('local', models.CharField(blank=True, max_length=128, null=True, verbose_name='归属地')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='时间')), ], options={ 'verbose_name_plural': '在线ip', 'ordering': ('-time',), }, ), migrations.CreateModel( name='Announcement', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='时间')), ('body', models.TextField(verbose_name='主体')), ], options={ 'verbose_name_plural': '系统公告', 'ordering': ('-time',), }, ), migrations.CreateModel( name='Donate', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='捐赠时间')), ('money', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, null=True, verbose_name='捐赠金额')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'verbose_name_plural': '捐赠', 'ordering': ('-time',), }, ), migrations.CreateModel( name='InviteCode', fields=[ ('type', models.IntegerField(choices=[(1, '公开'), (0, '不公开')], default=0, verbose_name='类型')), ('code', models.CharField(blank=True, default=shadowsocks.tools.get_long_random_string, max_length=40, primary_key=True, serialize=False, verbose_name='邀请码')), ('time_created', models.DateTimeField(auto_now_add=True, verbose_name='创建时间')), ], options={ 'verbose_name_plural': '邀请码', 'ordering': ('-time_created',), }, ), migrations.CreateModel( name='MoneyCode', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('user', models.CharField(blank=True, max_length=128, null=True, verbose_name='用户名')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='捐赠时间')), ('code', models.CharField(blank=True, default=shadowsocks.tools.get_long_random_string, max_length=40, unique=True, verbose_name='充值码')), ('number', models.DecimalField(blank=True, decimal_places=2, default=10, max_digits=10, null=True, verbose_name='捐赠金额')), ('isused', models.BooleanField(default=False, verbose_name='是否使用')), ], options={ 'verbose_name_plural': '充值码', 'ordering': ('isused',), }, ), migrations.CreateModel( name='Node', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('node_id', models.IntegerField(unique=True, verbose_name='节点id')), ('name', models.CharField(max_length=32, verbose_name='名字')), ('server', models.CharField(max_length=128, verbose_name='服务器IP')), ('method', models.CharField(choices=[('aes-256-cfb', 'aes-256-cfb'), ('rc4-md5', 'rc4-md5'), ('salsa20', 'salsa20'), ('aes-128-ctr', 'aes-128-ctr')], default='aes-256-cfb', max_length=32, verbose_name='加密类型')), ('custom_method', models.SmallIntegerField(choices=[(0, 0), (1, 1)], default=0, verbose_name='自定义加密')), ('traffic_rate', models.FloatField(default=1.0, verbose_name='流量比例')), ('protocol', models.CharField(choices=[('auth_sha1_v4', 'auth_sha1_v4'), ('auth_aes128_md5', 'auth_aes128_md5'), ('auth_aes128_sha1', 'auth_aes128_sha1'), ('auth_chain_a', 'auth_chain_a'), ('origin', 'origin')], default='origin', max_length=32, verbose_name='协议')), ('obfs', models.CharField(choices=[('plain', 'plain'), ('http_simple', 'http_simple'), ('http_simple_compatible', 'http_simple_compatible'), ('http_post', 'http_post'), ('tls1.2_ticket_auth', 'tls1.2_ticket_auth')], default='plain', max_length=32, verbose_name='混淆')), ('info', models.CharField(blank=True, max_length=1024, null=True, verbose_name='节点说明')), ('status', models.CharField(choices=[('好用', '好用'), ('维护', '维护'), ('坏了', '坏了')], default='ok', max_length=32, verbose_name='状态')), ('level', models.PositiveIntegerField(default=0, validators=[django.core.validators.MaxValueValidator(9), django.core.validators.MinValueValidator(0)], verbose_name='节点等级')), ], options={ 'verbose_name_plural': '节点', 'db_table': 'ss_node', 'ordering': ['id'], }, ), migrations.CreateModel( name='NodeInfoLog', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('node_id', models.IntegerField(verbose_name='节点id')), ('uptime', models.FloatField(verbose_name='更新时间')), ('load', models.CharField(max_length=32, verbose_name='负载')), ('log_time', models.IntegerField(verbose_name='日志时间')), ], options={ 'verbose_name_plural': '节点日志', 'db_table': 'ss_node_info_log', 'ordering': ('-log_time',), }, ), migrations.CreateModel( name='NodeOnlineLog', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('node_id', models.IntegerField(verbose_name='节点id')), ('online_user', models.IntegerField(verbose_name='在线人数')), ('log_time', models.IntegerField(verbose_name='日志时间')), ], options={ 'verbose_name_plural': '节点在线记录', 'db_table': 'ss_node_online_log', }, ), migrations.CreateModel( name='PurchaseHistory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('user', models.CharField(max_length=128, verbose_name='购买者')), ('money', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, null=True, verbose_name='金额')), ('purchtime', models.DateTimeField(auto_now_add=True, verbose_name='购买时间')), ], options={ 'verbose_name_plural': '购买记录', 'ordering': ('-purchtime',), }, ), migrations.CreateModel( name='Shop', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=128, verbose_name='商品描述')), ('transfer', models.BigIntegerField(default=1073741824, verbose_name='增加的流量')), ('money', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, null=True, verbose_name='金额')), ('level', models.PositiveIntegerField(default=0, validators=[django.core.validators.MaxValueValidator(9), django.core.validators.MinValueValidator(0)], verbose_name='设置等级')), ('days', models.PositiveIntegerField(default=0, validators=[django.core.validators.MaxValueValidator(365), django.core.validators.MinValueValidator(1)], verbose_name='设置等级时间(天)')), ], options={ 'verbose_name_plural': '商品', }, ), migrations.CreateModel( name='Ticket', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('time', models.DateTimeField(auto_now_add=True, verbose_name='时间')), ('title', models.CharField(max_length=128, verbose_name='标题')), ('body', models.TextField(verbose_name='内容主体')), ('status', models.CharField(choices=[('开启', '开启'), ('关闭', '关闭')], default='开启', max_length=10, verbose_name='状态')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], options={ 'verbose_name_plural': '工单', 'ordering': ('-time',), }, ), migrations.AddField( model_name='purchasehistory', name='info', field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='shadowsocks.Shop'), ), migrations.AddField( model_name='aliveip', name='node_id', field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='alive_node_id', to='shadowsocks.Node'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0010_auto_20180331_1151'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, unique=True, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('special_id', models.CharField(max_length=20, primary_key=True, serialize=False, unique=True, verbose_name='Идентификатор')), ('status_special_id', models.BooleanField(default=False, verbose_name='Статус')), ('start_period', models.DateTimeField(blank=True, null=True)), ('end_period', models.DateTimeField(blank=True, null=True)), ('balanse', models.IntegerField(default=0, verbose_name='Баланс')), ('IP_adress', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP')), ('followers', models.ForeignKey(blank=True, on_delete=django.db.models.deletion.CASCADE, related_name='User', to=settings.AUTH_USER_MODEL, verbose_name='Подписчики')), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('inviter', models.OneToOneField(blank=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='Инвайт')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Tariff', fields=[ ('name', models.CharField(max_length=100, primary_key=True, serialize=False, verbose_name='Тариф')), ('cost', models.IntegerField(verbose_name='Стоимость')), ('period', models.IntegerField(verbose_name='Период')), ('tariff_bonus', models.DecimalField(decimal_places=2, max_digits=3, verbose_name='Бонус')), ], ), migrations.AddField( model_name='user', name='tariff_name', field=models.OneToOneField(blank=True, on_delete=django.db.models.deletion.CASCADE, to='choose.Tariff', verbose_name='Тариф'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('checkEmail', models.BooleanField(default=False, verbose_name='邮箱验证')), ('pcode', models.CharField(blank=True, max_length=10)), ('icode', models.CharField(max_length=10)), ('eth_address', models.CharField(blank=True, max_length=50)), ('telegram_name', models.CharField(blank=True, default='', max_length=50)), ('ip', models.GenericIPAddressField()), ('is_kyc', models.BooleanField(default=False, verbose_name='kyc验证')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Bonus', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('email', models.CharField(max_length=50)), ('dcb_bonus', models.DecimalField(decimal_places=4, default=0, max_digits=20)), ('hash', models.CharField(max_length=100, unique=True)), ('status', models.BooleanField(default=False, verbose_name='是否发送')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='Config', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('private_price', models.IntegerField(default=0)), ('public_price', models.IntegerField(default=0)), ('private_token_count', models.IntegerField(default=0)), ('public_token_count', models.IntegerField(default=0)), ('private_received_token', models.IntegerField(default=0)), ('public_received_token', models.IntegerField(default=0)), ('eth_price', models.IntegerField(default=0)), ('public_date_start', models.DateTimeField(default=0)), ('public_date_end', models.DateTimeField(default=0)), ('private_is_over', models.BooleanField(default=False, verbose_name='私募是否结束')), ('public_is_over', models.BooleanField(default=False, verbose_name='公开是否结束')), ], ), migrations.CreateModel( name='Contact', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('first_name', models.CharField(max_length=50)), ('last_name', models.CharField(max_length=50)), ('email', models.CharField(max_length=50)), ('subject', models.CharField(max_length=50)), ('message', models.CharField(max_length=50)), ('status', models.BooleanField(default=False, verbose_name='是否处理')), ], ), migrations.CreateModel( name='Country', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=20)), ('en_name', models.CharField(max_length=60)), ('code', models.CharField(max_length=5)), ('code2', models.CharField(max_length=5)), ('code3', models.CharField(max_length=5)), ], ), migrations.CreateModel( name='Kyc', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('country', models.IntegerField()), ('first_name', models.CharField(max_length=50)), ('last_name', models.CharField(max_length=50)), ('id_type', models.IntegerField(verbose_name='ID类型')), ('id_number', models.CharField(max_length=30)), ('photo1', models.ImageField(blank=True, upload_to='img')), ('photo2', models.ImageField(blank=True, upload_to='img')), ('photo3', models.ImageField(blank=True, upload_to='img')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='Noip', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('ip', models.GenericIPAddressField()), ], ), migrations.CreateModel( name='Reserve', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('email', models.CharField(max_length=50)), ('status', models.BooleanField(default=False, verbose_name='是否众筹了')), ], ), migrations.CreateModel( name='Telegram', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('first_name', models.CharField(max_length=50)), ('name', models.CharField(max_length=50)), ('dcb_num', models.DecimalField(decimal_places=4, default=0, max_digits=20)), ('hash', models.CharField(max_length=20, unique=True)), ('updateID', models.CharField(default='', max_length=50, unique=True)), ('status', models.BooleanField(default=False, verbose_name='是否发送')), ], ), migrations.CreateModel( name='Token', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('eth_num', models.DecimalField(decimal_places=8, default=0, max_digits=20)), ('dcb_num', models.DecimalField(decimal_places=4, default=0, max_digits=20)), ('hash', models.CharField(max_length=100, unique=True)), ('status', models.BooleanField(default=False, verbose_name='是否发送')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='Verification', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('email', models.CharField(max_length=50)), ('code', models.CharField(max_length=10)), ('status', models.IntegerField(default=0)), ], ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='users', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('roleid', models.CharField(default='', max_length=50, verbose_name='角色id')), ('mobile', models.CharField(blank=True, max_length=11, null=True, verbose_name='手机号')), ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ], options={ 'verbose_name': '用户信息', 'verbose_name_plural': '用户信息', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='ansible_group', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('hostgroup', models.CharField(max_length=200, null=True)), ('ansible_groupid', models.CharField(max_length=200, null=True)), ], ), migrations.CreateModel( name='ansible_host', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('hostip', models.GenericIPAddressField()), ('hostname', models.CharField(max_length=50, null=True)), ('hostport', models.CharField(max_length=50, null=True)), ('project_owner', models.CharField(max_length=50, null=True)), ('idc_name', models.CharField(max_length=50, null=True)), ('ansible_groupid', models.CharField(max_length=20, null=True)), ('spaceid', models.CharField(max_length=20, null=True)), ], ), migrations.CreateModel( name='compile_conf', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('varnameid', models.CharField(max_length=50)), ('varname', models.CharField(max_length=50)), ('varpath', models.CharField(max_length=200)), ], ), migrations.CreateModel( name='grayphone', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('phone', models.CharField(max_length=11)), ('expirytime', models.CharField(max_length=30, null=True)), ('phoneencrypt', models.CharField(max_length=150, null=True)), ('online', models.CharField(max_length=10)), ('createuser', models.CharField(max_length=30)), ('createtime', models.CharField(max_length=30, null=True)), ], ), migrations.CreateModel( name='hostspace', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('spaceid', models.CharField(max_length=20, null=True)), ('spacename', models.CharField(max_length=20, null=True)), ], ), migrations.CreateModel( name='memuid', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('submemuname', models.CharField(max_length=50, null=True)), ('submemuurl', models.CharField(max_length=50, null=True)), ('memunameid', models.CharField(max_length=50, null=True)), ], ), migrations.CreateModel( name='memulist', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('permission_url', models.CharField(max_length=50, null=True)), ('memuname', models.CharField(max_length=10, null=True)), ('memunameid', models.CharField(max_length=10, null=True)), ('permission_id', models.CharField(max_length=50, null=True)), ], ), migrations.CreateModel( name='permission', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('permission_id', models.CharField(max_length=10, null=True)), ('roleid', models.CharField(max_length=10, null=True)), ], ), migrations.CreateModel( name='RecordLogTable', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('username', models.CharField(max_length=100)), ('recordclass', models.CharField(max_length=150)), ('recordvalue', models.TextField(max_length=10000)), ('logtime', models.DateTimeField(default='2019-01-30 16:29:41')), ], ), migrations.CreateModel( name='RedisHost', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('proxy_name', models.CharField(max_length=50, null=True)), ('redis_ip', models.GenericIPAddressField()), ('redis_port', models.CharField(max_length=20)), ('admin_addr', models.GenericIPAddressField(null=True)), ('admin_port', models.CharField(max_length=20, null=True)), ('redis_pass', models.CharField(max_length=50, null=True)), ('project_owner', models.CharField(max_length=50, null=True)), ('project_principal', models.CharField(max_length=20, null=True)), ('typename', models.CharField(max_length=20, null=True)), ('typeid', models.CharField(max_length=1, null=True)), ], ), migrations.CreateModel( name='role', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('roleid', models.CharField(max_length=10, null=True)), ('Rolename', models.CharField(max_length=50, null=True)), ], ), migrations.CreateModel( name='tenginehost', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('host', models.GenericIPAddressField()), ('hostredisport', models.CharField(max_length=10, null=True)), ], ), migrations.AddField( model_name='users', name='user_permissions', field=models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('dashboard', '0001_initial'), ] operations = [ migrations.CreateModel( name='CustomUser', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('phone', models.CharField(blank=True, db_column='Phone Number', max_length=100, null=True)), ('address', models.CharField(blank=True, db_column='Address', max_length=100, null=True)), ('is_login', models.BooleanField(db_column='Is Login', default='True')), ('created', models.DateTimeField(auto_now_add=True)), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='APIRequestLog', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('requested_at', models.DateTimeField(db_index=True)), ('response_ms', models.PositiveIntegerField(default=0)), ('path', models.CharField(db_index=True, max_length=200)), ('view', models.CharField(blank=True, db_index=True, max_length=200, null=True, verbose_name='From Whom')), ('view_method', models.CharField(blank=True, db_index=True, max_length=27, null=True)), ('remote_addr', models.GenericIPAddressField()), ('host', models.URLField()), ('method', models.CharField(max_length=10)), ('query_params', models.TextField(blank=True, null=True)), ('data', models.TextField(blank=True, null=True)), ('response', models.TextField(blank=True, null=True)), ('errors', models.TextField(blank=True, null=True)), ('status_code', models.PositiveIntegerField(blank=True, null=True)), ], options={ 'verbose_name': 'API Request Log', 'abstract': False, }, ), migrations.CreateModel( name='Builder', fields=[ ('id', models.CharField(db_column='Builder Id', max_length=255, primary_key=True, serialize=False)), ('name', models.CharField(db_column='Builder Name', max_length=100)), ('limit_reached', models.IntegerField(db_column='Limit Reached', default=0)), ('start_date', models.DateField(blank=True, db_column='Start Date', null=True)), ('is_livprop_tranfer', models.BooleanField(db_column='Is Fulfilment Services', default=True)), ('is_encryption', models.BooleanField(db_column='Is Encryption', default=True)), ('is_excel_load', models.BooleanField(db_column='Is Excel Upload', default=True)), ('is_live_push_api', models.BooleanField(db_column='Is LiveChat Push API', default=True)), ('is_live_pull_api', models.BooleanField(db_column='Is LiveChat Pull API', default=True)), ('is_auto_assign_tme', models.BooleanField(db_column='Is Auto Assign For TME', default=True)), ('is_auto_assign_bd', models.BooleanField(db_column='Is Auto Assign For BD', default=True)), ('is_active', models.BooleanField(db_column='Is Active', default=False)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='BuyingReason', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='CallStatus', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('status_type', models.CharField(choices=[('Initial', 'Initial'), ('Intermediate', 'Intermediate'), ('Finish', 'Finish'), ('Negative', 'Negative')], default='Initial', max_length=20)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='CallstatusLeadstatus', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ], ), migrations.CreateModel( name='City', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='Country', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='Emailaddress', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('mail_id', models.CharField(db_column='email', max_length=500)), ('status_error', models.TextField(blank=True, max_length=200, null=True)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='Lead', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('visitor_id', models.CharField(db_column='vsid', max_length=20, unique=True)), ('source_date', models.DateField(blank=True, db_column='Source Date', null=True)), ('name', models.CharField(blank=True, db_column='Customer Name', max_length=150, null=True)), ('age', models.IntegerField(blank=True, db_column='Age', null=True, validators=[django.core.validators.MaxValueValidator(100), django.core.validators.MinValueValidator(18)])), ('designation', models.CharField(blank=True, db_column='Designation', max_length=65, null=True)), ('address', models.TextField(blank=True, null=True)), ('from_unit_size', models.IntegerField(blank=True, db_column='from Unit Size', null=True)), ('to_unit_size', models.IntegerField(blank=True, db_column='To Unit Size', null=True)), ('from_budget', models.IntegerField(blank=True, db_column='From Budget', null=True)), ('to_budget', models.IntegerField(blank=True, db_column='To Budget', null=True)), ('additional_info', models.TextField(blank=True, db_column='Additional Info', null=True)), ('visit_date', models.DateField(blank=True, db_column='Visit Date', default='1999-01-01')), ('address_lat_long', models.CharField(blank=True, db_column='Address Lat Long', max_length=30, null=True)), ('is_livprop_tranfer', models.BooleanField(db_column='Is Fulfilment Services', default=True)), ('status_error', models.TextField(blank=True, max_length=200, null=True)), ('created', models.DateTimeField(auto_now_add=True)), ('modified', models.DateTimeField(auto_now=True)), ('bd', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='bd', to=settings.AUTH_USER_MODEL)), ('builder', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='management.Builder')), ('buying_reason', models.ForeignKey(blank=True, db_column='Buying Reason', null=True, on_delete=django.db.models.deletion.CASCADE, to='management.BuyingReason')), ('city', models.ForeignKey(blank=True, db_column='City', null=True, on_delete=django.db.models.deletion.CASCADE, to='management.City')), ('country', models.ForeignKey(blank=True, db_column='Country', null=True, on_delete=django.db.models.deletion.CASCADE, to='management.Country')), ('email', models.ManyToManyField(blank=True, db_column='Email', to='management.Emailaddress')), ('last_lead_activity', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='Last_Lead_Activity', to='dashboard.LeadActivity')), ('lead_activity', models.ManyToManyField(blank=True, db_column='Lead Activity', to='dashboard.LeadActivity')), ], ), migrations.CreateModel( name='Leadsource', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='LeadStatus', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='Name', max_length=50)), ('status_type', models.CharField(choices=[('Initial', 'Initial'), ('Intermediate', 'Intermediate'), ('Finish', 'Finish'), ('Negative', 'Negative')], default='Initial', max_length=20)), ('create', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='LeadType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='Package', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='Package Name', max_length=100)), ('validity_days', models.IntegerField(db_column='Validity', default=365, validators=[django.core.validators.MaxValueValidator(3000)])), ('lead_limit', models.BigIntegerField(db_column='Lead Limit', default=9223372036854775807)), ('tme_limit', models.IntegerField(db_column='TME Limit', default=0)), ('bd_limit', models.IntegerField(db_column='BD Limit', default=0)), ('tmebd_limit', models.IntegerField(db_column='TME/BD Limit', default=0)), ('is_livprop_tranfer', models.BooleanField(db_column='Is Fulfilment Services', default=True)), ('is_encryption', models.BooleanField(db_column='Is Encryption', default=True)), ('is_excel_load', models.BooleanField(db_column='Is Excel Upload', default=True)), ('is_live_push_api', models.BooleanField(db_column='Is LiveChat Push API', default=True)), ('is_live_pull_api', models.BooleanField(db_column='Is LiveChat Pull API', default=True)), ('is_auto_assign_tme', models.BooleanField(db_column='Is Auto Assign For TME', default='False')), ('is_auto_assign_bd', models.BooleanField(db_column='Is Auto Assign For BD', default='False')), ('is_active', models.BooleanField(db_column='Is Active', default=True)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='PhoneNumber', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('number', models.CharField(db_column='Phone Number', max_length=150)), ('status_error', models.TextField(blank=True, max_length=200, null=True)), ('created', models.DateTimeField(auto_now_add=True)), ('builder', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='management.Builder')), ], ), migrations.CreateModel( name='Project', fields=[ ('id', models.CharField(db_column='Project Id', max_length=255, primary_key=True, serialize=False)), ('name', models.CharField(db_column='Project Name', max_length=300)), ('description', models.TextField(blank=True, db_column='Project Description', null=True)), ('address', models.TextField(blank=True, db_column='Project Address', null=True)), ('is_active', models.BooleanField(db_column='Is Active', default=True)), ('addresslatlong', models.CharField(blank=True, db_column='Address lat long', max_length=30, null=True)), ('created', models.DateTimeField(auto_now_add=True)), ('builder', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='management.Builder')), ('site_manager', models.ManyToManyField(blank=True, db_column='Site Manager', to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='SaleStatus', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='Service', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='Service Name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ('status', models.ManyToManyField(blank=True, db_column='Lead Status', to='management.LeadStatus')), ], ), migrations.CreateModel( name='Skype', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('skype_id', models.CharField(db_column='Skype Id', max_length=100)), ('status_error', models.TextField(blank=True, max_length=200, null=True)), ('created', models.DateTimeField(auto_now_add=True)), ('builder', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='management.Builder')), ], ), migrations.CreateModel( name='UnitType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='name', max_length=100)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.CreateModel( name='UserRole', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(db_column='Role Name', max_length=50)), ('ui_type', models.CharField(choices=[('MA', 'Management'), ('ED', 'Editing')], default='MA', max_length=2)), ('user_type', models.CharField(choices=[('FA', 'Fullfilment Admin'), ('SA', 'Super Admin'), ('FT', 'Fullfilment TME'), ('FB', 'Fullfilment BD'), ('FTB', 'Fullfilment TMEBD'), ('CA', 'Client Admin'), ('CT', 'Client TME'), ('CB', 'Client BD'), ('CTB', 'Client TMEBD'), ('CUS', 'Custome')], default='CA', max_length=3)), ('is_encrypted', models.BooleanField(db_column='Is Encrypted', default=True)), ('created', models.DateTimeField(auto_now_add=True)), ], ), migrations.AddField( model_name='lead', name='lead_source', field=models.ForeignKey(blank=True, db_column='Lead Source', null=True, on_delete=django.db.models.deletion.CASCADE, to='management.Leadsource'), ), migrations.AddField( model_name='lead', name='lead_type', field=models.ForeignKey(blank=True, db_column='Lead Type', null=True, on_delete=django.db.models.deletion.CASCADE, to='management.LeadType'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0007_alter_validators_add_error_messages'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 30 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=30, unique=True, validators=[ django.core.validators.RegexValidator( '^[\\w.@+-]+$', 'Enter a valid username. This value may contain only letters, numbers and @/./+/-/_ characters.' ) ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('avatar', models.FileField(blank=True, null=True, upload_to='avatar/')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ], options={ 'abstract': False, 'verbose_name': 'user', 'verbose_name_plural': 'users', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Attachment', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('file_name', models.FileField(blank=True, null=True, upload_to='ticket_files/')), ], ), migrations.CreateModel( name='Comments', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('date', models.DateTimeField(default=datetime.datetime.now)), ('comment', models.TextField(blank=True, null=True)), ('private', models.BooleanField(default=False)), ], ), migrations.CreateModel( name='Company', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100)), ], ), migrations.CreateModel( name='Inventory', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100)), ('ip', models.GenericIPAddressField(protocol='ipv4')), ], ), migrations.CreateModel( name='InventoryGroup', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100)), ('company_rel', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='core.Company')), ], ), migrations.CreateModel( name='Logs', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('log_action', models.CharField(max_length=200)), ('log_destiny', models.CharField(max_length=200)), ], ), migrations.CreateModel( name='Microtasks', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('subject', models.CharField(max_length=40)), ('body', models.TextField(blank=True, null=True)), ('percentage', models.IntegerField(blank=True, default=0, null=True)), ], ), migrations.CreateModel( name='Priority', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=30)), ], ), migrations.CreateModel( name='Queue', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100)), ('shortcode', models.CharField(max_length=10)), ('description', models.CharField(blank=True, max_length=30, null=True)), ('company_rel', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.Company')), ], ), migrations.CreateModel( name='Rights', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('enabled', models.BooleanField(default=True)), ('can_view', models.BooleanField(default=False)), ('can_create', models.BooleanField(default=False)), ('can_delete', models.BooleanField(default=False)), ('can_edit', models.BooleanField(default=False)), ('can_comment', models.BooleanField(default=False)), ('grp_src', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='src_grp', to='auth.Group')), ('queue_dst', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='dst_queue', to='core.Queue')), ], ), migrations.CreateModel( name='State', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=30)), ('description', models.CharField(blank=True, max_length=150, null=True)), ('active', models.BooleanField(default=True)), ('color', models.CharField(blank=True, default='008ac6', max_length=10, null=True)), ], ), migrations.CreateModel( name='Ticket', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('date', models.DateTimeField(default=datetime.datetime.now)), ('subject', models.CharField(max_length=40)), ('body', models.TextField(blank=True, null=True)), ('percentage', models.IntegerField(blank=True, default=0, null=True)), ('assigned_company', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='core.Company')), ('assigned_inventory', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='core.Inventory')), ('assigned_prio', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.Priority')), ('assigned_queue', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='core.Queue')), ('assigned_state', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.State')), ('assigned_user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='a_user', to=settings.AUTH_USER_MODEL)), ('create_user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='c_user', to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='UserType', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('status', models.CharField(max_length=20)), ], ), migrations.AddField( model_name='microtasks', name='assigned_state', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='core.State'), ), migrations.AddField( model_name='microtasks', name='ticket_rel', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='ticket_rel_mtask', to='core.Ticket'), ), migrations.AddField( model_name='logs', name='log_ticket', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='ticket_log', to='core.Ticket'), ), migrations.AddField( model_name='logs', name='log_user', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='user_log', to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='inventory', name='group_rel', field=models.ForeignKey( null=True, on_delete=django.db.models.deletion.CASCADE, to='core.InventoryGroup'), ), migrations.AddField( model_name='comments', name='ticket_rel', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='ticket_rel_comm', to='core.Ticket'), ), migrations.AddField( model_name='comments', name='user_rel', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='user_rel_comm', to=settings.AUTH_USER_MODEL), ), migrations.AddField( model_name='attachment', name='ticket_rel', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='core.Ticket'), ), migrations.AddField( model_name='user', name='status_rel', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='core.UserType'), ), migrations.AddField( model_name='user', name='user_permissions', field=models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ migrations.CreateModel( name='Doctor', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('fio', models.CharField(max_length=250, verbose_name='ФИО врача')), ], options={ 'verbose_name': 'ФИО врача', 'verbose_name_plural': 'ФИО врачей', }, ), migrations.CreateModel( name='ForbiddenWord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('word', models.CharField(max_length=100, verbose_name='Запрещенное слово')), ], options={ 'verbose_name': 'Запрещенное слово', 'verbose_name_plural': 'Запрещенные слова', }, ), migrations.CreateModel( name='PermittedWords', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('word', models.CharField(max_length=100, verbose_name='Слово-исключение')), ], options={ 'verbose_name': 'Слово-исключение', 'verbose_name_plural': 'Слова-исключения', }, ), migrations.CreateModel( name='Review', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('dt_created', models.DateTimeField( auto_now_add=True, verbose_name='Дата и время создания отзыва')), ('dt_updated', models.DateTimeField( auto_now_add=True, verbose_name='Дата и время редактирования отзыва')), ('origin_text', models.TextField(verbose_name='Исходный отзыв')), ('finished_text', models.TextField(verbose_name='Обработанный отзыв')), ('moderation_flag', models.BooleanField(default=False, verbose_name='Отзыв отмодерирован')), ('user_ip', models.GenericIPAddressField(protocol='IPv4')), ('doctor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='main.Doctor', verbose_name='ФИО врача')), ('user', models.ForeignKey( default=django.contrib.auth.models.AnonymousUser, on_delete=django.db.models.deletion.SET_DEFAULT, to=settings.AUTH_USER_MODEL, verbose_name='Пользователь, оставивший отзыв')), ], options={ 'verbose_name': 'Отзыв', 'verbose_name_plural': 'Отзывы', }, ), migrations.CreateModel( name='Specialty', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=100, verbose_name='Специальность')), ], options={ 'verbose_name': 'Специальность', 'verbose_name_plural': 'Специальности', }, ), migrations.AddField( model_name='doctor', name='specialty', field=models.ManyToManyField(to='main.Specialty'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('question', '0001_initial'), ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='UserModel', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('email', models.EmailField(max_length=254, unique=True, verbose_name='E-Posta Adresi')), ('userAbout', models.TextField(blank=True, null=True, verbose_name='Hakkında')), ('profileImage', models.ImageField(blank=True, default='user/NewTux.svg', null=True, upload_to='user/', verbose_name='Profil Resmi')), ('userCountry', models.CharField(blank=True, max_length=200, null=True, verbose_name='Ulke')), ('userFacebook', models.CharField(blank=True, max_length=200, null=True, verbose_name='Facebook Adresi')), ('userTwitter', models.CharField(blank=True, max_length=200, null=True, verbose_name='Twitter Adresi')), ('userLinkedin', models.CharField(blank=True, max_length=200, null=True, verbose_name='Linkedin Adresi')), ('userWebsite', models.CharField(blank=True, max_length=200, null=True, verbose_name='Kişisel Sitesi')), ('isVerified', models.BooleanField(default=0, verbose_name='Onaylanmis Kullanici')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'user', 'abstract': False, 'verbose_name_plural': 'users', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='ForgotPasswordModel', fields=[ ('forgotPassword', models.AutoField(primary_key=True, serialize=False, verbose_name='ID')), ('publicKey', models.UUIDField(default=uuid.uuid4)), ('privateKey', models.UUIDField(default=uuid.uuid4, editable=False)), ('userID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='QuestionHistory', fields=[ ('id', models.AutoField(primary_key=True, serialize=False, verbose_name='Geçmiş ID')), ('historyDate', models.DateTimeField(auto_now_add=True, verbose_name='Tarih')), ('ipAddress', models.GenericIPAddressField(null=True)), ('questionID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='question.QuestionModel')), ('userID', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='UserLoginHistory', fields=[ ('loginID', models.AutoField(primary_key=True, serialize=False, verbose_name='Giris ID')), ('loginDate', models.DateTimeField(auto_now_add=True, verbose_name='Giris Tarihi')), ('ipAddress', models.GenericIPAddressField(null=True, verbose_name='IP Adres')), ('location', models.TextField(null=True, verbose_name='Konum')), ('userAgent', models.CharField(max_length=250, null=True, verbose_name='User-Agent')), ('browser', models.CharField(max_length=250, null=True, verbose_name='Tarayıcı')), ('status', models.BooleanField(default=False, verbose_name='Durum')), ('userID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), migrations.CreateModel( name='UserVerifyModel', fields=[ ('verifyID', models.AutoField(primary_key=True, serialize=False)), ('publicKey', models.UUIDField(default=uuid.uuid4)), ('privateKey', models.UUIDField(default=uuid.uuid4, editable=False)), ('userID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alter_user_username_max_length'), ] operations = [ migrations.CreateModel( name='UserInfo', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('username', models.CharField( error_messages={ 'unique': 'A user with that username already exists.' }, help_text= 'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[ django.contrib.auth.validators. UnicodeUsernameValidator() ], verbose_name='username')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('gender', models.CharField(choices=[('0', '男'), ('1', '女')], max_length=1, verbose_name='性别')), ('mobile', models.CharField(blank=True, max_length=11, null=True, verbose_name='电话')), ('image', models.ImageField(default='default.png', max_length=255, upload_to='image/%Y/%m', verbose_name='头像')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': '用户信息', 'verbose_name_plural': '用户信息', 'db_table': 'user_info', }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Comment', fields=[ ('id', models.AutoField(primary_key=True, serialize=False)), ('content', models.TextField(verbose_name='评论内容')), ('publish_time', models.DateTimeField(default=datetime.datetime.now, verbose_name='评论时间')), ('state', models.BooleanField(default=True, verbose_name='审核状态')), ('ip', models.GenericIPAddressField(verbose_name='用户IP地址')), ], options={ 'verbose_name': '评论', 'verbose_name_plural': '评论', 'db_table': 'comment', }, ), migrations.CreateModel( name='Content', fields=[ ('id', models.AutoField(primary_key=True, serialize=False)), ('title', models.CharField(max_length=100, verbose_name='标题')), ('picture', models.CharField(max_length=20, verbose_name='标签')), ('content', ckeditor_uploader.fields.RichTextUploadingField( blank=True, null=True, verbose_name='新闻内容')), ('image', models.ImageField(default='default.png', max_length=255, upload_to='image/%Y/%m', verbose_name='文章图片')), ('publish_time', models.DateTimeField(default=datetime.datetime.now, verbose_name='发布时间')), ('clicked', models.IntegerField(default=0, verbose_name='点击量')), ], options={ 'verbose_name': '文章内容', 'verbose_name_plural': '文章内容', 'db_table': 'content', }, ), migrations.CreateModel( name='Type', fields=[ ('id', models.AutoField(primary_key=True, serialize=False)), ('name', models.CharField(max_length=20, verbose_name='新闻类型')), ], options={ 'verbose_name': '新闻类型', 'verbose_name_plural': '新闻类型', 'db_table': 'news_type', }, ), migrations.AddField( model_name='content', name='type_id', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='context', to='app01.Type', verbose_name='新闻类型'), ), migrations.AddField( model_name='content', name='user_id', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, related_name='context', to=settings.AUTH_USER_MODEL, verbose_name='用户'), ), migrations.AddField( model_name='comment', name='news_id', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to='app01.Content', verbose_name='新闻'), ), migrations.AddField( model_name='comment', name='restore', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='app01.Comment', verbose_name='回复对象'), ), migrations.AddField( model_name='comment', name='restore_user', field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='restore', to=settings.AUTH_USER_MODEL, verbose_name='回复用户'), ), migrations.AddField( model_name='comment', name='user_id', field=models.ForeignKey( on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='用户'), ), ]
class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0011_update_proxy_permissions'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('user_type', models.PositiveSmallIntegerField( choices=[(1, 'manager'), (2, 'supervisor'), ( 4, 'employee'), (3, 'admin'), ( 5, 'agent'), (7, 'online player'), (6, 'sub agent')])), ('username', phonenumber_field.modelfields.PhoneNumberField( error_messages={ 'unique': 'A user with that mobile already exists.' }, max_length=128, region=None, unique=True, verbose_name='mobile')), ('groups', models.ManyToManyField( blank=True, help_text= 'The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), ('user_permissions', models.ManyToManyField( blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), ], options={ 'verbose_name': 'user', 'verbose_name_plural': 'users', 'abstract': False, }, managers=[ ('objects', django.contrib.auth.models.UserManager()), ], ), migrations.CreateModel( name='Agent', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('commission', models.FloatField(validators=[ django.core.validators.MinValueValidator(5), django.core.validators.MaxValueValidator(50) ])), ('parent', models.ForeignKey( limit_choices_to={'user_type__in': [1, 2, 3, 4, 5, 6]}, on_delete=django.db.models.deletion.PROTECT, related_name='agent_referby', to=settings.AUTH_USER_MODEL, verbose_name='Refered by')), ('parent_node', mptt.fields.TreeForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='children', to='master.Agent')), ('user', models.OneToOneField( limit_choices_to={'user_type__in': [5, 6]}, on_delete=django.db.models.deletion.PROTECT, related_name='agent_agent', to=settings.AUTH_USER_MODEL, verbose_name='Agent')), ], options={ 'permissions': (('can_handle_query_of_agent', 'can handle query of agent'), ), }, ), migrations.CreateModel( name='Manager', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('parent', models.OneToOneField( limit_choices_to={ 'is_superuser': True, 'user_type': 3 }, on_delete=django.db.models.deletion.PROTECT, related_name='manager_admin', to=settings.AUTH_USER_MODEL, verbose_name='Admin')), ('user', models.OneToOneField( limit_choices_to={'user_type': 1}, on_delete=django.db.models.deletion.PROTECT, related_name='manager_manager', to=settings.AUTH_USER_MODEL, verbose_name='Manager')), ], options={ 'permissions': (('can_verify_bank_details', 'can verify bank details'), ), }, ), migrations.CreateModel( name='Supervisor', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('parent', models.ForeignKey(limit_choices_to={'user_type': 1}, on_delete=django.db.models.deletion.PROTECT, related_name='supervisor_manager', to='master.Manager', verbose_name='Manager')), ('user', models.OneToOneField( limit_choices_to={'user_type': 2}, on_delete=django.db.models.deletion.PROTECT, related_name='supervisor_supervisor', to=settings.AUTH_USER_MODEL, verbose_name='Supervisor')), ], options={ 'permissions': (('can_verify_bank_details', 'can verify bank details'), ), }, ), migrations.CreateModel( name='OnlinePlayer', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('monitoring_user', models.OneToOneField( limit_choices_to={'user_type__in': [1, 2, 3, 4]}, on_delete=django.db.models.deletion.PROTECT, related_name='onlineplayer_moniter', to=settings.AUTH_USER_MODEL)), ('user', models.OneToOneField( limit_choices_to={'user_type': 7}, on_delete=django.db.models.deletion.PROTECT, related_name='onlineplayer_player', to=settings.AUTH_USER_MODEL, verbose_name='Player')), ], options={ 'permissions': (('can_handle_query_of_player', 'can handle query of player'), ), }, ), migrations.CreateModel( name='HistoricalUser', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('password', models.CharField(max_length=128, verbose_name='password')), ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), ('is_superuser', models.BooleanField( default=False, help_text= 'Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')), ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), ('is_staff', models.BooleanField( default=False, help_text= 'Designates whether the user can log into this admin site.', verbose_name='staff status')), ('is_active', models.BooleanField( default=True, help_text= 'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('user_type', models.PositiveSmallIntegerField( choices=[(1, 'manager'), (2, 'supervisor'), ( 4, 'employee'), (3, 'admin'), ( 5, 'agent'), (7, 'online player'), (6, 'sub agent')])), ('username', phonenumber_field.modelfields.PhoneNumberField( db_index=True, error_messages={ 'unique': 'A user with that mobile already exists.' }, max_length=128, region=None, verbose_name='mobile')), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ], options={ 'verbose_name': 'historical user', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='HistoricalSupervisor', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ('parent', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type': 1}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='master.Manager', verbose_name='Manager')), ('user', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type': 2}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Supervisor')), ], options={ 'verbose_name': 'historical supervisor', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='HistoricalOnlinePlayer', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ('monitoring_user', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type__in': [1, 2, 3, 4]}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL)), ('user', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type': 7}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Player')), ], options={ 'verbose_name': 'historical online player', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='HistoricalManager', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ('parent', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={ 'is_superuser': True, 'user_type': 3 }, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Admin')), ('user', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type': 1}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Manager')), ], options={ 'verbose_name': 'historical manager', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='HistoricalEmployee', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ('parent', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type': 2}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='master.Supervisor', verbose_name='Supervisor')), ('user', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type': 4}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Employee')), ], options={ 'verbose_name': 'historical employee', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='HistoricalAgentPlayer', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('name', models.CharField(max_length=60)), ('mobile', phonenumber_field.modelfields.PhoneNumberField(blank=True, max_length=128, null=True, region=None)), ('created_on', models.DateTimeField(blank=True, editable=False)), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('agent', models.ForeignKey( blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='master.Agent')), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ], options={ 'verbose_name': 'historical agent player', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='HistoricalAgent', fields=[ ('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), ('ip_address', models.GenericIPAddressField(blank=True, null=True, verbose_name='IP address')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('commission', models.FloatField(validators=[ django.core.validators.MinValueValidator(5), django.core.validators.MaxValueValidator(50) ])), ('history_id', models.AutoField(primary_key=True, serialize=False)), ('history_date', models.DateTimeField()), ('history_change_reason', models.CharField(max_length=100, null=True)), ('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), ('history_user', models.ForeignKey( null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), ('parent', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type__in': [1, 2, 3, 4, 5, 6]}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Refered by')), ('parent_node', mptt.fields.TreeForeignKey( blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='master.Agent')), ('user', models.ForeignKey( blank=True, db_constraint=False, limit_choices_to={'user_type__in': [5, 6]}, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='Agent')), ], options={ 'verbose_name': 'historical agent', 'ordering': ('-history_date', '-history_id'), 'get_latest_by': 'history_date', }, bases=(simple_history.models.HistoricalChanges, models.Model), ), migrations.CreateModel( name='Employee', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('designation', models.CharField(default='no designation', max_length=70)), ('bank_details', django_cryptography.fields.encrypt( ckeditor.fields.RichTextField(blank=True, null=True))), ('parent', models.ForeignKey(limit_choices_to={'user_type': 2}, on_delete=django.db.models.deletion.PROTECT, related_name='employee_supervisor', to='master.Supervisor', verbose_name='Supervisor')), ('user', models.OneToOneField( limit_choices_to={'user_type': 4}, on_delete=django.db.models.deletion.PROTECT, related_name='employee_employee', to=settings.AUTH_USER_MODEL, verbose_name='Employee')), ], options={ 'permissions': (('can_verify_bank_details', 'can verify bank details'), ), }, ), migrations.CreateModel( name='AgentPlayer', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=60)), ('mobile', phonenumber_field.modelfields.PhoneNumberField(blank=True, max_length=128, null=True, region=None)), ('created_on', models.DateTimeField(auto_now_add=True)), ('agent', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, related_name='agentplayer_agent', to='master.Agent')), ], ), ]