//database part public List <populationAge> Expected_Pharmacy_Age(string customStartDate, string customEndDate) { List <populationAge> objList = new List <populationAge>(); var dt = _executor.GetDataTable(_pharmacySqlScripts.ExpectedAgeDetails(customStartDate, customEndDate)); for (int i = 0; i < dt.Rows.Count; i++) { populationAge obj = new populationAge { age = dt.Rows[i]["age_band"].ToString(), spend = dt.Rows[i]["p1_total_paid"].ToString().ToUpper(), members = dt.Rows[i]["p1_member_count"].ToString() }; objList.Add(obj); } return(objList); }
public List <Top_Condtion_By_Total_spend> Expected_Top_Condition_By_Total_Spend(string memberStatus) { List <Top_Condtion_By_Total_spend> objList = new List <Top_Condtion_By_Total_spend>(); var dt = _executor.GetDataTable(_dashboardSqlScripts.Top_Condition_By_Total_Spend(StartDate(), EndDate(), memberStatus)); for (int i = 0; i < dt.Rows.Count; i++) { Top_Condtion_By_Total_spend obj = new Top_Condtion_By_Total_spend { Conditions = dt.Rows[i]["disease_name"].ToString(), P_Spend = dt.Rows[i]["P_spend"].ToString(), Spend = dt.Rows[i]["Spend"].ToString(), P_Change = dt.Rows[i]["P_chnage"].ToString(), Members = dt.Rows[i]["Members"].ToString() }; objList.Add(obj); } return(objList); }