33 lines
1.0 KiB
Python
33 lines
1.0 KiB
Python
"""产品推荐模块 Blueprint。"""
|
|
from flask import Blueprint
|
|
|
|
recommend_bp = Blueprint("insurance_recommend", __name__)
|
|
|
|
|
|
@recommend_bp.route("/generate", methods=["POST"])
|
|
def generate_proposal():
|
|
"""生成推荐方案。"""
|
|
from insurance.utils.response import success
|
|
return success({"task_id": "placeholder", "status": "processing"})
|
|
|
|
|
|
@recommend_bp.route("/generate/<task_id>", methods=["GET"])
|
|
def get_proposal_status(task_id):
|
|
"""查询方案生成状态。"""
|
|
from insurance.utils.response import success
|
|
return success({"task_id": task_id, "status": "processing"})
|
|
|
|
|
|
@recommend_bp.route("/<proposal_id>/export", methods=["POST"])
|
|
def export_proposal(proposal_id):
|
|
"""导出推荐方案。"""
|
|
from insurance.utils.response import success
|
|
return success("导出接口(待实现)")
|
|
|
|
|
|
@recommend_bp.route("/<proposal_id>/share", methods=["POST"])
|
|
def share_proposal(proposal_id):
|
|
"""生成分享链接。"""
|
|
from insurance.utils.response import success
|
|
return success("分享接口(待实现)")
|