Exemple #1
0
    def GET(self):
        params = web.input()

        nid = params['nid']
        vid = params['vid']
        start = params['start']
        end = params['end']

        filename = str(nid) + "." + str(vid)

        web.header('Content-Type', 'application/json')
        return json.dumps(pyfina.data(filename, start, end))
Exemple #2
0
 def GET(self):
     params = web.input()
     
     nid = params['nid']
     vid = params['vid']
     start = params['start']
     end = params['end']
     
     filename = str(nid)+"."+str(vid)
     
     web.header('Content-Type', 'application/json')
     return json.dumps(pyfina.data(filename,start,end))
Exemple #3
0
def data(path):
    if not session['valid']:
        redirect("/")

    filename = path.replace("/", ".")

    start = request.args.get('start')
    end = request.args.get('end')
    interval = request.args.get('interval')

    print "DATA: " + filename + " " + start + " " + end + " " + interval

    data = json.dumps(pyfina.data(filename, start, end, interval))
    return Response(data, mimetype='text/plain')
Exemple #4
0
def data(path):
    if not session['valid']:
        redirect("/")
    
    filename = path.replace("/",".")
    
    
    start = request.args.get('start')
    end = request.args.get('end')
    interval = request.args.get('interval')
    
    print "DATA: "+filename+" "+start+" "+end+" "+interval
    
    data = json.dumps(pyfina.data(filename,start,end,interval))
    return Response(data, mimetype='text/plain')