64ee3cbd by 冯轩

MOD:auto/v1

1 parent 5ccd03be
...@@ -1632,6 +1632,18 @@ class AutoSettlementView(GenericView): ...@@ -1632,6 +1632,18 @@ class AutoSettlementView(GenericView):
1632 1632
1633 is_fsm = args.get('is_fsm') 1633 is_fsm = args.get('is_fsm')
1634 1634
1635 # 角色权限不符,返回空列表
1636 token = request.META.get("HTTP_AUTHORIZATION")
1637 user_role = rh.get_token(token[-11:])
1638 self.running_log.info('[api doc] [user_role={0}] '.format(user_role))
1639 if user_role == -1 or (user_role == 1 and business_type == 'HIL') or (user_role == 2 and business_type == 'AFC'):
1640 pagination = {'current': page, 'total': 0, 'page_size': page_size}
1641 res = {
1642 'pagination': pagination,
1643 'doc_list': []
1644 }
1645 return response.ok(data=res)
1646
1635 if isinstance(auto_result, int): 1647 if isinstance(auto_result, int):
1636 auto_result = consts.RESULT_MAP.get(auto_result) 1648 auto_result = consts.RESULT_MAP.get(auto_result)
1637 if isinstance(whole_result, int): 1649 if isinstance(whole_result, int):
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!