示例#1
0
    protected override void Page_Load(object sender, System.EventArgs e)
    {
        base.Page_Load(sender, e);

        if (PermissionManager.HasPermission("PatientEdAdmin"))
        {
            ManageMaterialMenu.Visible = true;
        }

        // Forward if needed
        string section = Request.QueryString["goToSection"];

        if ((Request.QueryString["findClicked"] != null && Request.QueryString["findClicked"].Equals("true")) || (Request.QueryString["epid"] != null))
        {
            MainWindow.Attributes["src"] = "AssembleContent.aspx?usePtInSession=true";
        }
        else if (!string.IsNullOrEmpty(section))
        {
            if (section == "AssembleContent")
            {
                MainWindow.Attributes["src"] = "AssembleContent.aspx?usePtInSession=false";
                // We need to clear Session
                SessionHandler sh = new SessionHandler(Session);
                sh.ClearCurrentPatient();                 // NOTE: why isn't this working?
            }
        }
        SetPopUpDisplay();
    }
示例#2
0
 /// <summary>
 /// Rebuilds dataset chanrt on selected chart change
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 protected void BuildDataset(object sender, EventArgs e)
 {
     if (!string.IsNullOrEmpty(UserDataSets.SelectedValue))
     {
         int datasetId = int.Parse(Security.CustomCryptoHelper.Decrypt(UserDataSets.SelectedValue));
         // set session
         SetSessionDataset(datasetId);
         // clear patient
         SessionHandler sh = new SessionHandler(Session);
         sh.ClearCurrentPatient();
         // redirect
         Response.Redirect("Dashboard.aspx");
     }
 }
示例#3
0
        /// <summary>
        /// Ajax method for processing callback to set new session dataset
        /// </summary>
        /// <param name="e"></param>
        protected void SetNewClientSession(Caisis.UI.ClientScript.Ajax.CaisisAjaxEventArgs e)
        {
            bool   datasetUpdated  = false;
            string clientDatasetId = e.ClientParam;

            if (!string.IsNullOrEmpty(clientDatasetId))
            {
                int datasetId = int.Parse(Security.CustomCryptoHelper.Decrypt(clientDatasetId));
                // udpate dataset
                SetSessionDataset(datasetId);
                // clear patient
                SessionHandler sh = new SessionHandler(Session);
                sh.ClearCurrentPatient();

                datasetUpdated = true;
            }
            e.ReturnValue = datasetUpdated.ToString().ToLower();
        }