#186 가격 필드명 price 로 변경

This commit is contained in:
chicpro
2013-05-15 18:50:24 +09:00
parent e887152412
commit 23259ab372
34 changed files with 148 additions and 205 deletions

View File

@ -164,9 +164,9 @@ if ($search) // 검색렬일 때만 처음 버튼을 보여줌
<a href="./orderform.php?od_id=<?php echo $row['od_id']; ?>"><?php echo $row['od_id']; ?></a>
</td>
<td class="td_name"><?php echo $row['od_name']; ?></td>
<td><?php echo display_amount($row['orderamount']); ?></td>
<td><?php echo display_amount($row['receiptamount']); ?></td>
<td><?php echo display_amount($row['misu']); ?></td>
<td><?php echo display_price($row['orderamount']); ?></td>
<td><?php echo display_price($row['receiptamount']); ?></td>
<td><?php echo display_price($row['misu']); ?></td>
<td><?php echo $hope_date; ?></td>
<td><input type="text" name="od_invoice_time[<?php echo $i; ?>]" value="<?php echo $invoice_time; ?>" class="frm_input" size="20" maxlength="19"></td>
<td>

View File

@ -65,7 +65,7 @@ $pg_anchor = '<ul class="anchor">
<tr>
<td class="td_odrnum2"><?php echo $row['od_id']; ?></td>
<td class="td_name"><?php echo $name; ?></td>
<td class="td_bignum"><?php echo display_amount($row['receiptamount']); ?></td>
<td class="td_bignum"><?php echo display_price($row['receiptamount']); ?></td>
<td class="td_payby"><?php echo $settle_method; ?></td>
<td class="td_smallmng"><a href="./orderform.php?od_id=<?php echo $row['od_id']; ?>"><img src="./img/icon_mod.jpg" alt="<?php echo $row['od_id']; ?> 수정"></a></td>
</tr>
@ -130,7 +130,7 @@ $pg_anchor = '<ul class="anchor">
<tr>
<td class="td_odrnum2"><a href="./orderstatuslist.php?sort1=od_id&amp;sel_field=od_id&amp;search=<?php echo $row['od_id']; ?>"><?php echo $row['od_id']; ?></a></td>
<td class="td_name"><?php echo $name; ?></td>
<td class="td_bignum"><?php echo display_amount($row['orderamount']); ?></td>
<td class="td_bignum"><?php echo display_price($row['orderamount']); ?></td>
<td class="td_payby"><?php echo $settle_method; ?></td>
<td class="td_smallmng"><a href="./orderform.php?od_id=<?php echo $row['od_id']; ?>"><img src="./img/icon_mod.jpg" alt="<?php echo $row['od_id']; ?> 수정"></a></td>
</tr>

View File

@ -424,31 +424,16 @@ $(function(){
</colgroup>
<tbody>
<tr>
<th scope="row"><label for="it_amount">비회원가격</label></th>
<th scope="row"><label for="it_price">판매가격</label></th>
<td>
<?php echo help("상품의 기본판매가격(로그인 이전 가격)이며 옵션별로 상품가격이 틀리다면 합산하여 상품상세페이지에 출력합니다."); ?>
<input type="text" name="it_amount" value="<?php echo $it['it_amount']; ?>" id="it_amount" class="frm_input" size="8"> 원
<input type="text" name="it_price" value="<?php echo $it['it_price']; ?>" id="it_price" class="frm_input" size="8"> 원
</td>
</tr>
<tr>
<th scope="row"><label for="it_amount2">회원가격</label></th>
<td>
<?php echo help("상품의 로그인 이후 가격(회원 권한 2 에만 적용)되며 옵션별로 상품가격이 틀리다면 합산하여 상품상세페이지에 출력합니다.\n<strong>입력이 없다면 비회원가격으로 대신합니다.</strong>"); ?>
<input type="text" name="it_amount2" value="<?php echo $it['it_amount2']; ?>" id="it_amount2" class="frm_input" size="8"> 원
</td>
</tr>
<tr>
<th scope="row"><label for="it_amount3">특별회원가격</label></th>
<td>
<?php echo help("상품의 로그인 이후 가격(회원 권한 3 이상에 적용)이며 옵션별로 상품가격이 틀리다면 합산하여 상품상세페이지에 출력합니다.\n<strong>입력이 없다면 회원가격으로 대신합니다. 회원가격도 없다면 비회원가격으로 대신합니다.</strong>"); ?>
<input type="text" name="it_amount3" value="<?php echo $it['it_amount3']; ?>" id="it_amount3" class="frm_input" size="8"> 원
</td>
</tr>
<tr>
<th scope="row"><label for="it_cust_amount">시중가격</label></th>
<th scope="row"><label for="it_cust_price">시중가격</label></th>
<td>
<?php echo help("입력하지 않으면 상품상세페이지에 출력하지 않습니다."); ?>
<input type="text" name="it_cust_amount" value="<?php echo $it['it_cust_amount']; ?>" id="it_cust_amount" class="frm_input" size="8"> 원
<input type="text" name="it_cust_price" value="<?php echo $it['it_cust_price']; ?>" id="it_cust_price" class="frm_input" size="8"> 원
</td>
</tr>
<tr>
@ -576,28 +561,6 @@ $(function(){
</select>
</span>
<select id="relation" class="sit_relation_list" size="8" onclick="relation_img(this.value, 'add_span')" ondblclick="relation_add(this);" onkeyup="relation_add(this);">
<?php
/*
$sql = " select ca_id, it_id, it_name, it_amount
from $g4[shop_item_table]
where it_id <> '$it_id'
order by ca_id, it_name ";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
{
$sql2 = " select ca_name from $g4[shop_category_table] where ca_id = '$row[ca_id]' ";
$row2 = sql_fetch($sql2);
// 김선용 2006.10
if(file_exists("{$g4['path']}/data/item/{$row['it_id']}_s"))
$it_image = "{$row['it_id']}_s";
else
$it_image = "";
echo "<option value='$row[it_id]/$it_image/{$row['it_amount']}'>$row2[ca_name] : ".cut_str(get_text(strip_tags($row[it_name])),30);
}
*/
?>
</select>
<div>
<strong class="sound_only">현재 활성화 된 상품</strong>
@ -713,7 +676,7 @@ $(function(){
<select name="relationselect" size="8" class="sit_relation_selected" onclick="relation_img(this.value, 'sel_span')" ondblclick="relation_del(this);" onkeyup="relation_del(this);">
<?php
$str = array();
$sql = " select b.ca_id, b.it_id, b.it_name, b.it_amount
$sql = " select b.ca_id, b.it_id, b.it_name, b.it_price
from {$g4['shop_item_relation_table']} a
left join {$g4['shop_item_table']} b on (a.it_id2=b.it_id)
where a.it_id = '$it_id'
@ -730,7 +693,7 @@ $(function(){
else
$it_image = "";
?>
<option value="<?php echo $row['it_id']; ?>/<?php echo $it_image; ?>/<?php echo $row['it_amount']; ?>"><?php echo $row2['ca_name']; ?> : <?php echo cut_str(get_text(strip_tags($row['it_name'])),30); ?></option>
<option value="<?php echo $row['it_id']; ?>/<?php echo $it_image; ?>/<?php echo $row['it_price']; ?>"><?php echo $row2['ca_name']; ?> : <?php echo cut_str(get_text(strip_tags($row['it_name'])),30); ?></option>
<?php
$str[] = $row['it_id'];
}

View File

@ -2,7 +2,7 @@
$sub_menu = '400300';
include_once('./_common.php');
$sql = " select ca_id, it_id, it_name, it_amount
$sql = " select ca_id, it_id, it_name, it_price
from {$g4['shop_item_table']}
where ca_id like '$ca_id%'
and it_id <> '$it_id'
@ -26,7 +26,7 @@ for($i=0;$row=sql_fetch_array($result);$i++) {
else
$it_image = "";
$options .= "<option value=\"".$row['it_id']."/".$it_image."/".$row['it_amount']."\">$ca_name : $it_name</option>\n";
$options .= "<option value=\"".$row['it_id']."/".$it_image."/".$row['it_price']."\">$ca_name : $it_name</option>\n";
}
echo $options;

View File

@ -401,10 +401,8 @@ $sql_common = " ca_id = '$ca_id',
it_explan = '$it_explan',
it_explan_html = '$it_explan_html',
it_mobile_explan = '$it_mobile_explan',
it_cust_amount = '$it_cust_amount',
it_amount = '$it_amount',
it_amount2 = '$it_amount2',
it_amount3 = '$it_amount3',
it_cust_price = '$it_cust_price',
it_price = '$it_price',
it_point = '$it_point',
it_sell_email = '$it_sell_email',
it_use = '$it_use',

View File

@ -6,9 +6,10 @@ $it_id = trim($_POST['it_id']);
$gubun = $_POST['gubun'] ? $_POST['gubun'] : 'wear';
if($it['it_id'])
$it_id = $it['it_id'];
$sql = " select it_id, it_info_gubun, it_info_value from {$g4['shop_item_table']} where it_id = '$it_id' ";
$it = sql_fetch($sql);
else {
$sql = " select it_id, it_info_gubun, it_info_value from {$g4['shop_item_table']} where it_id = '$it_id' ";
$it = sql_fetch($sql);
}
if(!$_POST['gubun'] && $it['it_info_gubun'])
$gubun = $it['it_info_gubun'];

View File

@ -147,16 +147,14 @@ if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌
<tr>
<th scope="col" rowspan="2"><?php echo subject_sort_link('it_id', 'sca='.$sca); ?>상품코드 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" colspan="2" rowspan="2">분류 및 <?php echo subject_sort_link('it_name', 'sca='.$sca); ?>상품명 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_amt"><?php echo subject_sort_link('it_amount', 'sca='.$sca); ?>비회원가격 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_amt2"><?php echo subject_sort_link('it_amount2', 'sca='.$sca); ?>회원가격 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_amt3"><?php echo subject_sort_link('it_amount3', 'sca='.$sca); ?>특별가격 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_amt"><?php echo subject_sort_link('it_price', 'sca='.$sca); ?>판매가격 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_camt"><?php echo subject_sort_link('it_cust_price', 'sca='.$sca); ?>시중가격 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" rowspan="2"><?php echo subject_sort_link('it_order', 'sca='.$sca); ?>순서 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" rowspan="2"><?php echo subject_sort_link('it_use', 'sca='.$sca, 1); ?>판매 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" rowspan="2"><?php echo subject_sort_link('it_hit', 'sca='.$sca, 1); ?>조회 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" rowspan="2">관리</th>
</tr>
<tr>
<th scope="col" id="sit_camt"><?php echo subject_sort_link('it_cust_amount', 'sca='.$sca); ?>시중가격 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_pt"><?php echo subject_sort_link('it_point', 'sca='.$sca); ?>포인트 <span class="sound_only">순 정렬</span></a></th>
<th scope="col" id="sit_qty"><?php echo subject_sort_link('it_stock_qty', 'sca='.$sca); ?>재고 <span class="sound_only">순 정렬</span></a></th>
</tr>
@ -183,9 +181,8 @@ if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌
<?php echo $tmp_ca_list; ?><br>
<input type="text" name="it_name[<?php echo $i; ?>]" value="<?php echo htmlspecialchars2(cut_str($row['it_name'],250, "")); ?>" required class="frm_input frm_sit_title required" size="30">
</td>
<td headers="sit_amt"><input type="text" name="it_amount[<?php echo $i; ?>]" value="<?php echo $row['it_amount']; ?>" class="frm_input sit_amt" size="7"></td>
<td headers="sit_amt2"><input type="text" name="it_amount2[<?php echo $i; ?>]" value="<?php echo $row['it_amount2']; ?>" class="frm_input sit_amt2" size="7"></td>
<td headers="sit_amt3"><input type="text" name="it_amount3[<?php echo $i; ?>]" value="<?php echo $row['it_amount3']; ?>" class="frm_input sit_amt3" size="7"></td>
<td headers="sit_amt"><input type="text" name="it_price[<?php echo $i; ?>]" value="<?php echo $row['it_price']; ?>" class="frm_input sit_amt" size="7"></td>
<td headers="sit_camt"><input type="text" name="it_cust_price[<?php echo $i; ?>]" value="<?php echo $row['it_cust_price']; ?>" class="frm_input sit_camt" size="7"></td>
<td rowspan="2"><input type="text" name="it_order[<?php echo $i; ?>]" value="<?php echo $row['it_order']; ?>" class="frm_input sit_odrby" size="3"></td>
<td rowspan="2"><input type="checkbox" name="it_use[<?php echo $i; ?>]" <?php echo ($row['it_use'] ? 'checked' : ''); ?> value="1"></td>
<td rowspan="2"><?php echo $row['it_hit']; ?></td>
@ -197,7 +194,6 @@ if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌
</td>
</tr>
<tr>
<td headers="sit_camt"><input type="text" name="it_cust_amount[<?php echo $i; ?>]" value="<?php echo $row['it_cust_amount']; ?>" class="frm_input sit_camt" size="7"></td>
<td headers="sit_pt"><input type="text" name="it_point[<?php echo $i; ?>]" value="<?php echo $row['it_point']; ?>" class="frm_input sit_pt" size="7"></td>
<td headers="sit_qty"><input type="text" name="it_stock_qty[<?php echo $i; ?>]" value="<?php echo $row['it_stock_qty']; ?>" class="frm_input sit_qty" size="7"></td>
</tr>

View File

@ -12,10 +12,8 @@ for ($i=0; $i<count($_POST['it_id']); $i++)
$sql = "update {$g4['shop_item_table']}
set ca_id = '{$_POST['ca_id'][$i]}',
it_name = '{$_POST['it_name'][$i]}',
it_cust_amount = '{$_POST['it_cust_amount'][$i]}',
it_amount = '{$_POST['it_amount'][$i]}',
it_amount2 = '{$_POST['it_amount2'][$i]}',
it_amount3 = '{$_POST['it_amount3'][$i]}',
it_cust_price = '{$_POST['it_cust_price'][$i]}',
it_price = '{$_POST['it_price'][$i]}',
it_point = '{$_POST['it_point'][$i]}',
it_stock_qty = '{$_POST['it_stock_qty'][$i]}',
it_use = '{$_POST['it_use'][$i]}',

View File

@ -103,7 +103,7 @@ if ($search) // 검색 결과일 때만 처음 버튼을 보여줌
<?php for ($i=0; $row=sql_fetch_array($result); $i++) { ?>
<tr>
<td class="td_odrnum2"><a href="./orderform.php?od_id=<?php echo $row['od_id']; ?>"><?php echo $row['od_id']; ?></a></td>
<td><?php echo display_amount($row['cd_amount']); ?></td>
<td><?php echo display_price($row['cd_amount']); ?></td>
<td class="td_num"><?php echo $row['cd_app_no']; ?></td>
<td class="td_smallmng"><?php echo $row['cd_app_rt']; ?></td>
<td class="td_time"><?php echo $row['cd_app_time']; ?></td>

View File

@ -89,7 +89,7 @@ if ($default['de_card_test']) {
$sql = " select a.ct_id,
a.it_id,
a.ct_qty,
a.ct_amount,
a.ct_price,
a.ct_point,
a.ct_status,
a.ct_time,
@ -160,9 +160,9 @@ $pg_anchor = '<ul class="anchor">
$ct_amount['소계'] = $row['ct_amount'] * $row['ct_qty'];
$ct_point['소계'] = $row['ct_point'] * $row['ct_qty'];
if ($row['ct_status']=='주문' || $row['ct_status']=='준비' || $row['ct_status']=='배송' || $row['ct_status']=='완료')
$t_ct_amount['정상'] += $row['ct_amount'] * $row['ct_qty'];
$t_ct_amount['정상'] += $row['ct_price'] * $row['ct_qty'];
else if ($row['ct_status']=='취소' || $row['ct_status']=='반품' || $row['ct_status']=='품절')
$t_ct_amount['취소'] += $row['ct_amount'] * $row['ct_qty'];
$t_ct_amount['취소'] += $row['ct_price'] * $row['ct_qty'];
$image = get_it_image($row['it_id'], (int)($default['de_simg_width'] / $image_rate), (int)($default['de_simg_height'] / $image_rate));
?>
@ -179,7 +179,7 @@ $pg_anchor = '<ul class="anchor">
</td>
<td class="td_small_stats"><?php echo $row['ct_status']; ?></td>
<td class="td_num"><?php echo $row['ct_qty']; ?></td>
<td class="td_num"><?php echo number_format($row['ct_amount']); ?></td>
<td class="td_num"><?php echo number_format($row['ct_price']); ?></td>
<td class="td_num"><?php echo number_format($ct_amount['소계']); ?></td>
<td class="td_num"><?php echo number_format($ct_point['소계']); ?></td>
<td class="td_small_stats"><?php echo get_yn($row['dct_point_use']); ?></td>
@ -230,7 +230,7 @@ $pg_anchor = '<ul class="anchor">
$s_receipt_way .= "+포인트";
?>
<strong class="sodr_nonpay">미수금 <?php echo display_amount($amount['미수']); ?></strong>
<strong class="sodr_nonpay">미수금 <?php echo display_price($amount['미수']); ?></strong>
<table>
<thead>
@ -249,11 +249,11 @@ $pg_anchor = '<ul class="anchor">
<tr>
<td class="td_odrnum2"><?php echo $od['od_id']; ?><!-- uq_id : <?php echo $od['uq_id']; ?> --></td>
<td class="td_payby"><?php echo $s_receipt_way; ?></td>
<td class="td_bignum"><?php echo display_amount($amount['정상']); ?></td>
<td class="td_bignum"><?php echo display_price($amount['정상']); ?></td>
<td class="td_bignum"><?php echo display_point($od['od_receipt_point']); ?></td>
<td class="td_bignum"><?php echo number_format($amount['입금']); ?>원</td>
<td class="td_bignum"><?php echo display_amount($od['od_dc_amount']); ?></td>
<td class="td_bignum"><?php echo display_amount($od['od_refund_amount']); ?></td>
<td class="td_bignum"><?php echo display_price($od['od_dc_amount']); ?></td>
<td class="td_bignum"><?php echo display_price($od['od_refund_amount']); ?></td>
<td class="td_bignum"><?php echo number_format($t_ct_amount['취소']); ?>원</td>
</tr>
</tbody>
@ -293,7 +293,7 @@ $pg_anchor = '<ul class="anchor">
<?php } ?>
<tr>
<th scope="row"><?php echo $od['od_settle_case']; ?> 입금액</th>
<td><?php echo display_amount($od['od_receipt_bank']); ?></td>
<td><?php echo display_price($od['od_receipt_bank']); ?></td>
</tr>
<tr>
<th scope="row">입금자</th>
@ -316,7 +316,7 @@ $pg_anchor = '<ul class="anchor">
</tr>
<tr>
<th scope="row"><?php echo $od['od_settle_case']; ?> 결제액</th>
<td><?php echo display_amount($od['od_receipt_hp']); ?></td>
<td><?php echo display_price($od['od_receipt_hp']); ?></td>
</tr>
<tr>
<th scope="row">결제 확인일시</th>
@ -333,7 +333,7 @@ $pg_anchor = '<ul class="anchor">
<th scope="row" class="sodr_sppay">신용카드 입금액</th>
<td>
<?php if ($od['od_card_time'] == "0000-00-00 00:00:00") {?>0원
<?php } else { ?><?php echo display_amount($od['od_receipt_card']); ?>
<?php } else { ?><?php echo display_price($od['od_receipt_card']); ?>
<?php } ?>
</td>
</tr>
@ -347,7 +347,7 @@ $pg_anchor = '<ul class="anchor">
</tr>
<tr>
<th scope="row" class="sodr_sppay">카드 승인취소</th>
<td><?php echo display_amount($od['od_cancel_card']); ?></td>
<td><?php echo display_price($od['od_cancel_card']); ?></td>
</tr>
<?php } ?>
<tr>
@ -356,11 +356,11 @@ $pg_anchor = '<ul class="anchor">
</tr>
<tr>
<th scope="row">DC</th>
<td><?php echo display_amount($od['od_dc_amount']); ?></td>
<td><?php echo display_price($od['od_dc_amount']); ?></td>
</tr>
<tr>
<th scope="row">환불액</th>
<td><?php echo display_amount($od['od_refund_amount']); ?></td>
<td><?php echo display_price($od['od_refund_amount']); ?></td>
</tr>
<?php
$sql = " select dl_company, dl_url, dl_tel from {$g4['shop_delivery_table']} where dl_id = '{$od['dl_id']}' ";

View File

@ -75,7 +75,7 @@ if ($od_send_mail)
// 신용카드 입금
if ($od['od_receipt_card'] > 0) {
$card_list['od_card_time'] = $od['od_card_time'];
$card_list['od_receipt_card'] = display_amount($od['od_receipt_card']);
$card_list['od_receipt_card'] = display_price($od['od_receipt_card']);
$is_receipt = true;
}
@ -83,7 +83,7 @@ if ($od_send_mail)
// 무통장 입금
if ($od['od_receipt_bank'] > 0) {
$bank_list['od_bank_time'] = $od['od_bank_time'];
$bank_list['od_receipt_bank'] = display_amount($od['od_receipt_bank']);
$bank_list['od_receipt_bank'] = display_price($od['od_receipt_bank']);
$bank_list['od_deposit_name'] = $od['od_deposit_name'];
$is_receipt = true;

View File

@ -317,7 +317,7 @@ if (mysql_num_rows($result) == 0)
if (preg_match("/[+]/", $opt[1]) == true)
$it_name .= "+";
// 금액을 전화문의 표시로
$it_name .= display_amount($opt[1]) . ")";
$it_name .= display_price($opt[1]) . ")";
}
$str_split = "<br />";
}

View File

@ -32,13 +32,13 @@ if (G4_HTTPS_DOMAIN) {
define(_MISU_QUERY_, "
count(distinct a.od_id) as ordercount, /* 주문서건수 */
count(b.ct_id) as itemcount, /* 상품건수 */
(SUM(b.ct_amount * b.ct_qty) + a.od_send_cost) as orderamount , /* 주문합계 */
(SUM(IF(b.ct_status = '취소' OR b.ct_status = '반품' OR b.ct_status = '품절', b.ct_amount * b.ct_qty, 0))) as ordercancel, /* 주문취소 */
(SUM(b.ct_price * b.ct_qty) + a.od_send_cost) as orderamount , /* 주문합계 */
(SUM(IF(b.ct_status = '취소' OR b.ct_status = '반품' OR b.ct_status = '품절', b.ct_price * b.ct_qty, 0))) as ordercancel, /* 주문취소 */
(a.od_receipt_bank + a.od_receipt_card + a.od_receipt_hp + a.od_receipt_point) as receiptamount, /* 입금합계 */
(a.od_refund_amount + a.od_cancel_card) as receiptcancel, /* 입금취소 */
(
(SUM(b.ct_amount * b.ct_qty) + a.od_send_cost) -
(SUM(IF(b.ct_status = '취소' OR b.ct_status = '반품' OR b.ct_status = '품절', b.ct_amount * b.ct_qty, 0))) -
(SUM(b.ct_price * b.ct_qty) + a.od_send_cost) -
(SUM(IF(b.ct_status = '취소' OR b.ct_status = '반품' OR b.ct_status = '품절', b.ct_price * b.ct_qty, 0))) -
a.od_dc_amount -
(a.od_receipt_bank + a.od_receipt_card + a.od_receipt_hp + a.od_receipt_point) +
(a.od_refund_amount + a.od_cancel_card)
@ -76,6 +76,18 @@ if(!$result) {
sql_query(" ALTER TABLE `{$g4['shop_order_table']}` DROP INDEX index1", false);
}
// 가격필드명변경
$sql = " select it_price from {$g4['shop_item_table']} limit 1 ";
$result = sql_query($sql, false);
if(!$result) {
sql_query(" ALTER TABLE `{$g4['shop_item_table']}`
CHANGE `it_amount` `it_price` INT(11) NOT NULL DEFAULT '0',
CHANGE `it_cust_amount` `it_cust_price` INT(11) NOT NULL DEFAULT '0' ", false);
sql_query(" ALTER TABLE `{$g4['shop_cart_table']}`
CHANGE `ct_amount` `ct_price` INT(11) NOT NULL DEFAULT '0',
ADD `ct_name` VARCHAR(255) NOT NULL DEFAULT '' AFTER `it_id` ", false);
}
//==============================================================================
// 쇼핑몰 필수 실행코드 모음 끝
//==============================================================================

View File

@ -185,34 +185,27 @@ function get_large_image($img, $it_id, $btn_image=true)
}
// 금액 표시
function display_amount($amount, $tel_inq=false)
function display_price($price, $tel_inq=false)
{
if ($tel_inq)
$amount = '전화문의';
$price = '전화문의';
else
$amount = number_format($amount, 0).'원';
$price = number_format($price, 0).'원';
return $amount;
return $price;
}
// 금액표시
// $it : 상품 배열
function get_amount($it)
function get_price($it)
{
global $member;
if ($it['it_tel_inq']) return '전화문의';
if ($member['mb_level'] > 2) // 특별회원
$amount = $it['it_amount3'];
$price = $it['it_price'];
if ($member['mb_level'] == 2 || $amount == 0) // 회원가격
$amount = $it['it_amount2'];
if ($member['mb_level'] == 1 || $amount == 0) // 비회원가격
$amount = $it['it_amount'];
return (int)$amount;
return (int)$price;
}
@ -541,7 +534,7 @@ function get_item_options($subject, $option, $index)
//if (!ereg("[-]", $opt[1]))
if (!preg_match("/[-]/", $opt[1]))
$str .= '+';
$str .= display_amount($opt[1]) . ')';
$str .= display_price($opt[1]) . ')';
}
$str .= '</option>'.PHP_EOL;
}
@ -586,7 +579,7 @@ function print_item_options()
//if (ereg("[+]", $opt[1]) == true)
if (preg_match("/[+]/", $opt[1]) == true)
$it_name .= '+';
$it_name .= display_amount($opt[1]).')';
$it_name .= display_price($opt[1]).')';
}
$str_split = '<br>';
}
@ -827,7 +820,7 @@ function display_relation_item($it_id, $width, $height, $rows=3)
if(!$it_id)
return $str;
$sql = " select b.it_id, b.it_name, b.it_amount, b.it_amount2, b.it_amount3, b.it_tel_inq, b.it_gallery
$sql = " select b.it_id, b.it_name, b.it_price, b.it_tel_inq, b.it_gallery
from {$g4['shop_item_relation_table']} a left join {$g4['shop_item_table']} b on ( a.it_id2 = b.it_id )
where a.it_id = '$it_id'
limit 0, $rows ";
@ -839,21 +832,15 @@ function display_relation_item($it_id, $width, $height, $rows=3)
$str .= '<ul class="sct_rel_ul">';
}
$full_img = G4_DATA_PATH.'/item/'.$row['it_id'].'_s';
$it_name = get_text($row['it_name']); // 상품명
$it_amount = ''; // 상품가격
$it_price = ''; // 상품가격
if(!$row['it_gallery']) {
$it_amount = get_amount($row);
$it_price = get_price($row);
if(!$row['it_tel_inq'])
$it_amount = display_amount($it_amount);
$it_price = display_price($it_price);
}
if(is_file($full_img)) {
$img_url = G4_DATA_URL.'/item/'.$row['it_id'].'_s';
$img = '<img src="'.$img_url.'" alt="'.$it_name.' / '.$it_amount.'" width="'.$width.'" height="'.$height.'">';
} else {
$img = '<img src="'.G4_SHOP_URL.'/img/no_image.gif" alt="'.$it_name.' / '.$it_amount.'" width="'.$width.'" height="'.$height.'">';
}
$img = get_it_image($row['it_id'], $width, $height);
$str .= '<li class="sct_rel_li"><a href="'.G4_SHOP_URL.'/item.php?it_id='.$row['it_id'].'" class="sct_rel_a">'.$img.'</a></li>';
}

View File

@ -49,7 +49,7 @@ $sql = " select a.ct_id,
a.it_opt4,
a.it_opt5,
a.it_opt6,
a.ct_amount,
a.ct_price,
a.ct_point,
a.ct_qty,
a.ct_status,
@ -84,7 +84,7 @@ for ($i=0; $row=mysql_fetch_array($result); $i++)
$good_info .= "ordr_numb={$od_id}_".sprintf("%04d", $i).chr(31);
$good_info .= "good_name=".addslashes($row['it_name']).chr(31);
$good_info .= "good_cntx=".$row['ct_qty'].chr(31);
$good_info .= "good_amtx=".$row['ct_amount'].chr(31);
$good_info .= "good_amtx=".$row['ct_price'].chr(31);
}
if ($i==0) { // 계속쇼핑
@ -107,7 +107,7 @@ for ($i=0; $row=mysql_fetch_array($result); $i++)
}
$point = $row['ct_point'] * $row['ct_qty'];
$sell_amount = $row['ct_amount'] * $row['ct_qty'];
$sell_amount = $row['ct_price'] * $row['ct_qty'];
?>
<tr>
@ -127,7 +127,7 @@ for ($i=0; $row=mysql_fetch_array($result); $i++)
echo '<td class="td_num">'.$row['ct_qty'].'</td>';
?>
<td class="td_bignum"><?php echo number_format($row['ct_amount']); ?></td>
<td class="td_bignum"><?php echo number_format($row['ct_price']); ?></td>
<td class="td_bignum"><?php echo number_format($sell_amount); ?></td>
<td class="td_bignum"><?php echo number_format($point); ?></td>

View File

@ -82,25 +82,15 @@ else if ($act == "multi") // 온라인견적(등)에서 여러개의 상품이
{
if ($_POST['it_id'][$i] == "" || $_POST['ct_qty'][$i] <= 0) { continue; }
// 비회원가격과 회원가격이 다르다면
if (!$is_member && $default['de_different_msg'])
{
$sql = " select it_amount, it_amount2 from {$g4['shop_item_table']} where it_id = '{$_POST['it_id'][$i]}' ";
$row = sql_fetch($sql);
if ($row['it_amount2'] && $row['it_amount'] != $row['it_amount2']) {
$error .= "\"{$_POST['it_name'][$i]}\" 의 비회원가격과 회원가격이 다릅니다. 로그인 후 구입하여 주십시오.\\n\\n";
}
}
//--------------------------------------------------------
// 변조 검사
//--------------------------------------------------------
$sql = " select * from {$g4['shop_item_table']} where it_id = '{$_POST['it_id'][$i]}' ";
$it = sql_fetch($sql);
$amount = get_amount($it);
$price = get_price($it);
// 상품가격이 다름
if ((int)$amount !== (int)$_POST['it_amount'][$i])
if ((int)$price !== (int)$_POST['it_price'][$i])
die("Error..");
$point = $it['it_point'];
@ -136,7 +126,7 @@ else if ($act == "multi") // 온라인견적(등)에서 여러개의 상품이
set uq_id = '$tmp_uq_id',
it_id = '{$_POST['it_id'][$i]}',
ct_status = '쇼핑',
ct_amount = '{$_POST['it_amount'][$i]}',
ct_price = '{$_POST['it_price'][$i]}',
ct_point = '{$_POST['it_point'][$i]}',
ct_point_use = '0',
ct_stock_use = '0',
@ -183,9 +173,9 @@ else // 장바구니에 담기
}
}
$amount = get_amount($it) + $opt_amount;
$price = get_price($it) + $opt_amount;
// 상품가격이 다름
if ((int)$amount !== (int)$_POST['it_amount'])
if ((int)$price !== (int)$_POST['it_price'])
die("Error..");
$point = $it['it_point'];
@ -234,7 +224,7 @@ else // 장바구니에 담기
it_opt5 = '{$_POST['it_opt5']}',
it_opt6 = '{$_POST['it_opt6']}',
ct_status = '쇼핑',
ct_amount = '{$_POST['it_amount']}',
ct_price = '{$_POST['it_price']}',
ct_point = '{$_POST['it_point']}',
ct_point_use = '0',
ct_stock_use = '0',

View File

@ -293,20 +293,20 @@ else
</tr>
<?php } else { // 전화문의가 아닐 경우?>
<?php if ($it['it_cust_amount']) { // 1.00.03?>
<?php if ($it['it_cust_price']) { // 1.00.03?>
<tr>
<th scope="row"><label for="disp_cust_amount">시중가격</label></th>
<th scope="row"><label for="disp_cust_price">시중가격</label></th>
<td>
<input type="text" name="disp_cust_amount" value="<?php echo number_format($it['it_cust_amount']); ?>" id="disp_cust_amount" readonly class="sit_ov_ro" size="8"> 원
<input type="text" name="disp_cust_price" value="<?php echo number_format($it['it_cust_price']); ?>" id="disp_cust_price" readonly class="sit_ov_ro" size="8"> 원
</td>
</tr>
<?php } // 전화문의 끝?>
<tr>
<th scope="row"><label for="disp_sell_amount">판매가격</label></th>
<th scope="row"><label for="disp_sell_price">판매가격</label></th>
<td>
<input type="text" name="disp_sell_amount" id="disp_sell_amount" readonly class="sit_ov_ro" size="8"> 원
<input type="hidden" name="it_amount" value="0">
<input type="text" name="disp_sell_price" id="disp_sell_price" readonly class="sit_ov_ro" size="8"> 원
<input type="hidden" name="it_price" value="0">
</td>
</tr>
@ -598,9 +598,9 @@ else
function amount_change()
{
var basic_amount = parseInt("<?php echo get_amount($it); ?>");
var basic_amount = parseInt("<?php echo get_price($it); ?>");
var basic_point = parseFloat("<?php echo $it['it_point']; ?>");
var cust_amount = parseFloat("<?php echo $it['it_cust_amount']; ?>");
var cust_amount = parseFloat("<?php echo $it['it_cust_price']; ?>");
var f = document.fitem;
var opt1 = 0;
@ -624,14 +624,14 @@ else
var amount = basic_amount + opt1 + opt2 + opt3 + opt4 + opt5 + opt6;
var point = parseInt(basic_point);
if (typeof(f.it_amount) != 'undefined')
f.it_amount.value = amount;
if (typeof(f.it_price) != 'undefined')
f.it_price.value = amount;
if (typeof(f.disp_sell_amount) != 'undefined')
f.disp_sell_amount.value = number_format(String(amount * ct_qty));
if (typeof(f.disp_sell_price) != 'undefined')
f.disp_sell_price.value = number_format(String(amount * ct_qty));
if (typeof(f.disp_cust_amount) != 'undefined')
f.disp_cust_amount.value = number_format(String(cust_amount * ct_qty));
if (typeof(f.disp_cust_price) != 'undefined')
f.disp_cust_price.value = number_format(String(cust_amount * ct_qty));
if (typeof(f.it_point) != 'undefined') {
f.it_point.value = point;
@ -645,7 +645,7 @@ else
function fitemcheck(f, act)
{
// 판매가격이 0 보다 작다면
if (f.it_amount.value < 0)
if (f.it_price.value < 0)
{
alert("전화로 문의해 주시면 감사하겠습니다.");
return;

View File

@ -22,11 +22,11 @@ for ($i=1; $row=sql_fetch_array($result); $i++)
<a href="<?php echo $href; ?>" class="sct_a">
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<?php if ($row['it_cust_amount'] && !$row['it_gallery']) { ?>
<s><?php echo display_amount($row['it_cust_amount']); ?></s>
<?php if ($row['it_cust_price'] && !$row['it_gallery']) { ?>
<s><?php echo display_price($row['it_cust_price']); ?></s>
<?php } ?>
<?php if (!$row['it_gallery']) { // 전시 상품이 아닐 때 ?>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<?php } ?>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>

View File

@ -22,11 +22,11 @@ for ($i=1; $row=sql_fetch_array($result); $i++)
<a href="<?php echo $href; ?>" class="sct_a">
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<?php if ($row['it_cust_amount'] && !$row['it_gallery']) { ?>
<s><?php echo display_amount($row['it_cust_amount']); ?></s>
<?php if ($row['it_cust_price'] && !$row['it_gallery']) { ?>
<s><?php echo display_price($row['it_cust_price']); ?></s>
<?php } ?>
<?php if (!$row['it_gallery']) { // 전시 상품이 아닐 때 ?>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<?php } ?>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>

View File

@ -22,11 +22,11 @@ for ($i=1; $row=sql_fetch_array($result); $i++)
<a href="<?php echo $href; ?>" class="sct_a">
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<?php if ($row['it_cust_amount'] && !$row['it_gallery']) { ?>
<s><?php echo display_amount($row['it_cust_amount']); ?></s>
<?php if ($row['it_cust_price'] && !$row['it_gallery']) { ?>
<s><?php echo display_price($row['it_cust_price']); ?></s>
<?php } ?>
<?php if (!$row['it_gallery']) { // 전시 상품이 아닐 때 ?>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<?php } ?>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>

View File

@ -22,11 +22,11 @@ for ($i=1; $row=sql_fetch_array($result); $i++)
<a href="<?php echo $href; ?>" class="sct_a">
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<?php if ($row['it_cust_amount'] && !$row['it_gallery']) { ?>
<s><?php echo display_amount($row['it_cust_amount']); ?></s>
<?php if ($row['it_cust_price'] && !$row['it_gallery']) { ?>
<s><?php echo display_price($row['it_cust_price']); ?></s>
<?php } ?>
<?php if (!$row['it_gallery']) { // 전시 상품이 아닐 때 ?>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<?php } ?>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>

View File

@ -46,7 +46,7 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">판매가격</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($list[$i]['ct_amount']); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($list[$i]['ct_price']); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">수량</th>
@ -54,7 +54,7 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">소계</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($list[$i]['stotal_amount']); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($list[$i]['stotal_amount']); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">포인트</th>
@ -65,13 +65,13 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
<?php if ($od_send_cost > 0) { // 배송비가 있다면 ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">배송비</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($od_send_cost); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($od_send_cost); ?></td>
</tr>
<?php } ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">주문합계</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($ttotal_amount); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($ttotal_amount); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">포인트합계</th>
@ -97,14 +97,14 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
<?php if ($od_receipt_card > 0) { ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">신용카드 입금액</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($od_receipt_card); ?><!-- (승인전 금액입니다.) --></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($od_receipt_card); ?><!-- (승인전 금액입니다.) --></td>
</tr>
<?php } ?>
<?php if ($od_receipt_bank > 0) { ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>"><?php echo $od_settle_case; ?> 입금액</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($od_receipt_bank); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($od_receipt_bank); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">계좌번호</th>

View File

@ -46,7 +46,7 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">판매가격</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($list[$i]['ct_amount']); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($list[$i]['ct_price']); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">수량</th>
@ -54,7 +54,7 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">소계</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($list[$i]['stotal_amount']); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($list[$i]['stotal_amount']); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">포인트</th>
@ -65,13 +65,13 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
<?php if ($od_send_cost > 0) { // 배송비가 있다면 ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">배송비</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($od_send_cost); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($od_send_cost); ?></td>
</tr>
<?php } ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">주문합계</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($ttotal_amount); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($ttotal_amount); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">포인트합계</th>
@ -97,14 +97,14 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
<?php if ($od_receipt_card > 0) { ?>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">신용카드 입금액</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($od_receipt_card); ?><!-- (승인전 금액입니다.) --></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($od_receipt_card); ?><!-- (승인전 금액입니다.) --></td>
</tr>
<?php } ?>
<?php if ($od_receipt_bank > 0) { ?>
<tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>"><?php echo $od_settle_case; ?> 입금액</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($od_receipt_bank); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($od_receipt_bank); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">계좌번호</th>

View File

@ -45,7 +45,7 @@ $ft_a_st = 'display:block;padding:30px 0;background:#484848;color:#fff;text-alig
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">판매가격</th>
<td style="<?php echo $td_st; ?>"><?php echo display_amount($list[$i]['ct_amount']); ?></td>
<td style="<?php echo $td_st; ?>"><?php echo display_price($list[$i]['ct_price']); ?></td>
</tr>
<tr>
<th scope="row" style="<?php echo $th_st; ?>">수량</th>

View File

@ -21,7 +21,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
<a href="<?php echo $href; ?>" class="sct_a">
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>
</span>

View File

@ -21,7 +21,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
<a href="<?php echo $href; ?>" class="sct_a">
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>
</span>

View File

@ -23,7 +23,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<p><?php echo $row['it_basic']; ?></p>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>
</span>

View File

@ -23,7 +23,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
<span class="sct_img"><?php echo get_it_image($row['it_id'], $img_width, $img_height); ?></span>
<b><?php echo stripslashes($row['it_name']); ?></b>
<p><?php echo $row['it_basic']; ?></p>
<span class="sct_cost"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></span>
<span class="sct_cost"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></span>
<span class="sct_icon">
<?php echo display_item_icon($row); // 이미지 아이콘?>
</span>

View File

@ -50,7 +50,7 @@ $i_temp_point = (int)$_POST['od_temp_point'];
// 주문금액이 상이함
$sql = " select SUM(ct_amount * ct_qty) as od_amount from {$g4['shop_cart_table']} where uq_id = '$tmp_uq_id' ";
$sql = " select SUM(ct_price * ct_qty) as od_amount from {$g4['shop_cart_table']} where uq_id = '$tmp_uq_id' ";
$row = sql_fetch($sql);
if ((int)$row['od_amount'] !== $i_amount) {
die("Error.");

View File

@ -39,9 +39,9 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
</td>
<td><?php echo substr($row['od_time'],0,16); ?> (<?php echo get_yoil($row['od_time']); ?>)</td>
<td class="td_bignum"><?php echo $row['itemcount']; ?></td>
<td class="td_bignum"><?php echo display_amount($row['orderamount']); ?></td>
<td class="td_bignum"><?php echo display_amount($row['receiptamount']); ?></td>
<td class="td_bignum"><?php echo display_amount($row['misu']); ?></td>
<td class="td_bignum"><?php echo display_price($row['orderamount']); ?></td>
<td class="td_bignum"><?php echo display_price($row['receiptamount']); ?></td>
<td class="td_bignum"><?php echo display_price($row['misu']); ?></td>
</tr>
<?php

View File

@ -79,7 +79,7 @@ if(openwin != null) {
}
else
{
$wanbul = display_amount($receipt_amount);
$wanbul = display_price($receipt_amount);
}
// 120615 : 취소된 값을 두번 빼주는 결과가 되어 코드 수정 (군포돼지님)
@ -119,7 +119,7 @@ if(openwin != null) {
</tr>
<tr>
<th scope="row">결제금액</th>
<td><?php echo display_amount($cd['cd_amount']); ?></td>
<td><?php echo display_price($cd['cd_amount']); ?></td>
</tr>
<tr>
<th scope="row">승인일시</th>
@ -149,7 +149,7 @@ if(openwin != null) {
</tr>
<tr>
<th scope="row">결제금액</th>
<td><?php echo display_amount($cd['cd_amount']); ?></td>
<td><?php echo display_price($cd['cd_amount']); ?></td>
</tr>
<tr>
<th scope="row">승인일시</th>
@ -181,7 +181,7 @@ if(openwin != null) {
?>
<tr>
<th scope="row">입금액</th>
<td><?php echo display_amount($od['od_receipt_bank']); ?></td>
<td><?php echo display_price($od['od_receipt_bank']); ?></td>
</tr>
<tr>
<th scope="row">입금확인일시</th>
@ -238,7 +238,7 @@ if(openwin != null) {
?>
<tr>
<th scope="row">승인취소 금액</th>
<td><?php echo display_amount($od['od_cancel_card']); ?></td>
<td><?php echo display_price($od['od_cancel_card']); ?></td>
</tr>
<?php
}
@ -248,7 +248,7 @@ if(openwin != null) {
?>
<tr>
<th scope="row">환불 금액</th>
<td><?php echo display_amount($od['od_refund_amount']); ?></td>
<td><?php echo display_price($od['od_refund_amount']); ?></td>
</tr>
<?php
}
@ -421,19 +421,19 @@ if(openwin != null) {
<ul>
<li>
총 구매액
<strong><?php echo display_amount($tot_amount); ?></strong>
<strong><?php echo display_price($tot_amount); ?></strong>
</li>
<?php
if ($od['od_dc_amount'] > 0) {
echo '<li>';
echo '할인액'.PHP_EOL;
echo '<strong>'.display_amount($od['od_dc_amount']).'</strong>';
echo '<strong>'.display_price($od['od_dc_amount']).'</strong>';
echo '</li>';
}
if ($misu_amount > 0) {
echo '<li>';
echo '미결제액'.PHP_EOL;
echo '<strong>'.display_amount($misu_amount).'</strong>';
echo '<strong>'.display_price($misu_amount).'</strong>';
echo '</li>';
}
?>

View File

@ -21,7 +21,7 @@ $sql = " select b.it_sell_email,
a.it_opt5,
a.it_opt6,
a.ct_qty,
a.ct_amount,
a.ct_price,
a.ct_point
from {$g4['shop_cart_table']} a, {$g4['shop_item_table']} b
where a.uq_id = '$tmp_uq_id'
@ -36,8 +36,8 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
$list[$i]['it_origin'] = $row['it_origin'];
$list[$i]['it_opt'] = print_item_options($row['it_id'], $row['it_opt1'], $row['it_opt2'], $row['it_opt3'], $row['it_opt4'], $row['it_opt5'], $row['it_opt6']);
$list[$i]['ct_qty'] = $row['ct_qty'];
$list[$i]['ct_amount'] = $row['ct_amount'];
$list[$i]['stotal_amount'] = $row['ct_amount'] * $row['ct_qty'];
$list[$i]['ct_price'] = $row['ct_price'];
$list[$i]['stotal_amount'] = $row['ct_price'] * $row['ct_qty'];
$list[$i]['stotal_point'] = $row['ct_point'] * $row['ct_qty'];
$ttotal_amount += $list[$i]['stotal_amount'];

View File

@ -119,9 +119,7 @@ $total_count = $row['cnt'];
for ($i=0; $i<$save['cnt']; $i++) {
$sql = " select it_id,
it_name,
it_amount,
it_amount2,
it_amount3,
it_price,
it_tel_inq,
it_point,
it_type1,
@ -137,7 +135,7 @@ $total_count = $row['cnt'];
<tr>
<td class="ssch_it_img"><?php echo $image; ?></td>
<td><?php echo get_text($row['it_name']).it_name_icon($row); ?></td>
<td class="ssch_num"><?php echo display_amount(get_amount($row), $row['it_tel_inq']); ?></td>
<td class="ssch_num"><?php echo display_price(get_price($row), $row['it_tel_inq']); ?></td>
<td class="ssch_num"><?php echo display_point($row['it_point']); ?></td>
</tr>
<?php } // for 끝 ?>

View File

@ -50,7 +50,7 @@ include_once('./_head.php');
}
}
$it_amount = get_amount($row);
$it_price = get_price($row);
if ($row['it_tel_inq']) $out_cd = 'tel_inq';
@ -73,7 +73,7 @@ include_once('./_head.php');
<input type="checkbox" name="it_id[<?php echo $i; ?>]" value="<?php echo $row['it_id']; ?>" onclick="out_cd_check(this, '<?php echo $out_cd; ?>');">
<?php } ?>
<input type="hidden" name="it_name[<?php echo $i; ?>]" value="<?php echo $row['it_name']; ?>">
<input type="hidden" name="it_amount[<?php echo $i; ?>]" value="<?php echo $it_amount; ?>">
<input type="hidden" name="it_price[<?php echo $i; ?>]" value="<?php echo $it_price; ?>">
<input type="hidden" name="it_point[<?php echo $i; ?>]" value="<?php echo $row['it_point']; ?>">
<input type="hidden" name="ct_qty[<?php echo $i; ?>]" value="1">
</td>