General developer forum

getting user id from context

Picture of Sam Chaffee
Re: getting user id from context
Core developersParticularly helpful Moodlers

Hi Lucian,

No problem. The other thing it allows is for is other plugins besides Assignment to use the advanced grading forms. So it has to be agnostic about the user to allow for that.

For example, we have a plugin that uses advanced grading in certain circumstances and it uses a different table's id as the itemid.

I think the only thing your advanced grading form needs to do regarding calculating the grade is to define the get_grade method on the gradingform_<yourgradingform>_instance class.



Average of ratings: Useful (1)