Download Geotrek Documentation Release 2.4.4 Makina
Transcript
Geotrek Documentation, Release 2.4.4
4.3 WYSIWYG editor configuration
Text form fields are enhanced using TinyMCE.
Its configuration can be customized using advanced settings (see above paragraph).
For example, in order to control which buttons are to be shown, and which tags are to be kept when cleaning-up, add
this bloc :
TINYMCE_DEFAULT_CONFIG = {
'theme_advanced_buttons1': 'bold,italic,forecolor,separator,code',
'valid_elements': "img,p,a,em/i,strong/b",
}
This will apply to all text fields.
For more information on configuration entries available, please refer to the official documentation of TinyMCE version
3.
4.4 View attachments in the browser
Attached files are downloaded by default by browser, with the following line, files will be opened in the browser :
MAPENTITY_CONFIG['SERVE_MEDIA_AS_ATTACHMENT'] = False
4.5 Using Google Maps projection in the Web interface
Your data will still be stored using the SRID you specified in the settings.ini file, but the maps in the Web
interface will be using the Google Mercator projection (EPSG:3857).
It allows you to use IGN Geoportail WMTS or OpenStreetMap tiles for example
Start by adding this line in your custom Django setting file :
LEAFLET_CONFIG['SRID'] = 3857
And specify the tiles URLs this way :
LEAFLET_CONFIG['TILES'] = [
('Scan', 'http://{s}.tile.osm.org/{z}/{x}/{y}.png', '(c) OpenStreetMap Contributors'),
('Ortho', 'http://{s}.tiles.mapbox.com/v3/openstreetmap.map-4wvf9l0l/{z}/{x}/{y}.jpg', '(c) MapBo
]
4.6 External authent
You can authenticate user against a remote database table or view.
To enable this feature, fill authent_dbname and other fields in etc/settings.ini.
Expected columns in table/view are :
• username : string (unique)
• first_name : string
14
Chapter 4. ADVANCED CONFIGURATION