Changeset 5c11e3e in osmose-frontend


Ignore:
Timestamp:
May 8, 2014 9:03:55 PM (6 years ago)
Author:
Frédéric Rodrigo <fred.rodrigo@…>
Children:
4066327
Parents:
0fc1496
git-author:
Frédéric Rodrigo <fred.rodrigo@…> (08/05/2014 19:32:19)
git-committer:
Frédéric Rodrigo <fred.rodrigo@…> (08/05/2014 21:03:55)
Message:

Add GPX output of errors list

Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • errors.py

    r0fc1496 r5c11e3e  
    129129        gen = "error" 
    130130 
    131     if not format in ('rss',): 
     131    if not format in ('rss', 'gpx'): 
    132132        format = None 
    133133 
     
    176176        response.content_type = 'application/rss+xml' 
    177177        tpl = 'errors/list.rss' 
     178    elif format == 'gpx': 
     179        response.content_type = 'application/gpx+xml' 
     180        tpl = 'errors/list.gpx' 
    178181    else: 
    179182        tpl = 'errors/index' 
  • osmose.py

    r9c41fa6 r5c11e3e  
    3131 
    3232def ext_filter(config): 
    33     regexp = r'html|json|xml|rss|png|svg|pdf' 
     33    regexp = r'html|json|xml|rss|png|svg|pdf|gpx' 
    3434    def to_python(match): 
    35         return match if match in ('html', 'json', 'xml', 'rss', 'png', 'svg', 'pdf') else 'html' 
     35        return match if match in ('html', 'json', 'xml', 'rss', 'png', 'svg', 'pdf', 'gpx') else 'html' 
    3636    def to_url(ext): 
    3737        return ext 
Note: See TracChangeset for help on using the changeset viewer.