Details
-
Type:
New Feature
-
Status:
Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: 2.0
-
Fix Version/s: None
-
Component/s: Conditional activities
-
Labels:None
-
Affected Branches:MOODLE_20_STABLE
Description
For those of us that do compliance training, sometimes the regulators want a person in a course for a certain period of time. (I.E. 2 hours 30 minutes for a 3 hour education course) In the AL hack I'm currently using for 1.9, I have a time setting, but I don' really see anything in the new conditional activities for 2.0 except for selecting a time frame when the course is available. Is it possible to add "total time" in course as a setting for locking activities in 2.0?
Thanks,
Todd
Nope - or not by me. I'm not planning to add any more features to conditional activities in 2.0, just tidying up what's there.
It seems to me this would be rather difficult to compute efficiently without adding an extra database table as I don't think we store 'first time in course' anywhere at present. [Except in log table, which is obviously a no-go.]
This also seems like a rather specialist requirement. Rather than building it into core, you might be able to use a plugin that interacts with the conditional activities system. For example if you can create a plugin that sets a Moodle grade value according to your condition (ie there is a custom grade item with 'Present for required time', this starts off at 0 and gets set to 10 by the system after a user has been there for 2.5 hours), then it's possible to make the conditional activities system do things based on that grade value.
The plugin could do its analysis in cron, and if this were specified only to work for very small installations rather than having to support full-scale use as core code does, then the information could even be obtained from mdl_log.