public static GetIndicationListPJ GetIndicationListBSForPJ(int SubTherapeuticId, int TherapeuticId) { GetIndicationListPJ listresponse = new GetIndicationListPJ(); listresponse = DefaultListDSForPJ.GetIndicationListDSForPJ(SubTherapeuticId, TherapeuticId); return(listresponse); }
public static GetIndicationListPJ GetIndicationListDSForPJ(int SubTherapeuticId, int TherapeuticId) { GetIndicationListPJ listresponse = new GetIndicationListPJ(); using (PJEntities entity = new PJEntities()) { var indicationData = from r in entity.Indication_Master select r; listresponse.IndicationList = (from a in indicationData where a.SubTherapeutic_Area_Master_Id == SubTherapeuticId where a.Therapeutic_Area_Master_Id == TherapeuticId where a.Is_Active == true select new IndicationList() { IndicationId = a.Indication_Master_Id, IndicationName = a.Indication_Name }).OrderBy(x => x.IndicationName).ToList(); } return(listresponse); }