{
  "title": "lang::report_7_inactive::local_kopere_bi",
  "description": "lang::report_7_inactive_report::local_kopere_bi",
  "user_id": null,
  "refkey": "inactive_enrollments",
  "category": {
    "refkey": "enrollments",
    "title": "lang::report_4_cat_title::local_kopere_bi",
    "description": "lang::report_4_cat_description::local_kopere_bi"
  },
  "blocks": [
    {
      "refkey": "enrollments-1",
      "type": "block-1",
      "sequence": 1,
      "elements": [
        {
          "title": "lang::report_7_users_not_accessed_course::local_kopere_bi",
          "refkey": "report_7_users_not_accessed_course",
          "block_num": 1,
          "type": "table",
          "theme": "light",
          "css": "",
          "html_before": "",
          "html_after": "",
          "commandsql": "SELECT u.id        AS u_id,\r\n       u.firstname,\r\n       u.lastname,\r\n       c.id       AS c_id,\r\n       c.fullname AS c_fullname,\r\n       u.email,\r\n       u.phone1,\r\n       u.city,\r\n       u.country,\r\n       u.firstaccess,\r\n       u.lastaccess,\r\n       u.lastlogin,\r\n       u.lastip,\r\n       (SELECT r.name\r\n           FROM {user_enrolments} ue2\r\n           JOIN {enrol} e ON e.id = ue2.enrolid\r\n           JOIN {role}  r ON e.id = r.id\r\n          WHERE ue2.userid = u.id\r\n            AND e.courseid = c.id ) AS rolename\r\n  FROM mdl_user_enrolments ue\r\n  JOIN mdl_enrol  e ON e.id = ue.enrolid\r\n  JOIN mdl_course c ON c.id = e.courseid\r\n  JOIN mdl_user   u ON u.id = ue.userid\r\nLEFT JOIN {user_lastaccess} ul ON ul.userid = u.id\r\n WHERE ul.timeaccess IS NULL",
          "cache": "30m",
          "reload": "30m",
          "info": "{\"column\":{\"u_id\":{\"key\":\"u_id\",\"title\":\"#\",\"type\":\"userphotoRenderer\",\"mustache\":\"\"},\"firstname\":{\"key\":\"firstname\",\"title\":\"lang::u_fullname::local_kopere_bi\",\"type\":\"userfullname\",\"mustache\":\"<a href=\\\"{{{config.wwwroot}}}\\\/user\\\/view.php?id={{{u_id}}}\\\"\\r\\n   target=\\\"profile\\\">{{{u_fullname}}}<\\\/a>\"},\"lastname\":{\"key\":\"lastname\",\"title\":\"\",\"type\":\"none\",\"mustache\":\"\"},\"c_id\":{\"key\":\"c_id\",\"title\":\"c_id\",\"type\":\"none\",\"mustache\":\"\"},\"c_fullname\":{\"key\":\"c_fullname\",\"title\":\"lang::c_fullname::local_kopere_bi\",\"type\":\"string\",\"mustache\":\"<a href=\\\"{{{config.wwwroot}}}\\\/course\\\/view.php?id={{{c_id}}}\\\"\\r\\n   target=\\\"course\\\">{{{c_fullname}}}<\\\/a>\"},\"email\":{\"key\":\"email\",\"title\":\"lang::email::moodle\",\"type\":\"string\",\"mustache\":\"<a href=\\\"mailto:{{{email}}}\\\" target=\\\"_blank\\\">{{{email}}}<\\\/a>\"},\"phone1\":{\"key\":\"phone1\",\"title\":\"lang::phone1::moodle\",\"type\":\"string\",\"mustache\":\"<a href=\\\"tel:{{{phone1}}}\\\" target=\\\"_blank\\\">{{{phone1}}}<\\\/a>\"},\"city\":{\"key\":\"city\",\"title\":\"lang::city::moodle\",\"type\":\"string\",\"mustache\":\"{{{city}}}\"},\"country\":{\"key\":\"country\",\"title\":\"lang::country::moodle\",\"type\":\"string\",\"mustache\":\"{{{country}}}\"},\"firstaccess\":{\"key\":\"firstaccess\",\"title\":\"lang::firstaccess::moodle\",\"type\":\"datetimeRenderer\",\"mustache\":\"{{{firstaccess}}}\"},\"lastaccess\":{\"key\":\"lastaccess\",\"title\":\"lang::lastaccess::moodle\",\"type\":\"datetimeRenderer\",\"mustache\":\"{{{lastaccess}}}\"},\"lastlogin\":{\"key\":\"lastlogin\",\"title\":\"lang::lastlogin::moodle\",\"type\":\"datetimeRenderer\",\"mustache\":\"{{{lastlogin}}}\"},\"lastip\":{\"key\":\"lastip\",\"title\":\"lang::lastip::moodle\",\"type\":\"string\",\"mustache\":\"<a href=\\\"https:\\\/\\\/www.geodatatool.com\\\/?ip={{{lastip}}}\\\" target=\\\"geoip\\\">{{{lastip}}}<\\\/a>\"},\"rolename\":{\"key\":\"rolename\",\"title\":\"lang::rolename::local_kopere_bi\",\"type\":\"string\",\"mustache\":\"{{{rolename}}}\"}}}"
        }
      ]
    }
  ]
}
