OXID eShop CE  4.10.7
 All Classes Namespaces Files Functions Variables Pages
oxstatistic.php
Go to the documentation of this file.
1 <?php
2 
8 class oxStatistic extends oxBase
9 {
10 
14  protected $_sClassName = 'oxstatistic';
15 
19  public function __construct()
20  {
22  $this->init('oxstatistics');
23  }
24 
30  public function setReports($aVal)
31  {
32  $this->oxstatistics__oxvalue = new oxField(serialize($aVal), oxField::T_RAW);
33  }
34 
40  public function getReports()
41  {
42  return unserialize($this->oxstatistics__oxvalue->value);
43  }
44 
54  protected function _setFieldData($sFieldName, $sValue, $iDataType = oxField::T_TEXT)
55  {
56  if ('oxvalue' === $sFieldName) {
57  $iDataType = oxField::T_RAW;
58  }
59 
60  return parent::_setFieldData($sFieldName, $sValue, $iDataType);
61  }
62 }