Availability dataformcontent
Availability dataformcontent | |
---|---|
Type | Availability conditions |
Set | N/A |
Downloads | http://moodle.org/plugins/view.php?plugin=availability_dataformcontent |
Issues | https://tracker.moodle.org/browse/CONTRIB/component/XXXXX |
Discussion | http://moodle.org/mod/forum/view.php?id=3505 |
Maintainer(s) | Itamar Tzadok |
- Overview
- Activity administration
- Building an activity
- CSS tips and tricks
- JS tips and tricks
- Activating RSS
- Activity workflow
- Grading
The Dataform content availability condition allows teachers to restrict user access to an activity or section based on content of a designated Dataform instance in the course.
Using the condition
The Dataform content condition requires a designated Dataform activity (dashboard) where the instructor will add entries on behalf of participants to unlock the restricted activities and resources.
The dashboard must have a field that can hold a reference to the restricted activity. The default reference type is the activity name. Accordingly the standard text field type and select field type can be used for the designated field. The field must have the reserved field name. By default the reserved name is 'Conditional Activity'. The Moodle administrator can set a different reserved name via the admin settings or lang strings.
With the dashboard Dataform added in the course, the instructor can assign the condition to the desired activities. The Dataform content restriction type appears in the restriction chooser only if there exists in the course a Dataform instance with a field that has the reserved name.
In the condition the instructor has to select the preferred dashboard. Only Dataform instances with the designated field will be available for selection in the dropdown.
With the 'Conditional Activity' field the instructor can apply the condition for particular participants. To apply the condition, the instructor has to add an entry on behalf of a particpant, and enter in the name of the restricted activity in the 'Conditional Activity' field. The participant will be granted access to the restricted activity effective immediately.
Steps for a basic example
- In site administration, enable conditional access .
- In the course, add a Dataform with the name 'Dashboard'.
- In the Dataform settings, set 'Separate participants' to 'Yes'.
- In the Dataform fields index, add a text field with the name 'Conditional Activity'.
- In the Dataform views index, add an aligned view with the name 'List'.
- Set the view template to ##entries##.
- Uncheck all the view submission buttons.
- Set the view as the default view.
- In the Dataform views index, add an aligned view with the name 'Manage List'.
- Replace in the entry template '[[EAU:name]]' with '[[EAU:edit]]'.
- In the course, add a Page resource with the name 'Extra Page'.
- In the Page settings add a Datafrom content restriction condition and select 'Dashboard'.
- Set the condition to hidden.
- Log in as a student.
- You will not see the Extra Page resource in the course.
- Log in as a teacher.
- Go the dashboard.
- Go to the Manage List view.
- Click 'Add a new entry'.
- Select the student in the entry user dropdown.
- Enter the text 'Extra Page' in the text field.
- Save the entry.
- Log in as a student.
- You will see the Extra Page resource in the course.
Admin settings
The reserved field name and reserved filter name are also available via the plugin language strings. The language strings take effect when the admin settings remain empty.
Note: Moodle doesn't yet provide access to the admin settings page of availability condition plugins. You can still set these settings directly in config.php.
Installation
Git clone
- Type the following command in the root of your Moodle install: git clone git://github.com/itamart/moodle-availability_dataformcontent.git availability/condition/dataformcontent
- Add /availability/condition/dataformcontent to your .git/info/exclude.
- Visit http://yoursite.com/admin to finish the installation.
Download
- Download zip from: https://github.com/itamart/moodle-availability_dataformcontent/archive/v2.8.5.zip (see https://github.com/itamart/moodle-availability_dataformcontent/releases for other available releases) or http://moodle.org/plugins/pluginversions.php?plugin=availability_dataformcontent.
- Unzip into the availability/condition subfolder of your Moodle install.
- Rename the new folder to dataformcontent.
- Visit http://yoursite.com/admin to finish the installation.