/****************************************************** ' System :Eco-footprint 管理ページ ' Content:会員個人検索 '******************************************************/ $top = '../..'; $inc = "$top/inc"; include("$inc/login_check.php"); include("$inc/header.php"); $inc = "$top/../inc"; include("$inc/common.php"); include("$inc/define.php"); include("$inc/database.php"); include("$inc/decode.php"); include("$inc/select.php"); include("$inc/format.php"); include("$inc/list.php"); // 登録状況 function decode_step($code) { switch($code) { case 1: return "仮登録1"; break; case 2: return "仮登録2"; break; case 3: return "本登録"; break; case 9: return "退会"; break; default: return "-不明-"; } } // 登録状況select function select_step($default,$selected) { if ($default) echo "", "\n"; echo '', "\n"; echo '', "\n"; echo '', "\n"; } // 種別select function select_kind($selected) { echo '', "\n"; echo '', "\n"; } //メイン処理 set_global('member', '会員情報管理', '会員個人検索', BACK_TOP); // セッション登録 get_session_vars($pset, 'member_personal', 'and_or', 'mail_addr', 'name1', 'name2', 'name1_kana', 'name2_kana', 'birthday_y', 'birthday_m', 'birthday_d', 'regist_y', 'regist_m', 'regist_d', 'kind', 'type', 'displine', 'sort_col', 'sort_dir', 'page'); // where条件 if ($member_id != '') and_or_join($where, "mb_id LIKE '%$member_id%'", $and_or); if ($mail_addr != '') and_or_join($where, "mb_mail_addr LIKE '%$mail_addr%'", $and_or); if ($name1 != '') and_or_join($where, "mb_name1 LIKE '%$name1%'", $and_or); if ($name2 != '') and_or_join($where, "mb_name2 LIKE '%$name2%'", $and_or); if ($name1_kana != '') and_or_join($where, "mb_name1_kana LIKE '%$name1_kana%'", $and_or); if ($name2_kana != '') and_or_join($where, "mb_name2_kana LIKE '%$name2_kana%'", $and_or); if ($birthday_y != '') and_or_join($where, "mb_birthday=" . sql_date("$birthday_y/$birthday_m/$birthday_d"), $and_or); if ($regist_y != '') and_or_join($where, "DATE_TRUNC('day', mb_regist_date)=" . sql_date("$regist_y/$regist_m/$regist_d"), $and_or); if ($step != '') and_or_join($where, "mb_step=$step", $and_or); if ($where != '') $where = "($where)"; and_join($where, 'mb_step<>9'); if ($kind != '') and_join($where, "mb_kind=$kind", $and_or); else and_join($where, "mb_kind IS NULL", $and_or); $where = "WHERE $where"; // ソート条件 $order_by = order_by(6, 1, 'mb_id', 'mb_mail_addr', 'mb_name1||mb_name2', 'mb_name1_kana||mb_name2_kana', 'mb_birthday', 'mb_regist_date','mb_step'); // 表示行数条件 $limit = disp_limit(); $sql = "select count(mb_seq_no) as count from t_member $where"; $num = db_fetch1($sql); $sql = "select mb_seq_no,mb_id,mb_mail_addr,mb_step,mb_name1,mb_name2,mb_name1_kana,mb_name2_kana,mb_birthday,mb_regist_date" . " from t_member $where $order_by $limit"; $result = db_exec($sql); $nrow = pg_numrows($result); ?>
=$fetch->mb_id?> | =htmlspecialchars($fetch->mb_mail_addr)?> | =htmlspecialchars("$fetch->mb_name1 $fetch->mb_name2")?> | =htmlspecialchars("$fetch->mb_name1_kana $fetch->mb_name2_kana")?> | =str_replace('-', '/', $fetch->mb_birthday)?> | =format_date($fetch->mb_regist_date)?> | =decode_step($fetch->mb_step)?> |