Fixed export to excel for departments.