source: TI01-discovery/trunk/OAIInfoEditor/oai_info_editor/lib/constants.py @ 5235

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/TI01-discovery/trunk/OAIInfoEditor/oai_info_editor/lib/constants.py@5235
Revision 5235, 1.2 KB checked in by cbyrom, 12 years ago (diff)

Add functionality to allow admin users to add new provider info +
restrict deletion of info to admin users + add basic input checking
to ensure provider name is specified as a minimum.

  • Property svn:executable set to *
Line 
1'''
2 Module to store various constants used by the oai info editor controller
3 NB, the primary purpose of this is to separate these out from the controllers
4 so they can be used in the test suite to check results.  This also allows
5 centralisation of data which might need to be changed to tailor the look and
6 feel of the web app.
7 
8 @author: C Byrom, Tessella Apr 2009
9'''
10EDITOR_HOME_TITLE = "OAI Info Editor Home"
11NEW_PAGE_TITLE = "Creating new provider info"
12HELP_PAGE_TITLE = 'OAI Info Editor Help Page'
13VIEW_PAGE_TITLE = "View data for provider, '%s'"
14VIEW_ALL_DATA_TITLE = "View all provider data"
15EDIT_PAGE_TITLE = "Edit data for provider, '%s'"
16
17SUBMIT_BUTTON_TEXT = 'Submit checked requests together'
18
19# flag to indicate an input field is a checkbox
20CHECKBOX_SUFFIX = "checked"
21
22# key to use in session when displaying text via a javascript pop up
23POP_UP_MESSAGE_SESSION_KEY = "popUpSessionKey"
24
25# name to use in hidden field for storing record ID
26MAIN_ID_FLAG = "main_id"
27
28ALL_PROVIDER_IDS = "display_all"
29
30DATE_FORMAT = "%Y-%m-%dT%H:%M:%SZ"
31
32# name to use for new provider infos to mark them out as new
33NEW_PROVIDER_INFO_NAME = "newPI"
34
35
36# different types of text input fields - used by utils.EditTextField
37TEXT_FIELD = "text_field"
38TEXT_AREA = "text_area"
Note: See TracBrowser for help on using the repository browser.