1
package org.hisp.dhis.dashboard.action;
3
import org.hisp.dhis.organisationunit.OrganisationUnit;
4
import org.hisp.dhis.organisationunit.OrganisationUnitService;
6
import com.opensymphony.xwork.ActionSupport;
8
public class GetOrgUnitsAction extends ActionSupport
10
// -------------------------------------------------------------------------
12
// -------------------------------------------------------------------------
14
private OrganisationUnitService organisationUnitService;
16
public void setOrganisationUnitService( OrganisationUnitService organisationUnitService )
18
this.organisationUnitService = organisationUnitService;
21
// -------------------------------------------------------------------------
23
// -------------------------------------------------------------------------
25
private Integer orgUnitId;
27
public void setOrgUnitId( Integer orgUnitId )
29
this.orgUnitId = orgUnitId;
32
private OrganisationUnit orgUnit;
34
public OrganisationUnit getOrgUnit()
39
// -------------------------------------------------------------------------
40
// Action implementation
41
// -------------------------------------------------------------------------
43
public String execute() throws Exception
45
/* OrganisationUnit */
48
orgUnit = organisationUnitService.getOrganisationUnit( orgUnitId );