Hello,
In an earlier Moodle-version (Moodle 3.x) we developed a report for quizzes. That report takes an object "cm" which includes a the data of a quiz activity. The moduleid of that quiz activity is 135. Moodle provides for the reports an object similar to:
Versuche: 54966
object(stdClass)#72 (23) { ["id"]=> string(3) "135" ["course"]=> string(1) "7" ["module"]=> string(2) "16" ["instance"]=> string(2) "57" ["section"]=> string(2) "23" ["idnumber"]=> string(0) "" ["added"]=> string(10) "1548925287" ["score"]=> string(1) "0" ["indent"]=> string(1) "0" ["visible"]=> string(1) "1" ["visibleoncoursepage"]=> string(1) "1" ["visibleold"]=> string(1) "1" ["groupmode"]=> string(1) "2" ["groupingid"]=> string(1) "0" ["completion"]=> string(1) "2" ["completiongradeitemnumber"]=> string(1) "0" ["completionview"]=> string(1) "1" ["completionexpected"]=> string(1) "0" ["showdescription"]=> string(1) "0" ["availability"]=> string(68) "{"op":"&","c":[{"type":"completion","cm":137,"e":1}],"showc":[true]}" ["deletioninprogress"]=> string(1) "0" ["name"]=> string(109) "Our Country Quiz" ["modname"]=> string(4) "quiz" }
In our new Moodle Version 4.3 Moodle provides an the following object
object(cm_info)#238 (48) { ["modinfo":"cm_info":private]=> object(course_modinfo)#147 (8) {
....
The quiz info is also included in that object:
[135]=>
object(cm_info)#237 (48) {
["modinfo":"cm_info":private]=>
*RECURSION*
["state":"cm_info":private]=>
int(2)
["id":"cm_info":private]=>
string(3) "135"
["instance":"cm_info":private]=>
string(2) "57"
["idnumber":"cm_info":private]=>
string(0) ""
...
["modname":"cm_info":private]=>
string(4) "quiz"
["module":"cm_info":private]=>
string(2) "16"
["name":"cm_info":private]=>
string(109) "Our Country Quiz"
...
Is there a chance to extract these quiz info and pass it to our report.
Thanks for your help!
Best,
Sarah