add index function
This commit is contained in:
parent
eaa2c74c6a
commit
3354536919
@ -45,7 +45,7 @@ with open("WEB_setting.json") as f:
|
||||
|
||||
|
||||
# 创建Flask对象
|
||||
from flask import Flask
|
||||
from flask import Flask, send_file
|
||||
from flask.ext.restful import Api, Resource, reqparse
|
||||
from flask.ext.socketio import SocketIO
|
||||
from flask_cors import *
|
||||
@ -594,6 +594,12 @@ class CtaStrategyVar(Resource):
|
||||
return {'result_code':'success','data':l}
|
||||
|
||||
|
||||
########################################################################
|
||||
@app.route('/')
|
||||
def index_html():
|
||||
"""首页"""
|
||||
return send_file( os.path.abspath('.') + '/web/index.html' )
|
||||
|
||||
# 注册资源
|
||||
api.add_resource(Token, '/token')
|
||||
api.add_resource(Gateway, '/gateway')
|
||||
|
Loading…
Reference in New Issue
Block a user