You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
484 B
Python
15 lines
484 B
Python
from django.db import models
|
|
|
|
# Create your models here.
|
|
|
|
|
|
class Department(models.Model):
|
|
name = models.CharField(max_length=128, verbose_name='部门名称')
|
|
parent_id = models.IntegerField(verbose_name='上级部门id', null=True, blank=True)
|
|
status = models.IntegerField(verbose_name='状态', default=1)
|
|
create_time = models.DateTimeField(auto_now_add=True, verbose_name='创建时间', null=True, blank=True)
|
|
|
|
class Meta:
|
|
db_table = 'tp_department'
|
|
|