Aktionen
Fehler #233
geschlossenException wenn man ein date erstellen will, gruppen aktiviert aber keine angelegt sind
Beginn:
05.05.2013
Abgabedatum:
% erledigt:
100%
Geschätzter Aufwand:
Beschreibung
da du jetzt anscheinend dafür verantwortlich bist.
PHP warning Invalid argument supplied for foreach() E:\xampp\htdocs\est\trunk\src\framework\web\helpers\CHtml.php(2283) 2271 $key=isset($htmlOptions['key']) ? $htmlOptions['key'] : 'primaryKey'; 2272 if(is_array($selection)) 2273 { 2274 foreach($selection as $i=>$item) 2275 { 2276 if(is_object($item)) 2277 $selection[$i]=$item->$key; 2278 } 2279 } 2280 elseif(is_object($selection)) 2281 $selection=$selection->$key; 2282 2283 foreach($listData as $key=>$value) 2284 { 2285 if(is_array($value)) 2286 { 2287 $content.='<optgroup label="'.($raw?$key : self::encode($key))."\">\n"; 2288 $dummy=array('options'=>$options); 2289 if(isset($htmlOptions['encode'])) 2290 $dummy['encode']=$htmlOptions['encode']; 2291 $content.=self::listOptions($selection,$value,$dummy); 2292 $content.='</optgroup>'."\n"; 2293 } 2294 else 2295 { Stack Trace #0 + E:\xampp\htdocs\est\trunk\src\framework\web\helpers\CHtml.php(920): CHtml::listOptions("''", null, array("placeholder" => "Hier können Sie mehrere Gruppen auswählen...", "id" => "groups-select", "multiple" => true, "name" => "Date[groups]")) #1 – E:\xampp\htdocs\est\trunk\src\protected\extensions\select2\Select2.php(69): CHtml::dropDownList("Date[groups]", "''", null, array("placeholder" => "Hier können Sie mehrere Gruppen auswählen...", "id" => "groups-select", "multiple" => true)) 64 } 65 66 if (isset($this->model)) { 67 echo CHtml::dropDownList($name, $this->model->{$this->attribute}, $this->data, $this->htmlOptions); 68 } else { 69 echo CHtml::dropDownList($name, $this->value, $this->data, $this->htmlOptions); 70 } 71 72 $this->registerScripts($id); 73 } 74 #2 + E:\xampp\htdocs\est\trunk\src\framework\web\CBaseController.php(167): Select2->run() #3 – E:\xampp\htdocs\est\trunk\src\protected\extensions\select2\Select2.php(120): CBaseController->widget("Select2", array("name" => "Date[groups]", "value" => "''", "data" => null, "htmlOptions" => array("placeholder" => "Hier können Sie mehrere Gruppen auswählen...", "id" => "groups-select", "select2Options" => array("allowClear" => true)), ...), true) 115 'name' => $name, 116 'value' => $select, 117 'data' => $data, 118 'htmlOptions' => $htmlOptions, 119 'multiple' => true, 120 ), true); 121 } 122 123 public static function activeMultiSelect($model, $attribute, $data, $htmlOptions = array()) { 124 return self::multiSelect(CHtml::activeName($model, $attribute) . '[]', CHtml::value($model, $attribute), $data, $htmlOptions); 125 } #4 – E:\xampp\htdocs\est\trunk\src\protected\views\date\_form.php(184): Select2::multiSelect("Date[groups]", "''", null, array("placeholder" => "Hier können Sie mehrere Gruppen auswählen...", "id" => "groups-select", "select2Options" => array("allowClear" => true))) 179 'placeholder' => 'Hier können Sie mehrere Gruppen auswählen...', 180 'id' => 'groups-select', 181 'select2Options' => array( 182 'allowClear' => true, 183 ), 184 )); 185 echo $form->error($model, 'groups'); 186 ?> 187 188 </div> 189 </div> #5 + E:\xampp\htdocs\est\trunk\src\framework\web\CBaseController.php(126): require("E:\xampp\htdocs\est\trunk\src\protected\views\date\_form.php") #6 + E:\xampp\htdocs\est\trunk\src\protected\extensions\yii-debug-toolbar\components\YiiDebugViewRenderer.php(47): CBaseController->renderInternal("E:\xampp\htdocs\est\trunk\src\protected\views\date\_form.php", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #7 + E:\xampp\htdocs\est\trunk\src\framework\web\CBaseController.php(93): YiiDebugViewRenderer->renderFile(DateController, "E:\xampp\htdocs\est\trunk\src\protected\views\date\_form.php", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #8 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(869): CBaseController->renderFile("E:\xampp\htdocs\est\trunk\src\protected\views\date\_form.php", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #9 + E:\xampp\htdocs\est\trunk\src\protected\views\date\create.php(40): CController->renderPartial("_form", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => "")) #10 + E:\xampp\htdocs\est\trunk\src\framework\web\CBaseController.php(126): require("E:\xampp\htdocs\est\trunk\src\protected\views\date\create.php") #11 + E:\xampp\htdocs\est\trunk\src\protected\extensions\yii-debug-toolbar\components\YiiDebugViewRenderer.php(47): CBaseController->renderInternal("E:\xampp\htdocs\est\trunk\src\protected\views\date\create.php", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #12 + E:\xampp\htdocs\est\trunk\src\framework\web\CBaseController.php(93): YiiDebugViewRenderer->renderFile(DateController, "E:\xampp\htdocs\est\trunk\src\protected\views\date\create.php", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #13 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(869): CBaseController->renderFile("E:\xampp\htdocs\est\trunk\src\protected\views\date\create.php", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #14 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(782): CController->renderPartial("create", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => ""), true) #15 + E:\xampp\htdocs\est\trunk\src\protected\controllers\DateController.php(114): CController->render("create", array("model" => Date, "a_disabled" => "", "timeLabel" => "", "dateLabel" => "")) #16 + E:\xampp\htdocs\est\trunk\src\framework\web\actions\CInlineAction.php(49): DateController->actionCreate() #17 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(308): CInlineAction->runWithParams(array("r" => "date/create")) #18 + E:\xampp\htdocs\est\trunk\src\framework\web\filters\CFilterChain.php(133): CController->runAction(CInlineAction) #19 + E:\xampp\htdocs\est\trunk\src\framework\web\filters\CFilter.php(40): CFilterChain->run() #20 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(1145): CFilter->filter(CFilterChain) #21 + E:\xampp\htdocs\est\trunk\src\framework\web\filters\CInlineFilter.php(58): CController->filterAccessControl(CFilterChain) #22 + E:\xampp\htdocs\est\trunk\src\framework\web\filters\CFilterChain.php(130): CInlineFilter->filter(CFilterChain) #23 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(291): CFilterChain->run() #24 + E:\xampp\htdocs\est\trunk\src\framework\web\CController.php(265): CController->runActionWithFilters(CInlineAction, array("accessControl")) #25 + E:\xampp\htdocs\est\trunk\src\framework\web\CWebApplication.php(282): CController->run("create") #26 + E:\xampp\htdocs\est\trunk\src\framework\web\CWebApplication.php(141): CWebApplication->runController("date/create") #27 + E:\xampp\htdocs\est\trunk\src\framework\base\CApplication.php(169): CWebApplication->processRequest() #28 + E:\xampp\htdocs\est\trunk\src\index.php(30): CApplication->run()
Aktionen