diff options
author | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-05-11 08:35:16 +0800 |
---|---|---|
committer | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-05-11 08:35:16 +0800 |
commit | d57f0ffcb377f57cda39795fd032d7ba2690eaf8 (patch) | |
tree | 04766bc692bdc041f69ec4f523340b771fe1ec11 | |
parent | fc1df3375ea5d4bada5db4802f563f575bebf362 (diff) | |
download | pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.tar pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.tar.gz pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.tar.bz2 pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.tar.lz pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.tar.xz pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.tar.zst pttbbs-d57f0ffcb377f57cda39795fd032d7ba2690eaf8.zip |
last commit err
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@835 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | mbbsd/admin.c | 4 | ||||
-rw-r--r-- | mbbsd/mbbsd.c | 4 | ||||
-rw-r--r-- | mbbsd/user.c | 18 | ||||
-rw-r--r-- | sample/pttbbs.conf | 4 |
4 files changed, 16 insertions, 14 deletions
diff --git a/mbbsd/admin.c b/mbbsd/admin.c index 309f0f8d..5253a37c 100644 --- a/mbbsd/admin.c +++ b/mbbsd/admin.c @@ -1,4 +1,4 @@ -/* $Id: admin.c,v 1.35 2003/05/10 16:52:01 bbs Exp $ */ +/* $Id: admin.c,v 1.36 2003/05/11 00:35:16 victor Exp $ */ #include "bbs.h" /* 使用者管理 */ @@ -823,7 +823,7 @@ scan_register_form(char *regfile, int automode, int neednum) prints("\033[1;32m------------- 請站長嚴格審核使用者資料,您還有 %d 份---------------\033[m\n", neednum); prints(" %-12s:%s\n", finfo[0], fdata[0]); prints(" %-12s:%s\n", finfo[1], fdata[1]); -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG prints("1.%-12s:%s%s\n", finfo[n], fdata[n], muser.uflag2 & FOREIGN ? "外籍" : ""); #else prints("1.%-12s:%s\n", finfo[n], fdata[n]); diff --git a/mbbsd/mbbsd.c b/mbbsd/mbbsd.c index 33f45264..d52ffbcb 100644 --- a/mbbsd/mbbsd.c +++ b/mbbsd/mbbsd.c @@ -1,4 +1,4 @@ -/* $Id: mbbsd.c,v 1.75 2003/05/10 16:52:01 bbs Exp $ */ +/* $Id: mbbsd.c,v 1.76 2003/05/11 00:35:16 victor Exp $ */ #include "bbs.h" #define SOCKET_QLEN 4 @@ -884,7 +884,7 @@ user_login() if (!PERM_HIDE(currutmp)) cuser.lastlogin = login_start_time; -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG if (cuser.uflag2 & (FOREIGN | LIVERIGHT)){ if (login_start_time - cuser.firstlogin > (FOREIGN_REG_DAY - 5) * 24 * 3600){ mail_muser(cuser, "[出入境管理局]", "etc/foreign_expired_warn"); diff --git a/mbbsd/user.c b/mbbsd/user.c index 0ff9a7f0..98c8eac1 100644 --- a/mbbsd/user.c +++ b/mbbsd/user.c @@ -1,4 +1,4 @@ -/* $Id: user.c,v 1.56 2003/05/10 16:52:01 bbs Exp $ */ +/* $Id: user.c,v 1.57 2003/05/11 00:35:16 victor Exp $ */ #include "bbs.h" static char *sex[8] = { @@ -52,7 +52,7 @@ user_display(userec_t * u, int real) " \033[m \033[30;41m┴┬┴┬┴┬\033[m\n"); prints(" 代號暱稱: %s(%s)\n" " 真實姓名: %s" -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG " %s%s" #endif "\n" @@ -61,7 +61,7 @@ user_display(userec_t * u, int real) " 性 別: %s\n" " 銀行帳戶: %d 銀兩\n", u->userid, u->username, u->realname, -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG u->uflag2 & FOREIGN ? "(外籍: " : "", u->uflag2 & FOREIGN ? (u->uflag2 & LIVERIGHT) ? "永久居留)" : "未取得居留權)" @@ -320,7 +320,7 @@ uinfo_query(userec_t * u, int real, int unum) if (real) { getdata_buf(i++, 0, "真實姓名:", x.realname, sizeof(x.realname), DOECHO); -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG getdata_buf(i++, 0, cuser.uflag2 & FOREIGN ? "護照號碼" : "身分證號:", #else getdata_buf(i++, 0, "身分證號:", @@ -448,7 +448,7 @@ uinfo_query(userec_t * u, int real, int unum) x.chc_tie = atoi(p); break; } -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG if (getdata_str(i++, 0, "國籍 1)本國 2)外國:", buf, 2, DOECHO, x.uflag2 & FOREIGN ? "2" : "1")) if ((fail = atoi(buf)) > 0){ if (fail == 2){ @@ -939,7 +939,7 @@ toregister(char *email, char *genbuf, char *phone, char *career, char fore, fn = fopen(buf, "w"); assert(fn); fprintf(fn, "%s%s\n%s\n%s\n%s\n%s\n%s\n", -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG fore & FOREIGN ? "#foreign\n" : #endif "", @@ -1235,7 +1235,7 @@ u_register(void) move(1, 0); prints("%s(%s) 您好,請據實填寫以下的資料:", cuser.userid, cuser.username); -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG while (1) { getfield(2, "Y/n", "是否為本國籍?", fore, 2); fore[0] = tolower(fore[0]); @@ -1261,7 +1261,7 @@ u_register(void) break; vmsg("您的輸入不正確(若有問題麻煩至SYSOP板)"); } -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG } else{ while( 1 ){ @@ -1353,7 +1353,7 @@ u_register(void) cuser.month = mon; cuser.day = day; cuser.year = year; -#ifdef FOREIGN_REG_DAY +#ifdef FOREIGN_REG if (fore[0]) cuser.uflag2 |= FOREIGN; else diff --git a/sample/pttbbs.conf b/sample/pttbbs.conf index 8a09e6a0..73a324bd 100644 --- a/sample/pttbbs.conf +++ b/sample/pttbbs.conf @@ -42,7 +42,9 @@ /* 定義看板好友名單將會在幾秒鐘後失效強迫重載 */ #define HBFLexpire (432000) -/* 定義外國人最長居留時間,之後需向站方申請永久居留權 */ +/* 定義是否使用外籍使用者註冊 + 及外國人最長居留時間,之後需向站方申請永久居留權 */ +#define FOREIGN_REG #define FOREIGN_REG_DAY 30 /* 板主可以按大寫 H切換隱形與否 */ |