您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

20 行
513B

  1. from flask import Blueprint
  2. from modules import cbpi
  3. from flask_swagger import swagger
  4. from flask import json
  5. from flask import Blueprint
  6. @cbpi.addon.core.initializer(order=22)
  7. def web(cbpi):
  8. s = Blueprint('web_view', __name__, template_folder='templates', static_folder='static')
  9. @s.route('/', methods=["GET"])
  10. def index():
  11. return s.send_static_file("index.html")
  12. cbpi.addon.core.add_menu_link("JQuery View", "/web_view")
  13. cbpi.web.register_blueprint(s, url_prefix='/web_view')