2024-11-18 02:47:25 +08:00
|
|
|
# Permission List
|
2024-11-19 21:22:01 +08:00
|
|
|
PLIST = ["article.read", "article.pend", "article.del", "setting.edit"] # no permission:usermgr except root
|
|
|
|
PLIST_ROOT = PLIST + ["usermgr"]
|
|
|
|
|
|
|
|
# event type
|
2024-11-19 23:29:01 +08:00
|
|
|
EVENT_TYPE = {
|
2024-12-09 03:24:22 +08:00
|
|
|
"general": ["newpost", "delpost", "newcomment", "delcomment"],
|
2024-12-17 01:08:35 +08:00
|
|
|
"admin": ["login", "user.create", "user.delete", # user
|
|
|
|
"article.delete", "comment.delete", # article
|
|
|
|
"article.pend", "comment.pend", # comment
|
|
|
|
"setting.modify"], # settings
|
2024-11-19 23:29:01 +08:00
|
|
|
"server": ["server.start"]
|
|
|
|
}
|
2024-11-18 02:47:25 +08:00
|
|
|
|
|
|
|
# Platform Setting Model
|
2024-11-19 21:22:01 +08:00
|
|
|
PLATFORM_SETTING_MODEL = {
|
2024-11-18 02:47:25 +08:00
|
|
|
"Check_Before_Post": [bool],
|
|
|
|
"JWT_Valid_Time": [int],
|
|
|
|
"Niming_Max_Word": [int],
|
|
|
|
"Attachment_Count": [int],
|
|
|
|
"Attachment_Size": [int],
|
|
|
|
"Allowed_MIME": [list, str],
|
2024-12-09 03:24:22 +08:00
|
|
|
}
|