public void CallExit() { try { if (!blExit) { blExit = true; if (StrAgentNumber != "") { clsDataService.DeallocateSIPInformation(long.Parse(StrAgentNumber)); } try { foreach (ClsChannel cl in _DiallerChannel) { if (cl.CallResult == ClsChannel.CallStatus.CallInProgress) { VMuktiHelper.CallEvent("HangUp", this, new VMuktiEventArgs("PredictiveDialer", cl.ChannelID)); } } } catch (Exception ex) { ex.Data.Add("My Key", "VMukti--:--VmuktiModules--:--Call Center--:--AutoDialer--:--Dialer.Business--:--ClsChannelManager.cs--:--HangUp()--"); ClsException.LogError(ex); ClsException.WriteToErrorLogFile(ex); } //if (objLeadCollection != null) //{ foreach (ClsLead cd in objLeadCollection) { clsDataService.UpdateLeadStatus(cd.ID, cd.Status); // clsDataService.UpdateLeadStatus(cd.ID, "Fresh"); } UpdateSyncAtExit(); } } catch (Exception ex) { ex.Data.Add("My Key", "VMukti--:--VmuktiModules--:--Call Center--:--AutoDialer--:--Dialer.Business--:--ClsChannelManager.cs--:--CallExit()--"); ClsException.LogError(ex); ClsException.WriteToErrorLogFile(ex); } finally { if (!blExit) { UpdateSyncAtExit(); } } }
public void CallExit() { try { if (!blExit) { blExit = true; if (StrAgentNumber != "") { clsDataService.DeallocateSIPInformation(long.Parse(StrAgentNumber)); } try { if (channel1.ChannelID != "") { VMuktiHelper.CallEvent("HangUp", this, new VMuktiEventArgs(channel1.ChannelID)); } } catch { } foreach (ClsLead cd in objLeadCollection) { clsDataService.UpdateLeadStatus(cd.ID, cd.Status); } UpdateSyncAtExit(); } } catch (Exception ex) { VMuktiHelper.ExceptionHandler(ex, "CallExit()", "ClsChannelManager.cs"); } finally { if (!blExit) { UpdateSyncAtExit(); } } }