관리-도구
편집 파일: 183_add_user_field_to_malware_scans.py
from peewee import CharField def migrate(migrator, *_, fake=False, **__): if fake: return malware_scans = migrator.orm["malware_scans"] migrator.add_fields( malware_scans, initiator=CharField(null=True), ) def rollback(migrator, *_, fake=False, **__): if fake: return malware_scans = migrator.orm["malware_scans"] migrator.remove_fields(malware_scans, "initiator")