| 1 | <?php
|
|---|
| 2 | /*
|
|---|
| 3 | * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
|
|---|
| 4 | *
|
|---|
| 5 | * http://www.lockon.co.jp/
|
|---|
| 6 | */
|
|---|
| 7 | require_once("../require.php");
|
|---|
| 8 |
|
|---|
| 9 | class LC_Page {
|
|---|
| 10 | var $arrSession;
|
|---|
| 11 | var $list_data;
|
|---|
| 12 | var $default_template;
|
|---|
| 13 | var $default_template_mobile;
|
|---|
| 14 | var $arrMagazineType;
|
|---|
| 15 |
|
|---|
| 16 | function LC_Page() {
|
|---|
| 17 | $this->tpl_mainpage = 'basis/template.tpl';
|
|---|
| 18 | $this->tpl_mainno = 'basis';
|
|---|
| 19 | $this->tpl_subnavi = 'basis/subnavi.tpl';
|
|---|
| 20 | $this->tpl_subno = 'mail';
|
|---|
| 21 | $this->tpl_subtitle = '¥Æ¥ó¥×¥ì¡¼¥ÈÀßÄê';
|
|---|
| 22 | }
|
|---|
| 23 | }
|
|---|
| 24 |
|
|---|
| 25 | $conn = new SC_DBConn();
|
|---|
| 26 | $objPage = new LC_Page();
|
|---|
| 27 | $objView = new SC_AdminView();
|
|---|
| 28 | $objSess = new SC_Session();
|
|---|
| 29 |
|
|---|
| 30 | // ǧ¾Ú²ÄÈݤÎȽÄê
|
|---|
| 31 | sfIsSuccess($objSess);
|
|---|
| 32 |
|
|---|
| 33 | if ( $_GET['mode'] == "delete" && sfCheckNumLength($_GET['id'])===true ){
|
|---|
| 34 |
|
|---|
| 35 | // ÅÐÏ¿ºï½ü
|
|---|
| 36 | $sql = "UPDATE dtb_mailtemplate SET del_flg = 1 WHERE template_id = ?";
|
|---|
| 37 | $conn->query($sql, array($_GET['id']));
|
|---|
| 38 | sfReload();
|
|---|
| 39 | }
|
|---|
| 40 |
|
|---|
| 41 |
|
|---|
| 42 | $sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = 0";
|
|---|
| 43 | $default_template = $conn->getAll($sql);
|
|---|
| 44 | $objPage->default_template = $default_template[0];
|
|---|
| 45 |
|
|---|
| 46 | $sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = 1";
|
|---|
| 47 | $default_template_mobile = $conn->getAll($sql);
|
|---|
| 48 | $objPage->default_template_mobile = $default_template_mobile[0];
|
|---|
| 49 |
|
|---|
| 50 | $sql = "SELECT * FROM dtb_mailtemplate WHERE del_flg = 0 AND template_id >1 ORDER BY create_date ASC";
|
|---|
| 51 | $list_data = $conn->getAll($sql);
|
|---|
| 52 | $linemax = count($list_data);
|
|---|
| 53 |
|
|---|
| 54 | for($i = 0;$i < count($list_data);$i++){
|
|---|
| 55 | $split_data = explode(".",$list_data[$i]["create_date"]);
|
|---|
| 56 | $list_data[$i]["create_date"] = $split_data[0];
|
|---|
| 57 | }
|
|---|
| 58 |
|
|---|
| 59 | //print_r($list_data);
|
|---|
| 60 | $objPage->list_data = $list_data;
|
|---|
| 61 | $objPage->arrMagazineType = $arrMagazineTypeAll;
|
|---|
| 62 |
|
|---|
| 63 | $objView->assignobj($objPage);
|
|---|
| 64 | $objView->display(MAIN_FRAME);
|
|---|
| 65 | ?> |
|---|