summaryrefslogtreecommitdiffstats
path: root/mbbsd/bbs.c
diff options
context:
space:
mode:
authorvictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-02-02 15:48:58 +0800
committervictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-02-02 15:48:58 +0800
commit75959970db064a713d61af3754bbf6fd9f07e254 (patch)
tree4c4824901de07e523146359bf09d7c1e9c05a64b /mbbsd/bbs.c
parentd6c16a5e66db737d0e7d987aa6837f08070e3fe2 (diff)
downloadpttbbs-75959970db064a713d61af3754bbf6fd9f07e254.tar
pttbbs-75959970db064a713d61af3754bbf6fd9f07e254.tar.gz
pttbbs-75959970db064a713d61af3754bbf6fd9f07e254.tar.bz2
pttbbs-75959970db064a713d61af3754bbf6fd9f07e254.tar.lz
pttbbs-75959970db064a713d61af3754bbf6fd9f07e254.tar.xz
pttbbs-75959970db064a713d61af3754bbf6fd9f07e254.tar.zst
pttbbs-75959970db064a713d61af3754bbf6fd9f07e254.zip
reason for bad post
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@1506 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/bbs.c')
-rw-r--r--mbbsd/bbs.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c
index 8c93f7b3..5b04073f 100644
--- a/mbbsd/bbs.c
+++ b/mbbsd/bbs.c
@@ -3,6 +3,10 @@
static int recommend(int ent, fileheader_t * fhdr, char *direct);
+static char *badpost_reason[] = {
+ "廣告", "不當用辭", "人身攻擊"
+};
+
static void
mail_by_link(char *owner, char *title, char *path)
{
@@ -1872,19 +1876,33 @@ del_post(int ent, fileheader_t * fhdr, char *direct)
else
num = searchuser(fhdr->owner);
#ifdef ASSESS
+#define SIZE sizeof(badpost_reason) / sizeof(char *)
if (not_owned && num > 0 && !(currmode & MODE_DIGEST)) {
getdata(1, 40, "惡劣文章?(y/N)", genbuf, 3, LCECHO);
if(genbuf[0]=='y') {
+ int i;
+ char reason[64];
+ move(b_lines - 2, 0);
+ for (i = 0; i < SIZE; i++)
+ prints("%d.%s ", i + 1, badpost_reason[i]);
+ prints("%d.%s", i + 1, "其他");
+ getdata(b_lines - 1, 0, "請選擇", reason, sizeof(reason), LCECHO);
+ i = reason[0] - '0';
+ if (i <= 0 || i > SIZE)
+ getdata(b_lines, 0, "請輸入原因", reason, sizeof(reason), DOECHO);
+ else
+ strcpy(reason, badpost_reason[i - 1]);
if (!(inc_badpost(num, 1) % 10)){
post_violatelaw(xuser.userid, "Ptt 系統警察", "劣文累計十篇", "罰單一張");
mail_violatelaw(xuser.userid, "Ptt 系統警察", "劣文累計十篇", "罰單一張");
xuser.userlevel |= PERM_VIOLATELAW;
}
- sprintf(genbuf,"劣文退回:%-40.40s", fhdr->title);
+ sprintf(genbuf,"劣文退回(%s):%-40.40s", reason, fhdr->title);
mail_id(xuser.userid, genbuf, newpath, cuser.userid);
}
}
+#undef SIZE
#endif
setbtotal(currbid);