dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #11185
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 3158: Pushed much of dashboard web module code down to service layer. Fixed typo in DashboardConfigurat...
Merge authors:
Lars Helge Øverland (larshelge)
------------------------------------------------------------
revno: 3158 [merge]
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2011-03-24 17:58:40 +0100
message:
Pushed much of dashboard web module code down to service layer. Fixed typo in DashboardConfiguration class. Unfortunately this causes existing dashboard settings to be lost so you will have to set up the dashboard again.
removed:
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/rss/
added:
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/manager/
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/
renamed:
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DashBoardConfiguration.java => dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardConfiguration.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DashboardManager.java => dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardManager.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/ContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/ContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/DocumentContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/DocumentContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/MapViewContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/MapViewContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/OlapUrlContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/OlapUrlContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/ReportContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/ReportContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/ReportTableContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/ReportTableContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java => dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/rss/RssItem.java => dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/RssItem.java
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/aggregation/AggregatedDataSetAssociation.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/caseaggregation/CaseAggregationCondition.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/datalock/DataSetLock.java
dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/light_blue/light_blue.css
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ClearAreaAction.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ProvideContentAction.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/SetAreaItemAction.java
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardConfiguration.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardManager.java
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/RssItem.java
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/aggregation/AggregatedDataSetAssociation.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/aggregation/AggregatedDataSetAssociation.java 2011-01-25 20:50:16 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/aggregation/AggregatedDataSetAssociation.java 2011-03-24 16:58:40 +0000
@@ -27,14 +27,12 @@
package org.hisp.dhis.aggregation;
-import java.io.Serializable;
/**
* @author Chau Thu Tran
* @version $ID : AggregatedDataSetAssociation.java 10:02:44 AM Jul 9, 2010
*/
public class AggregatedDataSetAssociation
- implements Serializable
{
private int periodTypeId;
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/caseaggregation/CaseAggregationCondition.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/caseaggregation/CaseAggregationCondition.java 2010-11-30 06:17:34 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/caseaggregation/CaseAggregationCondition.java 2011-03-24 16:58:40 +0000
@@ -27,8 +27,6 @@
package org.hisp.dhis.caseaggregation;
-import java.io.Serializable;
-
import org.hisp.dhis.dataelement.DataElement;
import org.hisp.dhis.dataelement.DataElementCategoryOptionCombo;
@@ -38,7 +36,6 @@
* @version CaseAggregationCondition.java Nov 17, 2010 10:47:12 AM
*/
public class CaseAggregationCondition
- implements Serializable
{
public static final String SEPARATOR_ID = "\\.";
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DashBoardConfiguration.java' => 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardConfiguration.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DashBoardConfiguration.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardConfiguration.java 2011-03-24 16:58:40 +0000
@@ -1,4 +1,4 @@
-package org.hisp.dhis.dashboard.manager;
+package org.hisp.dhis.dashboard;
/*
* Copyright (c) 2004-2010, University of Oslo
@@ -35,16 +35,18 @@
* @author Lars Helge Overland
* @version $Id$
*/
-public class DashBoardConfiguration
+public class DashboardConfiguration
implements Serializable
{
+ private static final long serialVersionUID = 8829362188465214078L;
+
private Map<String, String> areaItems;
// -------------------------------------------------------------------------
// Constructor
// -------------------------------------------------------------------------
- public DashBoardConfiguration()
+ public DashboardConfiguration()
{
areaItems = new HashMap<String, String>();
}
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DashboardManager.java' => 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardManager.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DashboardManager.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardManager.java 2011-03-24 16:58:40 +0000
@@ -1,4 +1,4 @@
-package org.hisp.dhis.dashboard.manager;
+package org.hisp.dhis.dashboard;
/*
* Copyright (c) 2004-2010, University of Oslo
@@ -43,4 +43,6 @@
Map<String, Object> getContent();
Set<String> getContentProviderNames();
+
+ DashboardConfiguration getConfiguration();
}
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/rss/RssItem.java' => 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/RssItem.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/rss/RssItem.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/RssItem.java 2011-03-24 16:58:40 +0000
@@ -1,4 +1,4 @@
-package org.hisp.dhis.dashboard.rss;
+package org.hisp.dhis.dashboard;
/*
* Copyright (c) 2004-2010, University of Oslo
@@ -36,6 +36,8 @@
public class RssItem
implements Serializable
{
+ private static final long serialVersionUID = 3865942196910511305L;
+
private String title;
private String link;
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/datalock/DataSetLock.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/datalock/DataSetLock.java 2009-09-14 16:07:07 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/datalock/DataSetLock.java 2011-03-24 16:58:40 +0000
@@ -26,7 +26,6 @@
*/
package org.hisp.dhis.datalock;
-import java.io.Serializable;
import java.util.Date;
import java.util.HashSet;
import java.util.Set;
@@ -39,7 +38,7 @@
* @author Brajesh Murari
* @version $Id$
*/
-public class DataSetLock implements Serializable
+public class DataSetLock
{
/**
* The unique identifier for this DataSetLock
=== added directory 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/manager'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/manager/DefaultDashboardManager.java 2011-03-24 16:58:40 +0000
@@ -32,6 +32,8 @@
import java.util.Map;
import java.util.Set;
+import org.hisp.dhis.dashboard.DashboardConfiguration;
+import org.hisp.dhis.dashboard.DashboardManager;
import org.hisp.dhis.dashboard.provider.ContentProvider;
import org.hisp.dhis.user.NoCurrentUserException;
import org.hisp.dhis.user.UserSettingService;
@@ -43,7 +45,7 @@
public class DefaultDashboardManager
implements DashboardManager
{
- private static final String KEY_USERSETTING = "dashboardConfiguration";
+ private static final String KEY_USERSETTING = "dashboardConfig";
private Map<String, ContentProvider> contentProviders;
@@ -69,7 +71,7 @@
public void setAreaItem( String area, String item )
{
- DashBoardConfiguration config = getConfiguration();
+ DashboardConfiguration config = getConfiguration();
config.setAreaItem( area, item );
@@ -78,7 +80,7 @@
public void clearArea( String area )
{
- DashBoardConfiguration config = getConfiguration();
+ DashboardConfiguration config = getConfiguration();
config.clearArea( area );
@@ -89,7 +91,7 @@
{
Map<String, Object> content = new HashMap<String, Object>();
- DashBoardConfiguration config = getConfiguration();
+ DashboardConfiguration config = getConfiguration();
Collection<String> items = config.getAreaItems().values();
@@ -111,25 +113,25 @@
return contentProviders.keySet();
}
+ public DashboardConfiguration getConfiguration()
+ {
+ try
+ {
+ DashboardConfiguration config = (DashboardConfiguration) userSettingService.getUserSetting( KEY_USERSETTING );
+
+ return config != null ? config : new DashboardConfiguration();
+ }
+ catch ( NoCurrentUserException ex )
+ {
+ throw new RuntimeException( "Could not get configuration because no current user exists", ex );
+ }
+ }
+
// -------------------------------------------------------------------------
// Supportive methods
// -------------------------------------------------------------------------
- private DashBoardConfiguration getConfiguration()
- {
- try
- {
- DashBoardConfiguration config = (DashBoardConfiguration) userSettingService.getUserSetting( KEY_USERSETTING );
-
- return config != null ? config : new DashBoardConfiguration();
- }
- catch ( NoCurrentUserException ex )
- {
- throw new RuntimeException( "Could not get configuration because no current user exists", ex );
- }
- }
-
- private void setConfiguration( DashBoardConfiguration config )
+ private void setConfiguration( DashboardConfiguration config )
{
try
{
=== added directory 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/ContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/ContentProvider.java'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/DocumentContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/DocumentContentProvider.java'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/MapViewContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/MapViewContentProvider.java'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/OlapUrlContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/OlapUrlContentProvider.java'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/ReportContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/ReportContentProvider.java'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/ReportTableContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/ReportTableContentProvider.java'
=== renamed file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java' => 'dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/provider/RssContentProvider.java 2011-03-24 02:10:56 +0000
@@ -27,6 +27,8 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+import static org.hisp.dhis.system.util.MathUtils.getMax;
+
import java.io.IOException;
import java.net.MalformedURLException;
import java.util.ArrayList;
@@ -38,12 +40,10 @@
import org.amplecode.staxwax.reader.XMLReader;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.hisp.dhis.dashboard.rss.RssItem;
+import org.hisp.dhis.dashboard.RssItem;
import org.springframework.core.io.Resource;
import org.springframework.core.io.UrlResource;
-import static org.hisp.dhis.system.util.MathUtils.getMax;
-
/**
* @author Lars Helge Overland
* @version $Id$
=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml 2011-03-15 23:26:14 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml 2011-03-24 02:10:56 +0000
@@ -212,6 +212,81 @@
ref="org.hisp.dhis.dashboard.DashboardContentStore"/>
</bean>
+ <!-- Dashboard Content providers -->
+
+ <bean id="reportContentProvider"
+ class="org.hisp.dhis.dashboard.provider.ReportContentProvider">
+ <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
+ <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
+ <property name="key" value="reports"/>
+ </bean>
+
+ <bean id="documentContentProvider"
+ class="org.hisp.dhis.dashboard.provider.DocumentContentProvider">
+ <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
+ <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
+ <property name="key" value="documents"/>
+ </bean>
+
+ <bean id="reportTableContentProvider"
+ class="org.hisp.dhis.dashboard.provider.ReportTableContentProvider">
+ <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
+ <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
+ <property name="key" value="reportTables"/>
+ </bean>
+
+ <bean id="mapViewContentProvider"
+ class="org.hisp.dhis.dashboard.provider.MapViewContentProvider">
+ <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
+ <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
+ <property name="systemSettingManager" ref="org.hisp.dhis.options.SystemSettingManager" />
+ <property name="key" value="mapViews"/>
+ </bean>
+
+ <bean id="olapUrlContentProvider"
+ class="org.hisp.dhis.dashboard.provider.OlapUrlContentProvider">
+ <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
+ <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
+ <property name="key" value="olapUrls"/>
+ </bean>
+
+ <bean id="rssHealthContentProvider"
+ class="org.hisp.dhis.dashboard.provider.RssContentProvider">
+ <property name="url" value="http://health.yahoo.com/news/rss/health"/>
+ <property name="key" value="healthItems"/>
+ </bean>
+
+ <!-- Dashboard Manager -->
+
+ <bean id="org.hisp.dhis.dashboard.DashboardManager"
+ class="org.hisp.dhis.dashboard.manager.DefaultDashboardManager">
+ <property name="userSettingService" ref="org.hisp.dhis.user.UserSettingService"/>
+ <property name="contentProviders">
+ <map>
+ <entry>
+ <key><value>report</value></key>
+ <ref local="reportContentProvider"/>
+ </entry>
+ <entry>
+ <key><value>document</value></key>
+ <ref local="documentContentProvider"/>
+ </entry>
+ <entry>
+ <key><value>report_table</value></key>
+ <ref local="reportTableContentProvider"/>
+ </entry>
+ <entry>
+ <key><value>map_view</value></key>
+ <ref local="mapViewContentProvider"/>
+ </entry>
+ <entry>
+ <key><value>rss_health</value></key>
+ <ref local="rssHealthContentProvider"/>
+ </entry>
+ </map>
+ </property>
+ </bean>
+
<!-- Tally Sheet -->
<bean id="org.hisp.dhis.tallysheet.TallySheetService"
=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/light_blue/light_blue.css'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/light_blue/light_blue.css 2011-03-20 12:12:22 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/light_blue/light_blue.css 2011-03-24 10:38:51 +0000
@@ -145,7 +145,7 @@
div#popupHeader
{
- background-color: #425073;
+ background-color: #1d5288;
height: 34px;
width: 100%;
position: absolute;
=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ClearAreaAction.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ClearAreaAction.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ClearAreaAction.java 2011-03-24 02:10:56 +0000
@@ -29,7 +29,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.hisp.dhis.dashboard.manager.DashboardManager;
+import org.hisp.dhis.dashboard.DashboardManager;
import com.opensymphony.xwork2.Action;
=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ProvideContentAction.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ProvideContentAction.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/ProvideContentAction.java 2011-03-24 02:10:56 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.chart.Chart;
import org.hisp.dhis.chart.ChartService;
import org.hisp.dhis.chart.comparator.ChartTitleComparator;
-import org.hisp.dhis.dashboard.manager.DashboardManager;
+import org.hisp.dhis.dashboard.DashboardManager;
import com.opensymphony.xwork2.Action;
import com.opensymphony.xwork2.ActionContext;
=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/SetAreaItemAction.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/SetAreaItemAction.java 2010-04-12 21:23:33 +0000
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/action/SetAreaItemAction.java 2011-03-24 02:10:56 +0000
@@ -29,7 +29,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.hisp.dhis.dashboard.manager.DashboardManager;
+import org.hisp.dhis.dashboard.DashboardManager;
import com.opensymphony.xwork2.Action;
=== removed directory 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/manager'
=== removed directory 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/provider'
=== removed directory 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/rss'
=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/META-INF/dhis/beans.xml 2011-02-01 11:09:50 +0000
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/META-INF/dhis/beans.xml 2011-03-24 02:10:56 +0000
@@ -4,100 +4,25 @@
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
- <!-- Content providers -->
-
- <bean id="reportContentProvider"
- class="org.hisp.dhis.dashboard.provider.ReportContentProvider">
- <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
- <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
- <property name="key" value="reports"/>
- </bean>
-
- <bean id="documentContentProvider"
- class="org.hisp.dhis.dashboard.provider.DocumentContentProvider">
- <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
- <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
- <property name="key" value="documents"/>
- </bean>
-
- <bean id="reportTableContentProvider"
- class="org.hisp.dhis.dashboard.provider.ReportTableContentProvider">
- <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
- <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
- <property name="key" value="reportTables"/>
- </bean>
-
- <bean id="mapViewContentProvider"
- class="org.hisp.dhis.dashboard.provider.MapViewContentProvider">
- <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
- <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
- <property name="systemSettingManager" ref="org.hisp.dhis.options.SystemSettingManager" />
- <property name="key" value="mapViews"/>
- </bean>
-
- <bean id="olapUrlContentProvider"
- class="org.hisp.dhis.dashboard.provider.OlapUrlContentProvider">
- <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService"/>
- <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService"/>
- <property name="key" value="olapUrls"/>
- </bean>
-
- <bean id="rssHealthContentProvider"
- class="org.hisp.dhis.dashboard.provider.RssContentProvider">
- <property name="url" value="http://health.yahoo.com/news/rss/health"/>
- <property name="key" value="healthItems"/>
- </bean>
-
- <!-- Manager -->
-
- <bean id="org.hisp.dhis.dashboard.manager.DashboardManager"
- class="org.hisp.dhis.dashboard.manager.DefaultDashboardManager">
- <property name="userSettingService" ref="org.hisp.dhis.user.UserSettingService"/>
- <property name="contentProviders">
- <map>
- <entry>
- <key><value>report</value></key>
- <ref local="reportContentProvider"/>
- </entry>
- <entry>
- <key><value>document</value></key>
- <ref local="documentContentProvider"/>
- </entry>
- <entry>
- <key><value>report_table</value></key>
- <ref local="reportTableContentProvider"/>
- </entry>
- <entry>
- <key><value>map_view</value></key>
- <ref local="mapViewContentProvider"/>
- </entry>
- <entry>
- <key><value>rss_health</value></key>
- <ref local="rssHealthContentProvider"/>
- </entry>
- </map>
- </property>
- </bean>
-
<!-- Actions -->
<bean id="org.hisp.dhis.dashboard.action.ProvideContentAction"
class="org.hisp.dhis.dashboard.action.ProvideContentAction"
scope="prototype">
- <property name="manager" ref="org.hisp.dhis.dashboard.manager.DashboardManager"/>
+ <property name="manager" ref="org.hisp.dhis.dashboard.DashboardManager"/>
<property name="chartService" ref="org.hisp.dhis.chart.ChartService"/>
</bean>
<bean id="org.hisp.dhis.dashboard.action.SetAreaItemAction"
class="org.hisp.dhis.dashboard.action.SetAreaItemAction"
scope="prototype">
- <property name="manager" ref="org.hisp.dhis.dashboard.manager.DashboardManager"/>
+ <property name="manager" ref="org.hisp.dhis.dashboard.DashboardManager"/>
</bean>
<bean id="org.hisp.dhis.dashboard.action.ClearAreaAction"
class="org.hisp.dhis.dashboard.action.ClearAreaAction"
scope="prototype">
- <property name="manager" ref="org.hisp.dhis.dashboard.manager.DashboardManager"/>
+ <property name="manager" ref="org.hisp.dhis.dashboard.DashboardManager"/>
</bean>
<bean id="org.hisp.dhis.dashboard.action.GetChartAction"