diff --git a/adm/admin.head.php b/adm/admin.head.php index fb3b2096e..e2d25a1e9 100644 --- a/adm/admin.head.php +++ b/adm/admin.head.php @@ -136,7 +136,7 @@ function imageview(id, w, h)
  • - + 사용후기 diff --git a/adm/admin.menu400.shop_1of2.php b/adm/admin.menu400.shop_1of2.php index 007291aa1..2f6d44288 100644 --- a/adm/admin.menu400.shop_1of2.php +++ b/adm/admin.menu400.shop_1of2.php @@ -10,13 +10,14 @@ $menu['menu400'] = array ( array('400200', '분류관리', G4_ADMIN_URL.'/shop_admin/categorylist.php', 'scf_cate'), array('400300', '상품관리', G4_ADMIN_URL.'/shop_admin/itemlist.php', 'scf_item'), array('400660', '상품문의', G4_ADMIN_URL.'/shop_admin/itemqalist.php', 'scf_item_qna'), - array('400650', '사용후기', G4_ADMIN_URL.'/shop_admin/itempslist.php', 'scf_ps'), + array('400650', '사용후기', G4_ADMIN_URL.'/shop_admin/itemuselist.php', 'scf_ps'), array('400620', '상품재고관리', G4_ADMIN_URL.'/shop_admin/itemstocklist.php', 'scf_item_stock'), array('400610', '상품유형관리', G4_ADMIN_URL.'/shop_admin/itemtypelist.php', 'scf_item_type'), array('400500', '상품옵션재고관리', G4_ADMIN_URL.'/shop_admin/optionstocklist.php', 'scf_item_option'), array('400490', '마일리지관리', G4_ADMIN_URL.'/shop_admin/mileagelist.php', 'scf_mileage'), array('400650', '쿠폰관리', G4_ADMIN_URL.'/shop_admin/couponlist.php', 'scf_coupon'), array('400500', '배송일괄처리', G4_ADMIN_URL.'/shop_admin/deliverylist.php', 'scf_deli', 1), - array('400740', '배송업체관리', G4_ADMIN_URL.'/shop_admin/deliverycodelist.php', 'scf_deli_co', 1) + array('400740', '배송업체관리', G4_ADMIN_URL.'/shop_admin/deliverycodelist.php', 'scf_deli_co', 1), + array('400750', '추가배송비관리', G4_ADMIN_URL.'/shop_admin/sendcostlist.php', 'scf_sendcost', 1) ); ?> \ No newline at end of file diff --git a/adm/shop_admin/configform.php b/adm/shop_admin/configform.php index be2879968..8ff303a84 100644 --- a/adm/shop_admin/configform.php +++ b/adm/shop_admin/configform.php @@ -754,12 +754,12 @@ $pg_anchor = ' +
    + + + + + + + + @@ -125,26 +137,31 @@ if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 + - + - + @@ -152,17 +169,53 @@ if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 } if ($i == 0) { - echo ''; + echo ''; } ?>
    + + + 상품명 이름 제목
    + + + + + + + value="1"> - 수정 - 삭제 + 수정
    자료가 없습니다.
    자료가 없습니다.
    +
    + + +
    +
    + - + + diff --git a/adm/shop_admin/itemuselistupdate.php b/adm/shop_admin/itemuselistupdate.php new file mode 100644 index 000000000..c7c22e1d2 --- /dev/null +++ b/adm/shop_admin/itemuselistupdate.php @@ -0,0 +1,39 @@ + diff --git a/adm/shop_admin/sendcostlist.php b/adm/shop_admin/sendcostlist.php new file mode 100644 index 000000000..08a9c462c --- /dev/null +++ b/adm/shop_admin/sendcostlist.php @@ -0,0 +1,161 @@ + + +
    +

    추가배송비 내역

    + +
    + + + + + + + + + + + + + + + + + + + + + '; + ?> + +
    + + + 지역명우편번호추가배송비
    + + +
    자료가 없습니다.
    + +
    + +
    + +
    +
    + + + +
    +

    추가배송비 등록

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    + + +
    + + +
    + +
    + +
    + +
    + +
    + + + + \ No newline at end of file diff --git a/adm/shop_admin/sendcostupdate.php b/adm/shop_admin/sendcostupdate.php new file mode 100644 index 000000000..37f381dd6 --- /dev/null +++ b/adm/shop_admin/sendcostupdate.php @@ -0,0 +1,45 @@ + \ No newline at end of file diff --git a/adm/shop_admin/sendcostzipcode.php b/adm/shop_admin/sendcostzipcode.php new file mode 100644 index 000000000..0f61c69e0 --- /dev/null +++ b/adm/shop_admin/sendcostzipcode.php @@ -0,0 +1,117 @@ +'.$value.' '.PHP_EOL; + } + } +} + +$g4['title'] = "우편번호 찾기"; +include_once(G4_PATH.'/head.sub.php'); +?> + + +
    +
    + + + + + + + + + + + +
    우편번호 찾기
    주소지의 시/군을 입력하세요.
    + + + +
    +
    + + +

    검색결과

    +

    + +

    검색된 결과가 없습니다.

    + +
    + + + + \ No newline at end of file diff --git a/css/admin.css b/css/admin.css index e15919e65..ece22dad2 100644 --- a/css/admin.css +++ b/css/admin.css @@ -232,8 +232,8 @@ strong.sodr_nonpay {display:block;padding:5px 0;text-align:right} .sit_qa_answer {width:30px;text-align:center} /* 사용후기 */ -.sit_ps_subject {width:290px} -.sit_ps_confirm {width:30px;text-align:center} +.sit_use_subject {width:290px} +.sit_use_confirm {width:30px;text-align:center} /* 상품옵션재고관리 */ .sit_stock_qty_alert {color:#ff1133;font-weight:bold} diff --git a/extend/shop.extend2.php b/extend/shop.extend2.php index cb3310c15..f13e10d10 100644 --- a/extend/shop.extend2.php +++ b/extend/shop.extend2.php @@ -142,7 +142,7 @@ if(intval(preg_replace("/[^0-9]/", "", $row['Type'])) != 20) { sql_query(" ALTER TABLE `{$g4['shop_item_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); sql_query(" ALTER TABLE `{$g4['shop_cart_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); sql_query(" ALTER TABLE `{$g4['shop_item_qa_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); - sql_query(" ALTER TABLE `{$g4['shop_item_ps_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); + sql_query(" ALTER TABLE `{$g4['shop_item_use_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); sql_query(" ALTER TABLE `{$g4['shop_item_relation_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); sql_query(" ALTER TABLE `{$g4['shop_item_relation_table']}` MODIFY COLUMN it_id2 VARCHAR(20) NOT NULL DEFAULT '' ", false); sql_query(" ALTER TABLE `{$g4['shop_event_item_table']}` MODIFY COLUMN it_id VARCHAR(20) NOT NULL DEFAULT '' ", false); @@ -312,4 +312,20 @@ if(!$result) { ADD `od_receipt_amount` INT(11) NOT NULL DEFAULT '0' AFTER `od_temp_point`, ADD `od_receipt_time` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `od_bank_account` ", false); } + +// 추가배송비 테이블 +$sql = " select sc_id from {$g4['shop_sendcost_table']} limit 1 "; +$result = sql_query($sql, false); +if(!$result) { + sql_query(" CREATE TABLE IF NOT EXISTS `{$g4['shop_sendcost_table']}` ( + `sc_id` INT(11) NOT NULL AUTO_INCREMENT, + `sc_name` VARCHAR(255) NOT NULL DEFAULT '', + `sc_zip1` VARCHAR(10) NOT NULL DEFAULT '', + `sc_zip2` VARCHAR(10) NOT NULL DEFAULT '', + `sc_amount` INT(11) NOT NULL DEFAULT '0', + PRIMARY KEY (`sc_id`), + KEY `sc_zip1` (`sc_zip1`), + KEY `sc_zip2` (`sc_zip2`) + )", true); +} ?> \ No newline at end of file diff --git a/install/install_db.php b/install/install_db.php index 3e05de7b8..415a11cd6 100644 --- a/install/install_db.php +++ b/install/install_db.php @@ -284,7 +284,7 @@ if($shop_install) { de_simg_height = '$simg_height', de_mimg_width = '$mimg_width', de_mimg_height = '$mimg_height', - de_item_ps_use = '1', + de_item_use_use = '1', de_level_sell = '1', de_code_dup_use = '1', de_sms_cont1 = '{이름}님의 회원가입을 축하드립니다.\nID:{회원아이디}\n{회사명}', @@ -485,7 +485,7 @@ if($shop_install) { fwrite($f, "\$g4['shop_faq_master_table'] = SHOP_TABLE_PREFIX.'faq_master'; // 자주하시는 질문 마스터 테이블\n"); fwrite($f, "\$g4['shop_item_table'] = SHOP_TABLE_PREFIX.'item'; // 상품 테이블\n"); fwrite($f, "\$g4['shop_item_option_table'] = SHOP_TABLE_PREFIX.'item_option'; // 상품옵션 테이블\n"); - fwrite($f, "\$g4['shop_item_ps_table'] = SHOP_TABLE_PREFIX.'item_ps'; // 상품 사용후기 테이블\n"); + fwrite($f, "\$g4['shop_item_use_table'] = SHOP_TABLE_PREFIX.'item_use'; // 상품 사용후기 테이블\n"); fwrite($f, "\$g4['shop_item_qa_table'] = SHOP_TABLE_PREFIX.'item_qa'; // 상품 질문답변 테이블\n"); fwrite($f, "\$g4['shop_item_relation_table'] = SHOP_TABLE_PREFIX.'item_relation'; // 관련 상품 테이블\n"); fwrite($f, "\$g4['shop_new_win_table'] = SHOP_TABLE_PREFIX.'new_win'; // 새창 테이블\n"); @@ -494,6 +494,7 @@ if($shop_install) { fwrite($f, "\$g4['shop_wish_table'] = SHOP_TABLE_PREFIX.'wish'; // 보관함(위시리스트) 테이블\n"); fwrite($f, "\$g4['shop_mileage_table'] = SHOP_TABLE_PREFIX.'mileage'; // 마일리지 테이블\n"); fwrite($f, "\$g4['shop_coupon_table'] = SHOP_TABLE_PREFIX.'coupon'; // 쿠폰정보 테이블\n"); + fwrite($f, "\$g4['shop_sendcost_table'] = SHOP_TABLE_PREFIX.'sendcost'; // 추가배송비 테이블\n"); fwrite($f, "?>"); } diff --git a/install/shop.sql b/install/shop.sql index d348aae01..061d04679 100644 --- a/install/shop.sql +++ b/install/shop.sql @@ -280,7 +280,7 @@ CREATE TABLE IF NOT EXISTS `shop_default` ( `de_sms_hp` varchar(255) NOT NULL DEFAULT '', `de_kcp_mid` varchar(255) NOT NULL DEFAULT '', `de_iche_use` tinyint(4) NOT NULL DEFAULT '0', - `de_item_ps_use` tinyint(4) NOT NULL DEFAULT '0', + `de_item_use_use` tinyint(4) NOT NULL DEFAULT '0', `de_code_dup_use` tinyint(4) NOT NULL DEFAULT '0', `de_cart_keep_term` int(11) NOT NULL DEFAULT '0', `de_guest_cart_use` tinyint(4) NOT NULL DEFAULT '0', @@ -475,11 +475,11 @@ CREATE TABLE IF NOT EXISTS `shop_item_option` ( -- -------------------------------------------------------- -- --- Table structure for table `shop_item_ps` +-- Table structure for table `shop_item_use` -- -DROP TABLE IF EXISTS `shop_item_ps`; -CREATE TABLE IF NOT EXISTS `shop_item_ps` ( +DROP TABLE IF EXISTS `shop_item_use`; +CREATE TABLE IF NOT EXISTS `shop_item_use` ( `is_id` int(11) NOT NULL AUTO_INCREMENT, `it_id` varchar(20) NOT NULL DEFAULT '0', `mb_id` varchar(20) NOT NULL DEFAULT '', @@ -652,6 +652,26 @@ CREATE TABLE IF NOT EXISTS `shop_mileage` ( KEY `mb_id` (`mb_id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; +-- -------------------------------------------------------- + +-- +-- Table structure for table `shop_sendcost` +-- + +DROP TABLE IF EXISTS `shop_sendcost`; +CREATE TABLE IF NOT EXISTS `shop_sendcost` ( + `sc_id` INT(11) NOT NULL AUTO_INCREMENT, + `sc_name` VARCHAR(255) NOT NULL DEFAULT '', + `sc_zip1` VARCHAR(10) NOT NULL DEFAULT '', + `sc_zip2` VARCHAR(10) NOT NULL DEFAULT '', + `sc_amount` INT(11) NOT NULL DEFAULT '0', + PRIMARY KEY (`sc_id`), + KEY `sc_zip1` (`sc_zip1`), + KEY `sc_zip2` (`sc_zip2`) +) ENGINE=MyISAM DEFAULT CHARSET=utf8; + +-- -------------------------------------------------------- + -- -- Table structure for table `shop_wish` -- diff --git a/lib/shop.lib.php b/lib/shop.lib.php index ef0a18ede..18c8211c7 100644 --- a/lib/shop.lib.php +++ b/lib/shop.lib.php @@ -448,7 +448,7 @@ function get_star_image($it_id) { global $g4; - $sql = "select (SUM(is_score) / COUNT(*)) as score from {$g4['shop_item_ps_table']} where it_id = '$it_id' "; + $sql = "select (SUM(is_score) / COUNT(*)) as score from {$g4['shop_item_use_table']} where it_id = '$it_id' "; $row = sql_fetch($sql); return (int)get_star($row['score']); diff --git a/mobile/shop/itemuse.inc.php b/mobile/shop/itemuse.inc.php index b3bf0ce40..ee3ef4c50 100644 --- a/mobile/shop/itemuse.inc.php +++ b/mobile/shop/itemuse.inc.php @@ -14,7 +14,7 @@ include_once(G4_LIB_PATH.'/thumb.lib.php'); @@ -659,9 +670,9 @@ else return false; }); - $(".item_use_count").text(""); - $(".item_qa_count").text(""); - $(".item_relation_count").text(""); + //$(".item_use_count").text(""); + //$(".item_qa_count").text(""); + //$(".item_relation_count").text(""); }); // 바로구매 또는 장바구니 담기 diff --git a/shop/itemuse.php b/shop/itemuse.php index e47595cfc..ce7fa8bc8 100644 --- a/shop/itemuse.php +++ b/shop/itemuse.php @@ -4,8 +4,8 @@ include_once(G4_LIB_PATH.'/thumbnail.lib.php'); $it_id = $_REQUEST['it_id']; -$itemuse_write = G4_BBS_URL.'/write.php?bo_table=itemuse&wr_1='.$it_id; -$itemuse_board = G4_BBS_URL.'/board.php?bo_table=itemuse&wr_1='.$it_id; +$itemuse_form = "./itemuseform.php?it_id=".$it_id; +$itemuse_list = "./itemuselist.php"; include_once(G4_PATH.'/head.sub.php'); ?> @@ -30,7 +30,7 @@ include_once(G4_PATH.'/head.sub.php'); wr_4 : 관리자확인 */ //$sql_common = " from `{$g4['write_prefix']}itemuse` where wr_is_comment = 0 and wr_1 = '{$it['it_id']}' and wr_4 = '1' "; -$sql_common = " from `{$g4['write_prefix']}itemuse` where wr_is_comment = 0 and wr_1 = '{$it_id}' "; +$sql_common = " from `{$g4['shop_item_use_table']}` where it_id = '{$it_id}' and is_confirm = '1' "; // 테이블의 전체 레코드수만 얻음 $sql = " select COUNT(*) as cnt " . $sql_common; @@ -42,34 +42,34 @@ $total_page = ceil($total_count / $rows); // 전체 페이지 계산 if ($page == "") $page = 1; // 페이지가 없으면 첫 페이지 (1 페이지) $from_record = ($page - 1) * $rows; // 시작 레코드 구함 -$sql = "select * $sql_common order by wr_num limit $from_record, $rows "; +$sql = "select * $sql_common order by is_id desc limit $from_record, $rows "; $result = sql_query($sql); for ($i=0; $row=sql_fetch_array($result); $i++) { - $use_num = $total_count - ($page - 1) * $rows - $i; - $use_star = get_star($row['wr_3']); - $use_name = get_text($row['wr_name']); - $use_subject = conv_subject($row['wr_subject'],50,"…"); - //$use_content = ($row['wr_content']); - $use_content = get_view_thumbnail($row['wr_content'], 300); - $use_time = substr($row['wr_datetime'], 2, 8); - $use_href = G4_BBS_URL.'/board.php?bo_table=itemuse&wr_id='.$row['wr_id']; + $is_num = $total_count - ($page - 1) * $rows - $i; + $is_star = get_star($row['is_score']); + $is_name = get_text($row['is_name']); + $is_subject = conv_subject($row['is_subject'],50,"…"); + //$is_content = ($row['wr_content']); + $is_content = get_view_thumbnail($row['is_content'], 300); + $is_time = substr($row['is_time'], 2, 8); + $is_href = './itemuselist.php?bo_table=itemuse&wr_id='.$row['wr_id']; // http://stackoverflow.com/questions/6967081/show-hide-multiple-divs-with-jquery?answertab=votes#tab-top ?> - + - + - - - 별<?php echo $use_star; ?>개 + + + 별<?php echo $is_star; ?>개 - 사용후기 쓰기 새 창 - 더보기 + 사용후기 쓰기 새 창 + 더보기 + \ No newline at end of file diff --git a/shop/itemusewinupdate.php b/shop/itemuseformupdate.php similarity index 71% rename from shop/itemusewinupdate.php rename to shop/itemuseformupdate.php index 4a4f9038f..b5f71ecf4 100644 --- a/shop/itemusewinupdate.php +++ b/shop/itemuseformupdate.php @@ -1,19 +1,14 @@ +전체보기 + +
    + + + +
    +
    -

    전체 사용후기 목록입니다.

    + run($row['is_content']); + $is_content = get_view_thumbnail($row['is_content'], 500); $is_time = substr($row['is_time'], 2, 14); $small_image = $row['it_id']; @@ -68,11 +114,11 @@ $from_record = ($page - 1) * $rows; // 시작 열을 구함
    별<?php echo $star; ?>개
    -

    +

    -
    +
  • @@ -89,15 +135,15 @@ $from_record = ($page - 1) * $rows; // 시작 열을 구함 diff --git a/shop/itemuseupdate.php b/shop/itemuseupdate.php index cafe963cf..b75839253 100644 --- a/shop/itemuseupdate.php +++ b/shop/itemuseupdate.php @@ -45,18 +45,18 @@ $url = "./item.php?it_id=$it_id"; if ($w == '') { - $sql = " select max(is_id) as max_is_id from {$g4['shop_item_ps_table']} "; + $sql = " select max(is_id) as max_is_id from {$g4['shop_item_use_table']} "; $row = sql_fetch($sql); $max_is_id = $row['max_is_id']; - $sql = " select max(is_id) as max_is_id from {$g4['shop_item_ps_table']} + $sql = " select max(is_id) as max_is_id from {$g4['shop_item_use_table']} where it_id = '$it_id' and mb_id = '{$member['mb_id']}' "; $row = sql_fetch($sql); if ($row['max_is_id'] && $row['max_is_id'] == $max_is_id) alert("같은 상품에 대하여 계속해서 평가하실 수 없습니다."); - $sql = "insert {$g4['shop_item_ps_table']} + $sql = "insert {$g4['shop_item_use_table']} set it_id = '$it_id', mb_id = '{$member['mb_id']}', is_score = '$is_score', @@ -66,23 +66,23 @@ if ($w == '') is_content = '$is_content', is_time = '".G4_TIME_YMDHIS."', is_ip = '{$_SERVER['REMOTE_ADDR']}' "; - if (!$default['de_item_ps_use']) + if (!$default['de_item_use_use']) $sql .= ", is_confirm = '1' "; sql_query($sql); - if ($default['de_item_ps_use']) + if ($default['de_item_use_use']) alert("평가하신 글은 관리자가 확인한 후에 표시됩니다.", $url); else goto_url($url); } else if ($w == 'u') { - $sql = " select is_password from {$g4['shop_item_ps_table']} where is_id = '$is_id' "; + $sql = " select is_password from {$g4['shop_item_use_table']} where is_id = '$is_id' "; $row = sql_fetch($sql); if ($row['is_password'] != $is_password) alert("패스워드가 틀리므로 수정하실 수 없습니다."); - $sql = " update {$g4['shop_item_ps_table']} + $sql = " update {$g4['shop_item_use_table']} set is_subject = '$is_subject', is_content = '$is_content', is_score = '$is_score' @@ -95,7 +95,7 @@ else if ($w == 'd') { if ($is_member) { - $sql = " select count(*) as cnt from {$g4['shop_item_ps_table']} where mb_id = '{$member['mb_id']}' and is_id = '$is_id' "; + $sql = " select count(*) as cnt from {$g4['shop_item_use_table']} where mb_id = '{$member['mb_id']}' and is_id = '$is_id' "; $row = sql_fetch($sql); if (!$row['cnt']) alert("자신의 사용후기만 삭제하실 수 있습니다."); @@ -104,13 +104,13 @@ else if ($w == 'd') { $is_password = sql_password($is_password); - $sql = " select is_password from {$g4['shop_item_ps_table']} where is_id = '$is_id' "; + $sql = " select is_password from {$g4['shop_item_use_table']} where is_id = '$is_id' "; $row = sql_fetch($sql); if ($row['is_password'] != $is_password) alert("패스워드가 틀리므로 삭제하실 수 없습니다."); } - $sql = " delete from {$g4['shop_item_ps_table']} where mb_id = '{$member['mb_id']}' and is_id = '$is_id' "; + $sql = " delete from {$g4['shop_item_use_table']} where mb_id = '{$member['mb_id']}' and is_id = '$is_id' "; sql_query($sql); goto_url($url);