mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 13:38:32 +01:00
MDL-71636 core_question : API changes for column_base
This commit implements methods visibility changes to column_base class and its child classes.
This commit is contained in:
parent
9cd77c4130
commit
7c016b3451
@ -36,7 +36,7 @@ class question_name_column extends \core_question\local\bank\column_base {
|
||||
return 'questionname';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('question');
|
||||
}
|
||||
|
||||
|
@ -43,7 +43,7 @@ class comment_count_column extends column_base {
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('commentplural', 'qbank_comment');
|
||||
}
|
||||
|
||||
|
@ -68,7 +68,7 @@ class custom_field_column extends column_base {
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return $this->field->get_formatted_name();
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ class question_status_column extends column_base {
|
||||
return 'questionstatus';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('questionstatus', 'qbank_editquestion');
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ class discrimination_index extends column_base {
|
||||
*
|
||||
* @return string column title
|
||||
*/
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('discrimination_index', 'qbank_statistics');
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ class discriminative_efficiency extends column_base {
|
||||
*
|
||||
* @return string column title
|
||||
*/
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('discriminative_efficiency', 'qbank_statistics');
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ class facility_index extends column_base {
|
||||
*
|
||||
* @return string column title
|
||||
*/
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('facility_index', 'qbank_statistics');
|
||||
}
|
||||
|
||||
|
@ -32,7 +32,7 @@ class question_usage_column extends column_base {
|
||||
return 'questionusage';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('questionusage', 'qbank_usage');
|
||||
}
|
||||
|
||||
|
@ -32,7 +32,7 @@ class creator_name_column extends column_base {
|
||||
return 'creatorname';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('createdby', 'question');
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ class viewquestionname_column_helper extends column_base {
|
||||
return 'questionname';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('question');
|
||||
}
|
||||
|
||||
|
@ -44,7 +44,7 @@ class question_text_row extends row_base {
|
||||
return 'questiontext';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('questiontext', 'question');
|
||||
}
|
||||
|
||||
|
@ -32,11 +32,11 @@ class question_type_column extends column_base {
|
||||
return 'qtype';
|
||||
}
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return get_string('qtypeveryshort', 'question');
|
||||
}
|
||||
|
||||
protected function get_title_tip(): string {
|
||||
public function get_title_tip(): string {
|
||||
return get_string('questiontype', 'question');
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ namespace core_question\local\bank;
|
||||
*/
|
||||
abstract class action_column_base extends column_base {
|
||||
|
||||
protected function get_title(): string {
|
||||
public function get_title(): string {
|
||||
return ' ';
|
||||
}
|
||||
|
||||
|
@ -39,7 +39,7 @@ class checkbox_column extends column_base {
|
||||
return 'checkbox';
|
||||
}
|
||||
|
||||
protected function get_title() {
|
||||
public function get_title() {
|
||||
global $OUTPUT;
|
||||
|
||||
$mastercheckbox = new checkbox_toggleall('qbank', true, [
|
||||
@ -53,7 +53,7 @@ class checkbox_column extends column_base {
|
||||
return $OUTPUT->render($mastercheckbox);
|
||||
}
|
||||
|
||||
protected function get_title_tip() {
|
||||
public function get_title_tip() {
|
||||
return get_string('selectquestionsforbulk', 'question');
|
||||
}
|
||||
|
||||
|
@ -133,7 +133,7 @@ abstract class column_base {
|
||||
/**
|
||||
* Title for this column. Not used if is_sortable returns an array.
|
||||
*/
|
||||
abstract protected function get_title();
|
||||
abstract public function get_title();
|
||||
|
||||
/**
|
||||
* Use this when get_title() returns
|
||||
@ -141,7 +141,7 @@ abstract class column_base {
|
||||
*
|
||||
* @return string a fuller version of the name.
|
||||
*/
|
||||
protected function get_title_tip() {
|
||||
public function get_title_tip() {
|
||||
return '';
|
||||
}
|
||||
|
||||
|
@ -64,7 +64,7 @@ class edit_menu_column extends column_base {
|
||||
return $remainingcolumns;
|
||||
}
|
||||
|
||||
protected function get_title() {
|
||||
public function get_title() {
|
||||
return get_string('actions');
|
||||
}
|
||||
|
||||
|
@ -60,7 +60,7 @@ class testable_core_question_column extends \core_question\local\bank\column_bas
|
||||
return 'test_column';
|
||||
}
|
||||
|
||||
protected function get_title() {
|
||||
public function get_title() {
|
||||
return 'Test Column';
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user