Quantcast
Channel: Web services
Viewing all articles
Browse latest Browse all 2361

Re: mod_assign_save_grades Notifications

$
0
0
by Michael Hughes.  

This web service is ultimately calling apply_grade_to_user() in mod/assign/locallib.php, (by way of save_grade()) which sends the notification based on the $formdata->sendstudentnotifications field being present set and true.

If the the sendstudentnotifications element doesn't exist (and it won't because the Web API doesn't accept it nor pass it along to the Assignment API), then the notification shouldn't be emitted normally.

Are you sure it's this method and not the assignment cron that is emitting these notifications? The assignment cron (locallib.php assign::cron()) sends a notification under the following conditions, and the task to do this runs every minute (by default):

// Collect all submissions that require mailing.
// Submissions are included if all are true:
// - The assignment is visible in the gradebook.
// - No previous notification has been sent.
// - The grader was a real user, not an automated process.
// - The grade was updated in the past 24 hours.
// - If marking workflow is enabled, the workflow state is at 'released'.
There doesn't look like there is an option to stop this, other than setting the assignment to hidden (which has obvious implications if it still needs to be accessed), the assignments *grade item* (in the gradebook) or by writing into each user's user_flag record for the assignment that it's already been mailed.



Viewing all articles
Browse latest Browse all 2361

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>