@Override
public String execute(CommandParams<?> request) throws ServletException, IOException {
String page = null;
AbstractDao<Department> departmentDao = new DepartmentDao();
try {
List<Department> departments = departmentDao.findAll();
request.setAttribute(Commands.CATALOG_DEPARTMENTS, departments);
page = ConfigurationManager.INSTANCE.getProperty(ConfigurationManager.CATALOG_PAGE_PATH);
} catch (DaoException e) {
log.error("Was not able to execute catalog command");
page = ConfigurationManager.INSTANCE.getProperty(ConfigurationManager.ERROR_PAGE_PATH);