Пример #1
0
        protected override void Page_Load(object sender, System.EventArgs e)
        {
            base.Page_Load(sender, e);
            BuildChemoTx(this._patientId, "", "Dynamic");
            base.SetTitle(ComponentTitle);

            LookupCodeDa lpcDa  = new LookupCodeDa();
            DataTable    lpcDt  = lpcDa.GetLookupCodes("MedTxAgent");
            DataTable    lpcDt2 = lpcDa.GetLookupCodes("MedTxType");

            SetNewAgentLookupCode(MedTxAgent_6, lpcDt, MedTxType_6, lpcDt2);
            SetNewAgentLookupCode(MedTxAgent_7, lpcDt, MedTxType_7, lpcDt2);
            SetNewAgentLookupCode(MedTxAgent_8, lpcDt, MedTxType_8, lpcDt2);
            SetNewAgentLookupCode(MedTxAgent_9, lpcDt, MedTxType_9, lpcDt2);
            SetNewAgentLookupCode(MedTxAgent_10, lpcDt, MedTxType_10, lpcDt2);
        }
Пример #2
0
        protected void BuildCommonProblems()
        {
            LookupCodeDa lDa = new LookupCodeDa();
            DataTable    lDt = lDa.GetLookupCodes("Problem");

            if (lDt.Rows.Count > 0)
            {
                CommonProblems.DataSource = lDt.DefaultView;
                CommonProblems.DataBind();
            }
        }
Пример #3
0
        protected void BuildCommonPlans()
        {
            LookupCodeDa lDa = new LookupCodeDa();
            DataTable    lDt = lDa.GetLookupCodes("ProblemPlan,Disease,Osteoporosis");

            if (lDt.Rows.Count > 0)
            {
                CommonPlans.DataSource = lDt.DefaultView;
                CommonPlans.DataBind();
            }
        }
Пример #4
0
        protected void BuildPhysicianJSRepeater(string PhysicianType, Repeater PhysicianRepeater)
        {
            string LkpString = "OpSurgeon,PhysicianType," + PhysicianType;


            LookupCodeDa lDa = new LookupCodeDa();
            DataTable    lDt = lDa.GetLookupCodes(LkpString);

            if (lDt.Rows.Count > 0)
            {
                PhysicianRepeater.DataSource = lDt.DefaultView;
                PhysicianRepeater.DataBind();
            }
        }
Пример #5
0
/*      old way
 *      protected void BuildErectileFunction(int minNumRowsToShow, int minNumBlankRows)
 *              {
 *                      if (patientID != 0)
 *                      {
 *
 *                              DataTable eDt = ErectileFuntionDataTable();
 *
 *                              if (eDt != null && eDt.Columns.Count > 0)
 *                              {
 *                                      int numBlankRows = minNumRowsToShow - eDt.Rows.Count;
 *
 *                                      if (numBlankRows < minNumBlankRows)
 *                                      {
 *                                              numBlankRows = minNumBlankRows;
 *                                      }
 *
 *                                      for (int i=0; i<numBlankRows; i++)
 *                                      {
 *                                              DataRow blankRow = eDt.NewRow();
 *                                              eDt.Rows.Add(blankRow);
 *                                      }
 *                                      erectileFunction.DataSource = eDt.DefaultView;
 *                              }
 *                              else
 *                              {
 *                                      erectileFunction.DataSource = BlankErectileFunction(minNumRowsToShow).DefaultView;
 *                              }
 *
 *                      }
 *                      else
 *                      {
 *                              erectileFunction.DataSource = BlankErectileFunction(minNumRowsToShow).DefaultView;
 *                      }
 *
 *                      erectileFunction.DataBind();
 *
 *              }
 *
 *
 *              // create the datatable for erectile function.  Currently hits the database a lot - once for
 *              // each table cell populated on the form.  Also pulls column names from the lookup codes.  - jf
 *              protected DataTable ErectileFuntionDataTable()
 *              {
 *                      SurveyDa sDa = new SurveyDa();
 *
 *                      DataSet SurveyIdDs = sDa.FormGetSurveysByType(this.patientID, this._formName, "Dynamic", "Mulhall Erection");
 *                      DataTable eDt = new DataTable();
 *
 *                      if (SurveyIdDs.Tables.Count > 0 && SurveyIdDs.Tables[0].Rows.Count > 0)
 *                      {
 *
 *
 *
 *                              LookupCodeDa lDa = new LookupCodeDa();
 *                              DataTable lDt = lDa.GetLookupCodes("SurveyItem_MulhallErection");
 *                              int numCols = 0;
 *
 *                              if (lDt.Rows.Count > 0)
 *                              {
 *                                      numCols = lDt.Rows.Count;
 *                              }
 *
 *
 *                              MedicationDa OralAgentDa = new MedicationDa();
 *                              DataSet OralAgentDs;
 *
 *
 *                              if (numCols > 0)
 *                              {
 *
 *                                      // create date column
 *                                      DataColumn DateCol;
 *                                      DateCol = new DataColumn();
 *                                      DateCol.ColumnName = "Date";
 *                                      eDt.Columns.Add(DateCol);
 *
 *                                      // create Oral Agent column
 *                                      DataColumn AgentCol;
 *                                      AgentCol = new DataColumn();
 *                                      AgentCol.ColumnName = "Oral Agent";
 *                                      eDt.Columns.Add(AgentCol);
 *
 *                                      // create ICI Agent column
 *                                      DataColumn ICICol;
 *                                      ICICol = new DataColumn();
 *                                      ICICol.ColumnName = "ICI Agent";
 *                                      eDt.Columns.Add(ICICol);
 *
 *                                      // create Dose column
 *                                      DataColumn DoseCol;
 *                                      DoseCol = new DataColumn();
 *                                      DoseCol.ColumnName = "Dose";
 *                                      eDt.Columns.Add(DoseCol);
 *
 *                                      // add appropriately named columns to main table
 *                                      for (int i=0; i<numCols; i++)
 *                                      {
 *                                              DataColumn iCol;
 *                                              iCol = new DataColumn();
 *                                              iCol.ColumnName = lDt.Rows[i]["LkpCode"].ToString();
 *                                              eDt.Columns.Add(iCol);
 *                                      }
 *
 *
 *                                      // build the rows of the erectile function table
 *                                      for (int i=0; i<SurveyIdDs.Tables[0].Rows.Count; i++)
 *                                      {
 *
 *
 *                                              int SurvId = Convert.ToInt32(SurveyIdDs.Tables[0].Rows[i]["SurveyId"]);
 *                                              DataRow blankRow = eDt.NewRow();
 *                                              eDt.Rows.Add(blankRow);
 *
 *                                              eDt.Rows[i]["Date"] = SurveyIdDs.Tables[0].Rows[i]["SurveyDateText"].ToString();
 *
 *                                              OralAgentDs = new DataSet();
 *                                              OralAgentDs = OralAgentDa.FormGetErectileMedication(this.patientID, SurveyIdDs.Tables[0].Rows[i]["SurveyDate"].ToString());
 *                                              if (OralAgentDs.Tables.Count > 0 && OralAgentDs.Tables[0].Rows.Count > 0)
 *                                              {
 *                                                      if (OralAgentDs.Tables[0].Rows[0]["MedRoute"].ToString().ToUpper().Equals("INTRACAVERNOSAL"))
 *                                                      {
 *                                                              eDt.Rows[i]["ICI Agent"] = OralAgentDs.Tables[0].Rows[0]["Medication"].ToString();
 * //								eDt.Rows[i]["Oral Agent"] = "&nbsp;";
 *                                                      }
 *                                                      else
 *                                                      {
 *                                                              eDt.Rows[i]["Oral Agent"] = OralAgentDs.Tables[0].Rows[0]["Medication"].ToString();
 * //								eDt.Rows[i]["ICI Agent"] = "&nbsp;";
 *                                                      }
 *
 *                                                      eDt.Rows[i]["Dose"] = OralAgentDs.Tables[0].Rows[0]["MedDose"].ToString();
 *                                              }
 *
 *                                              // add data to the columns of the current row
 *                                              for (int j=0; j<numCols; j++)
 *                                              {
 *                                                      string SurvItem = lDt.Rows[j]["LkpCode"].ToString();
 *
 *                                                      DataSet dds = sDa.FormGetSurveyItemsResult(SurvId, this._formName, "Dynamic", SurvItem);
 *
 *                                                      if (dds.Tables.Count > 0 && dds.Tables[0].Rows.Count > 0)
 *                                                      {
 *                                                              eDt.Rows[i][SurvItem] = dds.Tables[0].Rows[0]["SurveyItemResult"].ToString();
 *                                                      }
 *
 *                                              }
 *
 *
 *
 *
 *
 *
 *                                      }
 *
 *                              }
 *                      }
 *
 *                      return eDt;
 *
 *              }
 */

        protected DataTable BlankErectileFunction(int MinNumRowsToShow)
        {
            DataTable    eDt     = new DataTable();
            LookupCodeDa lDa     = new LookupCodeDa();
            DataTable    lDt     = lDa.GetLookupCodes("SurveyItem_MulhallErection");
            int          numCols = 0;


            // create date column
            DataColumn DateCol;

            DateCol            = new DataColumn();
            DateCol.ColumnName = "Date";
            eDt.Columns.Add(DateCol);

            // create Oral Agent column
            DataColumn AgentCol;

            AgentCol            = new DataColumn();
            AgentCol.ColumnName = "Oral Agent";
            eDt.Columns.Add(AgentCol);

            // create ICI Agent column
            DataColumn ICICol;

            ICICol            = new DataColumn();
            ICICol.ColumnName = "ICI Agent";
            eDt.Columns.Add(ICICol);

            // create Dose column
            DataColumn DoseCol;

            DoseCol            = new DataColumn();
            DoseCol.ColumnName = "Dose";
            eDt.Columns.Add(DoseCol);

            // create Dose column
            DataColumn OralDoseCol;

            OralDoseCol            = new DataColumn();
            OralDoseCol.ColumnName = "Oral Dose";
            eDt.Columns.Add(OralDoseCol);

            // create Dose column
            DataColumn ICIDoseCol;

            ICIDoseCol            = new DataColumn();
            ICIDoseCol.ColumnName = "ICI Dose";
            eDt.Columns.Add(ICIDoseCol);



            if (lDt.Rows.Count > 0)
            {
                numCols = lDt.Rows.Count;
            }


            if (numCols > 0)
            {
                // add appropriately named columns to table
                for (int i = 0; i < numCols; i++)
                {
                    DataColumn iCol;
                    iCol            = new DataColumn();
                    iCol.ColumnName = lDt.Rows[i]["LkpCode"].ToString();
                    eDt.Columns.Add(iCol);
                }
            }

            for (int i = 0; i < MinNumRowsToShow; i++)
            {
                DataRow BlankRow;
                BlankRow = eDt.NewRow();
                eDt.Rows.Add(BlankRow);
            }

            return(eDt);
        }