From 3eca44299c5f563a225c47944e1fb53c4ad1a8d6 Mon Sep 17 00:00:00 2001 From: victor Date: Sat, 19 Feb 2005 06:55:12 +0000 Subject: define FOREIGN_REG to allow foreigner's registration define FOREIGN_REG_DAY to limit their deadline to get the right of stay git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2522 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/admin.c | 2 +- mbbsd/user.c | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'mbbsd') diff --git a/mbbsd/admin.c b/mbbsd/admin.c index 54930204..f357f1e3 100644 --- a/mbbsd/admin.c +++ b/mbbsd/admin.c @@ -1234,7 +1234,7 @@ scan_register_form(char *regfile, int automode, int neednum) default: outs("以下使用者資料已經更新:\n"); mail_muser(muser, "[註冊成功\囉]", "etc/registered"); -#ifdef FOREIGN_REG +#ifdef FOREIGN_REG_DAY > 0 if(muser.uflag2 & FOREIGN) mail_muser(muser, "[出入境管理局]", "etc/foreign_welcome"); #endif diff --git a/mbbsd/user.c b/mbbsd/user.c index 8802dfcb..6b0cd115 100644 --- a/mbbsd/user.c +++ b/mbbsd/user.c @@ -71,8 +71,10 @@ user_display(userec_t * u, int real) " \033[m \033[30;41m┴┬┴┬┴┬\033[m\n"); prints(" 代號暱稱: %s(%s)\n" " 真實姓名: %s" -#ifdef FOREIGN_REG +#ifdef FOREIGN_REG_DAY > 0 " %s%s" +#elif defined(FOREIGN_REG) + " %s" #endif "\n" " 居住住址: %s\n" @@ -80,11 +82,13 @@ user_display(userec_t * u, int real) " 性 別: %s\n" " 銀行帳戶: %d 銀兩\n", u->userid, u->username, u->realname, -#ifdef FOREIGN_REG +#ifdef FOREIGN_REG_DAY > 0 u->uflag2 & FOREIGN ? "(外籍: " : "", u->uflag2 & FOREIGN ? (u->uflag2 & LIVERIGHT) ? "永久居留)" : "未取得居留權)" : "", +#elif defined(FOREIGN_REG) + u->uflag2 & FOREIGN ? "(外籍)" : "", #endif u->address, u->email, sex[u->sex % 8], u->money); @@ -1429,7 +1433,7 @@ u_register(void) exit(0); } mail_muser(cuser, "[註冊成功\囉]", "etc/registeredmail"); -#ifdef FOREIGN_REG +#ifdef FOREIGN_REG_DAY > 0 if(cuser.uflag2 & FOREIGN) mail_muser(cuser, "[出入境管理局]", "etc/foreign_welcome"); #endif -- cgit v1.2.3