コード例 #1
0
        public List <Department> GetAllDepartments()
        {
            List <Department> departments = _departmentRepository.GetAllDepartments();

            foreach (Department department in departments)
            {
                department.Employees = _employeeController.GetEmployeesByDepartmentId(department.Id);
            }
            return(departments);
        }
コード例 #2
0
 public List <Employee> GetEmployeesByDepartmentId(int departmentId)
 {
     return(_employeeController.GetEmployeesByDepartmentId(departmentId));
 }