Package madrona :: Package kmlapp :: Module views
[hide private]

Module views

source code

Functions [hide private]
 
get_styles(features, collections, links=True)
Based on which features and collection are provided, the styles for all features are determined here
source code
 
get_user_data(user)
Organizes user's Features and FeatureCollections.
source code
 
get_data_for_feature(user, uid) source code
 
get_public_data()
No login necessary, everyone sees these Public groups defined in settings.SHARING_TO_PUBLIC_GROUPS
source code
 
get_shared_data(shareuser, sharegroup, user) source code
 
create_kmz(kml, zippath)
Given a KML string and a "/" seperated path like "FOLDERNAME/doc.kml", creates a zipped KMZ archive buffer that can be written directly to a django response object
source code
 
create_kml(request, input_username=None, input_uid=None, input_shareuser=None, input_sharegroup=None, links=False, kmz=False, session_key='0')
Returns a KML/KMZ containing Feautures/FeatureCollections owned by user
source code
 
create_shared_kml(request, input_username, kmz=False, session_key='0')
Returns a KML/KMZ containing shared MPAs (organized into folders by groups and users who have shared them)
source code
 
shared_public(request, kmz=False, session_key='0')
Shows all publically shared arrays Must be shared with a special set of public groups defined in settings.SHARING_TO_PUBLIC_GROUPS
source code
Variables [hide private]
  log = get_logger()
Function Details [hide private]

get_user_data(user)

source code 

Organizes user's Features and FeatureCollections. Only returns objects owned by user, not shared Returns only the features/collections at the top level, nested child features will be handled later through recursive calls to feature_set.

create_kml(request, input_username=None, input_uid=None, input_shareuser=None, input_sharegroup=None, links=False, kmz=False, session_key='0')

source code 

Returns a KML/KMZ containing Feautures/FeatureCollections owned by user

Decorators:
  • @cache_control(no_cache= True)

create_shared_kml(request, input_username, kmz=False, session_key='0')

source code 

Returns a KML/KMZ containing shared MPAs (organized into folders by groups and users who have shared them)

Decorators:
  • @cache_control(no_cache= True)