/** * Returns the data model based on the primary key given in the GET variable. * If the data model is not found, an HTTP exception will be raised. * @param integer $id the ID of the model to be loaded * @return NtpTreatmentCard the loaded model * @throws CHttpException */ public function loadModel($id) { $model = NtpTreatmentCard::model()->findByPk($id); if ($model === null) { throw new CHttpException(404, 'The requested page does not exist.'); } return $model; }
?> </div> <?php echo $form->error($model, 'category_2', array('class' => 'text-danger')); ?> </div> </div> <div class="form-group"> <?php echo $form->labelEx($model, 'category_3', array('class' => 'control-label col-sm-4')); ?> <div class="col-sm-8"> <div class="checkbox"> <?php echo $form->checkBoxList($model, 'category_3', NtpTreatmentCard::getCategory3()); ?> </div> <?php echo $form->error($model, 'category_3', array('class' => 'text-danger')); ?> </div> </div> <div class="form-group"> <?php echo $form->labelEx($model, 'treatment_started', array('class' => 'control-label col-sm-4')); ?> <div class="col-sm-8"> <?php echo $form->dateField($model, 'treatment_started', array('class' => 'form-control'));