| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- /*************************************************************************
- 【文件名】 Queue.h
- 【功能模块和目的】 外线来电队列基类头文件
- 【开发者及日期】 郑石诺 2015/01/21
- 【版本】 V1.0.0
- 【版权信息】 Copyright (C)2015 河南加一信息技术有限公司
- 【更改记录】
- *************************************************************************/
- #pragma once
- #include "AgentGroup.h"
- #include "IncomingCallGroup.h"
- class CIncomingCall;
- /*************************************************************************
- 【类名】 CQueue
- 【功能】
- 【接口说明】 外线来电队列基类
- 【开发者及日期】 郑石诺 2015/01/21
- 【版本】 V1.0.0
- 【版权信息】 Copyright (C)2015 河南加一信息技术有限公司
- 【更改记录】
- *************************************************************************/
- class CQueue
- {
- public:
- CQueue(UINT QueueNo);
- ~CQueue(void);
- UINT no(void) const { return m_QueueNo; }
- UINT callCount(void) const { return m_CallGroup.GetCount(); }
- bool getCallInfo(Call2Show& Info) { return m_CallGroup.getCallInfo(Info); }
- void clear(void);
-
- UINT talkIngAgentCount(void) { return m_AgentGroup.talkIngAgentCount(); } // 获取坐席组内通话中的数量 2022-01-27
- CString callIndex(); // 2022-04-01
- // 呼叫管理操作
- void onQueueRequest(CPduEntity* pCmd); // 呼叫请求排队
- bool onQueueCancel(CPduEntity* pCmd); // 呼叫取消排队
- bool onQueuePause(CPduEntity* pCmd); // 呼叫暂停排队
- bool onQueueContinue(CPduEntity* pCmd); // 呼叫继续排队
- // 座席相关
- void addAgent(CAgent* pAgent);
- void delAgent(CAgent* pAgent, bool isSave = true); // 2022-09-13 添加参数issave,如果cti断开造成删除坐席,不更新坐席在线情况
- void distributeAgent(void);
- // 保存坐席所在组的位置 2022-09-07
- std::string saveCurAllAgent();
- // 获取组内所有坐席,(坐席号|分机号|组号|坐席类型)
- CString getCurAllAgent() { m_AgentGroup.GetCurAllAgent(); };
- CAgent* GetFreeAgentForLoop() { return m_AgentGroup.GetFreeAgentForLoop(); };
- private:
- void __initStrategy(void);
- void __freeStrategy(void);
- CStrategyAD* __getStrategy(AGENT_STRATEGY StrategyId);
- void __onAgentDispatched(QUEUE_AGENT_RESULT Result, UINT Agent, UINT Exten, CIncomingCall* pCall); // 处理请求座席结果
- protected:
- UINT m_QueueNo;
- CIncomingCallGroup m_CallGroup; // 外线来电队列
- CAgentGroup m_AgentGroup; // 座席队列
- CMap<AGENT_STRATEGY, AGENT_STRATEGY, CStrategyAD*, CStrategyAD*> m_StrategyMap; // 保存所有座席分配策略
- };
|