Example #1
0
        private void RefreshGUI()
        {
            this.RefreshApplicationStatusCnt();


            string strFilterStatus = "";

            if (this.hidFilter.Value.Trim() != string.Empty)
            {
                string type = this.hidFilter.Value;

                // Maybe different role will have the different status list
                // This is for the Patient
                if (type == "1")
                {
                    strFilterStatus = "0,2,5";
                }
                else if (type == "2")
                {
                    strFilterStatus = "99";
                }
            }
            DataSet ds = WorklistDAL.GetWorklist(strFilterStatus);

            ds.Tables[0].Columns.Add("CommandText");
            ds.Tables[0].Columns.Add("StatusText");
            ds.Tables[0].Columns.Add("hospitalList");
            foreach (DataRow item in ds.Tables[0].Rows)
            {
                item["CommandText"] = "查看";


                #region Gender
                string gender = item["gender"].ToString();
                if (gender == "")
                {
                    item["gendertext"] = "未知";
                }
                else if (gender == "0")
                {
                    item["gendertext"] = "未知";
                }
                else if (gender == "1")
                {
                    item["gendertext"] = "女";
                }
                else if (gender == "2")
                {
                    item["gendertext"] = "男";
                }
                #endregion

                #region Status
                string Status = item["Status"].ToString();
                item["StatusText"] = Status; // Default
                if (Status == "0")
                {
                    item["StatusText"] = "未提交";
                }
                else if (Status == "1")
                {
                    item["StatusText"] = "已提交";
                }
                else if (Status == "2")
                {
                    item["StatusText"] = "已接受";
                }
                else if (Status == "3")
                {
                    item["StatusText"] = "已付初审费";
                }
                else if (Status == "4")
                {
                    item["StatusText"] = "初审中";
                }
                else if (Status == "5")
                {
                    item["StatusText"] = "已初审";
                }
                else if (Status == "6")
                {
                    item["StatusText"] = "已付会诊费";
                }
                else if (Status == "7")
                {
                    item["StatusText"] = "会诊中";
                }
                else if (Status == "8")
                {
                    item["StatusText"] = "已出结论";
                }
                else if (Status == "9")
                {
                    item["StatusText"] = "已翻译";
                }
                else if (Status == "99")
                {
                    item["StatusText"] = "已完成";
                }
                else if (Status == "100")
                {
                    item["StatusText"] = "已拒绝";
                }
                #endregion

                #region HospitalList
                string        strAPPGuid   = item["guid"].ToString();
                List <string> lstHospital  = new List <string>();
                DataRow[]     hospitalRows = ds.Tables[1].Select(string.Format("consult_application_guid='{0}'", strAPPGuid));
                foreach (var row in hospitalRows)
                {
                    if (row["hospital_name"].ToString().Trim().Length > 0)
                    {
                        lstHospital.Add(row["hospital_name"].ToString().Trim());
                    }
                }
                item["hospitalList"] = string.Join(",", lstHospital.ToArray());
                #endregion
            }
            this.GridView1.PageIndex  = 0;
            this.GridView1.DataSource = ds.Tables[0];
            this.GridView1.DataBind();

            Session["gridData"] = ds;
        }
Example #2
0
        /// <summary>
        /// 状态
        //0—未提交(开始用户阶段)
        //1—已提交
        //2—已接受(待付初审费)
        //3—已付初审费
        //4—初审中
        //5—已初审(待付会诊费)
        //6—已付会诊费
        //7—会诊中
        //8—已出结论
        //9—已翻译
        //99—已完成

        /// </summary>
        private void RefreshApplicationStatusCnt()
        {
            this.lblStatus_0.Text = WorklistDAL.GetApplicationCount("");
            this.lblStatus_1.Text = WorklistDAL.GetApplicationCount("0,2,5");
            this.lblStatus_2.Text = WorklistDAL.GetApplicationCount("99");
        }