Skip to content

Commit

Permalink
do not add flow_log when hand_ticket is call from task
Browse files Browse the repository at this point in the history
  • Loading branch information
blackholll committed May 7, 2019
1 parent f409b7d commit 6195c13
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions service/ticket/ticket_base_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -1067,8 +1067,9 @@ def handle_ticket(cls, ticket_id, request_data_dict, by_timer=False, by_task=Fal
for key, value in ticket_all_data.items():
if type(value) not in [int, str, bool, float]:
ticket_all_data[key] = str(ticket_all_data[key])

cls.add_ticket_flow_log(dict(ticket_id=ticket_id, transition_id=transition_id, suggestion=suggestion,
if not by_task:
# 脚本执行完自动触发的流转,因为在run_flow_task已经有记录操作日志,所以此次不再记录
cls.add_ticket_flow_log(dict(ticket_id=ticket_id, transition_id=transition_id, suggestion=suggestion,
participant_type_id=CONSTANT_SERVICE.PARTICIPANT_TYPE_PERSONAL, participant=username,
state_id=source_ticket_state_id, creator=username, ticket_data=json.dumps(ticket_all_data)))

Expand Down

0 comments on commit 6195c13

Please sign in to comment.