diff options
Diffstat (limited to 'views/mods/mod_statistics')
| -rw-r--r-- | views/mods/mod_statistics/chartsalestopaymentmethod/all.phtml | 17 | ||||
| -rw-r--r-- | views/mods/mod_statistics/charttopsellertosales/all.phtml | 12 | ||||
| -rw-r--r-- | views/mods/mod_statistics/simplefilter.phtml | 2 |
3 files changed, 25 insertions, 6 deletions
diff --git a/views/mods/mod_statistics/chartsalestopaymentmethod/all.phtml b/views/mods/mod_statistics/chartsalestopaymentmethod/all.phtml index c519090..9b5fe3a 100644 --- a/views/mods/mod_statistics/chartsalestopaymentmethod/all.phtml +++ b/views/mods/mod_statistics/chartsalestopaymentmethod/all.phtml @@ -17,17 +17,26 @@ <div class="wpsg_clearer"></div>
<?php
+ $barChartJS = Array();
+ $pieChartJS = Array();
+ $barChartJS['amount'] = '';
+ $barChartJS['payment'] = '';
+ $barChartJS['total'] = '';
+ $pieChartJS['amount'] = '';
+ $pieChartJS['sales'] = '';
+ $pieChartJS['percent'] = '';
+
foreach ($this->view['chart']['data']['records'] as $data)
{
$barChartJS['payment'] .= "'".wpsg_hspc($data['name'])."', ";
$barChartJS['total'] .= wpsg_hspc($data['total']).", ";
- $pieChartJS .= "['".wpsg_hspc($data['name'])."', ".wpsg_hspc($data['percent'])."], ";
+ $pieChartJS['percent'] .= "['".wpsg_hspc($data['name'])."', ".wpsg_hspc($data['percent'])."], ";
}
$barChartJS['payment'] = substr($barChartJS['payment'], 0, -2);
$barChartJS['total'] = substr($barChartJS['total'], 0, -2);
- $pieChartJS = substr($pieChartJS, 0, -2);
+ $pieChartJS['percent'] = substr($pieChartJS['percent'], 0, -2);
?>
@@ -55,7 +64,7 @@ xaxis: {
renderer: jQuery.jqplot.CategoryAxisRenderer,
ticks: payment,
- label:'<?php echo wpsg_hspc($this->view['chart']['info']['xaxis']['label']); ?>'
+ label:'<?php echo wpsg_hspc(wpsg_getStr($this->view['chart']['info']['xaxis']['label'])); ?>'
},
yaxis:{
label:'<?php echo wpsg_hspc($this->view['chart']['info']['yaxis']['label']); ?>',
@@ -68,7 +77,7 @@ highlighter: { show: false }
});
- var data = [<?php echo $pieChartJS; ?>];
+ var data = [<?php echo $pieChartJS['percent']; ?>];
var chartsalestopaymentmethodPie = jQuery.jqplot ('chartsalestopaymentmethod-pie', [data],
{
diff --git a/views/mods/mod_statistics/charttopsellertosales/all.phtml b/views/mods/mod_statistics/charttopsellertosales/all.phtml index dfff484..6544b94 100644 --- a/views/mods/mod_statistics/charttopsellertosales/all.phtml +++ b/views/mods/mod_statistics/charttopsellertosales/all.phtml @@ -20,7 +20,15 @@ <div class="wpsg_clearer"></div>
<?php
-
+ $barChartJS = Array();
+ $pieChartJS = Array();
+ $barChartJS['amount'] = '';
+ $barChartJS['payment'] = '';
+ $barChartJS['total'] = '';
+
+ $pieChartJS['amount'] = '';
+ $pieChartJS['sales'] = '';
+
foreach ($this->view['chart']['data']['records'] as $data)
{
$barChartJS['payment'] .= "'".wpsg_hspc($data['name'])."', ";
@@ -83,7 +91,7 @@ fontWeight: 'normal',
textColor: '#666666'
},
- label:'<?php echo wpsg_hspc($this->view['chart']['info']['xaxis']['label']); ?>',
+ label:'<?php echo wpsg_hspc(wpsg_getStr($this->view['chart']['info']['xaxis']['label'])); ?>',
labelOptions: {
fontFamily: 'Arial',
fontSize: '14pt',
diff --git a/views/mods/mod_statistics/simplefilter.phtml b/views/mods/mod_statistics/simplefilter.phtml index c3906de..9c8eb5b 100644 --- a/views/mods/mod_statistics/simplefilter.phtml +++ b/views/mods/mod_statistics/simplefilter.phtml @@ -56,8 +56,10 @@ <input style="float:left; margin-left:25px;" type="submit" class="button-secondary" value="<?php echo __('Anzeigen', 'wpsg'); ?>" />
<div class="customfilter" style="display:none;">
+ <?php if (isset($this->view['filter']['day'][0])) { ?>
<?php echo wpsg_drawForm_Date('filter[day][0]', __('von', 'wpsg'), $this->view['filter']['day'][0]['d'].'.'.$this->view['filter']['day'][0]['m'].'.'.$this->view['filter']['day'][0]['Y'], array('time' => false)); ?>
<?php echo wpsg_drawForm_Date('filter[day][1]', __('bis', 'wpsg'), $this->view['filter']['day'][1]['d'].'.'.$this->view['filter']['day'][1]['m'].'.'.$this->view['filter']['day'][1]['Y'], array('time' => false)); ?>
+ <?php } ?>
</div>
<input type="hidden" id="wpsg_statistics_order" name="filter[order]" value="<?php echo wpsg_hspc($this->view['filter']['order']); ?>" />
|
