コード例 #1
0
ファイル: Product.php プロジェクト: kirkbauer2/kirkxc
 /**
  * Populate model object properties by the passed data
  *
  * @param array $data Data to set
  *
  * @return void
  */
 protected function setModelProperties(array $data)
 {
     $data['useCustomOG'] = $this->getPostedData('useCustomOG');
     $nonFilteredData = \XLite\Core\Request::getInstance()->getNonFilteredData();
     $data['ogMeta'] = isset($nonFilteredData['postedData']['ogMeta']) ? $nonFilteredData['postedData']['ogMeta'] : '';
     parent::setModelProperties($data);
 }
コード例 #2
0
ファイル: Product.php プロジェクト: kirkbauer2/kirkxc
 /**
  * Populate model object properties by the passed data
  *
  * @param array $data Data to set
  *
  * @return void
  */
 protected function setModelProperties(array $data)
 {
     $participateSale = $this->getPostedData('participateSale');
     $data['participateSale'] = false;
     if ($participateSale) {
         $data['participateSale'] = true;
         $data['discountType'] = $this->getPostedData('discountType');
         $data['salePriceValue'] = doubleval($this->getPostedData('salePriceValue'));
     }
     parent::setModelProperties($data);
 }