17 array(
'oxtitle',
'oxstat', 1, 0, 0),
18 array(
'oxid',
'oxstat', 0, 0, 1)
20 'container2' => array(
21 array(
'oxtitle',
'oxstat', 1, 0, 0),
22 array(
'oxid',
'oxstat', 0, 0, 1)
45 $sStatId = $sSynchId ? $sSynchId : $sOxId;
46 $oStat =
oxNew(
'oxstatistic');
47 $oStat->load($sStatId);
48 $aStatData = unserialize($oStat->oxstatistics__oxvalue->value);
56 $sFilter = (is_array($aFilter) && isset($aFilter[
'_0'])) ? $oStr->preg_replace(
'/^\*/',
'%', $aFilter[
'_0']) : null;
58 foreach ($aReports as $oReport) {
61 if (is_array($aStatData) && in_array($oReport->filename, $aStatData)) {
65 if (!is_array($aStatData) || !in_array($oReport->filename, $aStatData)) {
71 if ($sFilter && !$oStr->preg_match(
"/^" . preg_quote($sFilter) .
"/i", $oReport->name)) {
75 $aData[$iCnt][
'_0'] = $oReport->name;
76 $aData[$iCnt][
'_1'] = $oReport->filename;
83 usort($aData, array($this,
"sortAsc"));
85 usort($aData, array($this,
"sortDesc"));
88 usort($aData, array($this,
"sortAsc"));
91 $aResponse[
'records'] = $aData;
92 $aResponse[
'totalRecords'] = count($aReports);
109 if ($oOne[
'_0'] == $oSec[
'_0']) {
113 return ($oOne[
'_0'] < $oSec[
'_0']) ? -1 : 1;
127 if ($oOne[
'_0'] == $oSec[
'_0']) {
131 return ($oOne[
'_0'] > $oSec[
'_0']) ? -1 : 1;
146 foreach ($aReports as $oRep) {
147 $aStats[] = $oRep->filename;
153 $oStat =
oxNew(
'oxstatistic');
154 if (is_array($aStats) && $oStat->load($soxId)) {
155 $aStatData = $oStat->getReports();
158 foreach ($aReports as $oRep) {
159 if (in_array($oRep->filename, $aStats) && ($iPos = array_search($oRep->filename, $aStatData)) !==
false) {
160 unset($aStatData[$iPos]);
164 $oStat->setReports($aStatData);
180 foreach ($aReports as $oRep) {
181 $aStats[] = $oRep->filename;
187 $oStat =
oxNew(
'oxstatistic');
188 if ($oStat->load($soxId)) {
189 $aStatData = (array) $oStat->getReports();
193 foreach ($aReports as $oRep) {
194 if (in_array($oRep->filename, $aStats) && !in_array($oRep->filename, $aStatData)) {
195 $aStatData[] = $oRep->filename;
199 $oStat->setReports($aStatData);