示例#1
0
        //private frmDetail m_frmDetail;
        public void GetDepartmentList()
        {
            try
            {
                OracleParameter par1 = new OracleParameter("@result", OracleType.Cursor);
                par1.Direction = ParameterDirection.Output;
                DataSet ds = DS_SqlHelper.ExecuteDataSet("EMRQCMANAGER.usp_QcmanagerDepartmentlist", new OracleParameter[] { par1 }, CommandType.StoredProcedure);
                m_pageSouce = ds.Tables[0];

                gridControldepartment.DataSource = m_pageSouce;
                if (m_pageSouce.Rows.Count == 0)
                {
                    MessageBox.Show("无数据");
                }
            }
            catch (Exception)
            {
                throw;
            }
        }
示例#2
0
 /// <summary>
 /// xll 2013-06-25
 /// 查询数据
 /// 将病人信息 时段数据和日数据整合到一个DataTable中来
 /// </summary>
 /// <returns></returns>
 public DataTable SearchInpatentDataZheHe(string hour, string date)
 {
     try
     {
         string         departcode = CommonObjects.CurrentUser.CurrentDeptId;
         string         wardcode   = CommonObjects.CurrentUser.CurrentWardId;
         SqlParameter[] sqlParams  = new SqlParameter[]
         {
             new SqlParameter("@departCode", SqlDbType.VarChar, 50),
             new SqlParameter("@wardcode", SqlDbType.VarChar, 50),
             new SqlParameter("@Timelot", SqlDbType.VarChar, 50),
             new SqlParameter("@TimelotSave", SqlDbType.VarChar, 50),
             new SqlParameter("@date", SqlDbType.NVarChar, 50),
             new SqlParameter("@result", SqlDbType.Structured, int.MaxValue),
             new SqlParameter("@result1", SqlDbType.Structured, int.MaxValue),
             new SqlParameter("@result2", SqlDbType.Structured, int.MaxValue)
         };
         sqlParams[0].Value = departcode;
         sqlParams[1].Value = wardcode;
         sqlParams[2].Value = hour;
         sqlParams[3].Value = timelotSave;//天数据存为2时段
         string surveyDate = m_CurrDatetime;
         sqlParams[4].Value     = surveyDate;
         sqlParams[5].Direction = ParameterDirection.Output;
         sqlParams[6].Direction = ParameterDirection.Output;
         sqlParams[7].Direction = ParameterDirection.Output;
         DataSet   dataSet     = DS_SqlHelper.ExecuteDataSet("EMR_NURSE_STATION.usp_GetPatientsOfDept2", sqlParams, CommandType.StoredProcedure);
         DataTable dtInpatient = new DataTable();
         dtInpatient = ConvertToDataTable(dataSet);
         dtInpatient.DefaultView.Sort = "BED asc ";
         return(dtInpatient);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }