public ActionResult Index(string pCode) { var parliamentId = new ParliamentService().GetParliamentId(pCode); RepresentativeService service = new RepresentativeService(); RepresentativeListModel model = service.GetAllRepresentativesForParliament(parliamentId); return(View(model)); }
public ActionResult ManageRepresentatives() { if (SessionManager.Current.CurrentParliamentId == 0) { SessionManager.Current.CurrentParliamentId = 1; } RepresentativeService service = new RepresentativeService(); RepresentativeListModel model = service.GetAllRepresentativesForParliament(SessionManager.Current.CurrentParliamentId); return(View(model)); }