Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-18224

Create a better mechanism for outputting progress information from batch jobs

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Major Major
    • 2.0
    • 2.0
    • Libraries
    • None
    • MOODLE_20_STABLE
    • MOODLE_20_STABLE

      I hate the sort of

      if ($feedback) {
      echo ...;
      }

      or

      if (!defined('RESTORE_SILENTLY'))

      { echo "<ul>"; }

      code we have around the place.

      Instead, I am going to make a moodle_progress_trace class with a single output($message) method, with subclasses like null_progress_trace, text_progress_trace, html_progress_trace, etc. Then the batch code can just do $feedback->message('...'); and the right thing will happen.

            timhunt Tim Hunt
            timhunt Tim Hunt
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.