public List <Programare> listaProgramari(String data) { DateTime dataP = DateTime.ParseExact(data, "yyyy-MM-dd", null); List <Programare> programari = _programareDAO.getProgramari(dataP); if (programari != null) { foreach (Programare programare in programari) { List <ProgramareServiciu> programareServiciuList = _programareServiciuDAO.selectServiciiClient(programare.getId()); List <Serviciu> servicii = new List <Serviciu>(); foreach (ProgramareServiciu programareServiciu in programareServiciuList) { Serviciu serv = _serviciuDAO.getServiciu(programareServiciu.getNumeServiciu()); servicii.Add(serv); } programare.setServicii(servicii); } } else { return(null); } return(programari); }
public List <ProgramareServiciu> selectareServiciiClient(int id) { return(_programareServiciuDAO.selectServiciiClient(id)); }