Skip to content

Commit

Permalink
修改modell长度
Browse files Browse the repository at this point in the history
  • Loading branch information
yangbao home compute committed Nov 23, 2019
1 parent 37fa79f commit e0174ff
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 3 deletions.
Binary file modified apps/servers/migrations/__pycache__/0001_initial.cpython-36.pyc
Binary file not shown.
Binary file not shown.
Binary file modified apps/servers/migrations/__pycache__/__init__.cpython-36.pyc
Binary file not shown.
23 changes: 23 additions & 0 deletions apps/users/migrations/0004_auto_20191123_0906.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 2.2.3 on 2019-11-23 09:06

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('users', '0003_auto_20190905_1722'),
]

operations = [
migrations.AlterField(
model_name='userprofile',
name='is_staff',
field=models.CharField(blank=True, choices=[('1', '是'), ('0', '否')], default='1', max_length=10, verbose_name='是否在职'),
),
migrations.AlterField(
model_name='userprofile',
name='isadmin',
field=models.CharField(blank=True, choices=[('1', '是'), ('0', '否')], default='0', max_length=10, verbose_name='是否管理员'),
),
]
Binary file modified apps/users/migrations/__pycache__/0001_initial.cpython-36.pyc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified apps/users/migrations/__pycache__/__init__.cpython-36.pyc
Binary file not shown.
4 changes: 2 additions & 2 deletions apps/users/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
class UserProfile(AbstractUser):
staff_no = models.CharField(max_length=15, verbose_name='工号', blank=True)
department = models.CharField(max_length=15, verbose_name='部门', blank=True)
isadmin = models.CharField(max_length=1, choices=(('1', '是'), ('0', '否')),
isadmin = models.CharField(max_length=10, choices=(('1', '是'), ('0', '否')),
verbose_name='是否管理员', default='0', blank=True)
bg_telephone = models.CharField(max_length=12, verbose_name='办公电话', blank=True)
mobile = models.CharField(max_length=11, verbose_name='手机号码', blank=True)
is_superuser = models.IntegerField(verbose_name='是否超级管理员', default=0)
is_staff = models.CharField(max_length=1, choices=(('1', '是'), ('0', '否')),
is_staff = models.CharField(max_length=10, choices=(('1', '是'), ('0', '否')),
verbose_name='是否在职', default='1', blank=True)
modify_time = models.DateTimeField(default=datetime.now, verbose_name='修改时间')

Expand Down
2 changes: 1 addition & 1 deletion zcgl/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
'NAME': 'zcgl',
'USER': 'scott',
'PASSWORD': 'tiger',
'HOST': '10.40.16.61',
'HOST': '192.168.0.72',
}
}

Expand Down

0 comments on commit e0174ff

Please sign in to comment.