コード例 #1
0
ファイル: Flexy.php プロジェクト: villos/tree_admin
 /**
  * A Flexy helper method to return the value of a field for display.
  *
  * Overrides the parent Flexy helper method so that it can deal with
  * displaying warnings for average calculations, etc.
  *
  * @param array  $aArray An array of items.
  * @param string $k      The index name of the item to display.
  * @return mixed The item to display.
  */
 function showValue($aArray, $k)
 {
     if ($k == 'average') {
         if ($aArray[$k] === true || is_numeric($aArray[$k]) && $aArray[$k] > 0) {
             self::$averagedColumnDisplayed = true;
             return '<img src="' . OX::assetPath() . '/images/warning.gif" width="16 height="16" alt="" title="" />';
         } else {
             if (preg_match('/light$/', $aArray[$k])) {
                 return parent::showValue($aArray, $k);
             } else {
                 if (preg_match('/dark$/', $aArray[$k])) {
                     return parent::showValue($aArray, $k);
                 } else {
                     return '-';
                 }
             }
         }
     } else {
         return parent::showValue($aArray, $k);
     }
 }
コード例 #2
0
 function __construct($aParams)
 {
     $this->aPlugins = array();
     parent::__construct($aParams);
 }
コード例 #3
0
ファイル: Field.php プロジェクト: hostinger/revive-adserver
 function __construct()
 {
     $this->coreParams = OA_Admin_Statistics_Common::getCoreParams();
 }