// GET: LeaveType public ActionResult Index( ) { var listLeaveTypes = _repository.FindAll().ToList(); var model = _mapper.Map <List <LeaveTypeManager>, List <LeaveTypeModel> >(listLeaveTypes); return(View(model)); }
public ActionResult Index() { var listLeaveTypes = _repository.FindAll().ToList(); var model = _mapper.Map <List <LeaveTypeManager>, List <LeaveTypeModel> >(listLeaveTypes); CreateAlocationViewModel modelView = new CreateAlocationViewModel { leaveTypeManager = model }; return(View(modelView)); }