protected void selectScreenCast() { //4:Screen cast Guid guid = new Guid(); string agentName = ""; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(profileId); if (dt.Rows.Count != 0) { guid = dt[0].incident_guid; agentName = dt[0].agent_full_name; } String conferenceName = guid.ToString(); ConferenceStartupParameters parameters = ConferenceHelper.GetParametersForScreenCast(conferenceName, agentName, true); //parameters.ShouldCreateConference = false; //parameters.ShouldStartAppShare = false; //parameters.UseJavascript = false; //string tempConferenceName = Convert.ToString(1000000 + profileId); //parameters.ConferenceName = tempConferenceName; IncidentHelper.SetIncidentStateScreenCast(profileId); }
/// <summary> /// Cancel the Obsolete incidents (sitting too long in Queue) /// </summary> /// <returns></returns> protected bool cancelObsoleteIncidents() { bool result = false; //int cleanUpInterval = 300; // SosParameters.SosCallCleanUpInterval; //IncidentDS.IncidentDSDataTable dt = BllProxyIncident.GetIncidentQueueList(1, 0); //1:New; 0:All IncidentDS.IncidentDSDataTable dt = BllProxyIncident.GetIncidentsByStatus(1, 0); //1:New; 0:All foreach (IncidentDS.IncidentDSRow rowIncident in dt) { if (rowIncident.Isdate_openNull()) // Not for transferred incidents { DateTime now = DateTime.Now.ToUniversalTime(); TimeSpan span = now.Subtract(rowIncident.date_created); TimeSpan max = new TimeSpan(0, 0, 15, 0); // 15 minutes if (TimeSpan.Compare(span, max) > 0) { Int32 incidentId = rowIncident.incident_id; BllProxyIncidentHelper.SetIncidentSubject(incidentId, 3, "[_CLEARED_]"); // Canceled result = true; break; } } //--- } return(result); }
protected void selectConference() { //case 3: // Video session Guid sessionGUID = new Guid(); string agentName = ""; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(profileId); if (dt.Rows.Count != 0) { sessionGUID = dt[0].incident_guid; agentName = dt[0].agent_full_name; } String conferenceName = sessionGUID.ToString(); ConferenceStartupParameters parameters = ConferenceHelper.GetParametersForMultiVideo(conferenceName, "USER"); string tempConferenceName = Convert.ToString(1000000 + profileId); parameters.ConferenceName = tempConferenceName; //VideoChatControl.Parameters = parameters; IncidentHelper.SetIncidentStateVideoSession(profileId); }
/// <summary> /// Clear the Incident's ReservedAgent and Disable Agent not taking the call /// </summary> /// <param name="dtAllPoolAgents"></param> /// <returns></returns> protected bool checkReservations(PoolDS.PoolDSDataTable dtAllPoolAgents) { bool result = false; PoolDS.PoolDSRow[] rows = (PoolDS.PoolDSRow[])dtAllPoolAgents.Select("is_available=1 and is_busy=0", ""); if (rows.Length > 0) { int cancelInterval = UcConfParameters.UcCallForwardingInterval; // seconds foreach (PoolDS.PoolDSRow row in dtAllPoolAgents.Rows) { if ((!row.Isincident_idNull()) && (!row.Isdate_reservedNull())) { DateTime now = DateTime.Now.ToUniversalTime(); TimeSpan span = now.Subtract(row.date_reserved); TimeSpan max = new TimeSpan(0, 0, cancelInterval); if (TimeSpan.Compare(span, max) > 0) { Int32 incidentId = row.incident_id; Int32 incidentStatusId = 0; Int32 incidentAgentId = 0; IncidentDS.IncidentDSDataTable dtIncident = BllProxyIncident.SelectIncident(incidentId); if (dtIncident.Rows.Count > 0) { incidentStatusId = dtIncident[0].status_id; if (!dtIncident[0].Isagent_idNull()) { incidentAgentId = dtIncident[0].agent_id; } } if (incidentAgentId == 0) { if (incidentStatusId == 1) { BllProxyIncidentHelper.SetIncidentReservation(incidentId, 0); BllProxyPool.SetPoolAgentAvailable(row.agent_id, false); BllProxyPool.SetPoolAgentBusy(row.agent_id, false); } else { BllProxyPool.SetPoolAgentAvailable(row.agent_id, true); BllProxyPool.SetPoolAgentBusy(row.agent_id, true); } } result = true; } } } } return(result); }
public static bool OpenIncident(Int32 incidentId, Int32 agentId, out string msg) { msg = ""; bool success = false; agentPool.SetAgentBusy(agentId, true); BllProxyIncidentState.InsertIncidentState(incidentId, true, "NEW"); IncidentDS.IncidentDSDataTable dt = BllProxyIncident.OpenIncident(incidentId, agentId); if (dt.Rows.Count != 0) { if (dt[0].status_id == 2) { if ((!dt[0].Isreserved_agent_idNull()) && (dt[0].reserved_agent_id != agentId)) { msg = "The incident is RESERVED"; } else { Int32 incidentAgentId = dt[0].agent_id; String incidentAgentName = dt[0].agent_full_name; if (incidentAgentId != agentId) { msg = "The incident is in progress with " + incidentAgentName; } else { success = true; } } } else { msg = "canceled"; } } else { msg = "The incident has already been processed"; } if (success) { agentPool.ReleaseIncident(incidentId); agentPool.SetSession(agentId, incidentId); } else { agentPool.SetAgentBusy(agentId, false); } return(success); }
//------------------------------------------------------------------------------- public void SetAgentBusy(Int32 agentId, bool busy) { PoolDS.PoolDSDataTable dtPool = BllProxyPool.SelectPoolAgent(agentId); if (dtPool.Rows.Count != 0) { bool isBusy = busy; if (!isBusy) { IncidentDS.IncidentDSDataTable dtIncident = BllProxyIncident.GetIncidentsByStatus(2, agentId); //2:In-Progress if (dtIncident.Rows.Count != 0) { isBusy = true; } } if (isBusy) { BllProxyPool.SetPoolAgentBusy(agentId, true); } else { BllProxyPool.SetPoolAgentBusy(agentId, busy); } BllProxyPool.SetPoolAgentIncident(agentId, 0); } }
protected void selectTextChat() { //2:Text Chat string agentName = ""; string conferenceName = ""; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(profileId); if (dt.Rows.Count != 0) { conferenceName = dt[0].incident_guid.ToString(); agentName = dt[0].agent_full_name; } if (this.UcPage.UserRoleId != 2) // Agent { UserDS.UserDSDataTable dtU = BllProxyUser.SelectUser(this.UcPage.UserId); if (dtU.Rows.Count != 0) { string userRoleTitle = ""; switch (this.UcPage.UserRoleId) { case 1: // Administrator userRoleTitle = "ADMN"; break; case 2: // Agent userRoleTitle = "AGNT"; break; case 3: // Manager userRoleTitle = "MNGR"; break; case 4: // User userRoleTitle = "USER"; break; case 5: // Supervisor userRoleTitle = "SPVR"; break; } agentName = dtU[0].full_name + " [" + userRoleTitle + "]"; } } TextChatControl.ConfSessionId = conferenceName; TextChatControl.ConfSessionUser = agentName; IncidentHelper.SetIncidentStateTextChat(profileId); }
/// <summary> /// Disable the Agent if not online (Agent in AgentPool is not renewed for too long) /// Remove the Agent from AgentPool if not online for a week /// </summary> /// <param name="dtAllPoolAgents"></param> /// <returns></returns> protected bool cleanUp(PoolDS.PoolDSDataTable dtAllPoolAgents) { bool result = false; int cleanUpInterval = UcConfParameters.UcCallCleanUpInterval; foreach (PoolDS.PoolDSRow row in dtAllPoolAgents.Rows) { Int32 agentId = row.agent_id; DateTime now = DateTime.Now.ToUniversalTime(); TimeSpan span = now.Subtract(row.date_accessed); TimeSpan max; if (row.is_available) { // Disable the Agent if not online (Agent in AgentPool is not renewed for too long) max = new TimeSpan(0, 0, cleanUpInterval); // seconds if (TimeSpan.Compare(span, max) > 0) { BllProxyPool.SetPoolAgentAvailable(agentId, false); result = true; } // Clean up the Agent's Incident and turn Agent available if the Incident is gone if (!row.Isincident_idNull()) { IncidentDS.IncidentDSDataTable dtIncident = BllProxyIncident.SelectIncident(row.incident_id); if (dtIncident.Rows.Count > 0) { //if ((dtIncident[0].status_id != 1) || (dtIncident[0].agent_id != agentId)) if ((dtIncident[0].status_id != 1) || ((!dtIncident[0].Isagent_idNull()) && (dtIncident[0].agent_id != agentId))) { BllProxyPool.SetPoolAgentIncident(agentId, 0); BllProxyPool.SetPoolAgentBusy(agentId, false); result = true; } } } } else { // Remove the Agent from AgentPool if not online for a week max = new TimeSpan(7, 0, 0, 0); // 7 days if (TimeSpan.Compare(span, max) > 0) { BllProxyPool.DeletePoolAgent(agentId); result = true; } } } return(result); }
private static IncidentDS.IncidentDSDataTable processData(IncidentDS.IncidentDSDataTable dt) { foreach (IncidentDS.IncidentDSRow row in dt.Rows) { row.agent_full_name = Helper.GetFullName(row.agent_first_name, row.agent_last_name); row.contact_full_name = Helper.GetFullName(row.contact_first_name, row.contact_last_name); } return(dt); }
protected void selectTransfer() { //6:Transfer IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(profileId); if (dt.Rows.Count != 0) { statusId = dt[0].status_id; } TransferIncident.IncidentId = this.profileId; TransferIncident.StatusId = this.statusId; IncidentHelper.SetIncidentStateActive(profileId); }
//------------------------------------------------------------------------------- public void SetAgentBusy(Int32 agentId, bool busy) { if (table.Contains(agentId)) { AgentAccount agentAccount = (AgentAccount)table[agentId]; //if (agentAccount.IsAvailable) //{ bool isOccupied = false; if (!busy) { IncidentDS.IncidentDSDataTable dt = BllProxyIncident.GetIncidentsByStatus(2, agentId); //2:In-Progress if (dt.Rows.Count != 0) { isOccupied = true; } } // if (isOccupied) // { // agentAccount.IsBusy = false; // } // else // { // agentAccount.IsBusy = true; // } // agentAccount.IncidentId = 0; //} if (isOccupied) { agentAccount.IsBusy = true; } else { agentAccount.IsBusy = busy; } agentAccount.IncidentId = 0; } }
protected void showVideo(Int32 incidentId) { Guid guid = new Guid(); string agentName = ""; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(incidentId); if (dt.Rows.Count != 0) { guid = dt[0].incident_guid; agentName = dt[0].agent_full_name; } String conferenceName = guid.ToString(); ((UcMasterPage)this.Master).ShowVideoChat(incidentId, conferenceName, agentName, "Agent"); uctxControls.ShowVideoChat(incidentId, conferenceName, agentName, "Agent"); }
protected void showVideo(Int32 incidentId) { Guid guid = new Guid(); string agentName = ""; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(incidentId); if (dt.Rows.Count != 0) { guid = dt[0].incident_guid; agentName = dt[0].agent_full_name; } String conferenceName = guid.ToString(); //ConferenceStartupParameters parameters = new ConferenceStartupParameters(); //parameters.VideoTransmitterMode = true; //parameters.VideoReceiverMode = false; //parameters.UseJavascript = true; //parameters.VideoWidth = 640; //parameters.VideoHeight = 480; //parameters.VideoFPS = 20; //parameters.VideoBandwidth = 56000; //parameters.VideoQuality = 80; //parameters.ScreenVideoWidth = 100; //parameters.ScreenVideoHeight = 100; //parameters.ConferenceName = conferenceName; //parameters.UserType = "Coach"; //parameters.UserName = agentName; //parameters.ShouldCreateConference = true; //parameters.ShouldStartAppShare = true; //========================================================================== //ConferenceStartupParameters parameters = ConferenceHelper.GetParametersForTransmitter(conferenceName, agentName); //========================================================================== //((UcMasterPage)this.Master).ShowVideoChat(parameters); ((UcMasterPage)this.Master).ShowVideoChat(incidentId, conferenceName, agentName, "Agent"); uctxControls.ShowVideoChat(incidentId, conferenceName, agentName, "Agent"); }
protected void Page_Load(object sender, EventArgs e) { string pathRedirect = "CallQueue.aspx"; if (agentId == 0) { pathRedirect = "profile.aspx"; } else { IncidentDS.IncidentDSDataTable dt = BllProxyIncident.GetIncidentsByStatus(1, agentId); // New if (dt.Rows.Count != 0) { pathRedirect = "CallQueue.aspx"; } else { dt = BllProxyIncident.GetIncidentsByStatus(2, agentId); // In-Progress if (dt.Rows.Count != 0) { pathRedirect = "myCalls.aspx"; } else { dt = BllProxyIncident.GetIncidentsByStatus(5, agentId); // Follow-Up if (dt.Rows.Count != 0) { pathRedirect = "followupcalls.aspx"; } pathRedirect = "CallQueue.aspx"; } } } Response.Redirect(pathRedirect); }
protected void Page_Load(object sender, EventArgs e) { object obj = Request.QueryString["id"]; if (obj != null) { Int32 i = 0; if (Int32.TryParse(obj.ToString(), out i)) { this.incidentId = i; } } if (this.incidentId != 0) { string agentName = ""; string facilityName = ""; string conferenceName = ""; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(incidentId); if (dt.Rows.Count != 0) { conferenceName = dt[0].incident_guid.ToString(); facilityName = dt[0].facility_name; agentName = dt[0].agent_full_name; } ConferenceStartupParameters parameters = ConferenceHelper.GetParametersForReceiver(conferenceName, agentName, facilityName); //ConfVideo.Parameters = parameters; } else { //BllProxyIncidentHelper.SetIncidentStatus(this.incidentId, 4); // 4:Closed Response.Redirect("default.aspx"); } }
public void Start() { string script = "window.resizeTo( 360, 650 )"; ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "SetLiveConnectSize", script, true); ltTimeSpan.Text = ""; lblAgentName.Text = ""; Guid sessionGUID; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(incidentId); if (dt.Rows.Count != 0) { sessionGUID = dt[0].incident_guid; string facilityName = dt[0].facility_name; string agentName = dt[0].agent_full_name; lblAgentName.Text = agentName; //---------------------------------------------------------------------------- String conferenceName = sessionGUID.ToString(); ConferenceStartupParameters parameters1 = ConferenceHelper.GetParametersForTransmitter(conferenceName, facilityName); ConferenceStartupParameters parameters2 = ConferenceHelper.GetParametersForReceiver(conferenceName, agentName, facilityName); this.parameters = ConferenceHelper.GetParametersForScreenCast(conferenceName, facilityName, false); Session[Utility.ConferenceStartupParametersSessionVariableName] = this.parameters; parameters1.ScreenVideoWidth = 320; parameters1.ScreenVideoHeight = 240; string tempConferenceName = Convert.ToString(1000000 + incidentId); //string tempConferenceName = conferenceName; parameters1.ConferenceName = tempConferenceName; parameters2.VideoWidth = 640; parameters2.VideoHeight = 480; parameters2.ScreenVideoWidth = 640; // 320; parameters2.ScreenVideoHeight = 480; // 240; parameters2.ConferenceName = tempConferenceName; parameters.ConferenceName = tempConferenceName; UpdateVideoEvents(tempConferenceName); UpdateScreenEvents(tempConferenceName); UpdateAudioEvents(tempConferenceName, incidentId); ViewChatControl.ConfSessionId = conferenceName; ViewChatControl.ConfSessionUser = facilityName; //---------------------------------------------------------------------------- startTime = DateTime.Now; } else { Response.Redirect("UcKioskConnect.aspx"); } }
protected void showMenu() { UcAppBasePage page = this.UcAppPage; string siteMapProviderName = "DefaultSiteMapProvider"; switch (page.UserRoleId) { case 1: //ADMIN siteMapProviderName = "RoleAdminSiteMapProvider"; break; case 2: //AGENT siteMapProviderName = "RoleAgentSiteMapProvider"; break; case 5: //SUPERVISOR siteMapProviderName = "RoleSupervisorSiteMapProvider"; break; } SiteMapDataSource smds = new SiteMapDataSource(); smds.SiteMapProvider = siteMapProviderName; smds.ShowStartingNode = false; ucSideMenu.DataSource = smds; ucSideMenu.DataBind(); SiteMapNode currentSiteMapNode = SiteMap.Providers[siteMapProviderName].CurrentNode; for (int i = 0; i < ucSideMenu.Items.Count; i++) { MenuItem menu_item = ucSideMenu.Items[i]; if (currentSiteMapNode == null) { menu_item.ChildItems.Clear(); continue; } string menu_item_text = menu_item.Text; if (currentSiteMapNode.ToString().CompareTo(menu_item_text) == 0) { menu_item.Selected = true; continue; } if (currentSiteMapNode.ParentNode == null) { menu_item.ChildItems.Clear(); continue; } if (currentSiteMapNode.ParentNode.ToString().CompareTo(menu_item_text) != 0) { menu_item.ChildItems.Clear(); continue; } menu_item.Text = "<b>" + menu_item_text + "</b>"; for (int j = 0; j < menu_item.ChildItems.Count; j++) { MenuItem menu_item_child = menu_item.ChildItems[j]; string menu_item_child_text = menu_item_child.Text; if (currentSiteMapNode.ToString().CompareTo(menu_item_child_text) == 0) { menu_item_child.Selected = true; } //--------------------------------------------------------------------------- if (page.UserRoleId == 2) //Agent { Int32 agentId = ProxyHelper.GetUserAgentId(this.UcPage.UserId); //================================================================== //IncidentDS.IncidentDSDataTable dt = BllProxyIncident.GetIncidentsByStatus(0, agentId); // ALL //DataRow[] rows = dt.Select("status_id=0"); //None //if (menu_item_child_Text == "Call Queue") // rows = dt.Select("status_id=1"); // New //else if (menu_item_child_Text == "My Calls") // rows = dt.Select("status_id=2"); // In-Progress //else if (menu_item_child_Text == "Follow-Up") // rows = dt.Select("status_id=5"); // Follow-Up //cnt = rows.Length; //if (cnt != 0) // menu_item_child_Text = menu_item_child_Text + " [" + cnt.ToString() + "]"; //================================================================== IncidentDS.IncidentDSDataTable dt = null; if (menu_item_child_text == "Call Queue") { dt = BllProxyIncident.GetIncidentQueueList(1, agentId); // New } else if (menu_item_child_text == "My Calls") { dt = BllProxyIncident.GetIncidentsByStatus(2, agentId); // In-Progress } else if (menu_item_child_text == "Follow-Up") { dt = BllProxyIncident.GetIncidentFollowUpList(5, agentId); // Follow-Up } if (dt != null) { int cnt = dt.Rows.Count; if (cnt != 0) { menu_item_child_text += " [" + cnt.ToString() + "]"; } } } //--------------------------------------------------------------------------- menu_item_child.Text = " " + menu_item_child_text; } } //////--------------------------------------------------------- //for( int i = 0; i < ucSideMenu.Items.Count; i++ ) //{ // if( currentSiteMapNode != null ) // { // string menuItemText = ucSideMenu.Items[ i ].Text; // if( currentSiteMapNode.ToString().CompareTo( menuItemText ) != 0 ) // { // if( currentSiteMapNode.ParentNode != null ) // { // if( currentSiteMapNode.ParentNode.ToString().CompareTo( menuItemText ) != 0 ) // { // ucSideMenu.Items[ i ].ChildItems.Clear(); // } // else // { // ucSideMenu.Items[ i ].Text = "<b>" + menuItemText + "</b>"; // for( int j = 0; j < ucSideMenu.Items[ i ].ChildItems.Count; j++ ) // { // string childMenuItemText = ucSideMenu.Items[ i ].ChildItems[ j ].Text; // if( currentSiteMapNode.ToString().CompareTo( childMenuItemText ) == 0 ) // { // ucSideMenu.Items[ i ].ChildItems[ j ].Selected = true; // } // //--------------------------------------------------------------------------- // if( page.UserRoleId == 2 ) //Agent // { // Int32 agentId = ProxyHelper.GetUserAgentId( this.UcPage.UserId ); // Int32 cnt = 0; // //================================================================== // //IncidentDS.IncidentDSDataTable dt = BllProxyIncident.GetIncidentsByStatus(0, agentId); // ALL // //DataRow[] rows = dt.Select("status_id=0"); //None // //if (childMenuItemText == "Call Queue") // // rows = dt.Select("status_id=1"); // New // //else if (childMenuItemText == "My Calls") // // rows = dt.Select("status_id=2"); // In-Progress // //else if (childMenuItemText == "Follow-Up") // // rows = dt.Select("status_id=5"); // Follow-Up // //cnt = rows.Length; // //if (cnt != 0) // // childMenuItemText = childMenuItemText + " [" + cnt.ToString() + "]"; // //================================================================== // IncidentDS.IncidentDSDataTable dt = null; // if( childMenuItemText == "Call Queue" ) // dt = BllProxyIncident.GetIncidentQueueList( 1, agentId ); // New // else if( childMenuItemText == "My Calls" ) // dt = BllProxyIncident.GetIncidentsByStatus( 2, agentId ); // In-Progress // else if( childMenuItemText == "Follow-Up" ) // dt = BllProxyIncident.GetIncidentFollowUpList( 5, agentId ); // Follow-Up // if( dt != null ) // { // cnt = dt.Rows.Count; // if( cnt != 0 ) // childMenuItemText = childMenuItemText + " [" + cnt.ToString() + "]"; // } // } // //--------------------------------------------------------------------------- // ucSideMenu.Items[ i ].ChildItems[ j ].Text = " " + childMenuItemText; // } // } // } // else // { // ucSideMenu.Items[ i ].ChildItems.Clear(); // } // } // else // { // ucSideMenu.Items[ i ].Selected = true; // } // } // else // { // ucSideMenu.Items[ i ].ChildItems.Clear(); // } //} }
public static IncidentDS.IncidentDSDataTable GetIncidentByGuid(Guid incidentGuid) { IncidentDS.IncidentDSDataTable dt = DalIncident.GetIncidentByGuid(incidentGuid); return(processData(dt)); }
//----------------------------------------------------------------------------- public static IncidentDS.IncidentDSDataTable SelectIncident(Int32 incidentId) { IncidentDS.IncidentDSDataTable dt = DalIncident.SelectIncident(incidentId); return(processData(dt)); }
public static IncidentDS.IncidentDSDataTable OpenFollowUpIncident(Int32 incidentId, Int32 agentId) { IncidentDS.IncidentDSDataTable dt = DalIncident.OpenFollowUpIncident(incidentId, agentId); return(processData(dt)); }
public static IncidentDS.IncidentDSDataTable GetIncidentFollowUpList(Int32 statusId, Int32 agentId) { IncidentDS.IncidentDSDataTable dt = DalIncident.GetIncidentFollowUpList(statusId, agentId); return(processData(dt)); }
public static IncidentDS.IncidentDSDataTable GetIncidentsByContact(Int32 statusId, Int32 contactId) { IncidentDS.IncidentDSDataTable dt = DalIncident.GetIncidentsByContact(statusId, contactId); return(processData(dt)); }
public void Start() { ltTimeSpan.Text = ""; lblAgentName.Text = ""; pnlDisconnect.Visible = true; pnlDisconnectConfirm.Visible = false; pnlNew.Visible = true; pnlContent.Visible = false; pnlScreenCast.Visible = false; pnlAppShareSend.Visible = false; pnlAppShareReceive.Visible = false; Guid sessionGUID; IncidentDS.IncidentDSDataTable dt = BllProxyIncident.SelectIncident(incidentId); if (dt.Rows.Count != 0) { sessionGUID = dt[0].incident_guid; string facilityName = dt[0].facility_name; string agentName = dt[0].agent_full_name; lblAgentName.Text = agentName; //---------------------------------------------------------------------------- String conferenceName = sessionGUID.ToString(); ConferenceStartupParameters parameters1 = ConferenceHelper.GetParametersForTransmitter(conferenceName, facilityName); ConferenceStartupParameters parameters2 = ConferenceHelper.GetParametersForReceiver(conferenceName, agentName, facilityName); this.parameters = ConferenceHelper.GetParametersForScreenCast(conferenceName, facilityName, false); Session[Utility.ConferenceStartupParametersSessionVariableName] = this.parameters; parameters1.ScreenVideoWidth = 320; parameters1.ScreenVideoHeight = 240; string tempConferenceName = Convert.ToString(1000000 + incidentId); //string tempConferenceName = conferenceName; parameters1.ConferenceName = tempConferenceName; parameters2.VideoWidth = 640; parameters2.VideoHeight = 480; parameters2.ScreenVideoWidth = 640; // 320; parameters2.ScreenVideoHeight = 480; // 240; parameters2.ConferenceName = tempConferenceName; parameters.ConferenceName = tempConferenceName; UpdateVideoEvents(tempConferenceName); UpdateScreenEvents(tempConferenceName); UpdateAudioEvents(tempConferenceName); //this.startVideoTransmitter(parameters1); // !!!!! //this.startVideoReceiver(parameters2); //this.startCreenCast(this.parameters); //-- //TextChatControl.ConfSessionId = conferenceName; //TextChatControl.ConfSessionUser = facilityName; ViewChatControl.ConfSessionId = conferenceName; ViewChatControl.ConfSessionUser = facilityName; //-- //---------------------------------------------------------------------------- startTime = DateTime.Now; } else { Response.Redirect("UcKioskConnect.aspx"); } }
protected enumAgentStatus updateAgentStatus() { enumAgentStatus agentStatus = enumAgentStatus.NotDefined; if (this.active) { pnlNotRegistered.Visible = false; pnlIncomingCall.Visible = false; pnlUnavailable.Visible = false; pnlBusy.Visible = false; pnlConnected.Visible = false; pnlAvailable.Visible = false; btnRegister.Visible = false; btnTakeCall.Visible = false; btnSetAvailable.Visible = false; btnReset.Visible = false; btnUnRegister.Visible = false; if (agentId == 0) { // Not Defined agentStatus = enumAgentStatus.NotDefined; pnlNotRegistered.Visible = true; ltMessage.Text = "Not registered"; btnRegister.Visible = true; } else { PoolDS.PoolDSDataTable dt = BllProxyPool.SelectPoolAgent(agentId); if (dt.Rows.Count != 0) { if (dt[0].is_available) { if (dt[0].is_busy) { if (!dt[0].Isincident_idNull()) { // Incoming Call agentStatus = enumAgentStatus.IncomingCall; Int32 incidentId = dt[0].incident_id; IncidentDS.IncidentDSDataTable dtIncident = BllProxyIncident.SelectIncident(incidentId); string callName = ""; if (!dtIncident[0].Isfacility_nameNull()) { callName = dtIncident[0].facility_name; } else { if (!dtIncident[0].Iscontact_full_nameNull()) { callName = dtIncident[0].contact_full_name; } else { callName = "UNKNOWN"; } } // Incident Assigned pnlIncomingCall.Visible = true; ltMessage.Text = "You’ve got a call : " + callName; btnTakeCall.Visible = true; } else { // Busy agentStatus = enumAgentStatus.Busy; if (this.checkOnline()) { pnlConnected.Visible = true; pnlBusy.Visible = false; ltMessage.Text = "Online"; } else { pnlBusy.Visible = true; pnlConnected.Visible = false; ltMessage.Text = "Offline"; btnReset.Visible = true; } } } else { // Available agentStatus = enumAgentStatus.Available; pnlAvailable.Visible = true; ltMessage.Text = "Available"; btnUnRegister.Visible = true; } } else { // Off agentStatus = enumAgentStatus.Unavailable; if (this.checkOnline()) { pnlConnected.Visible = true; ltMessage.Text = "Online"; } else { pnlUnavailable.Visible = true; ltMessage.Text = "Unavailable"; btnSetAvailable.Visible = true; } } } else { // Not Defined agentStatus = enumAgentStatus.NotDefined; pnlNotRegistered.Visible = true; ltMessage.Text = "Not registered"; btnRegister.Visible = true; } } } return(agentStatus); }