Moodle plugins directory: GISMO | Moodle.org
GISMO
GISMO is a graphical interactive monitoring tool that provides useful visualization of students' activities in online courses to instructors. With GISMO instructors can examine various aspects of distance students, such as the attendance to courses, reading of materials, submission of assignments. Users of the popular learning management system Moodle may benefit from GISMO for their teaching activities. With respect to the standard reports provided by Moodle (which basically allow teachers to see if an individual student has viewed a specific resource or participated on a specific activity on a specific day), GISMO provides comprehensive visualizations that gives an overview of the whole class, not only a specific student or a particular resource. With GISMO, instructors can perform analysis of the whole class, and may have a "clear picture" of what the class is doing, or has done in a period in the past.
Is there any indication of when the block will be made available?
I've been trying this plugin and looks great, but I get a "Cannot extract data from server!" in some of the options, such as "Accesses by students" or "Accesses overview".
I've read in documentation that MySQL is the required database and we use PostgreSQL, can be this the reason of this message? If so, is it planned to support other databases supported by Moodle?
Thanks!
unfortunately I didn't test it on postgresql.
I will try to install a moodle on postgre and have a look at it.
Can you activate debug and send me the errors you get executing the file moodleurl/blocks/gismo/lib/gismo/server_side/export_data.php
I've done that and (apparently) there is no error messages:
GISMO - export data (start)!
Gismo data has been purged successfully!
MEMORY USAGE BEFORE: 2'849'320
DEBUG: Reset max_log_id Export all logs MEMORY USAGE (AFTER COURSES EXTRACTION): 7'546'760
Course ID: 1 NOT EXPORTED
Course ID: 61 MEMORY USAGE (MIDDLE ACCESSES ON ACTIVITIES): 7'560'816 MEMORY USAGE (MIDDLE ACCESSES ON ACTIVITIES): 7'560'456 MEMORY USAGE (MIDDLE ACCESSES ON ACTIVITIES): 7'560'280 MEMORY USAGE (AFTER ACCESSES ON ACTIVITIES): 7'560'280 MEMORY USAGE (MIDDLE GISMO STUDENTS LOGIN): 7'559'920 MEMORY USAGE (AFTER GISMO STUDENTS LOGIN): 7'559'920 MEMORY USAGE (MIDDLE ACCESSES ON RESOURCES): 7'560'536 MEMORY USAGE (AFTER ACCESSES ON RESOURCES): 7'560'536
----------
(...More similar logs...)
Course ID: 8105 MEMORY USAGE (MIDDLE ACCESSES ON ACTIVITIES): 7'623'952 MEMORY USAGE (MIDDLE ACCESSES ON ACTIVITIES): 7'623'592 MEMORY USAGE (MIDDLE ACCESSES ON ACTIVITIES): 7'623'416 MEMORY USAGE (AFTER ACCESSES ON ACTIVITIES): 7'623'416 MEMORY USAGE (MIDDLE GISMO STUDENTS LOGIN): 7'627'968 MEMORY USAGE (MIDDLE GISMO STUDENTS LOGIN): 7'622'928 MEMORY USAGE (AFTER GISMO STUDENTS LOGIN): 7'622'928 MEMORY USAGE (MIDDLE ACCESSES ON RESOURCES): 7'623'408 MEMORY USAGE (AFTER ACCESSES ON RESOURCES): 7'623'408
----------
MEMORY USAGE AFTER: 7'623'280 Gismo data has been syncronized successfully!
GISMO - export data (end)!
in my test installation is working
FYI: I've done all this on Moodle 2.7.3
can you please check in file ajax.php line 118 if you have
if($CFG->dbtype === "pgsql"){
Yes, that's the line 118 in ajax.php
I've also tried to execute the query of line 119 directly on the database and it works and return some data.
is it possible for you to copy the url requested from the ajax call and run it manually?
then try to "debug" a bit the code printing if it goes in that if and try to print the exact query it does with all the parameters?
in my case the url is this one:
http://moodleURL/blocks/gismo/ajax.php?from=1412114400&q=teacher%40student-accesses&srv_data=Tzo4OiJzdGRDbGFzcyI6Mjp7czoxNzoiYmxvY2tfaW5zdGFuY2VfaWQiO3M6MjoiNDAiO3M6OToiY291cnNlX2lkIjtzOjE6IjIiO30%3D&to=1420066800&token=0.39665836169700985
I've done that and the ajax call returns some data; it seems that the problem can the "description" field, because there can be HTML code on it, returns, etc.
The data looks like this (look at the users 13117 and 6122):
{
"name":"Students: accesses by students",
"links":null,
"data":[],
"error":"",
"arr":[],
"context":{},
"users":{
"12742":{"id":"12742","auth":"ldap","confirmed":"1","policyagreed":"0","deleted":"0","suspended":"0","mnethostid":"1","username":"user1","password":"not cached","idnumber":"12345","firstname":"name1","lastname":"lastname1","email":"email1@mail.com","emailstop":"0","icq":"","skype":"","yahoo":"","aim":"","msn":"","phone1":"","phone2":"","institution":"","department":"","address":"","city":"--","country":"ES","lang":"eu","theme":"","timezone":"99","firstaccess":"1379571216","lastaccess":"1382943428","lastlogin":"1385493383","currentlogin":"1391613274","lastip":"8.8.8.8","secret":"","picture":"0","url":"","description":"description1","descriptionformat":"0","mailformat":"1","maildigest":"0","maildisplay":"2","autosubscribe":"1","trackforums":"0","timecreated":"1379571216","timemodified":"1379571704","trustbitmask":"0","imagealt":"","lastnamephonetic":null,"firstnamephonetic":null,"middlename":null,"alternatename":null,"calendartype":"gregorian"},
(...More user data...)
"13117":{"id":"13117","auth":"ldap","confirmed":"1","policyagreed":"0","deleted":"0","suspended":"0","mnethostid":"1","username":"user2","password":"not cached","idnumber":"23456","firstname":"name2","lastname":"lastname2","email":"email1@mail.com","emailstop":"0","icq":"","skype":"","yahoo":"","aim":"","msn":"","phone1":"","phone2":"","institution":"","department":"","address":"","city":"","country":"EH","lang":"eu","theme":"","timezone":"99","firstaccess":"1410338100","lastaccess":"1417100997","lastlogin":"1417100869","currentlogin":"1417362012","lastip":"8.8.8.8","secret":"","picture":"0","url":"","description":"description2
","descriptionformat":"1","mailformat":"1","maildigest":"0","maildisplay":"2","autosubscribe":"1","trackforums":"0","timecreated":"1410338100","timemodified":"1410338784","trustbitmask":"0","imagealt":"","lastnamephonetic":"","firstnamephonetic":"","middlename":"","alternatename":"","calendartype":"gregorian"},
"13108":{"id":"13108","auth":"ldap","confirmed":"1","policyagreed":"0","deleted":"0","suspended":"0","mnethostid":"1","username":"user3","password":"not cached","idnumber":"34567","firstname":"name3","lastname":"lastname3","email":"email1@mail.com","emailstop":"0","icq":"","skype":"","yahoo":"","aim":"","msn":"","phone1":"","phone2":"","institution":"","department":"","address":"","city":"--","country":"ES","lang":"es","theme":"","timezone":"99","firstaccess":"1410338084","lastaccess":"1417101055","lastlogin":"1417342000","currentlogin":"1417380829","lastip":"8.8.8.8,"secret":"","picture":"0","url":"","description":"I\u00d1AKI","descriptionformat":"1","mailformat":"1","maildigest":"0","maildisplay":"2","autosubscribe":"1","trackforums":"0","timecreated":"1410338083","timemodified":"1412706244","trustbitmask":"0","imagealt":"","lastnamephonetic":"","firstnamephonetic":"","middlename":"","alternatename":"","calendartype":"gregorian"},
(...More user data...)
"6122":{"id":"6122","auth":"manual","confirmed":"1","policyagreed":"0","deleted":"0","suspended":"0","mnethostid":"1","username":"user4","password":"$2y$10$kEmTeY9IRvyvjaAPxCL5FuhgCq7ZjXzWTFSuJ9udxoIKATyZKzVYK","idnumber":"","firstname":"name4","lastname":"lastname4","email":"email4@mail.com","emailstop":"0","icq":"","skype":"","yahoo":"","aim":"","msn":"","phone1":"","phone2":"","institution":"","department":"","address":"","city":"--","country":"ES","lang":"en","theme":"","timezone":"99","firstaccess":"1225365418","lastaccess":null,"lastlogin":"1411762605","currentlogin":"1417172216","lastip":"8.8.8.8","secret":"","picture":"0","url":"","description":"
dff<\/p>","descriptionformat":"1","mailformat":"1","maildigest":"0","maildisplay":"0","autosubscribe":"1","trackforums":"0","timecreated":"1225365418","timemodified":"1357825515","trustbitmask":"0","imagealt":"","lastnamephonetic":null,"firstnamephonetic":null,"middlename":null,"alternatename":null,"calendartype":"gregorian"},
"13104":{"id":"13104","auth":"ldap","confirmed":"1","policyagreed":"0","deleted":"0","suspended":"0","mnethostid":"1","username":"user5","password":"not cached","idnumber":"45678","firstname":"name5","lastname":"lastname5","email":"email5@mail.com","emailstop":"0","icq":"","skype":"","yahoo":"","aim":"","msn":"","phone1":"","phone2":"","institution":"","department":"","address":"","city":"","country":"ES","lang":"eu","theme":"","timezone":"99","firstaccess":"1410337901","lastaccess":null,"lastlogin":"1416985935","currentlogin":"1417166633","lastip":"8.8.8.8","secret":"","picture":"0","url":"","description":"description5","descriptionformat":"1","mailformat":"1","maildigest":"0","maildisplay":"2","autosubscribe":"1","trackforums":"0","timecreated":"1410337900","timemodified":"1410341790","trustbitmask":"0","imagealt":"","lastnamephonetic":"","firstnamephonetic":"","middlename":"","alternatename":"","calendartype":"gregorian"}}}
is strange u don't get anything in the data field if the query when u run it manually works....
Yes, there is more than 500 rows for that course in that table, and yes, it's strange...
"data":{"10":{"id":"10","course":"2","userid":"1004","timedate":"2014-10-30","time":"1414684196","numval":"23"},"11":{"id":"11","course":"2","userid":"1004","timedate":"2014-10-31","time":"1414772094","numval":"62"},"18":{"id":"18","course":"2","userid":"1382","timedate":"2014-10-31","time":"1414772188","numval":"24"},"19":{"id":"19","course":"2","userid":"1382","timedate":"2014-11-03","time":"1415025766","numval":"37"},"12":{"id":"12","course":"2","userid":"1004","timedate":"2014-11-03","time":"1415027292","numval":"43"},"20":{"id":"20","course":"2","userid":"1382","timedate":"2014-11-04","time":"1415117267","numval":"2"},"13":{"id":"13","course":"2","userid":"1004","timedate":"2014-11-04","time":"1415119479","numval":"22"},"21":{"id":"21","course":"2","userid":"1382","timedate":"2014-11-11","time":"1415723992","numval":"44"},"14":{"id":"14","course":"2","userid":"1004","timedate":"2014-11-11","time":"1415724239","numval":"35"},"15":{"id":"15","course":"2","userid":"1004","timedate":"2014-11-12","time":"1415796461","numval":"20"},"22":{"id":"22","course":"2","userid":"1382","timedate":"2014-11-12","time":"1415796485","numval":"58"},"23":{"id":"23","course":"2","userid":"1382","timedate":"2014-11-13","time":"1415875071","numval":"22"},"16":{"id":"16","course":"2","userid":"1004","timedate":"2014-11-13","time":"1415875075","numval":"14"},"17":{"id":"17","course":"2","userid":"1004","timedate":"2014-11-14","time":"1415978323","numval":"26"},"24":{"id":"24","course":"2","userid":"1382","timedate":"2014-11-14","time":"1415978399","numval":"23"},"161":{"id":"161","course":"2","userid":"1382","timedate":"2014-11-17","time":"1416215638","numval":"3"},"162":{"id":"162","course":"2","userid":"1004","timedate":"2014-11-17","time":"1416215732","numval":"3"},"219":{"id":"219","course":"2","userid":"1382","timedate":"2014-12-03","time":"1417622223","numval":"3"},"221":{"id":"221","course":"2","userid":"1004","timedate":"2014-12-03","time":"1417622242","numval":"57"},"246":{"id":"246","course":"2","userid":"1382","timedate":"2014-12-04","time":"1417710711","numval":"17"},"538":{"id":"538","course":"2","userid":"1382","timedate":"2014-12-10","time":"1418226582","numval":"9"}}
can you please
var_dump($student_resource_access) at line 119 and see if the query return anything...
var_dump($ctu_params) at line 117 (before or after the query)
and then with the data returned build and execute the query manually (remove the userid part and u get all the users)
SELECT ROW_NUMBER() over(), a.* FROM (SELECT course, userid, timedate, sum(numval) as numval FROM mdl_block_gismo_sl WHERE course = FIRSTELEMENT AND time BETWEEN SECONDELEMENT AND THIRDELEMENT GROUP BY course, timedate, userid ORDER BY timedate ASC) as a