PHP warning

reset() expects parameter 1 to be array, boolean given

/domains/komtek.pl/public_html/asoft/yii/framework/db/schema/CDbCriteria.php(280)

268      * @param string $column the column name (or a valid SQL expression)
269      * @param array $values list of values that the column value should be in
270      * @param string $operator the operator used to concatenate the new condition with the existing one.
271      * Defaults to 'AND'.
272      * @return CDbCriteria the criteria object itself
273      */
274     public function addInCondition($column,$values,$operator='AND')
275     {
276         if(($n=count($values))<1)
277             $condition='0=1'; // 0=1 is used because in MSSQL value alone can't be used in WHERE
278         elseif($n===1)
279         {
280             $value=reset($values);
281             if($value===null)
282                 $condition=$column.' IS NULL';
283             else
284             {
285                 $condition=$column.'='.self::PARAM_PREFIX.self::$paramCount;
286                 $this->params[self::PARAM_PREFIX.self::$paramCount++]=$value;
287             }
288         }
289         else
290         {
291             $params=array();
292             foreach($values as $value)

Stack Trace

#1
+
 /domains/komtek.pl/public_html/asoft/protected/components/products.php(100): CDbCriteria->addInCondition("t.ID_SGRA", false)
095             }
096             
097             
098 //             else {
099                 if ($sgra) {
100                     $dataProvider->SetCriteria($dataProvider->getCriteria()->addInCondition('t.ID_SGRA',natSgra::sgraWithSub($sgra)));
101                 }
102                 if (!empty($price1)) {
103                     $dataProvider->SetCriteria($dataProvider->getCriteria()->addSearchCondition('t.'.aso_pokaz_ceny(),$price1,false,'AND','>='));
104                 }
105                 if (!empty($price2)) {
#3
+
 /domains/komtek.pl/public_html/asoft/custom/models/comView.php(116): CBaseController->widget("application.components.products")
111 //                'asObjectClass'=>'natStow',    
112 //            ));
113 //            $ret=$ret || $ret1;
114         }
115         if (!$ret)
116             self::controller()->widget('application.components.products');
117     }
118 
119     static protected function esklepLayout($content,$params) {
120         $s=aso_params('sklep');
121         $lite=(self::$layout==='lite');
#4
+
 /domains/komtek.pl/public_html/asoft/protected/models/absComView.php(299): comView::esklepIndex(null)
294 
295     static protected function index($params) {
296         if (Yii::$mainModule) {
297 //            if (aso_homePage()) self::controller()->pageTitle='Home';
298             $m=Yii::$mainModule.'Index';
299             static::$m($params);
300             return;
301         }
302     }
303     
304     static protected function layout($content,$params) {
2024-03-19 04:51:34 Apache Yii Framework/1.1.14