Fehler #155
geschlossenFehler bei der Lehrerauswahl
100%
Beschreibung
Rolle Eltern:
PHP notice
Undefined offset: 0
/home/est/public_html/est_trunk/protected/controllers/AppointmentController.php(296)
284 * Generiert den Inhalt der Terminvereinbarung für die Rolle Eltern
285 * @author David Mock <dumock@gmail.com>
286 * @param array $a_dates Array welches die nächsten Elternsprechtagstermine enthält
287 * @param array $a_tabs Array mit den Tabellen, die die Termine anzeigen
288 * @param string $select_content Das select-Element welches die id für den zu buchenden Termin an den Server überträgt.
289 * @param object $model Das model der aktuellen Ansicht
290 */
291 public function createMakeAppointmentContent($a_dates,&$a_tabs,&$selectContent,$model) {
292 $tabsUiId = 0; //id der tabellen, wichtig für Javascriptfunktionen aus custom.js
293 $selectContent = '<select id="form_dateAndTime" name="Appointment[dateAndTime_id]">';
294 foreach ($a_dates as $a_day) {
295 $tabsUiId++;
296 $tabsName = date('d.m.Y', strtotime($a_day0->date->date));
297 $tabsContent = '<div style="display:none;" id="date-ui-id-'.$tabsUiId.'">'.$tabsName.'</div>'; //verstecktes Element für Javascriptfunktionen aus custom.js
298 $tabsContent .= '<table><thead><th class="table-text" width="40%">Uhrzeit</th><th class="table-text" width="60%">Termin</th></thead><tbody>';
299 $selectContent .= '<optgroup label="'.$tabsName.'">';
300 $datesUiId = 0; //id der einzelnen Zeiten, wichtig für Javascriptfunktionen aus custom.js
301 foreach ($a_day as $key => $a_times) {
302 $datesUiId++;
303 $a_times = $this->isAppointmentAvailable($model->user->id,$a_day[$key]->id); //Array in dem gespeichert wird ob ein Termin Belegt oder Frei ist.
304 $tabsContent .= '<tr><td id="time-ui-id-'.$tabsUiId.'_'.$datesUiId.'" class="table-text">'.date('H:i', strtotime($a_day[$key]->time)).'</td>';
305 $selectContent .= '<option value="'.$a_day[$key]->id.'"';
306 if ($a_times1) { //Termin verfügbar
307 $tabsContent .= '<td id="ui-id-'.$tabsUiId.'_'.$datesUiId.'" class="avaiable table-text">'.$a_times0.'</td>';
308 } else {
Stack Trace
#0
–
/home/est/public_html/est_trunk/protected/views/appointment/makeAppointment.php(43): AppointmentController->createMakeAppointmentContent(array(array()), null, "<select id="form_dateAndTime" name="Appointment[dateAndTime_id]"...", Appointment)
38 Klicken Sie einfach auf ein Feld mit "Verfügbar" und bestätigen Sie am Ende der Seite den Termin.
39 </div>
40 41 $a_tabs = null;
42 $selectContent = null;
43 $this->createMakeAppointmentContent($a_dates, $a_tabs, $selectContent, $model);
44 ?>
45 <div class="js_show">
46 47 $this->widget('zii.widgets.jui.CJuiTabs',array(
48 'tabs'=>$a_tabs,
#1
+
/home/est/public_html/est_trunk/framework/web/CBaseController.php(126): require("/home/est/public_html/est_trunk/protected/views/appointment/make...")
#2
–
/home/est/public_html/est_trunk/protected/extensions/yii-debug-toolbar/components/YiiDebugViewRenderer.php(47): CBaseController->renderInternal("/home/est/public_html/est_trunk/protected/views/appointment/make...", array("model" => Appointment), true)
42
43 if (false !== $this->getIsProxy())
44 {
45 return $this->instance->renderFile($context,$sourceFile,$data,$return);
46 }
47 return $context->renderInternal($sourceFile,$data,$return);
48 }
49
50 public function generateViewFile($sourceFile, $viewFile)
51 {
52 if (false !== $this->getIsProxy())
#3
/home/est/public_html/est_trunk/framework/web/CBaseController.php(93): YiiDebugViewRenderer->renderFile(AppointmentController, "/home/est/public_html/est_trunk/protected/views/appointment/make...", array("model" => Appointment), true)
#4
/home/est/public_html/est_trunk/framework/web/CController.php(869): CBaseController->renderFile("/home/est/public_html/est_trunk/protected/views/appointment/make...", array("model" => Appointment), true)
#5
+
/home/est/public_html/est_trunk/framework/web/CController.php(782): CController->renderPartial("makeAppointment", array("model" => Appointment), true)
#6
–
/home/est/public_html/est_trunk/protected/controllers/AppointmentController.php(129): CController->render("makeAppointment", array("model" => Appointment))
124 if ($model->save()) {
125 Yii::app()->user->setFlash('success', 'Ihr Termin wurde erfolgreich gebucht.');
126 $this->redirect(array('index'));
127 }
128 }
129 $this->render('makeAppointment', array('model' => $model));
130 }
131
132 /**
133 * Updates a particular model.
134 * If update is successful, the browser will be redirected to the 'view' page.
#7
unknown(0): AppointmentController->actionMakeAppointment("30")
#8
/home/est/public_html/est_trunk/framework/web/actions/CAction.php(108): ReflectionMethod->invokeArgs(AppointmentController, array("30"))
#9
/home/est/public_html/est_trunk/framework/web/actions/CInlineAction.php(47): CAction->runWithParamsInternal(AppointmentController, ReflectionMethod, array("r" => "Appointment/makeAppointment", "teacher" => "30"))
#10
/home/est/public_html/est_trunk/framework/web/CController.php(308): CInlineAction->runWithParams(array("r" => "Appointment/makeAppointment", "teacher" => "30"))
#11
/home/est/public_html/est_trunk/framework/web/filters/CFilterChain.php(133): CController->runAction(CInlineAction)
#12
/home/est/public_html/est_trunk/framework/web/filters/CFilter.php(40): CFilterChain->run()
#13
/home/est/public_html/est_trunk/framework/web/CController.php(1145): CFilter->filter(CFilterChain)
#14
/home/est/public_html/est_trunk/framework/web/filters/CInlineFilter.php(58): CController->filterAccessControl(CFilterChain)
#15
/home/est/public_html/est_trunk/framework/web/filters/CFilterChain.php(130): CInlineFilter->filter(CFilterChain)
#16
/home/est/public_html/est_trunk/framework/web/CController.php(291): CFilterChain->run()
#17
/home/est/public_html/est_trunk/framework/web/CController.php(265): CController->runActionWithFilters(CInlineAction, array("accessControl"))
#18
/home/est/public_html/est_trunk/framework/web/CWebApplication.php(282): CController->run("makeAppointment")
#19
/home/est/public_html/est_trunk/framework/web/CWebApplication.php(141): CWebApplication->runController("Appointment/makeAppointment")
#20
/home/est/public_html/est_trunk/framework/base/CApplication.php(169): CWebApplication->processRequest()
#21
/home/est/public_html/est_trunk/index.php(30): CApplication->run()