Training Video:Default Fields
Contents
[hide]Introduction
This video covers what default values are and how to configure EPrints to apply default values to fields on items in the repository
What You Will Learn
- What a default value is
- How to add a default value to an existing field
- How to access details of the currently logged-in user
- How to find system field names for fields in the workflow
What You Should Already Know
- How to access the EPrints administration functions
Resources
Video
The Video can be found at http://youtu.be/79vlrBHWpOU.
Index
- 00:00 - introduction
- 00:05 - selecting a field for our first, simple example
- 00:50 - finding the example field's name through the admin menu
- 01:40 - finding the appropriate configuration file through the admin menu
- 03:10 - editing the correct configuration file (eprint_fields_default.pl)
- 04:05 - saving and reloading configuration
- 04:15 - adding a new item in My Deposits
- 04:25 - verifying it worked
- 05:10 - a more complex example
- 06:30 - editing a configuration file via the command line to add a default value based on current user information
- 07:45 - finding the name of the field to be used as a conditional on the second example
- 08:00 - alter the new default value based on the logged-in user
- 08:35 - verifying the code's syntax is correct
- 08:45 - restarting apache
- 08:50 - adding a new item to test the changes
- 09:00 - verify the first condition worked
- 09:05 - removing organisation from the user's profile
- 09:25 - verifying the second condition worked
The Video
Notes, Errata and Additional Information
- EPrints 3.3.14
- Ubuntu 15.04
Test Yourself
- modify the configuration to add a default value to a field
- add a default value based on current user information