Setting Course level assignment defaults

Setting Course level assignment defaults

by William Lowell -
Number of replies: 1

I am wondering if there is any way to set default assignment settings for moodle 2.5.  For example I use the online editor for all assignments so students can send me a message that they have finished their assignment and shared it with me in google docs.   That box is not checked in the assignment setup so I have to remember to check it every time I set an assignment.  Would like a way to set defaults for all the assignments settings after the date.  

WCL

Average of ratings: -
In reply to William Lowell

Re: Setting Course level assignment defaults

by Purnendu Dash -
Picture of Plugin developers

Dear William,

I am afraid, there are no such default settings for assignment as per your requirements. To enable such settings you have to make some changes in the coding.

For example if you want the "online editor" checkbox to be checked by default, you have to edit this in php code. Go to the mod/assign or mod/assignment folder and find the appropriate check box for the online editor (you will get this in mod_form.php or edit_form.php. Search with "$mform->addElement('checkbox'… "  and suchlike) and add the code,

 $mform->setDefault('replace_with_the_online_editor_chekbox_name', 1); below the checkbox code.

 Here I’m providing an example:

$mform->addElement('checkbox', 'onlineditor', get_string('online', 'assign'));

$mform->setDefault('onlineditor', 1);  

//add this line, the 1 means checkbox will always be checked//

Hope this works for you.

Warm regards

Purnendu (developer)

DualCube