From 9ab109aca68e1c0d292f17c8942681e82bec8411 Mon Sep 17 00:00:00 2001 From: chicpro Date: Fri, 6 Dec 2013 10:21:23 +0900 Subject: [PATCH] =?UTF-8?q?=ED=8C=9D=EC=97=85=20=EB=A0=88=EC=9D=B4?= =?UTF-8?q?=EC=96=B4=20=EC=A0=91=EC=86=8D=EA=B8=B0=EA=B8=B0=20=EC=84=A4?= =?UTF-8?q?=EC=A0=95=ED=95=A0=20=EC=88=98=20=EC=9E=88=EB=8F=84=EB=A1=9D=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- adm/shop_admin/newwinform.php | 12 ++++++++ adm/shop_admin/newwinformupdate.php | 6 ++-- adm/shop_admin/newwinlist.php | 16 +++++++++- extend/shop.extend2.php | 6 ++++ install/gnuboard5shop.sql | 1 + mobile/shop/newwin.inc.php | 48 +++++++++++++++++++++++++++++ mobile/shop/shop.head.php | 7 +++++ shop/newwin.inc.php | 1 + 8 files changed, 92 insertions(+), 5 deletions(-) create mode 100644 mobile/shop/newwin.inc.php diff --git a/adm/shop_admin/newwinform.php b/adm/shop_admin/newwinform.php index a87632cef..745f3d0da 100644 --- a/adm/shop_admin/newwinform.php +++ b/adm/shop_admin/newwinform.php @@ -16,6 +16,7 @@ if ($w == "u") else { $html_title .= " 입력"; + $nw['nw_device'] = 'both'; $nw['nw_disable_hours'] = 24; $nw['nw_left'] = 10; $nw['nw_top'] = 10; @@ -44,6 +45,17 @@ include_once (G5_ADMIN_PATH.'/admin.head.php'); + + + + + + + diff --git a/adm/shop_admin/newwinformupdate.php b/adm/shop_admin/newwinformupdate.php index dc3fdf43a..63a0a8179 100644 --- a/adm/shop_admin/newwinformupdate.php +++ b/adm/shop_admin/newwinformupdate.php @@ -10,7 +10,8 @@ if ($W == 'd') else auth_check($auth[$sub_menu], "w"); -$sql_common = " nw_begin_time = '$nw_begin_time', +$sql_common = " nw_device = '$nw_device', + nw_begin_time = '$nw_begin_time', nw_end_time = '$nw_end_time', nw_disable_hours = '$nw_disable_hours', nw_left = '$nw_left', @@ -23,9 +24,6 @@ $sql_common = " nw_begin_time = '$nw_begin_time', if($w == "") { - $sql = " alter table {$g5['g5_shop_new_win_table']} auto_increment=1 "; - sql_query($sql); - $sql = " insert {$g5['g5_shop_new_win_table']} set $sql_common "; sql_query($sql); diff --git a/adm/shop_admin/newwinlist.php b/adm/shop_admin/newwinlist.php index b6c2c2a35..55f5ff720 100644 --- a/adm/shop_admin/newwinlist.php +++ b/adm/shop_admin/newwinlist.php @@ -31,6 +31,7 @@ $result = sql_query($sql); 번호 제목 + 접속기기 시작일시 종료일시 시간 @@ -45,10 +46,23 @@ $result = sql_query($sql); + 시간 @@ -65,7 +79,7 @@ $result = sql_query($sql); } if ($i == 0) { - echo '자료가 한건도 없습니다.'; + echo '자료가 한건도 없습니다.'; } ?> diff --git a/extend/shop.extend2.php b/extend/shop.extend2.php index bf717cdb8..1c5f2d6a4 100644 --- a/extend/shop.extend2.php +++ b/extend/shop.extend2.php @@ -737,4 +737,10 @@ if(!sql_query(" select it_soldout from {$g5['g5_shop_item_table']} limit 1 ", fa sql_query(" ALTER TABLE `{$g5['g5_shop_item_table']}` ADD `it_soldout` tinyint(4) NOT NULL DEFAULT '0' AFTER `it_use` ", true); } + +// 팝업 레이어 접속기기 필드 추가 +if(!sql_query(" select nw_device from {$g5['g5_shop_new_win_table']} limit 1 ", false)) { + sql_query(" ALTER TABLE `{$g5['g5_shop_new_win_table']}` + ADD `nw_device` varchar(10) NOT NULL DEFAULT 'both' AFTER `nw_id` ", true); +} ?> diff --git a/install/gnuboard5shop.sql b/install/gnuboard5shop.sql index 2378f622a..514761384 100644 --- a/install/gnuboard5shop.sql +++ b/install/gnuboard5shop.sql @@ -579,6 +579,7 @@ CREATE TABLE IF NOT EXISTS `g5_shop_item_relation` ( DROP TABLE IF EXISTS `g5_shop_new_win`; CREATE TABLE IF NOT EXISTS `g5_shop_new_win` ( `nw_id` int(11) NOT NULL AUTO_INCREMENT, + `nw_device` varchar(10) NOT NULL DEFAULT 'both', `nw_begin_time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', `nw_end_time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', `nw_disable_hours` int(11) NOT NULL DEFAULT '0', diff --git a/mobile/shop/newwin.inc.php b/mobile/shop/newwin.inc.php new file mode 100644 index 000000000..22ce66fb0 --- /dev/null +++ b/mobile/shop/newwin.inc.php @@ -0,0 +1,48 @@ + + + +
+
+ +
+ +
+팝업레이어 알림이 없습니다.'; +?> + + + \ No newline at end of file diff --git a/mobile/shop/shop.head.php b/mobile/shop/shop.head.php index 472c89702..57a24329f 100644 --- a/mobile/shop/shop.head.php +++ b/mobile/shop/shop.head.php @@ -12,6 +12,13 @@ include_once(G5_LIB_PATH.'/popular.lib.php');
본문 바로가기
+ +
+

팝업레이어 알림

+ +
+ + 분류 diff --git a/shop/newwin.inc.php b/shop/newwin.inc.php index 562dae2d3..976dbb7ab 100644 --- a/shop/newwin.inc.php +++ b/shop/newwin.inc.php @@ -3,6 +3,7 @@ if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가 $sql = " select * from {$g5['g5_shop_new_win_table']} where '".G5_TIME_YMDHIS."' between nw_begin_time and nw_end_time + and nw_device IN ( 'both', 'pc' ) order by nw_id asc "; $result = sql_query($sql); for ($i=0; $row_nw=sql_fetch_array($result); $i++)