Re: [Dhis2-devs] Aggreration query for single event without registration
Hi Ola, Thanks a lot, that works great! Regards, Robin De : olati...@gmail.com [olati...@gmail.com] de la part de Ola Hodne Titlestad [ol...@ifi.uio.no] Envoyé : jeudi 22 janvier 2015 12:41 À : Robin Martens Cc : dhis2-us...@lists.launchpad.net; dhis2-devs Objet : Re: [Dhis2-devs] Aggreration query for single event without registration Robin, We have a feature to get number of events for a given program stage. Two options need to be set: 1) Operator, at the top of the page, need to be 'Number of visits' 2) Under the Program tab, select 'Visited selected program stage' The formula will then be on this format : [PS:391] With 391 being the internal id of the program stage. That should give you the total number of events for your single event without registration program. Ola -- 21. jan. 2015 10:37 skrev Robin Martens mart...@sher.bemailto:mart...@sher.be følgende: Hi all, Is it possible in the Aggregation Query Builder to use the Number of tracked entities operator to calculate a number of events, especially when it concerns Single events without registration? I tried it and although it finds the events based on the conditions, it always returns 0 as a value. Regards, Robin ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.netmailto:dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18103: minor fix, check for idobject for collection, not pr object
revno: 18103 committer: Morten Olav Hansen morte...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 18:43:31 +0700 message: minor fix, check for idobject for collection, not pr object modified: dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/MaintenanceController.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-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/MaintenanceController.java' --- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/MaintenanceController.java 2015-01-21 10:59:38 + +++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/MaintenanceController.java 2015-01-22 11:43:31 + @@ -133,7 +133,7 @@ for ( Property property : schema.getProperties() ) { -if ( !property.isCollection() ) +if ( !property.isCollection() || !property.isIdentifiableObject() ) { continue; } @@ -144,11 +144,6 @@ for ( Object object : collection ) { -if ( !IdentifiableObject.class.isInstance( object ) ) -{ -continue; -} - ListValidationViolation validationViolations = schemaValidator.validate( object ); if ( !validationViolations.isEmpty() ) ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18104: event-capture - filter those programs without program stage. Such metadata could exist if the db ...
revno: 18104 committer: Abyot Asalefew Gizaw aby...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 14:34:11 +0100 message: event-capture - filter those programs without program stage. Such metadata could exist if the db is manipulated directly. modified: dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js -- 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-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js' --- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js 2014-12-17 14:21:45 + +++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js 2015-01-22 13:34:11 + @@ -303,19 +303,22 @@ var build = builder.promise(); _.each( _.values( programs ), function ( program ) { -build = build.then(function() { -var d = $.Deferred(); -var p = d.promise(); -dhis2.ec.store.get('programs', program.id).done(function(obj) { -if(!obj || obj.version !== program.version) { -promise = promise.then( getProgram( program.id ) ); -} - -d.resolve(); + +if(program.programStages program.programStages[0].programStageDataElements){ +build = build.then(function() { +var d = $.Deferred(); +var p = d.promise(); +dhis2.ec.store.get('programs', program.id).done(function(obj) { +if(!obj || obj.version !== program.version) { +promise = promise.then( getProgram( program.id ) ); +} + +d.resolve(); +}); + +return p; }); - -return p; -}); +} }); build.done(function() { @@ -380,21 +383,22 @@ var build = builder.promise(); _.each( _.values( programs ), function ( program ) { - -build = build.then(function() { -var d = $.Deferred(); -var p = d.promise(); -dhis2.ec.store.get('programStages', program.programStages[0].id).done(function(obj) { -if(!obj || obj.version !== program.programStages[0].version) { -promise = promise.then( getProgramStage( program.programStages[0].id ) ); -} - -d.resolve(); + +if(program.programStages){ +build = build.then(function() { +var d = $.Deferred(); +var p = d.promise(); +dhis2.ec.store.get('programStages', program.programStages[0].id).done(function(obj) { +if(!obj || obj.version !== program.programStages[0].version) { +promise = promise.then( getProgramStage( program.programStages[0].id ) ); +} + +d.resolve(); +}); + +return p; }); - -return p; -}); - +} }); build.done(function() { @@ -442,22 +446,25 @@ var build = builder.promise(); _.each( _.values( programs ), function ( program ) { -_.each(_.values( program.programStages[0].programStageDataElements), function(prStDe){ -if( prStDe.dataElement.optionSet prStDe.dataElement.optionSet.id ){ -build = build.then(function() { -var d = $.Deferred(); -var p = d.promise(); -dhis2.ec.store.get('optionSets', prStDe.dataElement.optionSet.id).done(function(obj) { -if(!obj || obj.version !== prStDe.dataElement.optionSet.version) { -promise = promise.then( getOptionSet( prStDe.dataElement.optionSet.id ) ); -} -d.resolve(); + +if(program.programStages program.programStages[0].programStageDataElements){ +_.each(_.values( program.programStages[0].programStageDataElements), function(prStDe){ +if( prStDe.dataElement prStDe.dataElement.optionSet prStDe.dataElement.optionSet.id ){ +build = build.then(function() { +var d = $.Deferred(); +var p = d.promise(); +dhis2.ec.store.get('optionSets', prStDe.dataElement.optionSet.id).done(function(obj) { +if(!obj || obj.version !== prStDe.dataElement.optionSet.version) { +promise =
[Dhis2-devs-core] thanks
Hi devs, thanks all for the hard work leading up to 2.18. It was a short time-frame but we managed to get a strong release out. Lars -- Mailing list: https://launchpad.net/~dhis2-devs-core Post to : dhis2-devs-core@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs-core More help : https://help.launchpad.net/ListHelp
Re: [Dhis2-devs] Aggreration query for single event without registration
Robin, We have a feature to get number of events for a given program stage. Two options need to be set: 1) Operator, at the top of the page, need to be 'Number of visits' 2) Under the Program tab, select 'Visited selected program stage' The formula will then be on this format : [PS:391] With 391 being the internal id of the program stage. That should give you the total number of events for your single event without registration program. Ola -- 21. jan. 2015 10:37 skrev Robin Martens mart...@sher.be følgende: Hi all, Is it possible in the Aggregation Query Builder to use the Number of tracked entities operator to calculate a number of events, especially when it concerns Single events without registration? I tried it and although it finds the events based on the conditions, it always returns 0 as a value. Regards, Robin ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18102: Dashboard. Deleteing dashboard item from database when removed from dashboard
revno: 18102 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 12:23:36 +0100 message: Dashboard. Deleteing dashboard item from database when removed from dashboard modified: dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardService.java dhis-2/dhis-api/src/test/java/org/hisp/dhis/dashboard/DashboardTest.java dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/dashboard/impl/DefaultDashboardService.java dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/DashboardController.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/dashboard/Dashboard.java' --- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java 2015-01-17 07:41:26 + +++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java 2015-01-22 11:23:36 + @@ -28,22 +28,22 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +import java.util.ArrayList; +import java.util.List; + +import org.hisp.dhis.common.BaseIdentifiableObject; +import org.hisp.dhis.common.DxfNamespaces; +import org.hisp.dhis.common.IdentifiableObject; +import org.hisp.dhis.common.annotation.Scanned; +import org.hisp.dhis.common.view.DetailedView; +import org.hisp.dhis.common.view.ExportView; + import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonView; import com.fasterxml.jackson.databind.annotation.JsonSerialize; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement; -import org.hisp.dhis.common.BaseIdentifiableObject; -import org.hisp.dhis.common.DxfNamespaces; -import org.hisp.dhis.common.IdentifiableObject; -import org.hisp.dhis.common.annotation.Scanned; -import org.hisp.dhis.common.view.DetailedView; -import org.hisp.dhis.common.view.ExportView; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; /** * @author Lars Helge Overland @@ -110,27 +110,6 @@ } /** - * Removes the item with the given identifier from this dashboard. - * - * @param uid the item uid. - */ -public boolean removeItem( String uid ) -{ -IteratorDashboardItem iter = items.iterator(); - -while ( iter.hasNext() ) -{ -if ( uid.equals( iter.next().getUid() ) ) -{ -iter.remove(); -return true; -} -} - -return false; -} - -/** * Returns the item with the given uid, or null if no item with the given * uid is present for this dashboard. * @@ -163,6 +142,14 @@ return null; } + +/** + * Indicates whether this dashboard has at least one item. + */ +public boolean hasItems() +{ +return items != null !items.isEmpty(); +} @JsonProperty @JacksonXmlProperty( namespace = DxfNamespaces.DXF_2_0 ) === modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardService.java' --- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardService.java 2015-01-21 09:30:45 + +++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardService.java 2015-01-22 11:23:36 + @@ -43,6 +43,10 @@ { final String ID = DashboardService.class.getName(); +// - +// Dashboard +// - + DashboardSearchResult search( String query ); DashboardSearchResult search( String query, SetString maxTypes ); @@ -63,10 +67,16 @@ Dashboard getDashboard( String uid ); +// - +// DashboardItem +// - + void updateDashboardItem( DashboardItem item ); DashboardItem getDashboardItem( String uid ); +void deleteDashboardItem( DashboardItem item ); + int countMapDashboardItems( Map map ); int countChartDashboardItems( Chart chart ); === modified file 'dhis-2/dhis-api/src/test/java/org/hisp/dhis/dashboard/DashboardTest.java' --- dhis-2/dhis-api/src/test/java/org/hisp/dhis/dashboard/DashboardTest.java 2015-01-17 07:41:26 + +++ dhis-2/dhis-api/src/test/java/org/hisp/dhis/dashboard/DashboardTest.java 2015-01-22
[Dhis2-devs] Fwd: [Bug 1402244] [NEW] event report/visulizer: option set sort order not respocted
Hi OIav/Devs Is this bug related to my observation: I cannot get event (aggregate) analytics to sort my data by column [OU] alphabetically ASC. Right now data is displayed with no apparent display order... Regards, Greg -- Forwarded message -- From: Olav P 1402...@bugs.launchpad.net Date: Sat, Dec 13, 2014 at 7:41 PM Subject: [Dhis2-devs] [Bug 1402244] [NEW] event report/visulizer: option set sort order not respocted To: dhis2-devs@lists.launchpad.net Public bug reported: Event report/visulizer apps do not respect the sort order that is set for option sets. 2.17. ** Affects: dhis2 Importance: Undecided Status: New -- You received this bug notification because you are a member of DHIS 2 developers, which is subscribed to DHIS. https://bugs.launchpad.net/bugs/1402244 Title: event report/visulizer: option set sort order not respocted Status in DHIS 2: New Bug description: Event report/visulizer apps do not respect the sort order that is set for option sets. 2.17. To manage notifications about this bug go to: https://bugs.launchpad.net/dhis2/+bug/1402244/+subscriptions ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp -- *Health Information Systems Program - South Africa* *- - - - - - - **- - - - - - - **- - - - - - - **- - - - - - - **- - - - - * Mobile :073 246 2992 Landline: 021 554 3130 Fax: 086 733 8432 Skype: gregory_rowles ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
Re: [Dhis2-devs] cumulative data in Data Visualizer and Pilot Table
Hi Calle, it may not be good, but it is usually always necessary with the type of data which DHIS 2 normally stores. Take logistics data as an example. The data is usually reported each day, but for which one may not have recorded zeros for particular activities, such as when a given commodity is not dispensed. It is not really efficient to record all these zeros, so normally, they would simply not be recorded. When it comes to calculating a daily stock level, one will have missing observations, combined with a requirement to have a daily stock level. So, in this case, you must use the last observation carried forward approach, unless you want to record a zero for each day, for potentially thousands of commodities. Not really efficient. Same could be said when aggregating from facilities to national level. If any data is missing. It would needed to be imputed, either by using the LOCF approach, or other statistical methods (means for instance). We just need to take this into account when dealing with cumulative time data, otherwise, any sorts of calculations are usually simply not possible. Regards, Jason On Thu, Jan 22, 2015 at 6:55 AM, Calle Hedberg calle.hedb...@gmail.com wrote: Hi, I'm not sure if auto-replicating the previous month's value for a missing month is such a good idea. It's conceptually very similar to the ability in DHIS 1.x to use regression analysis to insert missing values, BUT we always blocked that for recent months - the idea was always that using regression analysis to insert missing values was a last resort which only could/should be available after several months (i.e. after all other avenues to get the missing data are exhausted). regards Calle On 21/01/2015, Jason Pickering jason.p.picker...@gmail.com wrote: One potentially tricky thing to keep in mind here is the problem of missing data, i.e. if the facility does not report for a month, or they report a zero and the data element is zero insignificant. Normally in time-series data, the last observation would be carried forward (LOCF). The spec does not really mention this, but in all likelihood, this would need to be part of the implementation. Regards, Jason On Wed, Jan 21, 2015 at 10:32 AM, John Lewis johnlewis.h...@gmail.com wrote: Hi Lars, Example in Excel. We had this chart in Dhis1 series. John On Wed, Jan 21, 2015 at 4:18 PM, John Lewis johnlewis.h...@gmail.com wrote: Hi Lars, Done. https://blueprints.launchpad.net/dhis2/+spec/visualisation-cumulative-chart Regards, John On Mon, Jan 19, 2015 at 5:11 PM, Lars Helge Øverland larshe...@gmail.com wrote: Hi John, yes that would be possible to implement. Feel free to write a blueprint with a bit more detail and we can schedule it on the road map. regards, Lars On Fri, Jan 16, 2015 at 3:00 AM, John Lewis johnlewis.h...@gmail.com wrote: Hi Guys, Various countries want to analyse the data cumulatively. for example compare BCG dose given (data element) for last 12 (or /6/3) month with graph showing monthly data and cumulative value. Is this possible to include it in analysis Regards, John ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp -- Jason P. Pickering email: jason.p.picker...@gmail.com tel:+46764147049 -- *** Calle Hedberg 46D Alma Road, 7700 Rosebank, SOUTH AFRICA Tel/fax (home): +27-21-685-6472 Cell: +27-82-853-5352 Iridium SatPhone: +8816-315-19274 Email: calle.hedb...@gmail.com Skype: calle_hedberg *** -- Jason P. Pickering email: jason.p.picker...@gmail.com tel:+46764147049 ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
Re: [Dhis2-devs] [Dhis2-users] DHIS version 2.18 is released
Congrats DHIS2 team.. Will check out the new version. Thanx On Thu, Jan 22, 2015 at 3:16 PM, Adebusoye Anifalaje bus...@hisp.org wrote: These are excellent features. It's amazing how you keep raising the bar! Congrats to the team. Now, time to test. Regards Busoye Sent from my Samsung Galaxy smartphone. Original message From: Lars Helge Øverland larshe...@gmail.com Date:22/01/2015 09:34 (GMT+00:00) To: DHIS 2 Developers list dhis2-devs@lists.launchpad.net, DHIS 2 Users list dhis2-us...@lists.launchpad.net Cc: Subject: [Dhis2-devs] DHIS version 2.18 is released Hi all, DHIS version 2.18 is out. We have some nice new features for you. New and interactive dashboard: The dashboard has received a lot of improvements. Demo https://apps.dhis2.org/demo/dhis-web-dashboard-integration/index.action (login with admin/district) - Interactive items: The map items let you zoom in or out and drill down/float up between layers. Click on series in charts to hide or show them. Hover over maps and charts to see data values and details. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-interactive.png - Google maps: The map dashboard items now use Google maps as background layer. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-google-maps.png - Re-size items: You can re-size items and switch between normal, double and full width by clicking on the resize link on the item headers. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-resize.png - Event reports: You can now include event reports in your dashboard. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-event-reports.png - Smarter search: Search by words independently to find favorites more easily, e.g. ANC district. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-search.png - More features: Support for pivots with legend sets, facility map layers and radius for map points. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-radius.png - Better looks: The dashboard items are rendered using the pivot table, data visualizer and GIS components which give a better visual appearance. Simpler configuration and loading of apps: Apps are now loaded by default through the Web API without any need for configuration. The benefit is that you can upgrade your DHIS 2 version without affecting already installed apps. The app configuration can be set through the apps Web API resource. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/app-settings.png | Docs https://www.dhis2.org/doc/snapshot/en/developer/html/ch02s06.html Managed users: A new managed users concept for user management has been introduced. This allows you to explicitly define which users are allowed to modify which users. This is done by defining users groups to manage other user groups through the standard user interface. To enable this you should grant users the authority to Add/update users within managed groups instead of the normal Add/update users. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/managed-user-groups.png | Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch07.html#d5e1533 Replication of users: New feature for creating an identical copy of a user, with a new username and password. Replicating accounts is useful when working with support requests related to access control. Select a user in from the user list, select replicate and enter new credentials. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/replicate-user.png | Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch07.html#user_maintenance | Demo https://apps.dhis2.org/demo/dhis-web-maintenance-user/alluser.action Tracker enrollment history: In tracker capture dashboard you can now list historical enrollments by clicking on History and view captured data for each of them. Notes can be added to historical events. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/tracker-history.png | Demo https://apps.dhis2.org/demo/dhis-web-tracker-capture/index.html#/ Easy enrollment for relatives: A program can be configured to present shortcuts for relatives, which now can be easily enrolled into a specified program. As an example, for a mother and child program you can now specify that the child should be added into a immunization program. This will make the immunization pre-selected in relationship dialog. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/relationship-shortcut.png Favorite names in dialogs: In all analysis apps you can see the name of the current favorite in the header of the favorite and share dialogs. This makes it simpler to see which favorite you are working on e.g. when updating favorites. Screenshot
Re: [Dhis2-devs] DHIS version 2.18 is released
These are excellent features. It's amazing how you keep raising the bar! Congrats to the team. Now, time to test. Regards Busoye Sent from my Samsung Galaxy smartphone. Original message From: Lars Helge Øverland larshe...@gmail.com Date:22/01/2015 09:34 (GMT+00:00) To: DHIS 2 Developers list dhis2-devs@lists.launchpad.net, DHIS 2 Users list dhis2-us...@lists.launchpad.net Cc: Subject: [Dhis2-devs] DHIS version 2.18 is released Hi all, DHIS version 2.18 is out. We have some nice new features for you. New and interactive dashboard: The dashboard has received a lot of improvements. Demo (login with admin/district) - Interactive items: The map items let you zoom in or out and drill down/float up between layers. Click on series in charts to hide or show them. Hover over maps and charts to see data values and details. Screenshot - Google maps: The map dashboard items now use Google maps as background layer. Screenshot - Re-size items: You can re-size items and switch between normal, double and full width by clicking on the resize link on the item headers. Screenshot - Event reports: You can now include event reports in your dashboard. Screenshot - Smarter search: Search by words independently to find favorites more easily, e.g. “ANC district”. Screenshot - More features: Support for pivots with legend sets, facility map layers and radius for map points. Screenshot - Better looks: The dashboard items are rendered using the pivot table, data visualizer and GIS components which give a better visual appearance. Simpler configuration and loading of apps: Apps are now loaded by default through the Web API without any need for configuration. The benefit is that you can upgrade your DHIS 2 version without affecting already installed apps. The app configuration can be set through the apps Web API resource. Screenshot | Docs Managed users: A new “managed users” concept for user management has been introduced. This allows you to explicitly define which users are allowed to modify which users. This is done by defining users groups to manage other user groups through the standard user interface. To enable this you should grant users the authority to Add/update users within managed groups instead of the normal “Add/update users”. Screenshot | Docs Replication of users: New feature for creating an identical copy of a user, with a new username and password. Replicating accounts is useful when working with support requests related to access control. Select a user in from the user list, select replicate and enter new credentials. Screenshot | Docs | Demo Tracker enrollment history: In tracker capture dashboard you can now list historical enrollments by clicking on “History” and view captured data for each of them. Notes can be added to historical events. Screenshot | Demo Easy enrollment for relatives: A program can be configured to present shortcuts for relatives, which now can be easily enrolled into a specified program. As an example, for a “mother and child” program you can now specify that the child should be added into a “immunization” program. This will make the immunization pre-selected in relationship dialog. Screenshot Favorite names in dialogs: In all analysis apps you can see the name of the current favorite in the header of the favorite and share dialogs. This makes it simpler to see which favorite you are working on e.g. when updating favorites. Screenshot | Demo CORS support: DHIS 2 now supports Cross-origin resource sharing (CORS), which is a mechanism that allows resources to be requested from another domain. This means most notably that you can make requests to the DHIS 2 Web API from a web page or portal living on another domain than the DHIS 2 instance. The domains which should be allowed access must be defined under system settings remote access. Docs | Screenshot See apps authorities: We have added authorities for seeing apps so that you can control per user roles who should be allowed to access which apps from the top menu. Screenshot Clear local storage app: A new app has been added for clearing the application storage, which is the area where DHIS 2 stores data locally in the web browser. This is sometimes tricky to clear and web browsers have different menu layout for doing it, so an app is useful e.g. when doing user support. Screenshot | Demo Attributes for program: Dynamic meta-data attributes can now be defined for programs from data administration attributes. Screenshot | Demo Remove expired invitations: A new maintenance function has been added under data administration maintenance for deleting users which represent user account invitations which now have expired. This is useful when you send out a lot of user invitations and need to clean up after some time. Docs | Demo Infrastructural indicator data in GIS: You can configure an indicator group as
Re: [Dhis2-devs] Validation rules in data entry form
Hi Anne For doing the same you can find other very good documentations available on www.dhis2.org Regards Brajesh Murari On Jan 21, 2015 10:55 PM, Brajesh Murari bramur...@gmail.com wrote: Hi Anne, The most simple way to set min-max for a multidimensional data element is to assign that multi dimensional data element to any specific period type dataset or you can create new dataset with certain period type and assign this multi dimensional data element in this new dataset and assign this dataset to at list one organisation unit and then visit to data entry module and select that organisation unit on which you have assigned this dataset and then select that dataset from dataset drop down button and then select a period from period drop down, you will find that data element with multiple option in data entry form, and then double click on each data entry text box that will appear with a popup window, and in this popup window, you can find two text fields, here you can enter values for min and max and then press save button. This way you will have to set min-max for all rest available other option sets of that multi dimensional data element. These entered min-max values would be uniform across all periods for that dataset period type for that origination unit. There is another way to do the same in Data Quality module, where you can simultaneously set min-max value for all multidimensional data element option sets for that data data element and for other multi dimensional data elements with option sets belongs to that dataset. But I am not sure this functionality is available in the revision build you are using. Thanks and Regards Brajesh Murari On Jan 21, 2015 3:19 PM, Anne Grace missannegr...@gmail.com wrote: Thanks for the clarifications Brajesh, I know understand what the system may do. My last question now is how can I set min-max for a multi dimensional data element? Thanks again, Anne On 21 Jan 2015, at 09:31, Brajesh Murari bramur...@gmail.com wrote: One more thing, I would like to clarify as per your raised question, DHIS is a community driven, community based web application with a very wide applicability, AND unfortunately, this community does't support any IS:IS activity at any point at any way across. Regards Brajesh Murari Hi Anne, Let me clear your point which need to put your attention and understandability about setting up a 'min-max' value and defining 'validation rule' in global context of DHIS. Setting 'min-max' value for a data element doe,t implies, you are defining a validation rule for that data element in belonging dataset, its just a range of value with certain predefined set of numeric interval for that data element without any mathematical operator or mathematical expression, if and only if data element is of number type or its variant type like flot, int, double etc. It can be varied dataset vs organisation unit wise for a specific data element with different period if you think in multi dimensional context. It only prompt with multi colours indicative popups during data entry, if and only if, the entered value does't belong to that predefined specified range of entered data value before or after pressing 'dataset completeness' button available in data entry form. Setting 'Validation Rule' in DHIS means defining a mathematical expression or formula like indicators which include all the time at least one or more data elements as mathematical operand with some predefined mathematical operators. Validation Rule in DHIS acts like a filtered condition which is uniform for all organisation unit and datasets for any period but depends upon defined period type. This would show you both weather validation rule pass or fail with list which can be exportable in multiple formats like PDF , CVS, Work Book etc. You can make validation rule group with multi validation rules and can perform and operate group wise validation test for checking data quality but officially, this activity is not recommended and banned in some of the countries is. Group Wise Validation Analysis. I think, you should prepare to define validation rule in Data Quality for these data elements, because 'min-max' is for different purpose like setting up a target for specific data element for a period for specific organisation unit. Regards Brajesh Murari Dear Brajesh, Could You guide me in please! Hi Anne, Let me clear your point which need to put your attention and understandability about setting up a 'min-max' value and defining 'validation rule' in global context of DHIS. Setting 'min-max' value for a data element doe,t implies, you are defining a validation rule for that data element in belonging dataset, its just a range of value with certain predefined set of numeric interval for that data element without any mathematical operator or mathematical expression, if and only if data element is of number type or its variant
[Dhis2-devs] DHIS version 2.18 is released
Hi all, DHIS version 2.18 is out. We have some nice new features for you. New and interactive dashboard: The dashboard has received a lot of improvements. Demo https://apps.dhis2.org/demo/dhis-web-dashboard-integration/index.action (login with admin/district) - Interactive items: The map items let you zoom in or out and drill down/float up between layers. Click on series in charts to hide or show them. Hover over maps and charts to see data values and details. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-interactive.png - Google maps: The map dashboard items now use Google maps as background layer. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-google-maps.png - Re-size items: You can re-size items and switch between normal, double and full width by clicking on the resize link on the item headers. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-resize.png - Event reports: You can now include event reports in your dashboard. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-event-reports.png - Smarter search: Search by words independently to find favorites more easily, e.g. “ANC district”. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-search.png - More features: Support for pivots with legend sets, facility map layers and radius for map points. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-radius.png - Better looks: The dashboard items are rendered using the pivot table, data visualizer and GIS components which give a better visual appearance. Simpler configuration and loading of apps: Apps are now loaded by default through the Web API without any need for configuration. The benefit is that you can upgrade your DHIS 2 version without affecting already installed apps. The app configuration can be set through the apps Web API resource. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/app-settings.png | Docs https://www.dhis2.org/doc/snapshot/en/developer/html/ch02s06.html Managed users: A new “managed users” concept for user management has been introduced. This allows you to explicitly define which users are allowed to modify which users. This is done by defining users groups to manage other user groups through the standard user interface. To enable this you should grant users the authority to Add/update users within managed groups instead of the normal “Add/update users”. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/managed-user-groups.png | Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch07.html#d5e1533 Replication of users: New feature for creating an identical copy of a user, with a new username and password. Replicating accounts is useful when working with support requests related to access control. Select a user in from the user list, select replicate and enter new credentials. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/replicate-user.png | Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch07.html#user_maintenance | Demo https://apps.dhis2.org/demo/dhis-web-maintenance-user/alluser.action Tracker enrollment history: In tracker capture dashboard you can now list historical enrollments by clicking on “History” and view captured data for each of them. Notes can be added to historical events. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/tracker-history.png | Demo https://apps.dhis2.org/demo/dhis-web-tracker-capture/index.html#/ Easy enrollment for relatives: A program can be configured to present shortcuts for relatives, which now can be easily enrolled into a specified program. As an example, for a “mother and child” program you can now specify that the child should be added into a “immunization” program. This will make the immunization pre-selected in relationship dialog. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/relationship-shortcut.png Favorite names in dialogs: In all analysis apps you can see the name of the current favorite in the header of the favorite and share dialogs. This makes it simpler to see which favorite you are working on e.g. when updating favorites. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/favorite-names.png | Demo https://apps.dhis2.org/demo/dhis-web-visualizer/index.html CORS support: DHIS 2 now supports Cross-origin resource sharing (CORS), which is a mechanism that allows resources to be requested from another domain. This means most notably that you can make requests to the DHIS 2 Web API from a web page or portal living on another domain than the DHIS 2 instance. The domains which should be allowed access must be defined under system settings remote access. Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch22.html#d5e3857 | Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/cors.png See apps
Re: [Dhis2-devs] [Dhis2-users] DHIS version 2.18 is released
Amazing features.thumbs up! It keeps getting better as usual. BlackBerry: 3114F90C Phone: 08028851441, 08035560463 emails: deemo...@yahoo.com, addyr...@yahoo.com Yahoo IM: deemoyes Facebook: pharael twitter:pharaell On Thursday, January 22, 2015 10:34 AM, Lars Helge Øverland larshe...@gmail.com wrote: Hi all, DHIS version 2.18 is out. We have some nice new features for you. New and interactive dashboard: The dashboard has received a lot of improvements. Demo (login with admin/district) - Interactive items: The map items let you zoom in or out and drill down/float up between layers. Click on series in charts to hide or show them. Hover over maps and charts to see data values and details. Screenshot - Google maps: The map dashboard items now use Google maps as background layer. Screenshot - Re-size items: You can re-size items and switch between normal, double and full width by clicking on the resize link on the item headers. Screenshot - Event reports: You can now include event reports in your dashboard. Screenshot - Smarter search: Search by words independently to find favorites more easily, e.g. “ANC district”. Screenshot - More features: Support for pivots with legend sets, facility map layers and radius for map points. Screenshot - Better looks: The dashboard items are rendered using the pivot table, data visualizer and GIS components which give a better visual appearance. Simpler configuration and loading of apps: Apps are now loaded by default through the Web API without any need for configuration. The benefit is that you can upgrade your DHIS 2 version without affecting already installed apps. The app configuration can be set through the apps Web API resource. Screenshot | Docs Managed users: A new “managed users” concept for user management has been introduced. This allows you to explicitly define which users are allowed to modify which users. This is done by defining users groups to manage other user groups through the standard user interface. To enable this you should grant users the authority to Add/update users within managed groups instead of the normal “Add/update users”. Screenshot | Docs Replication of users: New feature for creating an identical copy of a user, with a new username and password. Replicating accounts is useful when working with support requests related to access control. Select a user in from the user list, select replicate and enter new credentials. Screenshot | Docs | Demo Tracker enrollment history: In tracker capture dashboard you can now list historical enrollments by clicking on “History” and view captured data for each of them. Notes can be added to historical events. Screenshot | Demo Easy enrollment for relatives: A program can be configured to present shortcuts for relatives, which now can be easily enrolled into a specified program. As an example, for a “mother and child” program you can now specify that the child should be added into a “immunization” program. This will make the immunization pre-selected in relationship dialog. Screenshot Favorite names in dialogs: In all analysis apps you can see the name of the current favorite in the header of the favorite and share dialogs. This makes it simpler to see which favorite you are working on e.g. when updating favorites. Screenshot | Demo CORS support: DHIS 2 now supports Cross-origin resource sharing (CORS), which is a mechanism that allows resources to be requested from another domain. This means most notably that you can make requests to the DHIS 2 Web API from a web page or portal living on another domain than the DHIS 2 instance. The domains which should be allowed access must be defined under system settings remote access. Docs | Screenshot See apps authorities: We have added authorities for seeing apps so that you can control per user roles who should be allowed to access which apps from the top menu. Screenshot Clear local storage app: A new app has been added for clearing the application storage, which is the area where DHIS 2 stores data locally in the web browser. This is sometimes tricky to clear and web browsers have different menu layout for doing it, so an app is useful e.g. when doing user support. Screenshot | Demo Attributes for program: Dynamic meta-data attributes can now be defined for programs from data administration attributes. Screenshot | Demo Remove expired invitations: A new maintenance function has been added under data administration maintenance for deleting users which represent user account invitations which now have expired. This is useful when you send out a lot of user invitations and need to clean up after some time. Docs | Demo Infrastructural indicator data in GIS: You can configure an indicator group as “infrastructural” under general system settings, which will subsequently show up with indicator data in a dialog when left-clicking on an area or point in GIS. Screenshot | Demo Instant
Re: [Dhis2-devs] [Dhis2-users] DHIS version 2.18 is released
Congs DHIS2 Developers and Team. Thanks Lars for this. Looking forward for an upgrade. Alex On Thu, Jan 22, 2015 at 12:34 PM, Lars Helge Øverland larshe...@gmail.com wrote: Hi all, DHIS version 2.18 is out. We have some nice new features for you. New and interactive dashboard: The dashboard has received a lot of improvements. Demo https://apps.dhis2.org/demo/dhis-web-dashboard-integration/index.action (login with admin/district) - Interactive items: The map items let you zoom in or out and drill down/float up between layers. Click on series in charts to hide or show them. Hover over maps and charts to see data values and details. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-interactive.png - Google maps: The map dashboard items now use Google maps as background layer. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-google-maps.png - Re-size items: You can re-size items and switch between normal, double and full width by clicking on the resize link on the item headers. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-resize.png - Event reports: You can now include event reports in your dashboard. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-event-reports.png - Smarter search: Search by words independently to find favorites more easily, e.g. “ANC district”. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-search.png - More features: Support for pivots with legend sets, facility map layers and radius for map points. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/dashboard-radius.png - Better looks: The dashboard items are rendered using the pivot table, data visualizer and GIS components which give a better visual appearance. Simpler configuration and loading of apps: Apps are now loaded by default through the Web API without any need for configuration. The benefit is that you can upgrade your DHIS 2 version without affecting already installed apps. The app configuration can be set through the apps Web API resource. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/app-settings.png | Docs https://www.dhis2.org/doc/snapshot/en/developer/html/ch02s06.html Managed users: A new “managed users” concept for user management has been introduced. This allows you to explicitly define which users are allowed to modify which users. This is done by defining users groups to manage other user groups through the standard user interface. To enable this you should grant users the authority to Add/update users within managed groups instead of the normal “Add/update users”. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/managed-user-groups.png | Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch07.html#d5e1533 Replication of users: New feature for creating an identical copy of a user, with a new username and password. Replicating accounts is useful when working with support requests related to access control. Select a user in from the user list, select replicate and enter new credentials. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/replicate-user.png | Docs https://www.dhis2.org/doc/snapshot/en/user/html/ch07.html#user_maintenance | Demo https://apps.dhis2.org/demo/dhis-web-maintenance-user/alluser.action Tracker enrollment history: In tracker capture dashboard you can now list historical enrollments by clicking on “History” and view captured data for each of them. Notes can be added to historical events. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/tracker-history.png | Demo https://apps.dhis2.org/demo/dhis-web-tracker-capture/index.html#/ Easy enrollment for relatives: A program can be configured to present shortcuts for relatives, which now can be easily enrolled into a specified program. As an example, for a “mother and child” program you can now specify that the child should be added into a “immunization” program. This will make the immunization pre-selected in relationship dialog. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/relationship-shortcut.png Favorite names in dialogs: In all analysis apps you can see the name of the current favorite in the header of the favorite and share dialogs. This makes it simpler to see which favorite you are working on e.g. when updating favorites. Screenshot https://www.dhis2.org/sites/all/themes/dhis/images/218/favorite-names.png | Demo https://apps.dhis2.org/demo/dhis-web-visualizer/index.html CORS support: DHIS 2 now supports Cross-origin resource sharing (CORS), which is a mechanism that allows resources to be requested from another domain. This means most notably that you can make requests to the DHIS 2 Web API from a web page or portal living on another domain than the DHIS 2 instance. The
Re: [Dhis2-devs] Problems with detailed metadata export..
Sorry Jason. A quick look through isnt shedding light on me :-( Is this a test environment or did you run that against a running server with other users? There doesn't seem to be any tight loop like we saw with the paging bug, so I guess what we have here is not so much as a logical error as some sort of gross inefficiency somewhere. One thing I notice is that almost all RUNNABLE threads are somehow engaged with operations relating to user service. getCurrentUser, getUserCredentials etc. Given that this is a static snapshot in time of where exactly each thread is at, it seems odd that so many are caught up chasing users instead of doing real work. This might be a red herring or a pointer to that gross inefficiency - it might be that if the user credentials are being retrieved and tested each time the user is touching a metadata object (and it it is maybe touching many of them with this metadata export) that that is leading to excessive activity. Do you have a vast number of users in the system by any chance? On 22 January 2015 at 08:09, Jason Pickering jason.p.picker...@gmail.com wrote: OK, is this better? Stack attached. Tasks: 178 total, 1 running, 177 sleeping, 0 stopped, 0 zombie Cpu(s): 99.1%us, 0.1%sy, 0.0%ni, 0.4%id, 0.0%wa, 0.0%hi, 0.0%si, 0.3%st Mem: 16433100k total, 16330904k used, 102196k free,71828k buffers Swap: 262140k total,25108k used, 237032k free, 11411252k cached PID USER PR NI VIRT RES SHR S %CPU %MEMTIME+ COMMAND 28091 dhis 20 0 12.0g 3.6g 5916 S 796 23.0 328:48.52 java Command used was curl --verbose http:///dhis/api/dataElements.json?links=falsepaging=false; -u : Regards, Jason On Wed, Jan 21, 2015 at 11:05 PM, Bob Jolliffe bobjolli...@gmail.com wrote: Jason the cpu is not really through the roof here. Can you try another dump (while the cpu is through the roof)? The interesting threads to look at are the http-bio-8080 threads, which are the tomcat worker threads. If the server is not being accessed by dozens of users most of them should be sitting in a WAITING state. So then it is interesting to look at those which are marked as RUNNABLE. These are the ones which are trying as hard as they can to get the attention of the scheduler in order to chew cpu cycles. So if your process has become cpu bound then sometimes its possible to figure out which thread it is and what it is trying to do. This attached stack dump doesn't reveal much unfortunately, but then again the cpu (from top) is showing 62% idle. So try and get the cpu burning up again and grab 2 or 3 jstack samples. If it is cpu bound then it might show. On 21 January 2015 at 19:28, Jason Pickering jason.p.picker...@gmail.com wrote: Not really sure what is going on, but here is the stack dump. Maybe it will help. And some more info below. top - 21:26:40 up 477 days, 16:20, 2 users, load average: 2.99, 2.05, 1.03 Tasks: 171 total, 1 running, 170 sleeping, 0 stopped, 0 zombie Cpu(s): 38.3%us, 0.0%sy, 0.0%ni, 61.6%id, 0.0%wa, 0.0%hi, 0.0%si, 0.1%st Mem: 16433100k total, 15416512k used, 1016588k free,86276k buffers Swap: 262140k total,18872k used, 243268k free, 12412748k cached PID USER PR NI VIRT RES SHR S %CPU %MEMTIME+ COMMAND 28091 dhis 20 0 11.8g 2.1g 13m S 307 13.2 29:39.99 java Regards, Jason On Wed, Jan 21, 2015 at 7:42 PM, Bob Jolliffe bobjolli...@gmail.com wrote: If it is running for 15 minutes then almost certainly it is stuck in some kind of loop. Find the pid of the running jvm and also the owner of the java process. Then run: sudo -u process owner jstack pid jstack.txt That might give an idea of what the threads are up to ... On 21 January 2015 at 18:26, Morten Olav Hansen morte...@gmail.com wrote: 18k is not really that much.. is it giving you any kind of errors? given the SL demo db... we can easily export much more objects that that.. -- Morten On Thu, Jan 22, 2015 at 12:42 AM, Bob Jolliffe bobjolli...@gmail.com wrote: Can you try and get a jstack dump while it is busy chomping cpu. That will probably indicate where in the code it is spinning. There was a problem earlier with a weakness in the paging code but should have been fixed by that build. On 21 January 2015 at 15:00, Jason Pickering jason.p.picker...@gmail.com wrote: In one DHIS2 instance, we have a rather large number of data elements, more than 18,000. During the detailed metadata export, a request is made to api/dataElements.json?paging=falselinks=false. This throws the CPU of the server through the roof, with the operation taking many minutes (has been running for 15 minutes now with no response).There are no errors in the logs or the browser. Build revision is not known, but it is 2.17 from from 2015-01-17 02:03. Any idea what might be going on here? Regards, Jason -- Jason P. Pickering
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18110: minor introspector fix, properly handle TEXT types
revno: 18110 committer: Morten Olav Hansen morte...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-23 11:34:37 +0700 message: minor introspector fix, properly handle TEXT types modified: dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/AbstractPropertyIntrospectorService.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-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/AbstractPropertyIntrospectorService.java' --- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/AbstractPropertyIntrospectorService.java 2015-01-19 09:33:53 + +++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/AbstractPropertyIntrospectorService.java 2015-01-23 04:34:37 + @@ -40,6 +40,8 @@ import org.hibernate.type.AssociationType; import org.hibernate.type.CollectionType; import org.hibernate.type.EntityType; +import org.hibernate.type.SingleColumnType; +import org.hibernate.type.TextType; import org.hibernate.type.Type; import org.hisp.dhis.common.AnalyticalObject; import org.hisp.dhis.common.BaseAnalyticalObject; @@ -49,7 +51,6 @@ import org.hisp.dhis.common.DimensionalObject; import org.hisp.dhis.common.IdentifiableObject; import org.hisp.dhis.common.NameableObject; -import org.hisp.dhis.user.UserGroup; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.ApplicationContext; import org.springframework.orm.hibernate4.LocalSessionFactoryBean; @@ -182,13 +183,18 @@ AnyType anyType = (AnyType) type; } -if ( hibernateProperty.getColumnSpan() 0 ) +if ( SingleColumnType.class.isInstance( type ) ) { Column column = (Column) hibernateProperty.getColumnIterator().next(); property.setUnique( column.isUnique() ); property.setRequired( !column.isNullable() ); property.setLength( column.getLength() ); + +if ( TextType.class.isInstance( type ) ) +{ +property.setLength( Integer.MAX_VALUE ); +} } properties.put( property.getName(), property ); ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18106: Missing deletion handler
revno: 18106 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 18:10:43 +0100 message: Missing deletion handler modified: dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/CompleteDataSetRegistrationDeletionHandler.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-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/CompleteDataSetRegistrationDeletionHandler.java' --- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/CompleteDataSetRegistrationDeletionHandler.java 2015-01-17 07:41:26 + +++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/CompleteDataSetRegistrationDeletionHandler.java 2015-01-22 17:10:43 + @@ -28,6 +28,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +import org.hisp.dhis.dataelement.DataElementCategoryOptionCombo; import org.hisp.dhis.organisationunit.OrganisationUnit; import org.hisp.dhis.period.Period; import org.hisp.dhis.system.deletion.DeletionHandler; @@ -88,4 +89,12 @@ { completeDataSetRegistrationService.deleteCompleteDataSetRegistrations( unit ); } + +@Override +public String allowDeleteDataElementCategoryOptionCombo( DataElementCategoryOptionCombo optionCombo ) +{ +String sql = SELECT COUNT(*) FROM completedatasetregistration where attributeoptioncomboid= + optionCombo.getId(); + +return jdbcTemplate.queryForObject( sql, Integer.class ) == 0 ? null : ERROR; +} } ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18105: event-capture - force to scroll to top of page when clicking save-and-add-new
revno: 18105 committer: Abyot Asalefew Gizaw aby...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 17:55:07 +0100 message: event-capture - force to scroll to top of page when clicking save-and-add-new removed: dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/appcache/CacheManifest.java added: dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/appcache/CacheManifestAction.java modified: dhis-2/dhis-web/dhis-web-apps/src/main/resources/struts.xml dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js -- 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-web/dhis-web-apps/src/main/resources/struts.xml' --- dhis-2/dhis-web/dhis-web-apps/src/main/resources/struts.xml 2014-12-15 14:00:36 + +++ dhis-2/dhis-web/dhis-web-apps/src/main/resources/struts.xml 2015-01-22 16:55:07 + @@ -46,7 +46,7 @@ action name=index class=org.hisp.dhis.commons.action.NoAction result name=success type=redirectindex.html/result /action - action name=cacheManifest class=org.hisp.dhis.appcache.CacheManifest + action name=cacheManifest class=org.hisp.dhis.appcache.CacheManifestAction param name=appPathdhis-web-event-capture/param param name=i18nPathi18n/param param name=appCacheevent-capture.appcache/param === modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js' --- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js 2015-01-21 20:11:11 + +++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js 2015-01-22 16:55:07 + @@ -9,6 +9,7 @@ $modal, $timeout, $translate, +$anchorScroll, storage, Paginator, OptionSetService, @@ -559,6 +560,7 @@ //decide whether to stay in the current screen or not. if(addingAnotherEvent){ $scope.showEventRegistration(); +$anchorScroll(); } } }); === removed file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/appcache/CacheManifest.java' --- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/appcache/CacheManifest.java 2015-01-17 07:41:26 + +++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/appcache/CacheManifest.java 1970-01-01 00:00:00 + @@ -1,204 +0,0 @@ -package org.hisp.dhis.appcache; - -/* - * Copyright (c) 2004-2015, 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 java.io.BufferedReader; -import java.io.ByteArrayInputStream; -import java.io.File; -import java.io.FileReader; -import java.io.IOException; -import java.io.InputStream; - -import javax.servlet.ServletContext; - -import org.apache.struts2.ServletActionContext; -import org.hisp.dhis.system.SystemInfo; -import org.hisp.dhis.system.SystemService; -import org.hisp.dhis.user.UserSettingService; -import org.springframework.beans.factory.annotation.Autowired; - -import com.opensymphony.xwork2.Action; - -/** - * @author Abyot Asalefew Gizaw aby...@gmail.com - * - */
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18108: Added DataElementCategoryDimensionDeletionHandler.java
revno: 18108 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 19:19:00 +0100 message: Added DataElementCategoryDimensionDeletionHandler.java added: dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryDimensionDeletionHandler.java modified: dhis-2/dhis-services/dhis-service-core/src/main/resources/META-INF/dhis/beans.xml -- 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 === added file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryDimensionDeletionHandler.java' --- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryDimensionDeletionHandler.java 1970-01-01 00:00:00 + +++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryDimensionDeletionHandler.java 2015-01-22 18:19:00 + @@ -0,0 +1,69 @@ +package org.hisp.dhis.dataelement; + +/* + * Copyright (c) 2004-2015, 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.system.deletion.DeletionHandler; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.jdbc.core.JdbcTemplate; + +/** + * @author Lars Helge Overland + */ +public class DataElementCategoryDimensionDeletionHandler +extends DeletionHandler +{ +@Autowired +private JdbcTemplate jdbcTemplate; + +// - +// DeletionHandler implementation +// - + +@Override +public String getClassName() +{ +return DataElementCategoryDimension.class.getSimpleName(); +} + +@Override +public String allowDeleteDataElementCategoryOption( DataElementCategoryOption categoryOption ) +{ +String sql = select count(*) from categorydimension_items where categoryoptionid = + categoryOption.getId(); + +return jdbcTemplate.queryForObject( sql, Integer.class ) == 0 ? null : ERROR; +} + +@Override +public String allowDeleteDataElementCategory( DataElementCategory category ) +{ +String sql = select count(*) from categorydimension where categoryid = + category.getId(); + +return jdbcTemplate.queryForObject( sql, Integer.class ) == 0 ? null : ERROR; +} +} === modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/META-INF/dhis/beans.xml' --- dhis-2/dhis-services/dhis-service-core/src/main/resources/META-INF/dhis/beans.xml 2015-01-15 15:11:38 + +++ dhis-2/dhis-services/dhis-service-core/src/main/resources/META-INF/dhis/beans.xml 2015-01-22 18:19:00 + @@ -1050,6 +1050,9 @@ class=org.hisp.dhis.dataelement.DataElementCategoryComboDeletionHandler property name=categoryService ref=org.hisp.dhis.dataelement.DataElementCategoryService / /bean + + bean id=org.hisp.dhis.dataelement.DataElementCategoryDimensionDeletionHandler +class=org.hisp.dhis.dataelement.DataElementCategoryDimensionDeletionHandler / bean id=org.hisp.dhis.dataset.DataSetDeletionHandler
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18109: Scripts
revno: 18109 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 19:25:25 +0100 message: Scripts modified: resources/sql/div.sql -- 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 'resources/sql/div.sql' --- resources/sql/div.sql 2015-01-21 20:27:48 + +++ resources/sql/div.sql 2015-01-22 18:25:25 + @@ -182,6 +182,14 @@ inner join categorycombo cc on ccoc.categorycomboid=cc.categorycomboid where coc.categoryoptioncomboid=2118430; +-- Get category option combos linked to category option + +select coc.categoryoptioncomboid as coc_id, coc.uid as coc_uid, co.categoryoptionid as co_id, co.name as co_name +from categoryoptioncombo coc +inner join categoryoptioncombos_categoryoptions coo on coc.categoryoptioncomboid=coo.categoryoptioncomboid +inner join dataelementcategoryoption co on coo.categoryoptionid=co.categoryoptionid +where co.uid='LPeJEUjotaB'; + -- Display data out of reasonable time range select * @@ -229,6 +237,15 @@ on (cc.categoryoptioncomboid=co.categoryoptioncomboid) where categorycomboid=12414 ); +-- (Write) Delete all data values for an attribute category option + +delete from datavalue dv +where dv.attributeoptioncomboid in ( + select coc.categoryoptioncomboid from categoryoptioncombo coc + inner join categoryoptioncombos_categoryoptions coo on coc.categoryoptioncomboid=coo.categoryoptioncomboid + inner join dataelementcategoryoption co on coo.categoryoptionid=co.categoryoptionid + where co.uid='LPeJEUjotaB'); + -- (Write) MD5 set password to district for admin user update users set password='48e8f1207baef1ef7fe478a57d19f2e5' where username='admin'; @@ -312,3 +329,18 @@ inner join section s on (ds.sectionid=s.sectionid) where s.datasetid=dsm.datasetid) and dsm.datasetid=1979200; + +-- (Write) Remove orphaned dashboard items + +delete from dashboarditem di +where di.dashboarditemid not in ( + select dashboarditemid from dashboard_items) +and di.dashboarditemid not in ( + select dashboarditemid from dashboarditem_reports) +and di.dashboarditemid not in ( + select dashboarditemid from dashboarditem_reporttables) +and di.dashboarditemid not in ( + select dashboarditemid from dashboarditem_resources) +and di.dashboarditemid not in ( + select dashboarditemid from dashboarditem_users); + ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18107: Added missing deletion handler
revno: 18107 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Thu 2015-01-22 18:53:46 +0100 message: Added missing deletion handler modified: dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataapproval/DataApprovalDeletionHandler.java dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DefaultDeletionManager.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-services/dhis-service-core/src/main/java/org/hisp/dhis/dataapproval/DataApprovalDeletionHandler.java' --- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataapproval/DataApprovalDeletionHandler.java 2015-01-17 07:41:26 + +++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataapproval/DataApprovalDeletionHandler.java 2015-01-22 17:53:46 + @@ -28,6 +28,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +import org.hisp.dhis.dataelement.DataElementCategoryOptionCombo; import org.hisp.dhis.system.deletion.DeletionHandler; import org.springframework.jdbc.core.JdbcTemplate; @@ -61,8 +62,16 @@ @Override public String allowDeleteDataApprovalLevel( DataApprovalLevel dataApprovalLevel ) { -String sql = SELECT COUNT(*) FROM dataapproval where dataapprovallevelid= + dataApprovalLevel.getId(); - +String sql = select count(*) from dataapproval where dataapprovallevelid= + dataApprovalLevel.getId(); + +return jdbcTemplate.queryForObject( sql, Integer.class ) == 0 ? null : ERROR; +} + +@Override +public String allowDeleteDataElementCategoryOptionCombo( DataElementCategoryOptionCombo optionCombo ) +{ +String sql = select count(*) from dataapproval where attributeoptioncomboid= + optionCombo.getId(); + return jdbcTemplate.queryForObject( sql, Integer.class ) == 0 ? null : ERROR; } } === modified file 'dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DefaultDeletionManager.java' --- dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DefaultDeletionManager.java 2015-01-17 07:41:26 + +++ dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DefaultDeletionManager.java 2015-01-22 17:53:46 + @@ -40,8 +40,10 @@ import java.util.List; /** + * TODO: Add support for failed allow tests on transitive deletion handlers which + * are called as part of delete methods. + * * @author Lars Helge Overland - * @version $Id$ */ public class DefaultDeletionManager implements DeletionManager @@ -102,6 +104,8 @@ String message = handler.getClassName() + (hint.isEmpty() ? : ( ( + hint + ))); +log.info( Delete was not allowed by + currentHandler + : + message ); + throw new DeleteNotAllowedException( DeleteNotAllowedException.ERROR_ASSOCIATED_BY_OTHER_OBJECTS, message ); } } ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp
[Dhis2-devs] Total Number of Entities Across Facilities
Hi Everyone, Please, how can I get the total number of entities who have received services across a number of orgunits? -- Thank you and Kind Regards *Immarcqulate. A (Emma Kassy) * *You miss 100% of the shots you don't take.* ___ Mailing list: https://launchpad.net/~dhis2-devs Post to : dhis2-devs@lists.launchpad.net Unsubscribe : https://launchpad.net/~dhis2-devs More help : https://help.launchpad.net/ListHelp