Exemplo n.º 1
0
 protected function initInternal()
 {
     parent::initInternal();
     $this->helper = $this->getQuestionHelper($this->inquisition);
     $this->helper->initInternal();
     // for evaluations, hide correct option column
     if ($this->helper->isEvaluation()) {
         $view = $this->ui->getWidget('question_option_table_view');
         $correct_column = $view->getColumn('correct_option');
         $correct_column->visible = false;
     }
 }
Exemplo n.º 2
0
 protected function initInternal()
 {
     parent::initInternal();
     $this->helper = $this->getQuestionHelper();
     $this->helper->initInternal();
     // for evaluations, hide correct option column
     if ($this->helper->isEvaluation()) {
         $view = $this->ui->getWidget('option_view');
         $view->getColumn('correct_option')->visible = false;
         $toollink = $this->ui->getWidget('correct_option');
         $toollink->visible = false;
     }
 }
Exemplo n.º 3
0
    public function setInquisition(InquisitionInquisition $inquisition)
    {
        parent::setInquisition($inquisition);
        if (!$this->inquisition instanceof InquisitionInquisition) {
            // if we got here from the question index, load the inquisition
            // from the binding as we only have one inquisition per question
            $sql = sprintf('select inquisition from InquisitionInquisitionQuestionBinding
				where question = %s', $this->app->db->quote($this->question->id));
            $inquisition_id = SwatDB::queryOne($this->app->db, $sql);
            $this->inquisition = $this->loadInquisition($inquisition_id);
        }
        $this->helper = $this->getQuestionHelper();
        $this->helper->initInternal();
    }
Exemplo n.º 4
0
 protected function initInternal()
 {
     parent::initInternal();
     $this->helper = $this->getQuestionHelper();
     $this->helper->initInternal();
 }
Exemplo n.º 5
0
 public function setId($id)
 {
     parent::setId($id);
     $this->helper = $this->getQuestionHelper();
     $this->helper->initInternal();
 }
Exemplo n.º 6
0
 public function initInternal()
 {
     $this->question_helper->initInternal();
 }