diff --git a/Manage/rating/Rating.py b/Manage/rating/Rating.py index 4797f4e..f9465ce 100644 --- a/Manage/rating/Rating.py +++ b/Manage/rating/Rating.py @@ -1,3 +1,7 @@ +from Manage.rating.scripts import rating_result_script, search_rating_script, fill_detailss_script, risk_info_script, \ + report_edit_script, report_delete_script, report_create_script + + class Rating: def __init__(self): diff --git a/Manage/rating/routes.py b/Manage/rating/routes.py index c35b564..79926e2 100644 --- a/Manage/rating/routes.py +++ b/Manage/rating/routes.py @@ -1,12 +1,15 @@ from flask import Blueprint, request from common.APIAuth import api_secret from Manage.rating.Rating import Rating +from user.user_auth import verify_token, authority_scope + rating_route = Blueprint('rating', __name__) @rating_route.route('/search', methods=['POST']) -@api_secret -def search_rating(): +@verify_token +@authority_scope(['admin', 'developer', 'analysts', 'operator']) +def search_rating(**kwargs): """ 企业评价记录搜索 Parameters: diff --git a/Manage/rating/scripts.py b/Manage/rating/scripts.py index 49578b4..9c3156a 100644 --- a/Manage/rating/scripts.py +++ b/Manage/rating/scripts.py @@ -1,6 +1,10 @@ import json import requests +from Manage.rating.db import find_rating_records, find_rating_result_records, find_fill_details_records, \ + find_risk_info_records, update_report_data, find_evaluation_records, delete_report_pdf, update_evaluation_records, \ + find_report_data, update_comprehensive_records + def search_rating_script(query, skip, limit): """