def get_sitemap(): # 返回reboots文件 sitemap_txt_path = r'sitemap/sitemap.txt' return app.send_static_file(sitemap_txt_path)
def environment_mange(): return app.send_static_file('environment.html')
def sitemap_i1(): return app.send_static_file('sitemap_r1.xml')
def catch_all(path): return app.send_static_file("index.html")
def GSC_file(): return app.send_static_file('google137e022a821ce1e1.html')
def ico(): #fi = open(server_dir + 'favicon.ico', "rb") #return fi.read() #return send_from_directory(os.path.join(app.root_path, 'static'), 'favicon.ico', mimetype='image/vnd.microsoft.icon') return app.send_static_file("favicon.ico")
def parameter_detail_page(parameter_id): return app.send_static_file('parameter_detail.html')
def batch_run_log_detail(run_log_id, page_num): return app.send_static_file('batch_run_log_detail.html')
def logout(): if cur_user(): del session['user_id'] del session['real_name'] del session['timestamp'] return app.send_static_file('logout.html')
def parameter_page(page_num): return app.send_static_file('parameter.html')
def email_manage(): return app.send_static_file('email_manage.html')
def use_case_report(): return app.send_static_file('report.html')
def environment_detail(): return app.send_static_file('environment_detail.html')
def batch_run_log_page(page_num): return app.send_static_file('batch_run_log.html')
def interface_page(page_num): return app.send_static_file('interface.html')
def use_case_run_log_detail(run_log_id): return app.send_static_file('use_case_run_log_detail.html')
def interface_detail_page(interface_id): return app.send_static_file('interface_detail.html')
def home(): return app.send_static_file('index.html')
def use_case_page(page_num): return app.send_static_file('use_case_detail.html')
import json from application import app, es from application.models import User, Token, Concept from flask import request, jsonify, abort, g from functools import wraps from itsdangerous import (TimedJSONWebSignatureSerializer as Serializer, BadSignature, SignatureExpired) app.add_url_rule('/', 'root', lambda: app.send_static_file('index.html')) def verify_auth_token(token): """ Verifies that the token is valid for a user. """ s = Serializer(app.config['SECRET_KEY']) data = None try: data = s.loads(token) except SignatureExpired: return None except BadSignature: return None token = Token(token, data['email']) if token.is_valid_token(): return token.retrieve_user() else: return None
def use_case_detail_page(use_case_id): return app.send_static_file('use_case_detail.html')
def sitemap(): return app.send_static_file('sitemap.xml')
def batch_page(page_num): return app.send_static_file('batch.html')
def batch_detail_page(batch_id): return app.send_static_file('batch_detail.html')
def index(): return app.send_static_file("index.html")
def use_case_run_log_page(page_num): return app.send_static_file('use_case_run_log.html')
def sendoutput(): print "eee" return app.send_static_file('output.csv')