source: MILK/trunk/milk_server/milk_server/lib/constants.py @ 5302

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/MILK/trunk/milk_server/milk_server/lib/constants.py@5302
Revision 5302, 963 bytes checked in by cbyrom, 11 years ago (diff)

Simplify structure of discovery controller, using the results template
to render searches even when no results are found. Add new error
dict to avoid confusing with the error dict used by the formencode
input checker. Add additional input checks and improve error handling.
Add dropdown list to select order by values + add new constants
module to store associated data and error keys + tidy up DiscoveryState?
object to make clearer and logic more consistent + fix paging controls
for results data.

Line 
1'''
2 Module to store various constants used by the MILK stack
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 - and can be adjusted
5 without interfering with the actual code
6 
7 @author: C Byrom, Tessella May 2009
8'''
9DIF_FEED = "dif"
10PUBLISHED_FEED = "published"
11DISCOVERY_FEED = "discovery"
12
13# different types of text input fields - used by templates.utils.EditTextField
14TEXT_FIELD = "text_field"
15TEXT_AREA = "text_area"
16
17# key to set in global dict, to show a pop up on page load - e.g. see feed_creator
18POP_UP_MESSAGE = "somethingToDisplay24524"
19
20# author to use in feed data that is created automatically by the MILK stack
21AUTO_AUTHOR = "Generated automatically by BADC system"
22DISCOVERY_ADMIN_AUTHOR = "Discovery service admin"
23
24# NB, this info should probably be retrieved from the discovery web service
25ORDER_BY_LIST = [["Date", "date"], ["Data Centre", "dataCentre"]]
Note: See TracBrowser for help on using the repository browser.