Moodle 4.x devel[edit]
icon のバック[edit]
- lib.php apply_supports() で FEATURE_MOD_PURPOSE の問い合わせに以下の返答を返すとアイコンのバックが変わる.
- default は MOD_PURPOSE_OTHER
- MOD_PURPOSE_COMMUNICATION
- MOD_PURPOSE_ASSESSMENT
- MOD_PURPOSE_COLLABORATION
- MOD_PURPOSE_CONTENT
- MOD_PURPOSE_ADMINISTRATION
- MOD_PURPOSE_INTERFACE
- MOD_PURPOSE_OTHER
function apply_supports($feature)
{
switch($feature) {
case FEATURE_GROUPS: return false;
case FEATURE_GROUPINGS: return false;
case FEATURE_GROUPMEMBERSONLY: return false;
case FEATURE_MOD_INTRO: return true;
case FEATURE_COMPLETION_TRACKS_VIEWS: return false;
case FEATURE_COMPLETION_HAS_RULES: return false;
case FEATURE_GRADE_HAS_GRADE: return false;
case FEATURE_GRADE_OUTCOMES: return false;
case FEATURE_BACKUP_MOODLE2: return true;
case FEATURE_SHOW_DESCRIPTION: return true;
case FEATURE_MOD_PURPOSE: return MOD_PURPOSE_COMMUNICATION;
default: return null;
}
}