관리-도구
편집 파일: 035_add_dos_expiration_field.py
import peewee as pw def migrate(migrator, database, fake=False, **kwargs): IPList = migrator.orm["iplist"] migrator.add_fields( IPList, dos_expiration=pw.IntegerField(default=0, null=True) ) def rollback(migrator, database, fake=False, **kwargs): IPList = migrator.orm["iplist"] migrator.remove_fields(IPList, "dos_expiration")