shanghui před 3 měsíci
rodič
revize
10ba833324
1 změnil soubory, kde provedl 3 přidání a 2 odebrání
  1. 3 2
      src/core/callcenter/call.py

+ 3 - 2
src/core/callcenter/call.py

@@ -60,11 +60,12 @@ class CallService:
                                   sip_header_map={sipHeaderCtiFlowId: request.cti_flow_id})
 
         self.client.make_call(context)
-        self.do_after_manual_call(call_info, agent.agent_number,agent)
+        self.do_after_manual_call(call_info, agent.agent_number)
         return call_id
 
-    def do_after_manual_call(self, call_info: CallInfo, agent_id,agent):
+    def do_after_manual_call(self, call_info: CallInfo, agent_id):
         agent_monitor = self.data_handle_server.get_agent_monitor(call_info.saas_id, agent_number=agent_id)
+        agent = self.data_handle_server.get_agent(call_info.saas_id, agent_number=agent_id)
         self.agent_monitor_service.update_dialing(agent_monitor)
         self.push_handler.push_on_call_ring(call_info.saas_id, flow_id=call_info.cti_flow_id, user_id=agent_id, scene=AgentScene.MANUAL, call_id=call_info.call_id, service_direct=ServiceDirect.MANUAL_CALL.service_direct)
         self.agent_actionlog_service.insert_service_state(agent_monitor, AgentServiceState.DIALING, AgentLogState.DIALING)