4include_once(
"./Services/Table/classes/class.ilTable2GUI.php");
 
   22                $this->
setId(
"ilobjpollusr");
 
   24                parent::__construct($a_parent_obj, $a_parent_cmd);
 
   26                $this->
addColumn($lng->txt(
"login"), 
"login");
 
   27                $this->
addColumn($lng->txt(
"lastname"), 
"lastname");
 
   28                $this->
addColumn($lng->txt(
"firstname"), 
"firstname");
 
   32                        $this->answer_ids[] = $answer[
"id"];
 
   33                        $this->
addColumn($answer[
"answer"], 
"answer".$answer[
"id"]);
 
   38                $this->
setTitle($this->lng->txt(
"poll_question").
": \"".
 
   39                        $this->getParentObject()->object->getQuestion().
"\"");
 
   41                $this->
setFormAction($ilCtrl->getFormAction($a_parent_obj, $a_parent_cmd));
 
   49        protected function getItems(array $a_answer_ids)
 
   53                foreach($this->
getParentObject()->object->getVotesByUsers() as $user_id => $vote)
 
   55                        $answers = $vote[
"answers"];
 
   56                        unset($vote[
"answers"]);
 
   58                        foreach($a_answer_ids as $answer_id)
 
   60                                $vote[
"answer".$answer_id] = in_array($answer_id, $answers);
 
   71                $this->tpl->setCurrentBlock(
"answer_bl");
 
   72                foreach($this->answer_ids as $answer_id)
 
   74                        if($a_set[
"answer".$answer_id])
 
   80                                $this->tpl->setVariable(
"ANSWER", 
" ");                            
 
   82                        $this->tpl->parseCurrentBlock();
 
   85                $this->tpl->setVariable(
"LOGIN", $a_set[
"login"]);              
 
   86                $this->tpl->setVariable(
"FIRSTNAME", $a_set[
"firstname"]);
 
   87                $this->tpl->setVariable(
"LASTNAME", $a_set[
"lastname"]);                
 
   92                $a_csv->addColumn($a_set[
"login"]);             
 
   93                $a_csv->addColumn($a_set[
"lastname"]);
 
   94                $a_csv->addColumn($a_set[
"firstname"]);
 
   95                foreach($this->answer_ids as $answer_id)
 
   97                        if($a_set[
"answer".$answer_id])
 
   99                                $a_csv->addColumn(
true);                                        
 
  103                                $a_csv->addColumn(
false);                               
 
  111                $a_worksheet->write($a_row, 0, $a_set[
"login"]);                
 
  112                $a_worksheet->write($a_row, 1, $a_set[
"lastname"]);             
 
  113                $a_worksheet->write($a_row, 2, $a_set[
"firstname"]);
 
  115                foreach($this->answer_ids as $answer_id)
 
  117                        if($a_set[
"answer".$answer_id])
 
  119                                $a_worksheet->write($a_row, ++$col, 
true);                                              
 
  123                                $a_worksheet->write($a_row, ++$col, 
false);                             
 
TableGUI class for poll users.
__construct($a_parent_obj, $a_parent_cmd)
fillRowExcel($a_worksheet, &$a_row, $a_set)
Excel Version of Fill Row.
getItems(array $a_answer_ids)
fillRow($a_set)
Standard Version of Fill Row.
fillRowCSV($a_csv, $a_set)
CSV Version of Fill Row.
addColumn($a_text, $a_sort_field="", $a_width="", $a_is_checkbox_action_column=false, $a_class="", $a_tooltip="")
Add a column to the header.
setExportFormats(array $formats)
Set available export formats.
getParentObject()
Get parent object.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
setData($a_data)
set table data @access public
setRowTemplate($a_template, $a_template_dir="")
Set row template.
setDefaultOrderField($a_defaultorderfield)
Set Default order field.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
setDefaultOrderDirection($a_defaultorderdirection)
Set Default order direction.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)