옵션항목에 추가금액 표시하도록 수정

This commit is contained in:
chicpro
2013-12-02 17:50:40 +09:00
parent 31f5d15664
commit 87e9fe4e2a

View File

@ -1087,14 +1087,15 @@ function print_item_options($it_id, $cart_id)
{ {
global $g5; global $g5;
$sql = " select ct_option, ct_qty from {$g5['g5_shop_cart_table']} where it_id = '$it_id' and od_id = '$cart_id' order by io_type asc, ct_id asc "; $sql = " select ct_option, ct_qty, io_price
from {$g5['g5_shop_cart_table']} where it_id = '$it_id' and od_id = '$cart_id' order by io_type asc, ct_id asc ";
$result = sql_query($sql); $result = sql_query($sql);
$str = ''; $str = '';
for($i=0; $row=sql_fetch_array($result); $i++) { for($i=0; $row=sql_fetch_array($result); $i++) {
if($i == 0) if($i == 0)
$str .= '<ul>'.PHP_EOL; $str .= '<ul>'.PHP_EOL;
$str .= '<li>'.$row['ct_option'].' '.$row['ct_qty'].'개</li>'.PHP_EOL; $str .= '<li>'.$row['ct_option'].' '.$row['ct_qty'].'개 (+'.display_price($row['io_price']).')</li>'.PHP_EOL;
} }
if($i > 0) if($i > 0)