private bool SaveForm(int patientId, int providerId) { bool objReturn = false; //if (ServiceInterfaceManager.REFERRAL_PATIENT_EXISTS(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, patientId)) //{ // lblResult.Text = "The selected Patient has already been added to this Registry.<br /><br />"; //} //else //{ int referralId = ServiceInterfaceManager.REFERRAL_SAVE_MANUAL(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, patientId, providerId); if (referralId > 0) { REFERRAL r = ServiceInterfaceManager.REFERRAL_GET(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, referralId); if (r != null) { UserSession.CurrentRegistryId = r.STD_REGISTRY_ID; UserSession.CurrentReferralId = r.REFERRAL_ID; UserSession.CurrentPatientId = r.PATIENT_ID; UserSession.CurrentProviderId = r.PROVIDER_ID.GetValueOrDefault(); } objReturn = true; } else { lblResult.Text = "An error occurred while attempting to save, please try again.<br /><br />"; } //} return(objReturn); }
protected void BtnNext_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { bool blnContinue = false; string strResult = string.Empty; if (pnlUdf.Visible) { blnContinue = SaveForm(ref strResult); } else { blnContinue = true; } if (blnContinue) { Response.Redirect("~/Cohorts/Workstream.aspx", false); } else { lblResult.Text = strResult; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void LinkEdit_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { LinkButton lb = (LinkButton)sender; if (lb != null) { int id = 0; if (int.TryParse(lb.CommandArgument, out id)) { AdminUser.LoadForm(id); pnlUsers.Visible = false; pnlUser.Visible = true; } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected override void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { ServiceInterfaceManager.LogInformation("PAGE_LOAD", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); } try { base.Page_Load(sender, e); if (UserSession == null || UserSession.CurrentRegistryId <= 0) { Response.Redirect("~/Default.aspx", false); } else { LoadForm(UserSession.CurrentRegistryId); } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
public void LoadForm(int id) { ResetForm(); STD_REGISTRY registry = ServiceInterfaceManager.STD_REGISTRY_GET(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, id); if (registry != null) { hideRegistryId.Value = registry.ID.ToString(); txtRegistryName.Text = registry.NAME; txtRegistryCode.Text = registry.CODE; txtRegistryDescription.Text = registry.DESCRIPTION_TEXT; LoadUserLists(); if (registry.REGISTRY_OWNER > 0) { listRegistryOwner.SelectedValue = registry.REGISTRY_OWNER.ToString(); } if (registry.REGISTRY_ADMINISTRATOR > 0) { listRegistryAdministrator.SelectedValue = registry.REGISTRY_ADMINISTRATOR.ToString(); } if (registry.REGISTRY_SUPPORT_CONTACT > 0) { listSupportContact.SelectedValue = registry.REGISTRY_SUPPORT_CONTACT.ToString(); } } }
protected void ListCategories_SelectedIndexChanged(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { List <REGISTRY_COHORT_DATA> cohortDataList = Cohort_Data_List; if (cohortDataList != null) { foreach (ListItem li in listCategories.Items) { foreach (REGISTRY_COHORT_DATA rcd in cohortDataList) { if (li.Value == rcd.STD_REGISTRY_COHORT_TYPE_ID.ToString()) { rcd.UPDATED = DateTime.Now; rcd.UPDATEDBY = HttpContext.Current.User.Identity.Name; rcd.SELECTED_FLAG = li.Selected; break; } } } Cohort_Data_List = cohortDataList; } CheckAll(); } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void BtnPreview_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { List <REGISTRY_COHORT_DATA> cohorts = Cohort_Data_List; if (cohorts != null) { cohorts = cohorts.Where(data => data.SELECTED_FLAG == true).ToList(); int PopCount = ServiceInterfaceManager.REGISTRY_COHORT_DATA_GET_PREVIEW_COUNT(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, cohorts); if (PopCount > 0) { lblRecordCount.Text = PopCount.ToString() + " records found for selected parameters<br /><br />"; } else { lblRecordCount.Text = "Currently no Referrals are available for selected parameters<br /><br />"; } mpePreview.Show(); } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void GridActiveDirectory_Sorting(object sender, GridViewSortEventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { if (SORT_DIRECTION == "ASC") { SORT_DIRECTION = "DESC"; } else { SORT_DIRECTION = "ASC"; } string sortExpression = string.Empty; if (!string.IsNullOrEmpty(e.SortExpression)) { sortExpression += e.SortExpression + " " + SORT_DIRECTION; } SORT_EXPRESSION = sortExpression; DoSearch(); } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
private void DoSearch() { string strSearch = string.Empty; if (!string.IsNullOrEmpty(txtSearchLastName.Text)) { strSearch += txtSearchLastName.Text.Trim(); } if (!string.IsNullOrEmpty(txtSearchFirstName.Text)) { if (!string.IsNullOrEmpty(strSearch)) { strSearch += ", "; } strSearch += txtSearchFirstName.Text.Trim(); } if (string.IsNullOrEmpty(strSearch)) { lblResult.Text = "Please enter a valid last name and/or first name, no special characters are allowed<br /><br />"; } string searchColumn = ddlSearch.SelectedValue; string searchText = txtSearch.Text; ActiveDirectory = ServiceInterfaceManager.USERS_GET_ALL_BY_AD(ApplicationSession.DomainNames, strSearch, searchColumn, searchText, SORT_EXPRESSION); gridActiveDirectory.DataSource = ActiveDirectory; gridActiveDirectory.DataBind(); }
protected void BtnSave_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { string strResult = string.Empty; if (SaveForm(ref strResult)) { ResetForm(); OnSave(e); } else { pnlSearch.Visible = pnlResult.Visible = false; pnlUserInfo.Visible = true; lblResult.Text = strResult; } } catch (Exception ex) { if (ex.Message.ToLower().Contains("already exists")) { lblResult.Text = "The User you are saving already exists<br /><br />"; } else { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } } }
protected void ListRegistries_SelectedIndexChanged(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { rblRegistryRoles.Items.Clear(); rblRegistryRoles.DataBind(); List <USER_ROLES> userRoles = UserRoles; if (userRoles != null && rblRegistryRoles.Items != null) { foreach (USER_ROLES userRole in userRoles) { foreach (ListItem li in rblRegistryRoles.Items) { if (userRole.STD_ROLE_ID.ToString() == li.Value && !userRole.INACTIVE_FLAG) { rblRegistryRoles.SelectedValue = li.Value; } } } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void GridActiveDirectory_SelectedIndexChanged(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { if (gridActiveDirectory.SelectedIndex > -1) { USERS user = new USERS(); user.USERNAME = gridActiveDirectory.SelectedRow.Cells[1].Text.Replace(" ", ""); user.FIRST_NAME = gridActiveDirectory.SelectedRow.Cells[2].Text.Replace(" ", ""); user.LAST_NAME = gridActiveDirectory.SelectedRow.Cells[3].Text.Replace(" ", ""); user.FULL_NAME = user.FIRST_NAME + " " + user.LAST_NAME; user.EMAIL_ADDRESS = gridActiveDirectory.SelectedRow.Cells[4].Text.Replace(" ", ""); user.JOB_TITLE = gridActiveDirectory.SelectedRow.Cells[5].Text.Replace(" ", ""); user.TELEPHONE_NUMBER = gridActiveDirectory.SelectedRow.Cells[6].Text.Replace(" ", ""); user.FAX_NUMBER = gridActiveDirectory.SelectedRow.Cells[7].Text.Replace(" ", ""); LoadForm(user); } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void BtnSearchCancel_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { if (string.IsNullOrEmpty(txtUsername.Text)) { pnlResult.Visible = false; ResetForm(); OnCancel(e); } else { pnlSearch.Visible = false; pnlUserInfo.Visible = true; } OnSearchCancel(e); } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected virtual void Page_Load(object sender, EventArgs e) { int id = 0; if (!Page.IsPostBack) { if (Request.QueryString["id"] != null) { if (int.TryParse(Request.QueryString["id"].ToString(), out id)) { UserSession.CurrentRegistryId = id; } } if (Request.QueryString["path"] != null) { userSession.CurrentReportPath = Request.QueryString["path"]; } if (UserSession.CurrentRegistryId > 0) { STD_REGISTRY r = ServiceInterfaceManager.STD_REGISTRY_GET(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, UserSession.CurrentRegistryId); if (r != null) { UserSession.CurrentRegistry = r.NAME; UserSession.CurrentRegistryId = r.ID; } } } }
protected void BtnMvi_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { if (UserSession.CurrentRegistryId > 0 && UserSession.CurrentPatientId > 0) { bool objReturn = ServiceInterfaceManager.PRPA_IN201305UV02(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, UserSession.CurrentPatientId); if (objReturn) { LoadForm(); gridRegistry.DataBind(); lblResult.Text = "An MVI match was found and this patient's information has been updated<br /><br />"; } else { lblResult.Text = "An error occurred or an MVI match was not found. This patient's information has not been updated<br /><br />"; } } else { lblResult.Text = "An unexpected error occurred. Please try again or return to the Referrals/Patients page to select the patient again.<br /><br />"; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void LinkSelectPatient_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { UserSession.RefreshCommon(); LinkButton lb = (LinkButton)sender; if (lb != null) { int id = 0; int.TryParse(lb.CommandArgument, out id); if (id > 0) { UserSession.CurrentPatientId = id; Response.Redirect("~/Common/Patient.aspx", false); } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void BtnSave_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { bool cohortsSaved = SaveCohorts(); //Always attempt to save the Cohort parameters above //but don't overwrite other error messages (lblResult.Text) if (string.IsNullOrEmpty(lblResult.Text)) { if (cohortsSaved) { lblResult.Text = "Save successful<br /><br />"; } else { lblResult.Text = "Error saving Cohort parameters, please try again<br /><br />"; } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void LinkDelete_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { UserSession.RefreshCommon(); LinkButton lb = (LinkButton)sender; if (lb != null) { int id = 0; int.TryParse(lb.CommandArgument, out id); if (id > 0) { if (ServiceInterfaceManager.WKF_CASE_ACTIVITY_DELETE(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, id)) { lblResult.Text = "Delete successful<br /><br />"; } else { lblResult.Text = "Error deleting Activity, please try again<br /><br />"; } } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
private void LoadForm() { SETTINGS setting = null; setting = ServiceInterfaceManager.SETTINGS_GET_REGISTRYNAME(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, "EtlScheduleManual"); if (setting != null) { rblScheduleManual.SelectedValue = setting.VALUE; } setting = ServiceInterfaceManager.SETTINGS_GET_REGISTRYNAME(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, "EtlScheduleAuto"); if (setting != null) { rblScheduleAuto.SelectedValue = setting.VALUE; } setting = ServiceInterfaceManager.SETTINGS_GET_REGISTRYNAME(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, "EtlScheduleAutoTime"); if (setting != null) { listScheduleAutoTime.SelectedValue = setting.VALUE; } if (rblScheduleAuto.SelectedIndex > 0) { listScheduleAutoTime.Enabled = true; } List <REGISTRY_COHORT_DATA> cohortDataList = Cohort_Data_List; if (cohortDataList != null) { foreach (REGISTRY_COHORT_DATA rcd in cohortDataList) { if (rcd.STD_REGISTRY_COHORT_TYPES != null && rcd.STD_REGISTRY_COHORT_TYPES.CODE == "DOBMIN") { if (!string.IsNullOrEmpty(rcd.VALUE)) { DateTime dtMin = DateTime.MinValue; if (DateTime.TryParse(rcd.VALUE, out dtMin)) { txtDobMin.Text = dtMin.ToString("MM/dd/yyyy"); } } } else if (rcd.STD_REGISTRY_COHORT_TYPES != null && rcd.STD_REGISTRY_COHORT_TYPES.CODE == "DOBMAX") { if (!string.IsNullOrEmpty(rcd.VALUE)) { DateTime dtMax = DateTime.MinValue; if (DateTime.TryParse(rcd.VALUE, out dtMax)) { txtDobMax.Text = dtMax.ToString("MM/dd/yyyy"); } } } } SelectSource(); } }
protected void LinkActivityAdd_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { if (UserSession.CurrentWorkstreamId > 0) { ResetForm(); pnlActivities.Visible = false; pnlActivity.Visible = true; } else { pnlSelectWorkstream.Visible = true; pnlActivities.Visible = false; pnlActivity.Visible = false; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void LinkSelect_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { LinkButton lb = (LinkButton)sender; if (lb != null) { int id = 0; if (int.TryParse(lb.CommandArgument, out id)) { REFERRAL r = ServiceInterfaceManager.REFERRAL_GET(HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId, id); if (r != null) { UserSession.CurrentRegistryId = r.STD_REGISTRY_ID; UserSession.CurrentReferralId = r.REFERRAL_ID; UserSession.CurrentPatientId = r.PATIENT_ID; UserSession.CurrentProviderId = r.PROVIDER_ID.GetValueOrDefault(); Response.Redirect("~/Common/Referral.aspx", false); } } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void DsMenuItems_Selecting(object sender, ObjectDataSourceSelectingEventArgs e) { try { int roleId = 0; int.TryParse(listRoles.SelectedValue, out roleId); int id = 0; int.TryParse(listRegistries.SelectedValue, out id); if (id > 0) { string searchColumn = ddlMenuItems.SelectedValue; string searchText = txtMenuItems.Text; e.InputParameters.Clear(); e.InputParameters.Add("CURRENT_USER", HttpContext.Current.User.Identity.Name); e.InputParameters.Add("CURRENT_REGISTRY_ID", id); e.InputParameters.Add("STD_ROLE_ID", roleId); e.InputParameters.Add("SEARCH_COLUMN", searchColumn); e.InputParameters.Add("SEARCH_TEXT", searchText); } else { e.Cancel = true; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void BtnBack_Click(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { bool blnContinue = false; string strResult = string.Empty; blnContinue = SaveForm(ref strResult); if (blnContinue) { UserSession.CurrentRegistryId = 0; UserSession.CurrentSurveyId = 0; ResetForm(); pnlRegistries.Visible = true; pnlRegistry.Visible = false; btnNext.Visible = false; } else { lblResult.Text = strResult; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void ListRegistries_SelectedIndexChanged(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { int id = 0; int.TryParse(listRegistries.SelectedValue, out id); if (id > 0) { UserSession.CurrentRegistryId = id; pnlMenuItems.Visible = true; pnlMenuItem.Visible = false; listRoles.DataBind(); gridMenuItems.DataBind(); listRoleName.DataBind(); } else { UserSession.CurrentRegistryId = 0; pnlMenuItems.Visible = false; pnlMenuItem.Visible = false; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected override void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { ServiceInterfaceManager.LogInformation("PAGE_LOAD", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); } try { base.Page_Load(sender, e); lblResult.Text = string.Empty; if (UserSession == null || UserSession.CurrentRegistryId <= 0) { Response.Redirect("~/Cohorts/Default.aspx", false); } else { //BuildCohortsMenu(); if (!Page.IsPostBack) { txtUdfDescription.Attributes.Add("maxlength", txtUdfDescription.MaxLength.ToString()); pnlUdfs.Visible = true; pnlUdf.Visible = false; } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected void DsRoleName_Selecting(object sender, ObjectDataSourceSelectingEventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { int id = 0; int.TryParse(listRegistries.SelectedValue, out id); if (id > 0) { e.InputParameters.Clear(); e.InputParameters.Add("CURRENT_USER", HttpContext.Current.User.Identity.Name); e.InputParameters.Add("CURRENT_REGISTRY_ID", id); } else { e.Cancel = true; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
protected override void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { ServiceInterfaceManager.LogInformation("PAGE_LOAD", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); } try { base.Page_Load(sender, e); //BuildAdminMenu(); lblResult.Text = string.Empty; if (!Page.IsPostBack) { pnlUsers.Visible = true; pnlUser.Visible = false; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }
private void CreateIndex() { string pathSeparator = System.IO.Path.DirectorySeparatorChar.ToString(); string indexPath = HttpContext.Current.Request.PhysicalPath.Replace("Default.aspx", "Indexes" + pathSeparator); string searchPath = indexPath.Replace("Indexes" + pathSeparator, ""); Directory directory = null; Analyzer analyzer = null; IndexWriter writer = null; System.IO.TextReader reader = null; try { directory = FSDirectory.Open(new System.IO.DirectoryInfo(indexPath)); analyzer = new StandardAnalyzer(Lucene.Net.Util.Version.LUCENE_30); writer = new IndexWriter(directory, analyzer, true, IndexWriter.MaxFieldLength.UNLIMITED); string[] filePath = System.IO.Directory.GetFiles(searchPath); foreach (string sPath in filePath) { if (!sPath.ToLower().Contains("default.aspx")) { reader = new System.IO.StreamReader(sPath, System.Text.Encoding.Default); Document doc = new Document(); doc.Add(new Field("Contents", reader)); doc.Add(new Field("FileName", sPath, Field.Store.YES, Field.Index.ANALYZED)); writer.AddDocument(doc); writer.Optimize(); writer.Commit(); if (reader != null) { reader.Close(); reader.Dispose(); reader = null; } } } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, 0); throw ex; } finally { if (writer != null) { //writer.Close(); writer.Dispose(); writer = null; } } }
private void LoadForm() { ResetForm(); STD_REGISTRY systemRegistry = ApplicationSession.SystemRegistry; AppSettings appSettings = ServiceInterfaceManager.APPSETTINGS_GET(HttpContext.Current.User.Identity.Name, systemRegistry.ID); if (appSettings != null) { txtSqlCommandTimeout.Text = appSettings.SqlCommandTimeout.ToString(); txtLogFileSize.Text = appSettings.LogFileSize.ToString(); txtLogFileArchive.Text = appSettings.LogFileArchive.ToString(); listLogErrors.SelectedValue = appSettings.LogErrors.ToString().ToLower(); listLogInformation.SelectedValue = appSettings.LogInformation.ToString().ToLower(); listLogTiming.SelectedValue = appSettings.LogTiming.ToString().ToLower(); listDatabaseLogEnabled.SelectedValue = appSettings.DatabaseLogEnabled.ToString().ToLower(); //listEventLogEnabled.SelectedValue = appSettings.EventLogEnabled.ToString().ToLower(); listFileLogEnabled.SelectedValue = appSettings.FileLogEnabled.ToString().ToLower(); txtFileLogPath.Text = appSettings.FileLogPath.ToString(); listMviEnabled.SelectedValue = appSettings.MviEnabled.ToString().ToLower(); listMviProcessingCode.SelectedValue = appSettings.MviProcessingCode.ToString().ToUpper(); txtMviCertName.Text = appSettings.MviCertName.ToString(); txtMviServiceUrl.Text = appSettings.MviServiceUrl.ToString(); txtReportBuilderPath.Text = appSettings.ReportBuilderPath.ToString(); txtReportServerUrl.Text = appSettings.ReportServerUrl.ToString(); txtReportServicePath.Text = appSettings.ReportServicePath.ToString(); txtEtlSchedule.Text = appSettings.EtlSchedule; txtEtlRetryAttempts.Text = appSettings.EtlRetryAttempts.ToString(); txtEtlTimeBetweenAttempts.Text = appSettings.EtlTimeBetweenAttempts.ToString(); txtHomePageText.Text = appSettings.HomePageText; } }
protected void PatientReferral_SelectClicked(object sender, EventArgs e) { ServiceInterfaceManager.LogInformation("POSTBACK_EVENT", String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); try { int id = PatientReferral.ResultId; if (id > 0) { if (PatientReferral.SearchType == "PROVIDER") { LoadProvider(id); } else if (PatientReferral.SearchType == "PATIENT") { LoadPatient(id); } pnlProviders.Visible = false; pnlSearch.Visible = false; pnlProvider.Visible = true; } } catch (Exception ex) { ServiceInterfaceManager.LogError(ex.Message, String.Format("{0}.{1}", System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.FullName, System.Reflection.MethodBase.GetCurrentMethod().Name), HttpContext.Current.User.Identity.Name, UserSession.CurrentRegistryId); throw ex; } }