@app.route('/display2/<filename>')
def pdf(filename):
    return redirect(url_for('static', filename=('pdf/' + filename)), code=301)
@app.route('/display2/<filename>')
def pdf(filename):
    return redirect(url_for('static', filename=('pdf/' + filename)), code=301)