diff options
author | wens <wens@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2006-09-28 21:32:34 +0800 |
---|---|---|
committer | wens <wens@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2006-09-28 21:32:34 +0800 |
commit | dfe040bf4ad27abe77951f778c7b822c346e4556 (patch) | |
tree | 5a6b5124dd76c9dc090dc7180ccc8597a057bb52 /mbbsd/syspost.c | |
parent | 79d83827832f47bce28465646d89d3b76ddbbe99 (diff) | |
download | pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.tar pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.tar.gz pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.tar.bz2 pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.tar.lz pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.tar.xz pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.tar.zst pttbbs-dfe040bf4ad27abe77951f778c7b822c346e4556.zip |
* police logs
* lock article confirmation
* change permission of police actions (BMs are not allowed)
* remove police info from lock article
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3432 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/syspost.c')
-rw-r--r-- | mbbsd/syspost.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/mbbsd/syspost.c b/mbbsd/syspost.c index 447e00e3..36148543 100644 --- a/mbbsd/syspost.c +++ b/mbbsd/syspost.c @@ -128,3 +128,17 @@ post_newboard(const char *bgroup, const char *bname, const char *bms) post_msg("Record", title, genbuf, "[系統]"); } + +void +post_policelog(const char *bname, const char *atitle, const char *action, const int toggle) +{ + char genbuf[256], title[TTLEN+1]; + + snprintf(title, sizeof(title), "[%s] %s by %s", action, bname, cuser.userid); + snprintf(genbuf, sizeof(genbuf), + "%s (%s) %s %s 看板 %s 功能\n%s%s\n", + cuser.userid, fromhost, toggle ? "開啟" : "關閉", bname, action, + atitle ? "文章標題" : "", atitle ? atitle : ""); + + post_msg("PoliceLog", title, genbuf, "[系統]"); +} |