=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonDataElementGroup.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonDataElementGroup.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonDataElementGroup.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,7 @@ +{ "dataElementGroup": + { + "id": $!{dataElementGroup.id}, + "name": "$!encoder.jsEncode( ${dataElementGroup.name} )", + "memberCount": "$memberCount" + } +} === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonIndicatorGroup.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonIndicatorGroup.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonIndicatorGroup.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,8 @@ +{ "indicatorGroup": + { + "id": $!{indicator.id}, + "name": "$!encoder.jsEncode( ${indicatorGroup.name} )", + "alternativeName": "$!encoder.jsEncode( ${indicatorGroup.alternativeNamee} )", + "memberCount": "$memberCount" + } +} === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonIndicatorGroupSet.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonIndicatorGroupSet.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/jsonIndicatorGroupSet.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,7 @@ +{ "indicatorGroupSet": + { + "id": $!{indicatorGroupSet.id}, + "name": "$!encoder.jsEncode( ${indicatorGroupSet.name} )", + "memberCount": "$memberCount" + } +} === modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElement.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElement.vm 2010-10-28 09:17:13 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElement.vm 2010-11-20 08:23:34 +0000 @@ -1,13 +1,16 @@ $dataElement.id - $!encoder.xmlEncode( $dataElement.name ) - $!encoder.xmlEncode( $dataElement.alternativeName ) - $!encoder.xmlEncode( $dataElement.shortName ) - $!encoder.xmlEncode( $dataElement.code ) - $!encoder.xmlEncode( $dataElement.description ) - $dataElement.active - $!encoder.xmlEncode( $dataElement.type ) - $!encoder.xmlEncode( $dataElement.numberType ) - $!encoder.xmlEncode( $dataElement.aggregationOperator ) + $encoder.xmlEncode( $dataElement.name ) + $encoder.xmlEncode( $dataElement.shortName ) + $!encoder.xmlEncode( $dataElement.alternativeName ) + $!encoder.xmlEncode( $dataElement.code ) + $!encoder.xmlEncode( $dataElement.description ) + $dataElement.active + $dataElement.getDomainTypeNullSafe() + $dataElement.type + $dataElement.aggregationOperator + $!encoder.xmlEncode( $dataElement.url ) + $!format.formatDate( $dataElement.lastUpdated ) + $!encoder.xmlEncode( $dataElement.categoryCombo.name ) === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroup.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroup.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroup.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,6 @@ + + + $dataElementGroup.id + $encoder.xmlEncode( $dataElementGroup.name ) + $memberCount + === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroupSet.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroupSet.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroupSet.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,6 @@ + + + $dataElementGroupSet.id + $encoder.xmlEncode( $dataElementGroupSet.name ) + $dataElementGroupSet.members.size() + \ No newline at end of file === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroups.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroups.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElementGroups.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,10 @@ + + + #foreach( $dataElementGroup in $dataElementGroups ) + + $dataElementGroup.id + $encoder.xmlEncode( $dataElementGroup.name ) + + #end + + === modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElements.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElements.vm 2010-10-28 09:17:13 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataElements.vm 2010-11-20 08:23:34 +0000 @@ -2,14 +2,17 @@ #foreach( $dataElement in $dataElements ) - $dataElement.id - $!encoder.xmlEncode( $dataElement.name ) - $!encoder.xmlEncode( $dataElement.alternativeName ) - $!encoder.xmlEncode( $dataElement.shortName ) - $!encoder.xmlEncode( $dataElement.code ) - $!encoder.xmlEncode( $dataElement.type ) - $!encoder.xmlEncode( $dataElement.numberType ) - $!encoder.xmlEncode( $dataElement.aggregationOperator ) - + $dataElement.id + $encoder.xmlEncode( $dataElement.name ) + $encoder.xmlEncode( $dataElement.shortName ) + $!encoder.xmlEncode( $dataElement.alternativeName ) + $!encoder.xmlEncode( $dataElement.code ) + $!encoder.xmlEncode( $dataElement.description ) + $dataElement.active + $dataElement.getDomainTypeNullSafe() + $dataElement.type + $dataElement.aggregationOperator + $dataElement.categoryCombo + #end - + \ No newline at end of file === modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataSet.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataSet.vm 2010-01-25 09:23:35 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlDataSet.vm 2010-11-20 08:23:34 +0000 @@ -4,4 +4,7 @@ $!encoder.xmlEncode( $dataSet.name ) $!encoder.xmlEncode( $dataSet.shortName ) $dataSet.periodType.id + $i18n.getString( $dataSet.periodType.name ) + $dataSet.dataElements.size() + #if( $dataSet.dataEntryForm )$encoder.xmlEncode( $dataSet.dataEntryForm.name )#end \ No newline at end of file === modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicator.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicator.vm 2010-01-25 09:23:35 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicator.vm 2010-11-20 08:23:34 +0000 @@ -2,16 +2,19 @@ $indicator.id $!encoder.xmlEncode( $indicator.name ) + $!encoder.xmlEncode( $indicator.shortName ) $!encoder.xmlEncode( $indicator.alternativeName ) - $!encoder.xmlEncode( $indicator.shortName ) $!encoder.xmlEncode( $indicator.code ) $!encoder.xmlEncode( $indicator.description ) $indicator.annualized $indicator.indicatorType.id + $!encoder.xmlEncode( $indicator.indicatorType.name ) $!encoder.xmlEncode( $indicator.numerator ) $!encoder.xmlEncode( $indicator.numeratorDescription ) $!encoder.xmlEncode( $indicator.numeratorAggregationOperator ) $!encoder.xmlEncode( $indicator.denominator ) $!encoder.xmlEncode( $indicator.denominatorDescription ) - $!encoder.xmlEncode( $indicator.denominatorAggregationOperator ) + $!encoder.xmlEncode( $indicator.denominatorAggregationOperator ) + $!encoder.xmlEncode( $indicator.url ) + $!format.formatDate( $indicator.lastUpdated ) \ No newline at end of file === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroup.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroup.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroup.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,6 @@ + + + $indicatorGroup.id + $!encoder.xmlEncode( $indicatorGroup.name ) + $memberCount + \ No newline at end of file === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroupSet.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroupSet.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroupSet.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,6 @@ + + + $indicatorGroupSet.id + $encoder.xmlEncode( $indicatorGroupSet.name ) + $indicatorGroupSet.members.size() + === added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroups.vm' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroups.vm 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ajax/xmlIndicatorGroups.vm 2010-11-20 08:23:34 +0000 @@ -0,0 +1,9 @@ + + + #foreach( $indicatorGroup in $indicatorGroups ) + + $indicatorGroup.id + $encoder.xmlEncode( $indicatorGroup.name ) + + #end + === added file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetDataElementGroupAction.java' --- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetDataElementGroupAction.java 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetDataElementGroupAction.java 2010-11-20 08:23:34 +0000 @@ -0,0 +1,90 @@ +package org.hisp.dhis.commons.action; + +/* + * Copyright (c) 2004-2010, University of Oslo + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * * Neither the name of the HISP project nor the names of its contributors may + * be used to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +import org.hisp.dhis.dataelement.DataElementGroup; +import org.hisp.dhis.dataelement.DataElementService; + +import com.opensymphony.xwork2.ActionSupport; + +/** + * @author Torgeir Lorange Ostby + * @version $Id: GetDataElementGroupAction.java 2869 2007-02-20 14:26:09Z andegje $ + */ +public class GetDataElementGroupAction + extends ActionSupport +{ + // ------------------------------------------------------------------------- + // Dependencies + // ------------------------------------------------------------------------- + + private DataElementService dataElementService; + + public void setDataElementService( DataElementService dataElementService ) + { + this.dataElementService = dataElementService; + } + + // ------------------------------------------------------------------------- + // Input/output + // ------------------------------------------------------------------------- + + private Integer id; + + public void setId( Integer id ) + { + this.id = id; + } + + private DataElementGroup dataElementGroup; + + public DataElementGroup getDataElementGroup() + { + return dataElementGroup; + } + + private int memberCount; + + public int getMemberCount() + { + return memberCount; + } + + // ------------------------------------------------------------------------- + // Action implementation + // ------------------------------------------------------------------------- + + public String execute() + { + dataElementGroup = dataElementService.getDataElementGroup( id ); + + memberCount = dataElementGroup.getMembers().size(); + + return SUCCESS; + } +} === added file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetDataElementGroupSetAction.java' --- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetDataElementGroupSetAction.java 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetDataElementGroupSetAction.java 2010-11-20 08:23:34 +0000 @@ -0,0 +1,79 @@ +package org.hisp.dhis.commons.action; +/* + * Copyright (c) 2004-2010, University of Oslo + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * * Neither the name of the HISP project nor the names of its contributors may + * be used to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +import org.hisp.dhis.dataelement.DataElementGroupSet; +import org.hisp.dhis.dataelement.DataElementService; + +import com.opensymphony.xwork2.Action; + +/** + * @author Tran Thanh Tri + * @version $Id$ + */ +public class GetDataElementGroupSetAction + implements Action +{ + // ------------------------------------------------------------------------- + // Dependencies + // ------------------------------------------------------------------------- + + private DataElementService dataElementService; + + public void setDataElementService( DataElementService dataElementService ) + { + this.dataElementService = dataElementService; + } + + // ------------------------------------------------------------------------- + // Input & Output + // ------------------------------------------------------------------------- + + private Integer id; + + public void setId( Integer id ) + { + this.id = id; + } + + private DataElementGroupSet dataElementGroupSet; + + public DataElementGroupSet getDataElementGroupSet() + { + return dataElementGroupSet; + } + + public String execute() + throws Exception + { + + dataElementGroupSet = dataElementService.getDataElementGroupSet( id ); + + + return SUCCESS; + } +} \ No newline at end of file === added file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetIndicatorGroupAction.java' --- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetIndicatorGroupAction.java 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetIndicatorGroupAction.java 2010-11-20 08:23:34 +0000 @@ -0,0 +1,90 @@ +package org.hisp.dhis.commons.action; + +/* + * Copyright (c) 2004-2010, University of Oslo + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * * Neither the name of the HISP project nor the names of its contributors may + * be used to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +import org.hisp.dhis.indicator.IndicatorGroup; +import org.hisp.dhis.indicator.IndicatorService; + +import com.opensymphony.xwork2.ActionSupport; + +/** + * @author Torgeir Lorange Ostby + * @version $Id: GetIndicatorGroupAction.java 3305 2007-05-14 18:55:52Z larshelg $ + */ +public class GetIndicatorGroupAction + extends ActionSupport +{ + // ------------------------------------------------------------------------- + // Dependencies + // ------------------------------------------------------------------------- + + private IndicatorService indicatorService; + + public void setIndicatorService( IndicatorService indicatorService ) + { + this.indicatorService = indicatorService; + } + + // ------------------------------------------------------------------------- + // Input/output + // ------------------------------------------------------------------------- + + private Integer id; + + public void setId( Integer id ) + { + this.id = id; + } + + private IndicatorGroup indicatorGroup; + + public IndicatorGroup getIndicatorGroup() + { + return indicatorGroup; + } + + private int memberCount; + + public int getMemberCount() + { + return memberCount; + } + + // ------------------------------------------------------------------------- + // Action implementation + // ------------------------------------------------------------------------- + + public String execute() + { + indicatorGroup = indicatorService.getIndicatorGroup( id ); + + memberCount = indicatorGroup.getMembers().size(); + + return SUCCESS; + } +} === added file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetIndicatorGroupSetAction.java' --- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetIndicatorGroupSetAction.java 1970-01-01 00:00:00 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetIndicatorGroupSetAction.java 2010-11-20 08:23:34 +0000 @@ -0,0 +1,79 @@ +package org.hisp.dhis.commons.action; +/* + * Copyright (c) 2004-2010, University of Oslo + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * * Neither the name of the HISP project nor the names of its contributors may + * be used to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +import org.hisp.dhis.indicator.IndicatorGroupSet; +import org.hisp.dhis.indicator.IndicatorService; + +import com.opensymphony.xwork2.Action; + +/** + * @author Tran Thanh Tri + * @version $Id$ + */ +public class GetIndicatorGroupSetAction + implements Action +{ + + // ------------------------------------------------------------------------- + // Dependencies + // ------------------------------------------------------------------------- + + private IndicatorService indicatorService; + + public void setIndicatorService( IndicatorService indicatorService ) + { + this.indicatorService = indicatorService; + } + + // ------------------------------------------------------------------------- + // Input & Output + // ------------------------------------------------------------------------- + + private Integer id; + + public void setId( Integer id ) + { + this.id = id; + } + + private IndicatorGroupSet indicatorGroupSet; + + public IndicatorGroupSet getIndicatorGroupSet() + { + return indicatorGroupSet; + } + + @Override + public String execute() + throws Exception + { + indicatorGroupSet = indicatorService.getIndicatorGroupSet( id ); + + return SUCCESS; + } +} === modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml' --- dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml 2010-11-11 17:36:25 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml 2010-11-20 08:23:34 +0000 @@ -599,16 +599,41 @@ + + + + + + + + + + + + + + + + + + + + @@ -621,119 +646,98 @@ class="org.hisp.dhis.commons.action.GetDataSetAction" scope="prototype"> - + class="org.hisp.dhis.commons.action.GetDataSetsAction" scope="prototype"> + + + + + class="org.hisp.dhis.commons.action.GetIndicatorAction" scope="prototype"> + + + + + class="org.hisp.dhis.commons.action.GetIndicatorGroupsAction" scope="prototype"> + + + + + class="org.hisp.dhis.commons.action.GetIndicatorsAction" scope="prototype"> + + + + + + + + + + + + + + + + + + + - - - - + class="org.hisp.dhis.commons.action.GetPeriodAction" scope="prototype"> + class="org.hisp.dhis.commons.action.GetPeriodsAction" scope="prototype"> + class="org.hisp.dhis.commons.action.GetPeriodTypesAction" scope="prototype"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - === modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml' --- dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml 2010-09-14 09:03:41 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml 2010-11-20 08:23:34 +0000 @@ -309,6 +309,13 @@ + + + /dhis-web-commons/ajax/xmlCategoryOptionCombos.vm + plainTextError + + @@ -316,6 +323,27 @@ plainTextError + + + /dhis-web-commons/ajax/xmlDataElementGroup.vm + plainTextError + + + + + /dhis-web-commons/ajax/xmlDataElementGroups.vm + plainTextError + + + + + /dhis-web-commons/ajax/xmlDataElementGroupSet.vm + plainTextError + + @@ -341,12 +369,36 @@ plainTextError + + + /dhis-web-commons/ajax/xmlIndicatorGroup.vm + plainTextError + + + + + /dhis-web-commons/ajax/xmlIndicatorGroups.vm + plainTextError + + + + + /dhis-web-commons/ajax/xmlIndicatorGroupSet.vm + plainTextError + + /dhis-web-commons/ajax/xmlIndicators.vm plainTextError + + + /dhis-web-commons/ajax/xmlOperands.vm + plainTextError + + @@ -379,20 +431,7 @@ /dhis-web-commons/ajax/xmlPeriods.vm plainTextError - - - - /dhis-web-commons/ajax/xmlCategoryOptionCombos.vm - plainTextError - - - - - /dhis-web-commons/ajax/xmlOperands.vm - plainTextError - - + @@ -400,6 +439,27 @@ + + + /dhis-web-commons/ajax/jsonCategoryOptionCombos.vm + plainTextError + + + + + /dhis-web-commons/ajax/jsonDataElement.vm + plainTextError + + + + + /dhis-web-commons/ajax/jsonDataElementGroup.vm + plainTextError + + @@ -407,10 +467,10 @@ plainTextError - + - /dhis-web-commons/ajax/jsonDataElement.vm + /dhis-web-commons/ajax/jsonDataElementName.vm plainTextError @@ -433,6 +493,19 @@ plainTextError + + + /dhis-web-commons/ajax/jsonIndicator.vm + plainTextError + + + + + /dhis-web-commons/ajax/jsonIndicatorGroup.vm + plainTextError + + @@ -440,9 +513,10 @@ plainTextError - + - /dhis-web-commons/ajax/jsonIndicator.vm + /dhis-web-commons/ajax/jsonIndicatorGroupSet.vm plainTextError @@ -452,6 +526,12 @@ plainTextError + + + /dhis-web-commons/ajax/jsonOperands.vm + plainTextError + + @@ -459,20 +539,34 @@ plainTextError + + + /dhis-web-commons/ajax/jsonOrganisationUnitGroups.vm + plainTextError + + + + + /dhis-web-commons/ajax/jsonOrganisationUnits.vm + plainTextError + + + + + /dhis-web-commons/ajax/jsonOrganisationUnitLevels.vm + plainTextError + + /dhis-web-commons/ajax/jsonOrganisationUnits.vm plainTextError - - - - /dhis-web-commons/ajax/jsonOrganisationUnits.vm - plainTextError - - + /dhis-web-commons/ajax/jsonPeriod.vm @@ -485,26 +579,6 @@ plainTextError - - - /dhis-web-commons/ajax/jsonCategoryOptionCombos.vm - plainTextError - - - - - /dhis-web-commons/ajax/jsonDataElementName.vm - plainTextError - - - - - /dhis-web-commons/ajax/jsonOperands.vm - plainTextError - - @@ -521,21 +595,6 @@ plainTextError - - - /dhis-web-commons/ajax/jsonOrganisationUnitLevels.vm - plainTextError - - - - - /dhis-web-commons/ajax/jsonOrganisationUnitGroups.vm - plainTextError - - - === modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties' --- dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties 2010-11-09 07:42:19 +0000 +++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties 2010-11-20 08:23:34 +0000 @@ -422,7 +422,7 @@ expression = Expression left_expression = Left Expression right_expression = Right Expression -indicator_type = Indicator type +indicator_type = Indicator Type annualized = Annualized aggregation_operator = Aggregation operator numerator = Numerator === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/struts.xml' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/struts.xml 2010-11-02 13:02:10 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/struts.xml 2010-11-20 08:23:34 +0000 @@ -44,13 +44,6 @@ - - - /dhis-web-maintenance-datadictionary/responseDataElement.vm - plainTextError - - @@ -113,8 +106,7 @@ ../dhis-web-commons/ajax/jsonResponseError.vm plainTextError - - + @@ -211,14 +203,6 @@ class="org.hisp.dhis.dd.action.dataelementgroup.GetDataElementGroupListAction" method="searchByName"> /dhis-web-maintenance-datadictionary/dataElementGroupSearch.vm - - - - - - /dhis-web-maintenance-datadictionary/responseDataElementGroup.vm - F_DATAELEMENTGROUPSET_DELETE - - - /dhis-web-maintenance-datadictionary/responseDataElementGroupSet.vm - - + + + + /main.vm + /dhis-web-maintenance-datadictionary/indicator.vm + /dhis-web-maintenance-datadictionary/menu.vm + javascript/indicator.js,javascript/dataDictionary.js,javascript/denum.js + + + + /main.vm + /dhis-web-maintenance-datadictionary/sortIndicatorForm.vm + + + + indicator.action + + + + + + /dhis-web-commons/ajax/jsonResponseSuccess.vm + + /dhis-web-commons/ajax/jsonResponseError.vm + plainTextError + F_INDICATOR_DELETE + + + + /main.vm + /dhis-web-maintenance-datadictionary/addIndicatorForm.vm + javascript/shortName.js,javascript/indicator.js,javascript/denum.js + F_INDICATOR_ADD + + + + indicator.action + + F_INDICATOR_ADD + + + + getIndicatorTypeList + + F_INDICATOR_UPDATE + + + + /main.vm + /dhis-web-maintenance-datadictionary/updateIndicatorForm.vm + javascript/shortName.js,javascript/indicator.js,javascript/denum.js + F_INDICATOR_UPDATE + + + + indicator.action + + F_INDICATOR_UPDATE + + + + + /dhis-web-commons/ajax/jsonResponseSuccess.vm + + /dhis-web-commons/ajax/jsonResponseError.vm + plainTextError + @@ -438,14 +493,6 @@ javascript/indicatorGroup.js - - - /dhis-web-maintenance-datadictionary/responseIndicatorGroup.vm - - plainTextError - - @@ -562,14 +609,6 @@ F_INDICATORGROUPSET_DELETE - - - /dhis-web-maintenance-datadictionary/responseIndicatorGroupSet.vm - - - - plainTextError - - - - /main.vm - /dhis-web-maintenance-datadictionary/indicator.vm - /dhis-web-maintenance-datadictionary/menu.vm - javascript/indicator.js,javascript/dataDictionary.js,javascript/denum.js - - - - /main.vm - /dhis-web-maintenance-datadictionary/sortIndicatorForm.vm - - - - indicator.action - - - - - - /dhis-web-maintenance-datadictionary/responseIndicator.vm - plainTextError - - - - - /dhis-web-commons/ajax/jsonResponseSuccess.vm - - /dhis-web-commons/ajax/jsonResponseError.vm - plainTextError - F_INDICATOR_DELETE - - - - /main.vm - /dhis-web-maintenance-datadictionary/addIndicatorForm.vm - javascript/shortName.js,javascript/indicator.js,javascript/denum.js - F_INDICATOR_ADD - - - - indicator.action - - F_INDICATOR_ADD - - - - getIndicatorTypeList - - F_INDICATOR_UPDATE - - - - /main.vm - /dhis-web-maintenance-datadictionary/updateIndicatorForm.vm - javascript/shortName.js,javascript/indicator.js,javascript/denum.js - F_INDICATOR_UPDATE - - - - indicator.action - - F_INDICATOR_UPDATE - - - - - /dhis-web-commons/ajax/jsonResponseSuccess.vm - - /dhis-web-commons/ajax/jsonResponseError.vm - plainTextError - - -