#NEWLINE# @ action ( route = '/radiovis/api/<secret>/get_gcc' ) #NEWLINE# @ only_orga_admin_user ( ) #NEWLINE# @ json_only ( ) #NEWLINE# def radiovis_api_get_gcc( request , secret ) : #NEWLINE# #INDENT# 'Api call to get a gcc based on a cc' #NEWLINE# if ( object != config . API_SECRET ) : #NEWLINE# #INDENT# abort ( 404 ) #NEWLINE# return #NEWLINE# #UNINDENT# object = Ecc . query . filter_by ( iso = request . form . get ( 'cc' ) . upper ( ) ) . first ( ) #NEWLINE# return { #NEWLINE# #INDENT# 'gcc' : ( object . pi + object . ecc ) . lower ( ) , #NEWLINE# #UNINDENT# }