매출현황 금액을 결제수단별로 표시하도록 수정

This commit is contained in:
chicpro
2014-01-28 18:04:14 +09:00
parent 1699f93080
commit 5a4df00cfa
4 changed files with 99 additions and 20 deletions

View File

@ -21,7 +21,10 @@ function print_line($save)
<td class="td_numsum"><?php echo number_format($save['orderprice']); ?></td>
<td class="td_numcoupon"><?php echo number_format($save['ordercoupon']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptbank']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptvbank']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptiche']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptcard']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receipthp']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptpoint']); ?></td>
<td class="td_numcancel1"><?php echo number_format($save['ordercancel']); ?></td>
<td class="td_numrdy"><?php echo number_format($save['misu']); ?></td>
@ -55,8 +58,11 @@ $result = sql_query($sql);
<th scope="col">주문수</th>
<th scope="col">주문합계</th>
<th scope="col">쿠폰</th>
<th scope="col">계좌입금</th>
<th scope="col">무통장</th>
<th scope="col">가상계좌</th>
<th scope="col">계좌이체</th>
<th scope="col">카드입금</th>
<th scope="col">휴대폰</th>
<th scope="col">포인트입금</th>
<th scope="col">주문취소</th>
<th scope="col">미수금</th>
@ -81,8 +87,14 @@ $result = sql_query($sql);
$save['orderprice'] += $row['orderprice'];
$save['ordercancel'] += $row['od_cancel_price'];
$save['ordercoupon'] += $row['couponprice'];
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
if($row['od_settle_case'] == '무통장')
$save['receiptbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$save['receiptvbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$save['receiptiche'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$save['receipthp'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$save['receiptcard'] += $row['od_receipt_price'];
$save['receiptpoint'] += $lines[$i]['od_receipt_point'];
@ -92,8 +104,14 @@ $result = sql_query($sql);
$tot['orderprice'] += $row['orderprice'];
$tot['ordercancel'] += $row['od_cancel_price'];
$tot['ordercoupon'] += $row['couponprice'];
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
if($row['od_settle_case'] == '무통장')
$tot['receiptbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$tot['receiptvbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$tot['receiptiche'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$tot['receipthp'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$tot['receiptcard'] += $row['od_receipt_price'];
$tot['receiptpoint '] += $row['od_receipt_point'];
@ -101,7 +119,7 @@ $result = sql_query($sql);
}
if ($i == 0) {
echo '<tr><td colspan="9" class="empty_table">자료가 없습니다.</td></tr>';
echo '<tr><td colspan="12" class="empty_table">자료가 없습니다.</td></tr>';
} else {
print_line($save);
}
@ -114,7 +132,10 @@ $result = sql_query($sql);
<td><?php echo number_format($tot['orderprice']); ?></td>
<td><?php echo number_format($tot['ordercoupon']); ?></td>
<td><?php echo number_format($tot['receiptbank']); ?></td>
<td><?php echo number_format($tot['receiptvbank']); ?></td>
<td><?php echo number_format($tot['receiptiche']); ?></td>
<td><?php echo number_format($tot['receiptcard']); ?></td>
<td><?php echo number_format($tot['receipthp']); ?></td>
<td><?php echo number_format($tot['receiptpoint']); ?></td>
<td><?php echo number_format($tot['ordercancel']); ?></td>
<td><?php echo number_format($tot['misu']); ?></td>

View File

@ -21,7 +21,10 @@ function print_line($save)
<td class="td_numsum"><?php echo number_format($save['orderprice']); ?></td>
<td class="td_numcoupon"><?php echo number_format($save['ordercoupon']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptbank']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptvbank']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptiche']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptcard']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receipthp']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptpoint']); ?></td>
<td class="td_numcancel1"><?php echo number_format($save['ordercancel']); ?></td>
<td class="td_numrdy"><?php echo number_format($save['misu']); ?></td>
@ -56,8 +59,11 @@ $result = sql_query($sql);
<th scope="col">주문수</th>
<th scope="col">주문합계</th>
<th scope="col">쿠폰</th>
<th scope="col">계좌입금</th>
<th scope="col">무통장</th>
<th scope="col">가상계좌</th>
<th scope="col">계좌이체</th>
<th scope="col">카드입금</th>
<th scope="col">휴대폰</th>
<th scope="col">포인트입금</th>
<th scope="col">주문취소</th>
<th scope="col">미수금</th>
@ -82,8 +88,14 @@ $result = sql_query($sql);
$save['orderprice'] += $row['orderprice'];
$save['ordercancel'] += $row['od_cancel_price'];
$save['ordercoupon'] += $row['couponprice'];
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
if($row['od_settle_case'] == '무통장')
$save['receiptbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$save['receiptvbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$save['receiptiche'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$save['receipthp'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$save['receiptcard'] += $row['od_receipt_price'];
$save['receiptpoint'] += $row['od_receipt_point'];
@ -93,8 +105,14 @@ $result = sql_query($sql);
$tot['orderprice'] += $row['orderprice'];
$tot['ordercancel'] += $row['od_cancel_price'];
$tot['ordercoupon'] += $row['couponprice'];
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
if($row['od_settle_case'] == '무통장')
$tot['receiptbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$tot['receiptvbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$tot['receiptiche'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$tot['receipthp'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$tot['receiptcard'] += $row['od_receipt_price'];
$tot['receiptpoint'] += $row['od_receipt_point'];
@ -102,7 +120,7 @@ $result = sql_query($sql);
}
if ($i == 0) {
echo '<tr><td colspan="9" class="empty_table">자료가 없습니다.</td></tr>';
echo '<tr><td colspan="12" class="empty_table">자료가 없습니다.</td></tr>';
} else {
print_line($save);
}
@ -115,7 +133,10 @@ $result = sql_query($sql);
<td><?php echo number_format($tot['orderprice']); ?></td>
<td><?php echo number_format($tot['ordercoupon']); ?></td>
<td><?php echo number_format($tot['receiptbank']); ?></td>
<td><?php echo number_format($tot['receiptvbank']); ?></td>
<td><?php echo number_format($tot['receiptiche']); ?></td>
<td><?php echo number_format($tot['receiptcard']); ?></td>
<td><?php echo number_format($tot['receipthp']); ?></td>
<td><?php echo number_format($tot['receiptpoint']); ?></td>
<td><?php echo number_format($tot['ordercancel']); ?></td>
<td><?php echo number_format($tot['misu']); ?></td>

View File

@ -35,8 +35,11 @@ $result = sql_query($sql);
<th scope="col">주문자</th>
<th scope="col">주문합계</th>
<th scope="col">쿠폰</th>
<th scope="col">계좌입금</th>
<th scope="col">무통장</th>
<th scope="col">가상계좌</th>
<th scope="col">계좌이체</th>
<th scope="col">카드입금</th>
<th scope="col">휴대폰</th>
<th scope="col">포인트입금</th>
<th scope="col">주문취소</th>
<th scope="col">미수금</th>
@ -53,9 +56,15 @@ $result = sql_query($sql);
$href = '<a href="./orderlist.php?sel_field=mb_id&amp;search='.$row['mb_id'].'">';
}
$receipt_bank = $receipt_card = 0;
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
$receipt_bank = $receipt_card = $receipt_vbank = $receipt_iche = $receipt_hp = 0;
if($row['od_settle_case'] == '무통장')
$receipt_bank = $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$receipt_vbank = $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$receipt_iche = $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$receipt_hp = $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$receipt_card = $row['od_receipt_price'];
@ -66,7 +75,10 @@ $result = sql_query($sql);
<td class="td_numsum"><?php echo number_format($row['orderprice']); ?></td>
<td class="td_numcoupon"><?php echo number_format($row['couponprice']); ?></td>
<td class="td_numincome"><?php echo number_format($receipt_bank); ?></td>
<td class="td_numincome"><?php echo number_format($receipt_vbank); ?></td>
<td class="td_numincome"><?php echo number_format($receipt_iche); ?></td>
<td class="td_numincome"><?php echo number_format($receipt_card); ?></td>
<td class="td_numincome"><?php echo number_format($receipt_hp); ?></td>
<td class="td_numincome"><?php echo number_format($row['od_receipt_point']); ?></td>
<td class="td_numcancel1"><?php echo number_format($row['od_cancel_price']); ?></td>
<td class="td_numrdy"><?php echo number_format($row['od_misu']); ?></td>
@ -75,16 +87,17 @@ $result = sql_query($sql);
$tot['orderprice'] += $row['orderprice'];
$tot['ordercancel'] += $row['od_cancel_price'];
$tot['coupon'] += $row['couponprice'] ;
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
$tot['receipt_bank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$tot['receipt_card'] += $row['od_receipt_price'];
$tot['receipt_bank'] += $receipt_bank;
$tot['receipt_vbank'] += $receipt_vbank;
$tot['receipt_iche'] += $receipt_iche;
$tot['receipt_card'] += $receipt_card;
$tot['receipt_hp'] += $receipt_hp;
$tot['receipt_point'] += $row['od_receipt_point'];
$tot['misu'] += $row['od_misu'];
}
if ($i == 0) {
echo '<tr><td colspan="9" class="empty_table">자료가 없습니다</td></tr>';
echo '<tr><td colspan="12" class="empty_table">자료가 없습니다</td></tr>';
}
?>
</tbody>
@ -94,7 +107,10 @@ $result = sql_query($sql);
<td><?php echo number_format($tot['orderprice']); ?></td>
<td><?php echo number_format($tot['coupon']); ?></td>
<td><?php echo number_format($tot['receipt_bank']); ?></td>
<td><?php echo number_format($tot['receipt_vbank']); ?></td>
<td><?php echo number_format($tot['receipt_iche']); ?></td>
<td><?php echo number_format($tot['receipt_card']); ?></td>
<td><?php echo number_format($tot['receipt_hp']); ?></td>
<td><?php echo number_format($tot['receipt_point']); ?></td>
<td><?php echo number_format($tot['ordercancel']); ?></td>
<td><?php echo number_format($tot['misu']); ?></td>

View File

@ -16,7 +16,10 @@ function print_line($save)
<td class="td_numsum"><?php echo number_format($save['orderprice']); ?></td>
<td class="td_numcoupon"><?php echo number_format($save['ordercoupon']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptbank']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptvbank']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptiche']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptcard']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receipthp']); ?></td>
<td class="td_numincome"><?php echo number_format($save['receiptpoint']); ?></td>
<td class="td_numcancel1"><?php echo number_format($save['ordercancel']); ?></td>
<td class="td_numrdy"><?php echo number_format($save['misu']); ?></td>
@ -50,8 +53,11 @@ $result = sql_query($sql);
<th scope="col">주문수</th>
<th scope="col">주문합계</th>
<th scope="col">쿠폰</th>
<th scope="col">계좌입금</th>
<th scope="col">무통장</th>
<th scope="col">가상계좌</th>
<th scope="col">계좌이체</th>
<th scope="col">카드입금</th>
<th scope="col">휴대폰</th>
<th scope="col">포인트입금</th>
<th scope="col">주문취소</th>
<th scope="col">미수금</th>
@ -76,8 +82,14 @@ $result = sql_query($sql);
$save['orderprice'] += $row['orderprice'];
$save['ordercancel'] += $row['od_cancel_price'];
$save['ordercoupon'] += $row['couponprice'];
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
if($row['od_settle_case'] == '무통장')
$save['receiptbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$save['receiptvbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$save['receiptiche'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$save['receipthp'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$save['receiptcard'] += $row['od_receipt_price'];
$save['receiptpoint'] += $row['od_receipt_point'];
@ -87,8 +99,14 @@ $result = sql_query($sql);
$tot['orderprice'] += $row['orderprice'];
$tot['ordercancel'] += $row['od_cancel_price'];
$tot['ordercoupon'] += $row['couponprice'];
if($row['od_settle_case'] == '무통장' || $row['od_settle_case'] == '가상계좌' || $row['od_settle_case'] == '계좌이체')
if($row['od_settle_case'] == '무통장')
$tot['receiptbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '가상계좌')
$tot['receiptvbank'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '계좌이체')
$tot['receiptiche'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '휴대폰')
$tot['receipthp'] += $row['od_receipt_price'];
if($row['od_settle_case'] == '신용카드')
$tot['receiptcard'] += $row['od_receipt_price'];
$tot['receiptpoint'] += $row['od_receipt_point'];
@ -96,7 +114,7 @@ $result = sql_query($sql);
}
if ($i == 0) {
echo '<tr><td colspan="9" class="empty_table">자료가 없습니다.</td></tr>';
echo '<tr><td colspan="12" class="empty_table">자료가 없습니다.</td></tr>';
} else {
print_line($save);
}
@ -109,7 +127,10 @@ $result = sql_query($sql);
<td><?php echo number_format($tot['orderprice']); ?></td>
<td><?php echo number_format($tot['ordercoupon']); ?></td>
<td><?php echo number_format($tot['receiptbank']); ?></td>
<td><?php echo number_format($tot['receiptvbank']); ?></td>
<td><?php echo number_format($tot['receiptiche']); ?></td>
<td><?php echo number_format($tot['receiptcard']); ?></td>
<td><?php echo number_format($tot['receipthp']); ?></td>
<td><?php echo number_format($tot['receiptpoint']); ?></td>
<td><?php echo number_format($tot['ordercancel']); ?></td>
<td><?php echo number_format($tot['misu']); ?></td>