Uploaded image for project: 'Moodle app'
  1. Moodle app
  2. MOBILE-778 META: Migrate to Ionic
  3. MOBILE-864

Add support for logging (launching events) in the app

    XMLWordPrintable

    Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Minor
    • Resolution: Won't Fix
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0
    • Component/s: Logging
    • Labels:
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE

      Description

      Several current external functions does not launch events, this means that not logging is done for users.

      This is problematic, since some other plugins may depend on events launched by plugins (like forum) and the course log is not populated with this information (MOBILE-782).

      Note that a web service can be executed as a single USER or as an admin account, we can detect if an USER is the one launching the Web Service and in that case launch the event, example:

      $event = \mod_forum\event\course_module_viewed::create($params);
          $event->add_record_snapshot('course_modules', $cm);
          $event->add_record_snapshot('course', $course);
          $event->add_record_snapshot('forum', $forum);
          $event->trigger();
      

      This can be problematic, because in some cases maybe is not the real USER who is calling the Web Service, imaging a SIS that is caching all the messages posted by an user or something like that.

      There are several ways to fix these:

      • Force external functions to launch events always. (Maybe adding a new mandatory parameter "logging or launchevents" to say if the information must be logged)
      • Create new external functions for launching events in the system (so the client must launch events manually after doing some actions)

      Same applies for activity completion hooks, see: MOBILE-863 and MOBILE-782

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              jleyva Juan Leyva
              Participants:
              Component watchers:
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                31/Jul/15