mirror of
https://github.com/QingdaoU/OnlineJudge.git
synced 2025-01-16 01:13:47 +00:00
18 lines
479 B
Python
18 lines
479 B
Python
from django.db import models
|
|
|
|
from account.models import User
|
|
from utils.models import RichTextField
|
|
|
|
|
|
class Announcement(models.Model):
|
|
title = models.CharField(max_length=50)
|
|
# HTML
|
|
content = RichTextField()
|
|
create_time = models.DateTimeField(auto_now_add=True)
|
|
created_by = models.ForeignKey(User)
|
|
last_update_time = models.DateTimeField(auto_now=True)
|
|
visible = models.BooleanField(default=True)
|
|
|
|
class Meta:
|
|
db_table = "announcement"
|