|
|
|
|
@ -42,14 +42,12 @@ def create_app(config_name=None):
|
|
|
|
|
from app.controllers.task_controller import task_bp
|
|
|
|
|
from app.controllers.image_controller import image_bp
|
|
|
|
|
from app.controllers.admin_controller import admin_bp
|
|
|
|
|
from app.controllers.demo_controller import demo_bp
|
|
|
|
|
|
|
|
|
|
app.register_blueprint(auth_bp, url_prefix='/api/auth')
|
|
|
|
|
app.register_blueprint(user_bp, url_prefix='/api/user')
|
|
|
|
|
app.register_blueprint(task_bp, url_prefix='/api/task')
|
|
|
|
|
app.register_blueprint(image_bp, url_prefix='/api/image')
|
|
|
|
|
app.register_blueprint(admin_bp, url_prefix='/api/admin')
|
|
|
|
|
app.register_blueprint(demo_bp, url_prefix='/api/demo')
|
|
|
|
|
|
|
|
|
|
# 注册错误处理器
|
|
|
|
|
@app.errorhandler(404)
|
|
|
|
|
|