매출현황 그래프 수정
This commit is contained in:
@ -15,6 +15,7 @@ $pg_anchor = '<ul class="anchor">
|
|||||||
<li><a href="#anc_sidx_qna">상품문의</a></li>
|
<li><a href="#anc_sidx_qna">상품문의</a></li>
|
||||||
</ul>';
|
</ul>';
|
||||||
|
|
||||||
|
// 주문상태에 따른 합계 금액
|
||||||
function get_order_status_sum($status)
|
function get_order_status_sum($status)
|
||||||
{
|
{
|
||||||
global $g5;
|
global $g5;
|
||||||
@ -33,6 +34,7 @@ function get_order_status_sum($status)
|
|||||||
return $info;
|
return $info;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 일자별 주문 합계 금액
|
||||||
function get_order_date_sum($date)
|
function get_order_date_sum($date)
|
||||||
{
|
{
|
||||||
global $g5;
|
global $g5;
|
||||||
@ -143,22 +145,20 @@ function get_max_value($arr)
|
|||||||
$max_height = 240;
|
$max_height = 240;
|
||||||
$h_val = array();
|
$h_val = array();
|
||||||
$js_val = array();
|
$js_val = array();
|
||||||
|
$offset = 10; // 금액이 상대적으로 작아 높이가 0일 때 기본 높이로 사용
|
||||||
foreach($arr_order as $val) {
|
foreach($arr_order as $val) {
|
||||||
if($val['order'] > 0)
|
if($val['order'] > 0)
|
||||||
$h1 = intval(($max_height * $val['order']) / $max_y);
|
$h1 = intval(($max_height * $val['order']) / $max_y) + $offset;
|
||||||
else
|
else
|
||||||
$h1 = 0;
|
$h1 = 0;
|
||||||
|
|
||||||
if($val['cancel'] > 0)
|
if($val['cancel'] > 0)
|
||||||
$h2 = intval(($max_height * $val['cancel']) / $max_y);
|
$h2 = intval(($max_height * $val['cancel']) / $max_y) + $offset;
|
||||||
else
|
else
|
||||||
$h2 = 0;
|
$h2 = 0 ;
|
||||||
|
|
||||||
$h_val[]['order'] = $h1;
|
$h_val['order'][] = $h1;
|
||||||
$h_val[]['cancel'] = $h2;
|
$h_val['cancel'][] = $h2;
|
||||||
|
|
||||||
$js_val['order'][] = $h1;
|
|
||||||
$js_val['cancel'][] = $h2;
|
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
|
||||||
@ -236,8 +236,8 @@ $(function() {
|
|||||||
|
|
||||||
function graph_draw()
|
function graph_draw()
|
||||||
{
|
{
|
||||||
var g_h1 = new Array("<?php echo implode('", "', $js_val['order']); ?>");
|
var g_h1 = new Array("<?php echo implode('", "', $h_val['order']); ?>");
|
||||||
var g_h2 = new Array("<?php echo implode('", "', $js_val['cancel']); ?>");
|
var g_h2 = new Array("<?php echo implode('", "', $h_val['cancel']); ?>");
|
||||||
var duration = 600;
|
var duration = 600;
|
||||||
|
|
||||||
var $el = $("#sidx_graph_area li");
|
var $el = $("#sidx_graph_area li");
|
||||||
|
|||||||
@ -421,14 +421,14 @@ td.td_grpset {width:160px;border-left:1px solid #e9ecee;text-align:center}
|
|||||||
#sidx_graph {position:relative;width:1000px;height:350px}
|
#sidx_graph {position:relative;width:1000px;height:350px}
|
||||||
#sidx_graph_price {position:absolute;left:20px;top:50px;width:100px;margin:0;padding:0;list-style:none}
|
#sidx_graph_price {position:absolute;left:20px;top:50px;width:100px;margin:0;padding:0;list-style:none}
|
||||||
#sidx_graph_price li {height:50px;text-align:right}
|
#sidx_graph_price li {height:50px;text-align:right}
|
||||||
#sidx_graph_area {position:absolute;left:128px;top:40px;width:800px;height:260px;border-left:1px solid #eee;border-bottom:1px solid #eee;margin:0;padding:0;list-style:none}
|
#sidx_graph_area {position:absolute;left:128px;top:40px;width:800px;height:270px;border-left:1px solid #eee;border-bottom:1px solid #eee;margin:0;padding:0;list-style:none}
|
||||||
#sidx_graph_area li {float:left;position:relative;left:35px;width:100px;height:260px}
|
#sidx_graph_area li {float:left;position:relative;left:35px;width:100px;height:270px}
|
||||||
#sidx_graph_area .graph {position:absolute;bottom:0;width:20px;height:0}
|
#sidx_graph_area .graph {position:absolute;bottom:0;width:20px;height:0}
|
||||||
#sidx_graph_area .order {background-color:blue;left:30px}
|
#sidx_graph_area .order {background-color:blue;left:30px}
|
||||||
#sidx_graph_area .cancel {background-color:gray;left:55px}
|
#sidx_graph_area .cancel {background-color:gray;left:55px}
|
||||||
#sidx_graph_area #price_tooltip {display:none;position:absolute;bottom:0;left:0;background-color:#fff;border:1px solid gray}
|
#sidx_graph_area #price_tooltip {display:none;position:absolute;bottom:0;left:0;background-color:#fff;border:1px solid gray}
|
||||||
#sidx_graph_area #price_tooltip div {white-space:nowrap}
|
#sidx_graph_area #price_tooltip div {white-space:nowrap}
|
||||||
#sidx_graph_date {position:absolute;left:165px;top:310px;width:800px;margin:0;padding:0;list-style:none}
|
#sidx_graph_date {position:absolute;left:165px;top:320px;width:800px;margin:0;padding:0;list-style:none}
|
||||||
#sidx_graph_date li {float:left;width:100px;text-align:center}
|
#sidx_graph_date li {float:left;width:100px;text-align:center}
|
||||||
|
|
||||||
/* 쇼핑몰 설정 */
|
/* 쇼핑몰 설정 */
|
||||||
|
|||||||
Reference in New Issue
Block a user