Moodle PHP Documentation 4.5
Moodle 4.5dev (Build: 20240606) (d3ae1391abe)
qbank_customfields

Namespaces

namespace  qbank_customfields
  
 
namespace  qbank_customfields\customfield
  
 
namespace  qbank_customfields\event
  
 
namespace  qbank_customfields\output
  
 
namespace  qbank_customfields\privacy
  
 

Classes

class  backup_qbank_customfields_plugin
 
class  qbank_customfields\custom_field_column
 
class  qbank_customfields\customfield\question_handler
 
class  qbank_customfields\event\question_deleted_observer
 
class  qbank_customfields\output\renderer
 
class  qbank_customfields\plugin_feature
 
class  qbank_customfields\privacy\provider
 
class  restore_qbank_customfields_plugin
 

Functions

 qbank_customfields_preview_display (question_definition $question, int $courseid)
 Comment content for callbacks.
 

Variables

 $capabilities
 
 $observers
 
 $plugin = 2024041600
 
$plugin component = 'qbank_customfields'
 
$plugin maturity = MATURITY_STABLE
 
$plugin version = 2024042200
 

Detailed Description

Function Documentation

◆ qbank_customfields_preview_display()

qbank_customfields_preview_display ( question_definition $question,
int $courseid )

Comment content for callbacks.

Parameters
question_definition$question
int$courseid
Return values
string

Variable Documentation

◆ $capabilities

$capabilities
Initial value:
= [
'qbank/customfields:changelockedcustomfields' => [
'riskbitmask' => RISK_SPAM,
'captype' => 'write',
'contextlevel' => CONTEXT_COURSE,
'archetypes' => [
'manager' => CAP_ALLOW
],
],
'qbank/customfields:configurecustomfields' => [
'riskbitmask' => RISK_SPAM,
'captype' => 'write',
'contextlevel' => CONTEXT_SYSTEM,
'clonepermissionsfrom' => 'moodle/site:config'
],
'qbank/customfields:viewhiddencustomfields' => [
'captype' => 'read',
'contextlevel' => CONTEXT_COURSE,
'archetypes' => [
'editingteacher' => CAP_ALLOW,
'manager' => CAP_ALLOW
],
],
]
const CONTEXT_SYSTEM
System context level - only one instance in every system.
Definition accesslib.php:122
const CONTEXT_COURSE
Course context level - one instances for each course.
Definition accesslib.php:128
const RISK_SPAM
Capability allows users to add content others may see - see
Definition accesslib.php:147
const CAP_ALLOW
Allow permission, overrides CAP_PREVENT defined in parent contexts.
Definition accesslib.php:115

◆ $observers

$observers
Initial value:
= [
[
'eventname' => '\core\event\question_deleted',
'callback' => '\qbank_customfields\event\question_deleted_observer::delete_question_customfields'
]
]