public ActionResult ClientServices() { int trainerID = ((int)Session[SessionKeys.Trainer_ID]); TrainerClients clients = new TrainerClients() { TrainerId = trainerID, ClientsWithoutPlans = _dal.GetClientsWithoutPlans(trainerID), ClientsWithPlans = _dal.GetClientsWithPlans(trainerID) }; return(View(clients)); }
public ActionResult ClientServices() { if (Session[SessionKeys.Trainer_ID] == null) { return(Redirect("/User/Login")); } int trainerID = ((int)Session[SessionKeys.Trainer_ID]); TrainerClients clients = new TrainerClients() { TrainerId = trainerID, ClientsWithoutPlans = _dal.GetClientsWithoutPlans(trainerID), ClientsWithPlans = _dal.GetClientsWithPlans(trainerID) }; return(View(clients)); }