ILIAS  release_8 Revision v8.24
ilAssQuestionSkillAssignmentsTableGUI Class Reference
+ Inheritance diagram for ilAssQuestionSkillAssignmentsTableGUI:
+ Collaboration diagram for ilAssQuestionSkillAssignmentsTableGUI:

Public Member Functions

 setSkillQuestionAssignmentList (ilAssQuestionSkillAssignmentList $assignmentList)
 
 areManipulationsEnabled ()
 
 setManipulationsEnabled ($manipulationsEnabled)
 
 __construct ($parentOBJ, $parentCmd, ilCtrl $ctrl, ilLanguage $lng)
 
 init ()
 
 loadSkillPointsFromRequest ($loadSkillPointsFromRequest)
 
 fillRow (array $a_set)
 Standard Version of Fill Row. More...
 
- Public Member Functions inherited from ilTable2GUI
 __construct (?object $a_parent_obj, string $a_parent_cmd="", string $a_template_context="")
 
 setOpenFormTag (bool $a_val)
 
 getOpenFormTag ()
 
 setCloseFormTag (bool $a_val)
 
 getCloseFormTag ()
 
 determineLimit ()
 
 getSelectableColumns ()
 Get selectable columns. More...
 
 determineSelectedColumns ()
 
 isColumnSelected (string $col)
 
 getSelectedColumns ()
 
 resetOffset (bool $a_in_determination=false)
 
 initFilter ()
 
 getParentObject ()
 
 getParentCmd ()
 
 setTopAnchor (string $a_val)
 
 getTopAnchor ()
 
 setNoEntriesText (string $a_text)
 
 getNoEntriesText ()
 
 setIsDataTable (bool $a_val)
 
 getIsDataTable ()
 
 setEnableTitle (bool $a_enabletitle)
 
 getEnableTitle ()
 
 setEnableHeader (bool $a_enableheader)
 
 getEnableHeader ()
 
 setEnableNumInfo (bool $a_val)
 
 getEnableNumInfo ()
 
 setTitle (string $a_title, string $a_icon="", string $a_icon_alt="")
 
 setDescription (string $a_val)
 
 getDescription ()
 
 setOrderField (string $a_order_field)
 
 getOrderField ()
 
 setData (array $a_data)
 Set table data. More...
 
 getData ()
 
 dataExists ()
 
 setPrefix (string $a_prefix)
 set prefix for sort and offset fields (if you have two or more tables on a page that you want to sort separately) More...
 
 getPrefix ()
 
 addFilterItem (ilTableFilterItem $a_input_item, bool $a_optional=false)
 
 addFilterItemByMetaType (string $id, int $type=self::FILTER_TEXT, bool $a_optional=false, string $caption="")
 Add filter by standard type. More...
 
 getFilterItems (bool $a_optionals=false)
 
 getFilterItemByPostVar (string $a_post_var)
 
 setFilterCols (int $a_val)
 
 getFilterCols ()
 
 setDisableFilterHiding (bool $a_val=true)
 
 getDisableFilterHiding ()
 
 isFilterSelected (string $a_col)
 Is given filter selected? More...
 
 getSelectedFilters ()
 
 determineSelectedFilters ()
 
 setCustomPreviousNext (string $a_prev_link, string $a_next_link)
 
 setFormAction (string $a_form_action, bool $a_multipart=false)
 
 getFormAction ()
 
 setFormName (string $a_name="")
 
 getFormName ()
 get the name of the parent form More...
 
 setId (string $a_val)
 
 getId ()
 
 setDisplayAsBlock (bool $a_val)
 
 getDisplayAsBlock ()
 
 setSelectAllCheckbox (string $a_select_all_checkbox, bool $a_select_all_on_top=false)
 
 setExternalSorting (bool $a_val)
 
 getExternalSorting ()
 
 setFilterCommand (string $a_val, string $a_caption="")
 
 getFilterCommand ()
 
 setResetCommand (string $a_val, string $a_caption="")
 
 getResetCommand ()
 
 setExternalSegmentation (bool $a_val)
 
 getExternalSegmentation ()
 
 setRowTemplate (string $a_template, string $a_template_dir="")
 Set row template. More...
 
 setDefaultOrderField (string $a_defaultorderfield)
 
 getDefaultOrderField ()
 
 setDefaultOrderDirection (string $a_defaultorderdirection)
 
 getDefaultOrderDirection ()
 
 setDefaultFilterVisiblity (bool $a_status)
 
 getDefaultFilterVisibility ()
 
 clearCommandButtons ()
 
 addCommandButton (string $a_cmd, string $a_text, string $a_onclick='', string $a_id="", string $a_class="")
 
 addCommandButtonInstance (ilButtonBase $a_button)
 
 addMultiItemSelectionButton (string $a_sel_var, array $a_options, string $a_cmd, string $a_text, string $a_default_selection='')
 
 setCloseCommand (string $a_link)
 
 addMultiCommand (string $a_cmd, string $a_text)
 
 addHiddenInput (string $a_name, string $a_value)
 
 addHeaderCommand (string $a_href, string $a_text, string $a_target="", string $a_img="")
 
 setTopCommands (bool $a_val)
 
 getTopCommands ()
 
 addColumn (string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)
 
 getNavParameter ()
 
 setOrderLink (string $key, string $order_dir)
 
 fillHeader ()
 
 determineOffsetAndOrder (bool $a_omit_offset=false)
 
 storeNavParameter ()
 
 getHTML ()
 Get HTML. More...
 
 numericOrdering (string $a_field)
 Should this field be sorted numeric? More...
 
 render ()
 
 writeFilterToSession ()
 
 resetFilter ()
 
 fillFooter ()
 
 getLinkbar (string $a_num)
 
 fillHiddenRow ()
 
 fillActionRow ()
 
 setHeaderHTML (string $html)
 
 storeProperty (string $type, string $value)
 
 loadProperty (string $type)
 
 getCurrentState ()
 get current settings for order, limit, columns and filter More...
 
 setContext (string $id)
 
 getContext ()
 
 setShowRowsSelector (bool $a_value)
 Toggle rows-per-page selector. More...
 
 getShowRowsSelector ()
 
 setShowTemplates (bool $a_value)
 
 getShowTemplates ()
 
 restoreTemplate (string $a_name)
 Restore state from template. More...
 
 saveTemplate (string $a_name)
 Save current state as template. More...
 
 deleteTemplate (string $a_name)
 
 getLimit ()
 
 getOffset ()
 
 setExportFormats (array $formats)
 Set available export formats. More...
 
 setPrintMode (bool $a_value=false)
 
 getPrintMode ()
 
 getExportMode ()
 
 exportData (int $format, bool $send=false)
 Export and optionally send current table data. More...
 
 setEnableAllCommand (bool $a_value)
 
 setRowSelectorLabel (string $row_selector_label)
 
 getRowSelectorLabel ()
 
 setPreventDoubleSubmission (bool $a_val)
 
 getPreventDoubleSubmission ()
 
 setLimit (int $a_limit=0, int $a_default_limit=0)
 set max. More...
 
- Public Member Functions inherited from ilTableGUI
 __construct (array $a_data=[], bool $a_global_tpl=true)
 
 setTemplate (ilTemplate $a_tpl)
 
 getTemplateObject ()
 
 setData (array $a_data)
 Set table data. More...
 
 getData ()
 
 setTitle (string $a_title, string $a_icon="", string $a_icon_alt="")
 
 setHelp (string $a_help_page, string $a_help_icon, string $a_help_icon_alt="")
 
 setHeaderNames (array $a_header_names)
 
 getColumnCount ()
 
 setHeaderVars (array $a_header_vars, array $a_header_params=[])
 
 setColumnWidth (array $a_column_width)
 set table column widths More...
 
 setOneColumnWidth (string $a_column_width, int $a_column_number)
 
 setMaxCount (int $a_max_count)
 set max. More...
 
 setLimit (int $a_limit=0, int $a_default_limit=0)
 set max. More...
 
 getLimit ()
 
 setPrefix (string $a_prefix)
 set prefix for sort and offset fields (if you have two or more tables on a page that you want to sort separately) More...
 
 setOffset (int $a_offset)
 set dataset offset More...
 
 getOffset ()
 
 setOrderColumn (string $a_order_column="", string $a_default_column="")
 
 getOrderColumn ()
 
 setOrderDirection (string $a_order_direction)
 
 getOrderDirection ()
 
 setFooter (string $a_style, string $a_previous="", string $a_next="")
 
 enable (string $a_module_name)
 
 disable (string $a_module_name)
 
 sortData ()
 
 render ()
 
 renderHeader ()
 
 setOrderLink (string $key, string $order_dir)
 
 setStyle (string $a_element, string $a_style)
 
 getStyle (string $a_element)
 
 setBase (string $a_base)
 
 getBase ()
 
 getFormName ()
 get the name of the parent form More...
 
 setFormName (string $a_name="cmd")
 
 getSelectAllCheckbox ()
 get the name of the checkbox that should be toggled with a select all button More...
 
 setSelectAllCheckbox (string $a_select_all_checkbox)
 
 clearActionButtons ()
 
 addActionButton (string $btn_name, string $btn_value)
 

Private Member Functions

 initColumns ()
 
 getRowspan ($assignments)
 
 getManageCompetenceAssignsActionLink ()
 
 getCompetenceAssignPropertiesFormLink (ilAssQuestionSkillAssignment $assignment)
 
 buildActionLink ($href, $label)
 
 buildActionColumnHTML ($assignments)
 
 getEvalModeLabel (ilAssQuestionSkillAssignment $assignment)
 
 buildSkillPointsInput (ilAssQuestionSkillAssignment $assignment)
 
 isSkillPointInputRequired (ilAssQuestionSkillAssignment $assignment)
 

Private Attributes

 $skillQuestionAssignmentList
 
 $loadSkillPointsFromRequest = false
 
 $manipulationsEnabled
 

Additional Inherited Members

- Static Public Member Functions inherited from ilTable2GUI
static getAllCommandLimit ()
 
- Static Public Member Functions inherited from ilTableGUI
static linkbar (string $AScript, int $AHits, int $ALimit, int $AOffset, array $AParams=array(), array $ALayout=array(), string $prefix='')
 
- Data Fields inherited from ilTable2GUI
const FILTER_TEXT = 1
 
const FILTER_SELECT = 2
 
const FILTER_DATE = 3
 
const FILTER_LANGUAGE = 4
 
const FILTER_NUMBER_RANGE = 5
 
const FILTER_DATE_RANGE = 6
 
const FILTER_DURATION_RANGE = 7
 
const FILTER_DATETIME_RANGE = 8
 
const FILTER_CHECKBOX = 9
 
const EXPORT_EXCEL = 1
 
const EXPORT_CSV = 2
 
const ACTION_ALL_LIMIT = 1000
 
- Data Fields inherited from ilTableGUI
string $title = ""
 
string $icon = ""
 
string $icon_alt = ""
 
string $help_page = ""
 
string $help_icon = ""
 
string $help_icon_alt = ""
 
array $header_names = []
 
array $header_vars = []
 
array $linkbar_vars = []
 
array $data = []
 
int $column_count = 0
 
array $column_width = []
 
int $max_count = 0
 
int $limit = 0
 
bool $max_limit = false
 
int $offset = 0
 
string $order_column = ""
 
string $order_direction = ""
 
string $footer_style = ""
 
string $footer_previous = ""
 
string $footer_next = ""
 
bool $lang_support = true
 
bool $global_tpl = false
 
string $form_name = ""
 
string $select_all_checkbox = ""
 
array $action_buttons = []
 
string $prefix = ""
 
string $base = ""
 
array $enabled
 
array $styles
 
- Protected Member Functions inherited from ilTable2GUI
 getRequestedValues ()
 
 prepareOutput ()
 Anything that must be done before HTML is generated. More...
 
 isFilterVisible ()
 Check if filter is visible: manually shown (session, db) or default value set. More...
 
 isAdvMDFilter (ilAdvancedMDRecordGUI $a_gui, ilTableFilterItem $a_element)
 Check if filter element is based on adv md. More...
 
 fillRow (array $a_set)
 Standard Version of Fill Row. More...
 
 getFilterValue (ilTableFilterItem $a_item)
 Get current filter value. More...
 
 setFilterValue (ilTableFilterItem $a_item, $a_value)
 
 fillMetaExcel (ilExcel $a_excel, int &$a_row)
 Add meta information to excel export. More...
 
 fillHeaderExcel (ilExcel $a_excel, int &$a_row)
 Excel Version of Fill Header. More...
 
 fillRowExcel (ilExcel $a_excel, int &$a_row, array $a_set)
 Excel Version of Fill Row. More...
 
 fillMetaCSV (ilCSVWriter $a_csv)
 Add meta information to csv export. More...
 
 fillHeaderCSV (ilCSVWriter $a_csv)
 CSV Version of Fill Header. More...
 
 fillRowCSV (ilCSVWriter $a_csv, array $a_set)
 CSV Version of Fill Row. More...
 
- Protected Attributes inherited from ilTable2GUI
string $requested_tmpl_delete
 
string $requested_tmpl_create
 
string $requested_nav_par2 = ""
 
string $requested_nav_par = ""
 
string $requested_nav_par1 = ""
 
ILIAS Table TableGUIRequest $table_request = null
 
array $selected_columns = []
 
ilCtrl $ctrl
 
object $parent_obj = null
 
string $parent_cmd = ""
 
string $close_command = ""
 
string $top_anchor = "il_table_top"
 
array $filters = array()
 
array $optional_filters = array()
 
string $filter_cmd = 'applyFilter'
 
string $reset_cmd = 'resetFilter'
 
int $filter_cols = 5
 
bool $ext_sort = false
 
bool $ext_seg = false
 
string $context = ""
 
array $mi_sel_buttons = []
 
bool $disable_filter_hiding = false
 
bool $top_commands = true
 
array $selectable_columns = array()
 
array $selected_column = array()
 
bool $show_templates = false
 
bool $show_rows_selector = true
 
bool $rows_selector_off = false
 
bool $nav_determined = false
 
bool $limit_determined = false
 
bool $filters_determined = false
 
bool $columns_determined = false
 
bool $open_form_tag = true
 
bool $close_form_tag = true
 
array $export_formats = []
 
int $export_mode = 0
 
bool $print_mode = false
 
bool $enable_command_for_all = false
 
bool $restore_filter = false
 
array $restore_filter_values = []
 
bool $default_filter_visibility = false
 
array $sortable_fields = array()
 
bool $prevent_double_submission = true
 
string $row_selector_label = ""
 
bool $select_all_on_top = false
 
array $sel_buttons = []
 
string $nav_value = ''
 
string $noentriestext = ''
 
string $css_row = ''
 
bool $display_as_block = false
 
string $description = ''
 
string $id = ""
 
bool $custom_prev_next = false
 
string $reset_cmd_txt = ""
 
string $defaultorderfield = ""
 
string $defaultorderdirection = ""
 
array $column = []
 
bool $datatable = false
 
bool $num_info = false
 
bool $form_multipart = false
 
array $row_data = []
 
string $order_field = ""
 
array $selected_filter = []
 
string $form_action = ""
 
string $formname = ""
 
string $sort_order = ""
 
array $buttons = []
 
array $multi = []
 
array $hidden_inputs = []
 
array $header_commands = []
 
string $row_template = ""
 
string $row_template_dir = ""
 
string $filter_cmd_txt = ""
 
string $custom_prev = ""
 
string $custom_next = ""
 
array $raw_post_data = null
 
ilGlobalTemplateInterface $main_tpl
 
- Protected Attributes inherited from ilTableGUI
string $sort_order
 
string $link_params
 
array $header_params
 
 $tpl
 
ilLanguage $lng
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilAssQuestionSkillAssignmentsTableGUI::__construct (   $parentOBJ,
  $parentCmd,
ilCtrl  $ctrl,
ilLanguage  $lng 
)

Definition at line 63 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

64 {
65 parent::__construct($parentOBJ, $parentCmd);
66
67 $this->lng = $lng;
68 $this->ctrl = $ctrl;
69
70 $this->setId('assQstSkl');
71 $this->setPrefix('assQstSkl');
72
73 $this->setStyle('table', 'fullwidth');
74
75 $this->setRowTemplate("tpl.tst_skl_qst_assignment_row.html", "Modules/Test");
76
77 $this->enable('header');
78 $this->disable('sort');
79 $this->disable('select_all');
80 }
setPrefix(string $a_prefix)
set prefix for sort and offset fields (if you have two or more tables on a page that you want to sort...
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
setId(string $a_val)
ilLanguage $lng
enable(string $a_module_name)
setStyle(string $a_element, string $a_style)
disable(string $a_module_name)
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc

References ilTable2GUI\$ctrl, ilTableGUI\$lng, ILIAS\GlobalScreen\Provider\__construct(), ILIAS\Repository\ctrl(), ilTableGUI\disable(), ilTableGUI\enable(), ILIAS\Repository\lng(), ilTable2GUI\setId(), ilTable2GUI\setPrefix(), ilTable2GUI\setRowTemplate(), and ilTableGUI\setStyle().

+ Here is the call graph for this function:

Member Function Documentation

◆ areManipulationsEnabled()

ilAssQuestionSkillAssignmentsTableGUI::areManipulationsEnabled ( )

◆ buildActionColumnHTML()

ilAssQuestionSkillAssignmentsTableGUI::buildActionColumnHTML (   $assignments)
private

Definition at line 224 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

224 : string
225 {
226 $actions = array();
227
228 /* PHP8: This appears to be an incomplete feature: Removal of skill assignment is nowhere found other than
229 here, ilAssQuestionSkillAssignmentsGUI::CMD_REMOVE_SKILL_QUEST_ASSIGN is undefined. Defusing for now.
230
231 foreach ($assignments as $assignment) {
232 $this->ctrl->setParameter($this->parent_obj, 'skill_base_id', $assignment->getSkillBaseId());
233 $this->ctrl->setParameter($this->parent_obj, 'skill_tref_id', $assignment->getSkillTrefId());
234
235 $href = $this->ctrl->getLinkTarget(
236 $this->parent_obj,
237 ilAssQuestionSkillAssignmentsGUI::CMD_REMOVE_SKILL_QUEST_ASSIGN
238 );
239
240 $label = $this->lng->txt('tst_remove_competence');
241
242 $actions[] = $this->buildActionLink($href, $label);
243 }
244 */
245
246 $href = $this->ctrl->getLinkTarget(
247 $this->parent_obj,
249 );
250
251 $label = $this->lng->txt('tst_assign_competence');
252 $actions[] = $this->buildActionLink($href, $label);
253
254 return implode('<br />', $actions);
255 }

References buildActionLink(), ilAssQuestionSkillAssignmentsGUI\CMD_SHOW_SKILL_SELECT, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ buildActionLink()

ilAssQuestionSkillAssignmentsTableGUI::buildActionLink (   $href,
  $label 
)
private

Definition at line 219 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

219 : string
220 {
221 return "<a href=\"{$href}\" title=\"{$label}\">{$label}</a>";
222 }

Referenced by buildActionColumnHTML(), getCompetenceAssignPropertiesFormLink(), and getManageCompetenceAssignsActionLink().

+ Here is the caller graph for this function:

◆ buildSkillPointsInput()

ilAssQuestionSkillAssignmentsTableGUI::buildSkillPointsInput ( ilAssQuestionSkillAssignment  $assignment)
private

Definition at line 266 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

266 : string
267 {
268 $assignmentKey = implode(':', array(
269 $assignment->getSkillBaseId(), $assignment->getSkillTrefId(), $assignment->getQuestionId()
270 ));
271
272 if ($this->loadSkillPointsFromRequest) {
273 $points = isset($_POST['skill_points'][$assignmentKey]) ? ilUtil::stripSlashes($_POST['skill_points'][$assignmentKey]) : '';
274 } else {
275 $points = $assignment->getSkillPoints();
276 }
277
278 return "<input type\"text\" size=\"2\" name=\"skill_points[{$assignmentKey}]\" value=\"{$points}\" />";
279 }
static stripSlashes(string $a_str, bool $a_strip_html=true, string $a_allow="")

References ilAssQuestionSkillAssignment\getQuestionId(), ilAssQuestionSkillAssignment\getSkillBaseId(), ilAssQuestionSkillAssignment\getSkillPoints(), ilAssQuestionSkillAssignment\getSkillTrefId(), loadSkillPointsFromRequest(), and ilUtil\stripSlashes().

Referenced by fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ fillRow()

ilAssQuestionSkillAssignmentsTableGUI::fillRow ( array  $a_set)

Standard Version of Fill Row.

Most likely to be overwritten by derived class.

Parameters
array$a_setdata array

Reimplemented from ilTable2GUI.

Definition at line 113 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

113 : void
114 {
115 $assignments = $this->skillQuestionAssignmentList->getAssignmentsByQuestionId($a_set['question_id']);
116
117 $this->ctrl->setParameter($this->parent_obj, 'question_id', $a_set['question_id']);
118
119 $this->tpl->setCurrentBlock('question_title');
120 $this->tpl->setVariable('ROWSPAN', $this->getRowspan($assignments));
121 $this->tpl->setVariable('QUESTION_TITLE', $a_set['title']);
122 $this->tpl->setVariable('QUESTION_DESCRIPTION', $a_set['description']);
123 $this->tpl->parseCurrentBlock();
124
125 $this->tpl->setCurrentBlock('tbl_content');
126
127 for ($i = 0, $numAssigns = count($assignments); $i < $numAssigns; $i++) {
128 /* @var ilAssQuestionSkillAssignment $assignment */
129 $assignment = $assignments[$i];
130
131 $this->tpl->setCurrentBlock('actions_col');
132 $this->tpl->setVariable('ACTION', $this->getCompetenceAssignPropertiesFormLink($assignment));
133 $this->tpl->parseCurrentBlock();
134
135 $this->tpl->setCurrentBlock('tbl_content');
136
137 $this->tpl->setVariable('COMPETENCE', $assignment->getSkillTitle());
138 $this->tpl->setVariable('COMPETENCE_PATH', $assignment->getSkillPath());
139 $this->tpl->setVariable('EVAL_MODE', $this->getEvalModeLabel($assignment));
140
141 if ($this->isSkillPointInputRequired($assignment)) {
142 $this->tpl->setVariable('SKILL_POINTS', $this->buildSkillPointsInput($assignment));
143 } else {
144 $this->tpl->setVariable('SKILL_POINTS', $assignment->getMaxSkillPoints());
145 }
146
147 if ($this->areManipulationsEnabled() || ($i + 1) < $numAssigns) {
148 $this->tpl->parseCurrentBlock();
149
150 $this->tpl->setCurrentBlock('tbl_content');
151 $this->tpl->setVariable("CSS_ROW", $this->css_row);
152 }
153 }
154
155 if ($this->areManipulationsEnabled()) {
156 $this->tpl->setCurrentBlock('actions_col');
157 $this->tpl->setVariable('ACTION', $this->getManageCompetenceAssignsActionLink());
158 $this->tpl->parseCurrentBlock();
159
160 $this->tpl->setCurrentBlock('tbl_content');
161 } elseif (!$numAssigns) {
162 $this->tpl->setCurrentBlock('actions_col');
163 $this->tpl->setVariable('ACTION', '&nbsp;');
164 $this->tpl->parseCurrentBlock();
165
166 $this->tpl->setCurrentBlock('tbl_content');
167 }
168 }
getCompetenceAssignPropertiesFormLink(ilAssQuestionSkillAssignment $assignment)
buildSkillPointsInput(ilAssQuestionSkillAssignment $assignment)
getEvalModeLabel(ilAssQuestionSkillAssignment $assignment)
isSkillPointInputRequired(ilAssQuestionSkillAssignment $assignment)
$i
Definition: metadata.php:41

References $i, areManipulationsEnabled(), buildSkillPointsInput(), ILIAS\Repository\ctrl(), getCompetenceAssignPropertiesFormLink(), getEvalModeLabel(), getManageCompetenceAssignsActionLink(), getRowspan(), and isSkillPointInputRequired().

+ Here is the call graph for this function:

◆ getCompetenceAssignPropertiesFormLink()

ilAssQuestionSkillAssignmentsTableGUI::getCompetenceAssignPropertiesFormLink ( ilAssQuestionSkillAssignment  $assignment)
private

Definition at line 197 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

197 : string
198 {
199 $this->ctrl->setParameter($this->parent_obj, 'skill_base_id', $assignment->getSkillBaseId());
200 $this->ctrl->setParameter($this->parent_obj, 'skill_tref_id', $assignment->getSkillTrefId());
201
202 $href = $this->ctrl->getLinkTarget(
203 $this->parent_obj,
205 );
206
207 if ($this->areManipulationsEnabled()) {
208 $label = $this->lng->txt('tst_edit_competence_assign');
209 } else {
210 $label = $this->lng->txt('tst_view_competence_assign');
211 }
212
213 $this->ctrl->setParameter($this->parent_obj, 'skill_base_id', null);
214 $this->ctrl->setParameter($this->parent_obj, 'skill_tref_id', null);
215
216 return $this->buildActionLink($href, $label);
217 }

References areManipulationsEnabled(), buildActionLink(), ilAssQuestionSkillAssignmentsGUI\CMD_SHOW_SKILL_QUEST_ASSIGN_PROPERTIES_FORM, ILIAS\Repository\ctrl(), ilAssQuestionSkillAssignment\getSkillBaseId(), ilAssQuestionSkillAssignment\getSkillTrefId(), and ILIAS\Repository\lng().

Referenced by fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getEvalModeLabel()

ilAssQuestionSkillAssignmentsTableGUI::getEvalModeLabel ( ilAssQuestionSkillAssignment  $assignment)
private

Definition at line 257 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

257 : string
258 {
259 if ($assignment->hasEvalModeBySolution()) {
260 return $this->lng->txt('qpl_skill_point_eval_mode_solution_compare');
261 }
262
263 return $this->lng->txt('qpl_skill_point_eval_mode_quest_result');
264 }

References ilAssQuestionSkillAssignment\hasEvalModeBySolution(), and ILIAS\Repository\lng().

Referenced by fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getManageCompetenceAssignsActionLink()

ilAssQuestionSkillAssignmentsTableGUI::getManageCompetenceAssignsActionLink ( )
private

Definition at line 185 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

185 : string
186 {
187 $href = $this->ctrl->getLinkTarget(
188 $this->parent_obj,
190 );
191
192 $label = $this->lng->txt('tst_manage_competence_assigns');
193
194 return $this->buildActionLink($href, $label);
195 }

References buildActionLink(), ilAssQuestionSkillAssignmentsGUI\CMD_SHOW_SKILL_SELECT, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

Referenced by fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getRowspan()

ilAssQuestionSkillAssignmentsTableGUI::getRowspan (   $assignments)
private

Definition at line 170 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

170 : int
171 {
172 $cnt = count($assignments);
173
174 if ($cnt == 0) {
175 return 1;
176 }
177
178 if ($this->areManipulationsEnabled()) {
179 $cnt++;
180 }
181
182 return $cnt;
183 }

References areManipulationsEnabled().

Referenced by fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ init()

ilAssQuestionSkillAssignmentsTableGUI::init ( )

Definition at line 82 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

82 : void
83 {
84 $this->initColumns();
85
86 if ($this->areManipulationsEnabled()) {
87 $this->setFormAction($this->ctrl->getFormAction($this->parent_obj));
88
89 $this->addCommandButton(
91 $this->lng->txt('tst_save_comp_points')
92 );
93 }
94 }
addCommandButton(string $a_cmd, string $a_text, string $a_onclick='', string $a_id="", string $a_class="")
setFormAction(string $a_form_action, bool $a_multipart=false)

References ilTable2GUI\addCommandButton(), areManipulationsEnabled(), ilAssQuestionSkillAssignmentsGUI\CMD_SAVE_SKILL_POINTS, ILIAS\Repository\ctrl(), initColumns(), ILIAS\Repository\lng(), and ilTable2GUI\setFormAction().

+ Here is the call graph for this function:

◆ initColumns()

ilAssQuestionSkillAssignmentsTableGUI::initColumns ( )
private

Definition at line 104 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

104 : void
105 {
106 $this->addColumn($this->lng->txt('tst_question'), 'question', '25%');
107 $this->addColumn($this->lng->txt('tst_competence'), 'competence', '');
108 $this->addColumn($this->lng->txt('tst_comp_eval_mode'), 'eval_mode', '13%');
109 $this->addColumn($this->lng->txt('tst_comp_points'), 'points', '12%');
110 $this->addColumn($this->lng->txt('actions'), 'actions', '20%');
111 }
addColumn(string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)

References ilTable2GUI\addColumn(), and ILIAS\Repository\lng().

Referenced by init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isSkillPointInputRequired()

ilAssQuestionSkillAssignmentsTableGUI::isSkillPointInputRequired ( ilAssQuestionSkillAssignment  $assignment)
private

Definition at line 281 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

281 : bool
282 {
283 if (!$this->areManipulationsEnabled()) {
284 return false;
285 }
286
287 if ($assignment->hasEvalModeBySolution()) {
288 return false;
289 }
290
291 return true;
292 }

References areManipulationsEnabled(), and ilAssQuestionSkillAssignment\hasEvalModeBySolution().

Referenced by fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ loadSkillPointsFromRequest()

ilAssQuestionSkillAssignmentsTableGUI::loadSkillPointsFromRequest (   $loadSkillPointsFromRequest)
Parameters
bool$loadSkillPointsFromRequest

Definition at line 99 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

References $loadSkillPointsFromRequest, and loadSkillPointsFromRequest().

Referenced by buildSkillPointsInput(), and loadSkillPointsFromRequest().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setManipulationsEnabled()

ilAssQuestionSkillAssignmentsTableGUI::setManipulationsEnabled (   $manipulationsEnabled)
Parameters
boolean$manipulationsEnabled

Definition at line 58 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

58 : void
59 {
60 $this->manipulationsEnabled = $manipulationsEnabled;
61 }

References $manipulationsEnabled.

◆ setSkillQuestionAssignmentList()

ilAssQuestionSkillAssignmentsTableGUI::setSkillQuestionAssignmentList ( ilAssQuestionSkillAssignmentList  $assignmentList)

Definition at line 42 of file class.ilAssQuestionSkillAssignmentsTableGUI.php.

42 : void
43 {
44 $this->skillQuestionAssignmentList = $assignmentList;
45 }

Field Documentation

◆ $loadSkillPointsFromRequest

ilAssQuestionSkillAssignmentsTableGUI::$loadSkillPointsFromRequest = false
private

◆ $manipulationsEnabled

ilAssQuestionSkillAssignmentsTableGUI::$manipulationsEnabled
private

◆ $skillQuestionAssignmentList

ilAssQuestionSkillAssignmentsTableGUI::$skillQuestionAssignmentList
private

The documentation for this class was generated from the following file: