[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10198: add method to get only the J2ME SMSCommand

2013-03-14 Thread noreply

revno: 10198
committer: Long 
branch nick: dhis2
timestamp: Thu 2013-03-14 14:19:34 +0700
message:
  add method to get only the J2ME SMSCommand
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandService.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandStore.java
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/DefaultSMSCommandService.java
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/HibernateSMSCommandStore.java
  
dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.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/smscommand/SMSCommandService.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandService.java	2013-03-09 14:12:57 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandService.java	2013-03-14 07:19:34 +
@@ -43,4 +43,6 @@
 void save( Set codes );
 
 void delete( SMSCommand cmd );
+
+Collection getJ2MESMSCommands();
 }

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandStore.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandStore.java	2013-03-09 14:12:57 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/smscommand/SMSCommandStore.java	2013-03-14 07:19:34 +
@@ -41,4 +41,6 @@
 void delete( SMSCommand cmd );
 
 void save( Set codes );
+
+Collection getJ2MESMSCommands();
 }

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/DefaultSMSCommandService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/DefaultSMSCommandService.java	2012-06-13 08:44:07 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/DefaultSMSCommandService.java	2013-03-14 07:19:34 +
@@ -40,4 +40,10 @@
 public void delete(SMSCommand cmd){
smsCommandStore.delete(cmd);
 }
+
+@Override
+public Collection getJ2MESMSCommands()
+{
+return smsCommandStore.getJ2MESMSCommands();
+}
 }

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/HibernateSMSCommandStore.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/HibernateSMSCommandStore.java	2012-08-24 12:14:49 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/smscommand/HibernateSMSCommandStore.java	2013-03-14 07:19:34 +
@@ -9,6 +9,7 @@
 import org.hibernate.Transaction;
 import org.hibernate.criterion.Order;
 import org.hibernate.criterion.Restrictions;
+import org.hisp.dhis.sms.parse.ParserType;
 import org.springframework.beans.factory.annotation.Required;
 
 public class HibernateSMSCommandStore
@@ -76,5 +77,14 @@
 t.commit();
 s.flush();
 }
+
+@SuppressWarnings( "unchecked" )
+@Override
+public Collection getJ2MESMSCommands()
+{
+Criteria criteria = sessionFactory.getCurrentSession().createCriteria( SMSCommand.class );
+criteria.add( Restrictions.eq( "parserType", ParserType.J2ME_PARSER ) );
+return criteria.list();
+}
 
 }

=== modified file 'dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java'
--- dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java	2013-03-13 10:11:52 +
+++ dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java	2013-03-14 07:19:34 +
@@ -196,7 +196,7 @@
 mobileModel.setDatasets( facilityReportingService.getMobileDataSetsForUnit( unit, locale ) );
 mobileModel.setServerCurrentDate( new Date() );
 mobileModel.setLocales( getLocalStrings( i18nService.getAvailableLocales() ) );
-mobileModel.setSmsCommands( this.getMobileSMSCommands( smsCommandService.getSMSCommands() ) );
+mobileModel.setSmsCommands( this.getMobileSMSCommands( smsCommandService.getJ2MESMSCommands() ) );
 return mobileModel;
 }
 

___
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 10199: Only load program list according to type of programs in data entry form.

2013-03-14 Thread noreply

revno: 10199
committer: Tran Chau 
branch nick: dhis2
timestamp: Thu 2013-03-14 14:36:22 +0700
message:
  Only load program list according to type of programs in data entry form.
modified:
  
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStore.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addPatientForm.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addSingleEventRegistration.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/singleEventSelect.vm
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/addProgramStageForm.vm
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/updateProgramStageForm.vm


--
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-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStore.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStore.java	2013-02-19 06:54:22 +
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStore.java	2013-03-14 07:36:22 +
@@ -31,6 +31,7 @@
 import java.util.HashSet;
 import java.util.Set;
 
+import org.hibernate.Criteria;
 import org.hibernate.criterion.Restrictions;
 import org.hisp.dhis.common.hibernate.HibernateIdentifiableObjectStore;
 import org.hisp.dhis.organisationunit.OrganisationUnit;
@@ -83,9 +84,11 @@
 @Override
 public Collection get( int type, OrganisationUnit organisationUnit )
 {
-final String hql = "from Program p where p.type = :type and :organisationUnit in elements(p.organisationUnits)";
-
-return getQuery( hql ).setInteger( "type", type ).setEntity( "organisationUnit", organisationUnit ).list();
+Criteria criteria = getCriteria();
+criteria.createAlias( "organisationUnits", "orgunit" );
+criteria.add( Restrictions.eq( "type", type ) );
+criteria.add( Restrictions.eq( "orgunit.id", organisationUnit.getId() ) );
+return criteria.list();
 }
 
 @Override
@@ -97,7 +100,7 @@
 {
 Set userRoles = userService.getUserCredentials( currentUserService.getCurrentUser() )
 .getUserAuthorityGroups();
-
+
 for ( Program program : getAll() )
 {
 if ( CollectionUtils.intersection( program.getUserRoles(), userRoles ).size() > 0 )

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml	2013-03-11 13:09:11 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml	2013-03-14 07:36:22 +
@@ -299,7 +299,7 @@
 
 
 
+  class="org.hisp.dhis.caseentry.action.caseentry.MultiDataEntrySelectAction">
   
   /main.vm
   /dhis-web-caseentry/singleEventSelect.vm

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addPatientForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addPatientForm.vm	2013-03-06 14:31:30 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addPatientForm.vm	2013-03-14 07:36:22 +
@@ -53,10 +53,10 @@
 	#parse( "/dhis-web-caseentry/patientForm.vm" )
 	
 		
-		
-			
-			
-			
+		
+			
+			
+			
 		
 	
 

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addSingleEventRegistration.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addSingleEventRegistration.vm	2013-03-06 14:31:30 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/addSingleEventRegistration.vm	2013-03-14 07:36:22 +
@@ -43,13 +43,22 @@
 	
 	
 	
-	#parse( "/dhis-web-caseentry/patientForm.vm" )
-	 #parse( "/dhis-web-caseentry/singleDataEntryForm.vm" )
-	
-		
-		
-		
-	
+	
+		
+			#parse( "/dhis-web-caseentry/patientForm.vm" )
+		
+		
+			#parse( "/dhis-web-caseentry/singleDataEntryForm.vm" )
+		
+		
+			
+			
+
+
+
+			
+		
+	
 
 
 

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10200: Local\in\mobile fixes

2013-03-14 Thread noreply

revno: 10200
committer: Bharath 
branch nick: dhis2
timestamp: Thu 2013-03-14 09:01:14 +0100
message:
  Local\in\mobile fixes
modified:
  local/in/dhis-mobile/dhis-service-mobile/pom.xml
  
local/in/dhis-mobile/dhis-service-mobile/src/main/java/org/hisp/dhis/mobile/api/DefaultMobileImportService.java
  
local/in/dhis-mobile/dhis-service-mobile/src/main/resources/META-INF/dhis/beans.xml
  local/in/dhis-mobile/dhis-web-mobile/pom.xml
  
local/in/dhis-mobile/dhis-web-mobile/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
=== modified file 'local/in/dhis-mobile/dhis-service-mobile/pom.xml'
--- local/in/dhis-mobile/dhis-service-mobile/pom.xml	2013-03-06 07:11:59 +
+++ local/in/dhis-mobile/dhis-service-mobile/pom.xml	2013-03-14 08:01:14 +
@@ -33,6 +33,10 @@
 			org.hisp.dhis
 			dhis-service-core
 		
+		
+			org.hisp.dhis
+			dhis-service-patient
+		
 		
 		
 		

=== modified file 'local/in/dhis-mobile/dhis-service-mobile/src/main/java/org/hisp/dhis/mobile/api/DefaultMobileImportService.java'
--- local/in/dhis-mobile/dhis-service-mobile/src/main/java/org/hisp/dhis/mobile/api/DefaultMobileImportService.java	2013-03-14 06:48:31 +
+++ local/in/dhis-mobile/dhis-service-mobile/src/main/java/org/hisp/dhis/mobile/api/DefaultMobileImportService.java	2013-03-14 08:01:14 +
@@ -109,7 +109,7 @@
 
 private static final Log LOG = LogFactory.getLog( DefaultMobileImportService.class );
 
-	
+	public static final String ORGUNITAUTOFORMAT = "ORGUNITAUTOFORMAT";
 
 // -
 // Dependencies
@@ -1414,7 +1414,7 @@
 			
 		}
 		
-		 PatientIdentifierType patientIdentifierType = patientIdentifierTypeService.getPatientIdentifierType( PatientIdentifierType.ORGUNITAUTOFORMAT );
+		 PatientIdentifierType patientIdentifierType = patientIdentifierTypeService.getPatientIdentifierType( ORGUNITAUTOFORMAT );
  int fourDigitRunningNo = 1;
  String fourDigitRunningNumber = "0001";
  
@@ -1590,7 +1590,7 @@
 		String[] elementIds = mappingString.split("\\,");
 		
 		
-		PatientIdentifierType patientIdentifierType = patientIdentifierTypeService.getPatientIdentifierType( PatientIdentifierType.ORGUNITAUTOFORMAT );
+		PatientIdentifierType patientIdentifierType = patientIdentifierTypeService.getPatientIdentifierType( ORGUNITAUTOFORMAT );
 	
 		
 		Patient patient = patientIdentifierService.getPatient(patientIdentifierType, UID.trim());

=== modified file 'local/in/dhis-mobile/dhis-service-mobile/src/main/resources/META-INF/dhis/beans.xml'
--- local/in/dhis-mobile/dhis-service-mobile/src/main/resources/META-INF/dhis/beans.xml	2013-03-14 06:48:31 +
+++ local/in/dhis-mobile/dhis-service-mobile/src/main/resources/META-INF/dhis/beans.xml	2013-03-14 08:01:14 +
@@ -27,8 +27,8 @@
 		
 		
 		
-		  	
-   	  	
+		
 
 
 jar
 		
 		
-		
+
+  org.hisp.dhis
+  dhis-service-core
+
+
+  org.hisp.dhis
+  dhis-service-patient
+
+
+	
 			commons-fileupload
 			commons-fileupload
 		

=== modified file 'local/in/dhis-mobile/dhis-web-mobile/src/main/resources/META-INF/dhis/beans.xml'
--- local/in/dhis-mobile/dhis-web-mobile/src/main/resources/META-INF/dhis/beans.xml	2013-03-14 06:48:31 +
+++ local/in/dhis-mobile/dhis-web-mobile/src/main/resources/META-INF/dhis/beans.xml	2013-03-14 08:01:14 +
@@ -79,11 +79,11 @@
   scope="prototype">
 
 
-
+	
 

___
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 10201: allow save and update of report-tables for any user

2013-03-14 Thread noreply

revno: 10201
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 15:04:13 +0700
message:
  allow save and update of report-tables for any user
modified:
  
dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/hibernate/HibernateGenericStore.java
  
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/AbstractCrudController.java
  
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/ReportTableController.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-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/hibernate/HibernateGenericStore.java'
--- dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/hibernate/HibernateGenericStore.java	2013-03-14 04:50:21 +
+++ dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/hibernate/HibernateGenericStore.java	2013-03-14 08:04:13 +
@@ -184,7 +184,7 @@
  * @param expressions the Criterions for the Criteria.
  * @return an object of the implementation Class type.
  */
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 protected final T getObject( Criterion... expressions )
 {
 return (T) getCriteria( expressions ).uniqueResult();
@@ -196,7 +196,7 @@
  * @param expressions the Criterions for the Criteria.
  * @return a List with objects of the implementation Class type.
  */
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 protected final List getList( Criterion... expressions )
 {
 return getCriteria( expressions ).list();
@@ -262,7 +262,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public final T get( int id )
 {
 T object = (T) sessionFactory.getCurrentSession().get( getClazz(), id );
@@ -278,7 +278,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public final T load( int id )
 {
 T object = (T) sessionFactory.getCurrentSession().load( getClazz(), id );
@@ -369,7 +369,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public final List getAll()
 {
 Query query = sharingEnabled() ? getQueryAllACL() : getQueryAll();
@@ -396,7 +396,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllEqName( String name )
 {
 Query query = sharingEnabled() ? getQueryAllEqNameACL( name ) : getQueryAllEqName( name );
@@ -428,7 +428,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllEqNameIgnoreCase( String name )
 {
 Query query = sharingEnabled() ? getQueryAllEqNameACLIgnoreCase( name ) : getQueryAllEqNameIgnoreCase( name );
@@ -460,7 +460,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllEqShortName( String shortName )
 {
 Query query = sharingEnabled() ? getQueryAllEqShortNameACL( shortName ) : getQueryAllEqShortName( shortName );
@@ -492,7 +492,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllEqShortNameIgnoreCase( String shortName )
 {
 Query query = sharingEnabled() ? getQueryAllEqShortNameACLIgnoreCase( shortName ) : getQueryAllEqShortNameIgnoreCase( shortName );
@@ -524,7 +524,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllLikeName( String name )
 {
 Query query = sharingEnabled() ? getQueryAllLikeNameACL( name ) : getQueryAllLikeName( name );
@@ -556,7 +556,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public final List getAllOrderedName()
 {
 Query query = sharingEnabled() ? getQueryAllOrderedNameACL() : getQueryAllOrderedName();
@@ -584,7 +584,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllOrderedName( int first, int max )
 {
 Query query = sharingEnabled() ? getQueryAllOrderedNameACL() : getQueryAllOrderedName();
@@ -596,7 +596,7 @@
 }
 
 @Override
-@SuppressWarnings( "unchecked" )
+@SuppressWarnings("unchecked")
 public List getAllOrderedLastUpdated( int first, int max )
 {
 Query query = sharingEnabled() ? getQueryAllOrderedLastUpdatedACL() : getQueryAllOrderedLastUpdated();
@@ -627,7 +627,7 @@
 }
 
 @Override
-  

[Dhis2-devs] [Bug 1154983] [NEW] better data set section header format

2013-03-14 Thread Nguyen Tran Do Xuan Thuy
Public bug reported:

The dataset section header format doesn't have the cell padding, or border for 
each cell, so it is confused for the forms which have many columns. 
The description is in the attached images

** Affects: dhis2
 Importance: Undecided
 Status: New

** Attachment added: "dataset section header format 1.png"
   
https://bugs.launchpad.net/bugs/1154983/+attachment/3573520/+files/dataset%20section%20header%20format%201.png

-- 
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/1154983

Title:
  better data set section header format

Status in DHIS 2 - District Health Information Software:
  New

Bug description:
  The dataset section header format doesn't have the cell padding, or border 
for each cell, so it is confused for the forms which have many columns. 
  The description is in the attached images

To manage notifications about this bug go to:
https://bugs.launchpad.net/dhis2/+bug/1154983/+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


Re: [Dhis2-devs] [Bug 1154489] [NEW] Poor user feedback after register new person

2013-03-14 Thread Thu Tran
Hi Ingvild,

I tested it again with revision 10199 on trunk. The bug doesn't occur.
Please help me to test it with this revision or later. Thank you.
*
*
Best regards,

Châu Thu Trân
HISP Viet Nam
Email: tran.hispviet...@gmail.com


On Wed, Mar 13, 2013 at 4:03 PM, Ingvild Indrebø wrote:

> Public bug reported:
>
> When the user clicks "Add" in register new patient the only feedback the
> user is given are data fields getting grey. Suggestion: either show a
> prompt saying the action was successful or/and go back to "Person
> management" screen where the list of persons now shows the recently
> added person. Trunk 2.11
>
> ** 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/1154489
>
> Title:
>   Poor user feedback after register new person
>
> Status in DHIS 2 - District Health Information Software:
>   New
>
> Bug description:
>   When the user clicks "Add" in register new patient the only feedback
>   the user is given are data fields getting grey. Suggestion: either
>   show a prompt saying the action was successful or/and go back to
>   "Person management" screen where the list of persons now shows the
>   recently added person. Trunk 2.11
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/dhis2/+bug/1154489/+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
>

-- 
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/1154489

Title:
  Poor user feedback after register new person

Status in DHIS 2 - District Health Information Software:
  New

Bug description:
  When the user clicks "Add" in register new patient the only feedback
  the user is given are data fields getting grey. Suggestion: either
  show a prompt saying the action was successful or/and go back to
  "Person management" screen where the list of persons now shows the
  recently added person. Trunk 2.11

To manage notifications about this bug go to:
https://bugs.launchpad.net/dhis2/+bug/1154489/+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


Re: [Dhis2-devs] [Bug 1154513] [NEW] Repeatable event not repeatable

2013-03-14 Thread Tran Chau
Dear sir and Ingvild,

*Repeatable program stage details* section is hidden in add/update program
stage form of single event programs.


Best regards,

Châu Thu Trân
HISP Viet Nam
Email: tran.hispviet...@gmail.com


On Wed, Mar 13, 2013 at 5:52 PM, Ola Hodne Titlestad wrote:

> Hi Ingvild,
>
> Single event programs are only allowed to have one event/visit, so no need
> to schedule a second visit.
>
> The repeatable option should be disabled when editing the stage in a
> single event program.
> Currently it is not, and I can see that this can cause some confusion.
>
> Ola
> -
>
>
> --
> Ola Hodne Titlestad (Mr)
> HISP
> Department of Informatics
> University of Oslo
>
> Mobile: +47 48069736
> Home address: Eftasåsen 68, 0687 Oslo, Norway. Googlemaps 
> link
>
>
> On 13 March 2013 11:02, Ingvild Indrebø  wrote:
>
>> Public bug reported:
>>
>> Single event with registration and the event is repeatable and "Display
>> generate event box after completed" is not checked then there are no
>> options to add a new event. Should be a box similar to repeatable
>> multiple events: "Create new event". Trunk 2.11 chrome
>>
>> ** Affects: dhis2
>>  Importance: Undecided
>>  Status: New
>>
>> ** Description changed:
>>
>>   Single event with registration and the event is repeatable and "Display
>>   generate event box after completed" is not checked then there are no
>>   options to add a new event. Should be a box similar to repeatable
>> - multiple events: "Create new event".
>> + multiple events: "Create new event". Trunk 2.11 chrome
>>
>> --
>> You received this bug notification because you are a member of DHIS 2
>> developers, which is subscribed to DHIS.
>> https://bugs.launchpad.net/bugs/1154513
>>
>> Title:
>>   Repeatable event not repeatable
>>
>> Status in DHIS 2 - District Health Information Software:
>>   New
>>
>> Bug description:
>>   Single event with registration and the event is repeatable and
>>   "Display generate event box after completed" is not checked then there
>>   are no options to add a new event. Should be a box similar to
>>   repeatable multiple events: "Create new event". Trunk 2.11 chrome
>>
>> To manage notifications about this bug go to:
>> https://bugs.launchpad.net/dhis2/+bug/1154513/+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
>>
>
>
> ___
> 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


Re: [Dhis2-devs] [Bug 1154497] [NEW] "Data entry screen" in Person Dashboard/History is empty

2013-03-14 Thread Tran Chau
Sorry, but the bug not occurs in my laptop. You can create an example in the
* http://apps.dhis2.org/dev/ *and we can see it ? Thank you.

Best regards,

Châu Thu Trân
HISP Viet Nam
Email: tran.hispviet...@gmail.com


On Wed, Mar 13, 2013 at 4:24 PM, Ingvild Indrebø wrote:

> Public bug reported:
>
> Programme and programme stage with the following settings: "Single event
> with registration" and "repeatable events" and "Display generate event box
> after completed" :
> After completed the programme stage and entered follow up date the tab
> "Data entry screen" in person dashboard is empty. If you click
> "the_programme _name" in the list of active programmes nothing comes up.
> Not the previous completed stage or the follow-up date is shown. However,
> the "report tab" next to the "data entry screen" shows the details
> previously entered. Trunk 2.11 chrome
>
> ** 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/1154497
>
> Title:
>   "Data entry screen" in Person Dashboard/History is empty
>
> Status in DHIS 2 - District Health Information Software:
>   New
>
> Bug description:
>   Programme and programme stage with the following settings: "Single event
> with registration" and "repeatable events" and "Display generate event box
> after completed" :
>   After completed the programme stage and entered follow up date the tab
> "Data entry screen" in person dashboard is empty. If you click
> "the_programme _name" in the list of active programmes nothing comes up.
> Not the previous completed stage or the follow-up date is shown. However,
> the "report tab" next to the "data entry screen" shows the details
> previously entered. Trunk 2.11 chrome
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/dhis2/+bug/1154497/+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
>
___
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 10202: Add button to hide history div in dashboard.

2013-03-14 Thread noreply

revno: 10202
committer: Tran Chau 
branch nick: dhis2
timestamp: Thu 2013-03-14 15:30:49 +0700
message:
  Add button to hide history div in dashboard.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm


--
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-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm	2013-03-07 16:01:54 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm	2013-03-14 08:30:49 +
@@ -207,7 +207,9 @@
 		
 			$i18n.getString("date")
 			$i18n.getString("visitor")
-			$i18n.getString("accessed_module")
+			$i18n.getString("accessed_module") 
+
+			
 		
 	
 	

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm	2013-03-08 09:15:27 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm	2013-03-14 08:30:49 +
@@ -125,8 +125,8 @@
 
 	
 		
-			
-			
+			
+			
 		
 		
 	

___
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] [Bug 1154517] Re: Clicking "History" link there are no options to close the pop-up window that appears

2013-03-14 Thread Thu Tran
** Changed in: dhis2
 Assignee: (unassigned) => Thu Tran (tran-hispvietnam)

-- 
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/1154517

Title:
  Clicking "History" link there are no options to close the pop-up
  window that appears

Status in DHIS 2 - District Health Information Software:
  New

Bug description:
  In Person management • Person dashboard » History, when clicking on
  the "History"-link a pop-up occurs, but there are no ways to close it.
  Trunk 2.11 Chrome

To manage notifications about this bug go to:
https://bugs.launchpad.net/dhis2/+bug/1154517/+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


Re: [Dhis2-devs] [Bug 1154514] [NEW] Buttons disappear when clicking "incomplete"

2013-03-14 Thread Tran Chau
Sorry, I tested and the bug doesn't occur. "*Complete", "Incomplete" and
"Update*" buttons still there. But I cannot see where *Cancel *button
in *Reschedule
and set status* tab in *Dashboard*. Please talk to me if I tested wrong
function.

Best regards,

Châu Thu Trân
HISP Viet Nam
Email: tran.hispviet...@gmail.com


On Wed, Mar 13, 2013 at 5:06 PM, Ingvild Indrebø wrote:

> Public bug reported:
>
> In person dashboard in data entry screen, when clicking "incomplete" all
> the buttons: "Complete", "Incomplete" and "Cancel" disappears. Trunk
> 2.11 chrome
>
> ** 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/1154514
>
> Title:
>   Buttons disappear when clicking "incomplete"
>
> Status in DHIS 2 - District Health Information Software:
>   New
>
> Bug description:
>   In person dashboard in data entry screen, when clicking "incomplete"
>   all the buttons: "Complete", "Incomplete" and "Cancel" disappears.
>   Trunk 2.11 chrome
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/dhis2/+bug/1154514/+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
>
___
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] [Bug 1154517] [NEW] Clicking "History" link there are no options to close the pop-up window that appears

2013-03-14 Thread Tran Chau
Dear Ingvild,

You can re-click on History link to hide it. But it make users confused. I
added more button on the header to hide the div. Thank you for reporting
bug.

Best regards,

Châu Thu Trân
HISP Viet Nam
Email: tran.hispviet...@gmail.com


On Wed, Mar 13, 2013 at 5:10 PM, Ingvild Indrebø wrote:

> Public bug reported:
>
> In Person management • Person dashboard » History, when clicking on the
> "History"-link a pop-up occurs, but there are no ways to close it. Trunk
> 2.11 Chrome
>
> ** 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/1154517
>
> Title:
>   Clicking "History" link there are no options to close the pop-up
>   window that appears
>
> Status in DHIS 2 - District Health Information Software:
>   New
>
> Bug description:
>   In Person management • Person dashboard » History, when clicking on
>   the "History"-link a pop-up occurs, but there are no ways to close it.
>   Trunk 2.11 Chrome
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/dhis2/+bug/1154517/+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
>
___
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] [Bug 1154497] [NEW] "Data entry screen" in Person Dashboard/History is empty

2013-03-14 Thread Ola Hodne Titlestad
I think this is somewhat related to this bug:
https://bugs.launchpad.net/dhis2/+bug/1154513

We should not allow single event programs to have repeatable events.

Ingvild, can you reproduce this bug also for multiple event programs?

Ola
---

--
Ola Hodne Titlestad (Mr)
HISP
Department of Informatics
University of Oslo

Mobile: +47 48069736
Home address: Eftasåsen 68, 0687 Oslo, Norway. Googlemaps
link


On 14 March 2013 09:16, Tran Chau  wrote:

> Sorry, but the bug not occurs in my laptop. You can create an example in
> the* http://apps.dhis2.org/dev/ *and we can see it ? Thank you.
>
> Best regards,
> 
> Châu Thu Trân
> HISP Viet Nam
> Email: tran.hispviet...@gmail.com
>
>
> On Wed, Mar 13, 2013 at 4:24 PM, Ingvild Indrebø wrote:
>
>> Public bug reported:
>>
>> Programme and programme stage with the following settings: "Single event
>> with registration" and "repeatable events" and "Display generate event box
>> after completed" :
>> After completed the programme stage and entered follow up date the tab
>> "Data entry screen" in person dashboard is empty. If you click
>> "the_programme _name" in the list of active programmes nothing comes up.
>> Not the previous completed stage or the follow-up date is shown. However,
>> the "report tab" next to the "data entry screen" shows the details
>> previously entered. Trunk 2.11 chrome
>>
>> ** 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/1154497
>>
>> Title:
>>   "Data entry screen" in Person Dashboard/History is empty
>>
>> Status in DHIS 2 - District Health Information Software:
>>   New
>>
>> Bug description:
>>   Programme and programme stage with the following settings: "Single
>> event with registration" and "repeatable events" and "Display generate
>> event box after completed" :
>>   After completed the programme stage and entered follow up date the tab
>> "Data entry screen" in person dashboard is empty. If you click
>> "the_programme _name" in the list of active programmes nothing comes up.
>> Not the previous completed stage or the follow-up date is shown. However,
>> the "report tab" next to the "data entry screen" shows the details
>> previously entered. Trunk 2.11 chrome
>>
>> To manage notifications about this bug go to:
>> https://bugs.launchpad.net/dhis2/+bug/1154497/+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
>>
>
>
> ___
> 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 10203: fixed bugs with program meta-data

2013-03-14 Thread noreply

revno: 10203
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 16:06:32 +0700
message:
  fixed bugs with program meta-data
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramService.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStore.java
  
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramService.java
  
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStore.java
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/GetProgramMetaDataAction.java
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/cacheManifest.vm


--
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/program/ProgramService.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramService.java	2013-02-20 08:38:11 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramService.java	2013-03-14 09:06:32 +
@@ -27,11 +27,11 @@
 
 package org.hisp.dhis.program;
 
-import java.util.Collection;
-
 import org.hisp.dhis.organisationunit.OrganisationUnit;
 import org.hisp.dhis.validation.ValidationCriteria;
 
+import java.util.Collection;
+
 /**
  * @author Abyot Asalefew
  * @version $Id$
@@ -53,15 +53,17 @@
 Collection getAllPrograms();
 
 Collection getPrograms( OrganisationUnit organisationUnit );
-
+
 Collection getProgramsByCurrentUser();
 
+Collection getProgramsByCurrentUser( int type );
+
 Collection getPrograms( ValidationCriteria validationCriteria );
 
 Collection getPrograms( int type );
-
+
 Collection getPrograms( int type, OrganisationUnit orgunit );
-
+
 Program getProgram( String uid );
 
 }

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStore.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStore.java	2013-02-19 06:54:22 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStore.java	2013-03-14 09:06:32 +
@@ -27,14 +27,13 @@
 
 package org.hisp.dhis.program;
 
-import java.util.Collection;
-
 import org.hisp.dhis.common.GenericNameableObjectStore;
 import org.hisp.dhis.organisationunit.OrganisationUnit;
 
+import java.util.Collection;
+
 /**
  * @author Chau Thu Tran
- * 
  * @version $Id: ProgramStore.java Dec 14, 2011 9:22:17 AM $
  */
 public interface ProgramStore
@@ -43,8 +42,10 @@
 String ID = ProgramStore.class.getName();
 
 Collection getByType( int type );
-
+
 Collection get( int type, OrganisationUnit orgunit );
-
+
 Collection getByCurrentUser();
+
+Collection getByCurrentUser( int type );
 }

=== modified file 'dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramService.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramService.java	2013-02-20 08:38:11 +
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramService.java	2013-03-14 09:06:32 +
@@ -27,17 +27,17 @@
 
 package org.hisp.dhis.program;
 
-import static org.hisp.dhis.i18n.I18nUtils.i18n;
-
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Set;
-
 import org.hisp.dhis.i18n.I18nService;
 import org.hisp.dhis.organisationunit.OrganisationUnit;
 import org.hisp.dhis.validation.ValidationCriteria;
 import org.springframework.transaction.annotation.Transactional;
 
+import java.util.Collection;
+import java.util.HashSet;
+import java.util.Set;
+
+import static org.hisp.dhis.i18n.I18nUtils.i18n;
+
 /**
  * @author Abyot Asalefew
  * @version $Id$
@@ -110,7 +110,7 @@
 }
 }
 
-return i18n( i18nService, programs);
+return i18n( i18nService, programs );
 }
 
 public Collection getPrograms( ValidationCriteria validationCriteria )
@@ -125,7 +125,7 @@
 }
 }
 
-return i18n( i18nService, programs);
+return i18n( i18nService, programs );
 }
 
 public Collection getPrograms( int type )
@@ -142,7 +142,13 @@
 {
 return i18n( i18nService, programStore.getByCurrentUser() );
 }
-
+
+@Override
+public Collection getProgramsByCurrentUser( int type )
+{
+return i18n( i18nService, programStore.getByCurrentUser( type ) );
+}
+
 public Program getProgram( String uid )
 {
 return i18n( i18nService, programStore.getByUid( uid ) );

=== modified file 'dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStore.java'
--- dhis-2/dhis-services/dhis-s

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10204: translation.

2013-03-14 Thread noreply

revno: 10204
committer: Tran Chau 
branch nick: dhis2
timestamp: Thu 2013-03-14 16:12:54 +0700
message:
  translation.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm


--
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-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties	2013-03-11 13:09:11 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties	2013-03-14 09:12:54 +
@@ -597,4 +597,6 @@
 aggregate_and_save = Aggregate and Save
 preview = Preview
 confirm_data_values_aggregated_saved_into_database_directly = Are you sure you want to save data values aggregated into database directly ?
-aggregate_successfully = Aggregate successfully
\ No newline at end of file
+aggregate_successfully = Aggregate successfully
+complete_quit = Complete/Quit
+re_enrol = Re-enrol
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-01 09:15:24 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-14 09:12:54 +
@@ -13,8 +13,8 @@
 			
 			
 
-
-
+
+
 			
 		
 	

___
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 10205: Report table, now using foreign key to RelativePeriods entity instead of embedding relative perio...

2013-03-14 Thread noreply

revno: 10205
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 11:12:47 +0100
message:
  Report table, now using foreign key to RelativePeriods entity instead of 
embedding relative periods using component mapping.
added:
  
dhis-2/dhis-support/dhis-support-jdbc/src/main/java/org/hisp/dhis/jdbc/batchhandler/RelativePeriodsBatchHandler.java
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java
  
dhis-2/dhis-services/dhis-service-core/src/main/resources/META-INF/dhis/beans.xml
  
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/chart/impl/DefaultChartService.java
  
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/reporttable/impl/DefaultReportTableService.java
  
dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/reporttable/hibernate/ReportTable.hbm.xml
  
dhis-2/dhis-services/dhis-service-reporting/src/test/java/org/hisp/dhis/reporttable/ReportTableStoreTest.java
  
dhis-2/dhis-support/dhis-support-jdbc/src/main/java/org/hisp/dhis/jdbc/batchhandler/ReportTableBatchHandler.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/chart/Chart.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java	2013-02-13 03:57:52 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java	2013-03-14 10:12:47 +
@@ -366,6 +366,11 @@
 return userOrganisationUnit || userOrganisationUnitChildren;
 }
 
+public boolean hasRelativePeriods()
+{
+return relatives != null && !relatives.isEmpty();
+}
+
 // -
 // Getters and setters
 // -

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java	2013-02-13 03:57:52 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java	2013-03-14 10:12:47 +
@@ -285,6 +285,14 @@
 
 return this;
 }
+
+/**
+ * Indicates whether this object contains at least one relative period.
+ */
+public boolean isEmpty()
+{
+return getRelativePeriods().isEmpty();
+}
 
 /**
  * Returns the period type for the option with the lowest frequency.

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java	2013-02-13 03:57:52 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java	2013-03-14 10:12:47 +
@@ -126,7 +126,7 @@
  */
 public boolean hasRelativePeriods()
 {
-return relatives != null && !relatives.getRelativePeriods().isEmpty();
+return relatives != null && !relatives.isEmpty();
 }
 
 /**

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java	2013-03-12 13:44:27 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java	2013-03-14 10:12:47 +
@@ -897,7 +897,7 @@
  */
 public boolean hasRelativePeriods()
 {
-return relatives != null && !relatives.getRelativePeriods().isEmpty();
+return relatives != null && !relatives.isEmpty();
 }
 
 public boolean isDoIndicators()

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-13 16:50:49 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 10:12:47 +
@@ -34,11 +34,17 @@
 import java.util.List;
 import java.util.Map;
 
+import org.amplecode.quick.BatchHandler;
+import org.amplecode.quick.BatchHandlerFactory;
 import org.amplecode.quick.StatementHolder;
 import org.amplecode.quick.StatementManager;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.hisp.dhis.jdbc.StatementBuilder;
+import org.hisp.dhis.jdbc.batchhandler.RelativePeriodsBatchHandler;
+import org.hisp.dhis.period.RelativePeriods;
 import org.hisp.dhis.system.startu

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10206: Unused code

2013-03-14 Thread noreply

revno: 10206
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 11:21:07 +0100
message:
  Unused code
modified:
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/mapping/DefaultMappingService.java
  
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
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/mapping/DefaultMappingService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/mapping/DefaultMappingService.java	2013-03-14 04:50:21 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/mapping/DefaultMappingService.java	2013-03-14 10:21:07 +
@@ -27,6 +27,11 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
+import java.util.Collection;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
 import org.hisp.dhis.aggregation.AggregatedDataValueService;
 import org.hisp.dhis.aggregation.AggregatedMapValue;
 import org.hisp.dhis.common.GenericIdentifiableObjectStore;
@@ -43,14 +48,8 @@
 import org.hisp.dhis.period.RelativePeriods;
 import org.hisp.dhis.system.util.ConversionUtils;
 import org.hisp.dhis.system.util.MathUtils;
-import org.hisp.dhis.user.CurrentUserService;
 import org.springframework.transaction.annotation.Transactional;
 
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
 /**
  * @author Jan Henrik Overland
  */
@@ -125,13 +124,6 @@
 this.aggregatedDataValueService = aggregatedDataValueService;
 }
 
-private CurrentUserService currentUserService;
-
-public void setCurrentUserService( CurrentUserService currentUserService )
-{
-this.currentUserService = currentUserService;
-}
-
 private ConfigurationService configurationService;
 
 public void setConfigurationService( ConfigurationService configurationService )

=== 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	2013-03-14 10:12:47 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/META-INF/dhis/beans.xml	2013-03-14 10:21:07 +
@@ -570,7 +570,6 @@
 
 
 
-
 
   
 

___
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 10208: cleaned up validator actions for indicator/group/groupset

2013-03-14 Thread noreply

revno: 10208
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 17:33:20 +0700
message:
  cleaned up validator actions for indicator/group/groupset
removed:
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicatorgroup/ValidateIndicatorGroupAction.java
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicatorgroupset/ValidateIndicatorGroupSetAction.java
modified:
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicator/ValidateIndicatorAction.java
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/META-INF/dhis/beans.xml
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/struts.xml
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/webapp/dhis-web-maintenance-datadictionary/addIndicatorForm.vm
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/webapp/dhis-web-maintenance-datadictionary/addIndicatorGroupForm.vm
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/webapp/dhis-web-maintenance-datadictionary/javascript/addIndicatorGroupSet.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-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicator/ValidateIndicatorAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicator/ValidateIndicatorAction.java	2013-02-07 10:25:34 +
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicator/ValidateIndicatorAction.java	2013-03-14 10:33:20 +
@@ -105,32 +105,6 @@
 
 public String execute()
 {
-if ( name != null )
-{
-// TODO compile fix, this should be removed
-Indicator match = indicatorService.getIndicatorByName( name ).get( 0 );
-
-if ( match != null && (id == null || match.getId() != id) )
-{
-message = i18n.getString( "name_in_use" );
-
-return ERROR;
-}
-}
-
-if ( shortName != null )
-{
-// TODO compile fix, this should be removed
-Indicator match = indicatorService.getIndicatorByShortName( shortName ).get( 0 );
-
-if ( match != null && (id == null || match.getId() != id) )
-{
-message = i18n.getString( "short_name_in_use" );
-
-return ERROR;
-}
-}
-
 if ( code != null && !code.trim().isEmpty() )
 {
 Indicator match = indicatorService.getIndicatorByCode( code );
@@ -143,7 +117,7 @@
 }
 }
 
-message = i18n.getString( "everything_is_ok" );
+message = i18n.getString( "ok" );
 
 return SUCCESS;
 }

=== removed file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicatorgroup/ValidateIndicatorGroupAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicatorgroup/ValidateIndicatorGroupAction.java	2013-02-07 10:25:34 +
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/indicatorgroup/ValidateIndicatorGroupAction.java	1970-01-01 00:00:00 +
@@ -1,113 +0,0 @@
-package org.hisp.dhis.dd.action.indicatorgroup;
-
-/*
- * Copyright (c) 2004-2012, 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

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10209: more validation cleanup

2013-03-14 Thread noreply

revno: 10209
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 17:50:51 +0700
message:
  more validation cleanup
modified:
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/ValidateDataSetAction.java
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.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-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/ValidateDataSetAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/ValidateDataSetAction.java	2013-02-08 04:20:26 +
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/ValidateDataSetAction.java	2013-03-14 10:50:51 +
@@ -136,38 +136,6 @@
 throws Exception
 {
 // -
-// Name
-// -
-
-if ( name != null )
-{
-DataSet match = dataSetService.getDataSetByName( name ).get( 0 );
-
-if ( match != null && (dataSetId == null || match.getId() != dataSetId) )
-{
-message = i18n.getString( "duplicate_names" );
-
-return ERROR;
-}
-}
-
-// -
-// Short name
-// -
-
-if ( shortName != null )
-{
-DataSet match = dataSetService.getDataSetByShortName( shortName ).get( 0 );
-
-if ( match != null && (dataSetId == null || match.getId() != dataSetId) )
-{
-message = i18n.getString( "duplicate_short_names" );
-
-return ERROR;
-}
-}
-
-// -
 // Code
 // -
 

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js	2013-02-08 04:20:26 +
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js	2013-03-14 10:50:51 +
@@ -9,7 +9,5 @@
 		'rules' : getValidationRules("dataSet")
 	});
 
-	// checkValueIsExist("name", "validateDataSet.action");
-	// checkValueIsExist("shortName", "validateDataSet.action");
 	checkValueIsExist("code", "validateDataSet.action");
 });

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.js	2013-02-08 04:20:26 +
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.js	2013-03-14 10:50:51 +
@@ -9,20 +9,6 @@
 		'rules' : getValidationRules("dataSet")
 	});
 
-/*
-	checkValueIsExist("name", "validateDataSet.action", {
-		dataSetId : function() {
-			return jQuery("#dataSetId").val();
-		}
-	});
-
-	checkValueIsExist("shortName", "validateDataSet.action", {
-		dataSetId : function() {
-			return jQuery("#dataSetId").val();
-		}
-	});
-*/
-
 	checkValueIsExist("code", "validateDataSet.action", {
 		dataSetId : function() {
 			return jQuery("#dataSetId").val();

___
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 10210: cleaned up validation for user-group

2013-03-14 Thread noreply

revno: 10210
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 17:53:15 +0700
message:
  cleaned up validation for user-group
modified:
  
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/usergroup/action/ValidateUserGroupAction.java
  
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/struts.xml
  
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/addUserGroupForm.vm
  
dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/updateUserGroupForm.vm


--
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-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/usergroup/action/ValidateUserGroupAction.java'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/usergroup/action/ValidateUserGroupAction.java	2013-03-12 09:27:40 +
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/java/org/hisp/dhis/dashboard/usergroup/action/ValidateUserGroupAction.java	2013-03-14 10:53:15 +
@@ -98,7 +98,7 @@
 }
 }
 
-message = i18n.getString( "everything_is_ok" );
+message = i18n.getString( "ok" );
 
 return SUCCESS;
 }

=== 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	2013-03-12 06:51:28 +
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/META-INF/dhis/beans.xml	2013-03-14 10:53:15 +
@@ -157,9 +157,4 @@
 
   
 
-  
-
-  
-
 

=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/struts.xml	2013-03-13 11:47:27 +
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/resources/struts.xml	2013-03-14 10:53:15 +
@@ -234,14 +234,5 @@
 			
 		
 
-		
-			/dhis-web-commons/ajax/jsonResponseSuccess.vm
-			
-			/dhis-web-commons/ajax/jsonResponseError.vm
-			
-			plainTextError
-		
-
 	
 

=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/addUserGroupForm.vm'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/addUserGroupForm.vm	2013-03-12 09:27:40 +
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/addUserGroupForm.vm	2013-03-14 10:53:15 +
@@ -11,9 +11,6 @@
 'rules' : getValidationRules( "userGroup" )
 } );
 
-/* remote validation */
-// checkValueIsExist( "name", "validateUserGroup.action" );
-
 		jQuery("#availableUsersList").dhisAjaxSelect({
 			source: "../dhis-web-commons-ajax-json/getUsers.action",
 			iterator: "users",

=== modified file 'dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/updateUserGroupForm.vm'
--- dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/updateUserGroupForm.vm	2013-03-12 09:27:40 +
+++ dhis-2/dhis-web/dhis-web-dashboard-integration/src/main/webapp/dhis-web-dashboard-integration/updateUserGroupForm.vm	2013-03-14 10:53:15 +
@@ -23,11 +23,6 @@
 return option;
 			}
 		});
-
-		/* remote validation */
-		/* checkValueIsExist( "name", "validateUserGroup.action", {
-			id : $group.id
-		} ); */
 	});
 
 

___
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 10211: cleaned up validation for data-dictionary

2013-03-14 Thread noreply

revno: 10211
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 17:55:38 +0700
message:
  cleaned up validation for data-dictionary
removed:
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/datadictionary/ValidateDataDictionaryAction.java
modified:
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/META-INF/dhis/beans.xml
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/resources/struts.xml
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/webapp/dhis-web-maintenance-datadictionary/javascript/addDataDictionaryForm.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
=== removed file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/datadictionary/ValidateDataDictionaryAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/datadictionary/ValidateDataDictionaryAction.java	2013-02-12 06:55:14 +
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-datadictionary/src/main/java/org/hisp/dhis/dd/action/datadictionary/ValidateDataDictionaryAction.java	1970-01-01 00:00:00 +
@@ -1,110 +0,0 @@
-package org.hisp.dhis.dd.action.datadictionary;
-
-/*
- * Copyright (c) 2004-2012, 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 com.opensymphony.xwork2.Action;
-import org.hisp.dhis.datadictionary.DataDictionary;
-import org.hisp.dhis.datadictionary.DataDictionaryService;
-import org.hisp.dhis.i18n.I18n;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class ValidateDataDictionaryAction
-implements Action
-{
-// -
-// Dependencies
-// -
-
-private DataDictionaryService dataDictionaryService;
-
-public void setDataDictionaryService( DataDictionaryService dataDictionaryService )
-{
-this.dataDictionaryService = dataDictionaryService;
-}
-
-private I18n i18n;
-
-public void setI18n( I18n i18n )
-{
-this.i18n = i18n;
-}
-
-// -
-// Input
-// -
-
-private Integer id;
-
-public void setId( Integer id )
-{
-this.id = id;
-}
-
-private String name;
-
-public void setName( String name )
-{
-this.name = name;
-}
-
-// -
-// Output
-// -
-
-private String message;
-
-public String getMessage()
-{
-return message;
-}
-
-// -
-// Action implementation
-// -
-
-public String execut

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10213: cleaned up validation for document

2013-03-14 Thread noreply

revno: 10213
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 18:00:17 +0700
message:
  cleaned up validation for document
removed:
  
dhis-2/dhis-web/dhis-web-reporting/src/main/java/org/hisp/dhis/reporting/document/action/ValidateDocumentAction.java
modified:
  dhis-2/dhis-web/dhis-web-reporting/src/main/resources/META-INF/dhis/beans.xml
  dhis-2/dhis-web/dhis-web-reporting/src/main/resources/struts.xml
  
dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/addDocumentForm.vm


--
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
=== removed file 'dhis-2/dhis-web/dhis-web-reporting/src/main/java/org/hisp/dhis/reporting/document/action/ValidateDocumentAction.java'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/java/org/hisp/dhis/reporting/document/action/ValidateDocumentAction.java	2013-02-08 05:10:24 +
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/java/org/hisp/dhis/reporting/document/action/ValidateDocumentAction.java	1970-01-01 00:00:00 +
@@ -1,127 +0,0 @@
-package org.hisp.dhis.reporting.document.action;
-
-/*
- * Copyright (c) 2004-2012, 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 com.opensymphony.xwork2.Action;
-import org.hisp.dhis.document.Document;
-import org.hisp.dhis.document.DocumentService;
-import org.hisp.dhis.i18n.I18n;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class ValidateDocumentAction
-implements Action
-{
-// -
-// Dependencies
-// -
-
-private DocumentService documentService;
-
-public void setDocumentService( DocumentService documentService )
-{
-this.documentService = documentService;
-}
-
-private I18n i18n;
-
-public void setI18n( I18n i18n )
-{
-this.i18n = i18n;
-}
-
-// -
-// Input
-// -
-
-private Integer id;
-
-public void setId( Integer id )
-{
-this.id = id;
-}
-
-private String name;
-
-public void setName( String name )
-{
-this.name = name;
-}
-
-// -
-// Output
-// -
-
-private String message;
-
-public String getMessage()
-{
-return message;
-}
-
-// -
-// Action implementation
-// -
-
-public String execute()
-{
-if ( name == null )
-{
-message = i18n.getString( "specify_name" );
-
-return INPUT;
-}
-else
-{
-name = name.trim();
-
-if ( name.length() == 0 )
-{
-message = i18n.getString( "specify_name" );
-
-return INPUT;
-}
-
-// TODO compil

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10212: removed data-element from list of supported sharing classes

2013-03-14 Thread noreply

revno: 10212
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 17:58:42 +0700
message:
  removed data-element from list of supported sharing classes
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/SharingUtils.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/common/SharingUtils.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/SharingUtils.java	2013-03-14 05:10:11 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/SharingUtils.java	2013-03-14 10:58:42 +
@@ -78,10 +78,6 @@
 PUBLIC_AUTHORITIES.put( DataDictionary.class, "F_DATADICTIONARY_PUBLIC_ADD" );
 PRIVATE_AUTHORITIES.put( DataDictionary.class, "F_DATADICTIONARY_PRIVATE_ADD" );
 
-SUPPORTED_TYPES.put( "dataElement", DataElement.class );
-PUBLIC_AUTHORITIES.put( DataElement.class, "F_DATAELEMENT_PUBLIC_ADD" );
-PRIVATE_AUTHORITIES.put( DataElement.class, "F_DATAELEMENT_PRIVATE_ADD" );
-
 SUPPORTED_TYPES.put( "indicator", Indicator.class );
 PUBLIC_AUTHORITIES.put( Indicator.class, "F_INDICATOR_PUBLIC_ADD" );
 PRIVATE_AUTHORITIES.put( Indicator.class, "F_INDICATOR_PRIVATE_ADD" );

___
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 10214: Upgraded charts to use the RelativePeriods entity instead of embedding through component mapping

2013-03-14 Thread noreply

revno: 10214
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 12:08:04 +0100
message:
  Upgraded charts to use the RelativePeriods entity instead of embedding 
through component mapping
modified:
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java
  
dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.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
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 10:12:47 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 11:08:04 +
@@ -535,8 +535,9 @@
 executeSql( "ALTER TABLE usergroup DROP CONSTRAINT usergroup_name_key" );
 executeSql( "ALTER TABLE datadictionary DROP CONSTRAINT datadictionary_name_key" );
 
+upgradeChartRelativePeriods();
+upgradeReportTableRelativePeriods();
 upgradeReportTableColumns();
-upgradeReportTableRelativePeriods();
 
 // clear out sharing of de-group/de-group-set for now
 executeSql( "UPDATE dataelementgroup SET userid=NULL WHERE userid IS NOT NULL" );
@@ -551,6 +552,74 @@
 log.info( "Tables updated" );
 }
 
+private void upgradeChartRelativePeriods()
+{
+BatchHandler batchHandler = batchHandlerFactory.createBatchHandler( RelativePeriodsBatchHandler.class ).init();
+
+try
+{
+String sql = "select reportingmonth, * from chart";
+
+ResultSet rs = statementManager.getHolder().getStatement().executeQuery( sql );
+
+while ( rs.next() )
+{
+RelativePeriods r = new RelativePeriods( 
+rs.getBoolean( "reportingmonth" ), 
+false,
+rs.getBoolean( "reportingquarter" ), 
+rs.getBoolean( "lastsixmonth" ), 
+rs.getBoolean( "monthsthisyear" ), 
+rs.getBoolean( "quartersthisyear" ), 
+rs.getBoolean( "thisyear" ), 
+false, false,
+rs.getBoolean( "lastyear" ), 
+rs.getBoolean( "last5years" ), 
+rs.getBoolean( "last12months" ), 
+rs.getBoolean( "last3months" ), 
+false, 
+rs.getBoolean( "last4quarters" ), 
+rs.getBoolean( "last2sixmonths" ), 
+false, false, false,
+false, false, false );
+
+int chartId = rs.getInt( "chartid" );
+
+if ( !r.isEmpty() )
+{
+int relativePeriodsId = batchHandler.insertObject( r, true );
+
+String update = "update chart set relativeperiodsid=" + relativePeriodsId + " where chartid=" + chartId;
+
+executeSql( update );
+
+log.info( "Updated relative periods for chart with id: " + chartId );
+}
+}
+
+executeSql( "alter table chart drop column reportingmonth" );
+executeSql( "alter table chart drop column reportingquarter" );
+executeSql( "alter table chart drop column lastsixmonth" );
+executeSql( "alter table chart drop column monthsthisyear" );
+executeSql( "alter table chart drop column quartersthisyear" );
+executeSql( "alter table chart drop column thisyear" );
+executeSql( "alter table chart drop column lastyear" );
+executeSql( "alter table chart drop column last5years" );
+executeSql( "alter table chart drop column last12months" );
+executeSql( "alter table chart drop column last3months" );
+executeSql( "alter table chart drop column last4quarters" );
+executeSql( "alter table chart drop column last2sixmonths" );
+}
+catch ( Exception ex )
+{
+log.warn( ex );
+}
+finally
+{
+batchHandler.flush();
+}
+}
+
 private void upgradeReportTableRelativePeriods()
 {
 BatchHandler batchHandler = batchHandlerFactory.createBatchHandler( RelativePeriodsBatchHandler.class ).init();

=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml'
--- dhis-2/dhis-services/dhis-service-reporti

[Dhis2-devs] [Branch ~dhis2-documenters/dhis2/dhis2-docbook-docs] Rev 688: Minor update

2013-03-14 Thread noreply

revno: 688
committer: Lars Helge Øverland 
branch nick: dhis2-docbook-docs
timestamp: Thu 2013-03-14 12:17:58 +0100
message:
  Minor update
modified:
  src/docbkx/en/dhis2_user_man_sharing.xml
  src/docbkx/en/dhis2_user_man_using_pivot_table.xml


--
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs

Your team DHIS 2 developers is subscribed to branch 
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs.
To unsubscribe from this branch go to 
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs/+edit-subscription
=== modified file 'src/docbkx/en/dhis2_user_man_sharing.xml'
--- src/docbkx/en/dhis2_user_man_sharing.xml	2013-03-13 13:28:11 +
+++ src/docbkx/en/dhis2_user_man_sharing.xml	2013-03-14 11:17:58 +
@@ -57,7 +57,7 @@
   "Create public report" authority granted, the report will become viewable for everyone and
   editable for users with the "Update report" authority. If you do not have that authority
   granted the report will be private to yourself. After you have created an object, you can
-  navigate to the sharing settings dialog and set your desired access options.
+  navigate to the "Sharing settings" dialog and set your desired access options.
   
   
 Sharing applied

=== modified file 'src/docbkx/en/dhis2_user_man_using_pivot_table.xml'
--- src/docbkx/en/dhis2_user_man_using_pivot_table.xml	2013-03-13 14:27:59 +
+++ src/docbkx/en/dhis2_user_man_using_pivot_table.xml	2013-03-14 11:17:58 +
@@ -123,8 +123,9 @@
 
   
 Show sub-totals: Display subtotals in the table for each dimension. In the screenshot
-  above, notice how subtotals are generated for each of the periods in the period
-  dimension.
+  above, notice how subtotals are generated for each of the periods in the period dimension.
+  Note that subtotals will be hidden for columns or rows if there is only one selected
+  dimension, as the values in that case are equal to the subtotals.
   
   
 Hide empty rows: Hides empty rows from the table, which is useful when looking at

___
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 10215: minor

2013-03-14 Thread noreply

revno: 10215
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Thu 2013-03-14 18:28:38 +0700
message:
  minor
modified:
  
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/AbstractCrudController.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/api/controller/AbstractCrudController.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/AbstractCrudController.java	2013-03-14 08:04:13 +
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/AbstractCrudController.java	2013-03-14 11:28:38 +
@@ -36,11 +36,14 @@
 import org.hisp.dhis.system.util.ReflectionUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.HttpStatus;
-import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.ui.Model;
 import org.springframework.util.StringUtils;
 import org.springframework.web.HttpRequestMethodNotSupportedException;
-import org.springframework.web.bind.annotation.*;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RequestMethod;
+import org.springframework.web.bind.annotation.RequestParam;
+import org.springframework.web.bind.annotation.ResponseStatus;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
@@ -68,7 +71,7 @@
 // GET
 //--
 
-@RequestMapping( method = RequestMethod.GET )
+@RequestMapping(method = RequestMethod.GET)
 public String getObjectList( @RequestParam Map parameters, Model model, HttpServletRequest request ) throws Exception
 {
 WebOptions options = new WebOptions( parameters );
@@ -91,7 +94,7 @@
 return StringUtils.uncapitalize( getEntitySimpleName() ) + "List";
 }
 
-@RequestMapping( value = "/query/{query}", method = RequestMethod.GET )
+@RequestMapping(value = "/query/{query}", method = RequestMethod.GET)
 public String query( @PathVariable String query, @RequestParam Map parameters, Model model, HttpServletRequest request ) throws Exception
 {
 WebOptions options = new WebOptions( parameters );
@@ -114,8 +117,8 @@
 return StringUtils.uncapitalize( getEntitySimpleName() ) + "List";
 }
 
-@RequestMapping( value = "/{uid}", method = RequestMethod.GET )
-public String getObject( @PathVariable( "uid" ) String uid, @RequestParam Map parameters,
+@RequestMapping(value = "/{uid}", method = RequestMethod.GET)
+public String getObject( @PathVariable("uid") String uid, @RequestParam Map parameters,
 Model model, HttpServletRequest request, HttpServletResponse response ) throws Exception
 {
 WebOptions options = new WebOptions( parameters );
@@ -141,7 +144,7 @@
 return StringUtils.uncapitalize( getEntitySimpleName() );
 }
 
-@RequestMapping( value = "/search/{query}", method = RequestMethod.GET )
+@RequestMapping(value = "/search/{query}", method = RequestMethod.GET)
 public String search( @PathVariable String query, @RequestParam Map parameters,
 Model model, HttpServletRequest request, HttpServletResponse response ) throws Exception
 {
@@ -172,13 +175,13 @@
 // POST
 //--
 
-@RequestMapping( method = RequestMethod.POST, consumes = { "application/xml", "text/xml" } )
+@RequestMapping(method = RequestMethod.POST, consumes = { "application/xml", "text/xml" })
 public void postXmlObject( HttpServletResponse response, HttpServletRequest request, InputStream input ) throws Exception
 {
 throw new HttpRequestMethodNotSupportedException( RequestMethod.POST.toString() );
 }
 
-@RequestMapping( method = RequestMethod.POST, consumes = "application/json" )
+@RequestMapping(method = RequestMethod.POST, consumes = "application/json")
 public void postJsonObject( HttpServletResponse response, HttpServletRequest request, InputStream input ) throws Exception
 {
 throw new HttpRequestMethodNotSupportedException( RequestMethod.POST.toString() );
@@ -188,16 +191,16 @@
 // PUT
 //--
 
-@RequestMapping( value = "/{uid}", method = RequestMethod.PUT, consumes = { "application/xml", "text/xml" } )
-@ResponseStatus( value = HttpStatus.NO_CONTENT )
-public void putXmlObject( HttpServletResponse response, HttpServletRequest req

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10216: Impl support for relative period last week in service layer

2013-03-14 Thread noreply

revno: 10216
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 12:51:43 +0100
message:
  Impl support for relative period last week in service layer
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriodEnum.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java
  dhis-2/dhis-api/src/test/java/org/hisp/dhis/period/RelativePeriodTest.java
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java
  
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/AbstractRelativePeriodsAction.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/period/RelativePeriodEnum.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriodEnum.java	2013-01-18 16:00:12 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriodEnum.java	2013-03-14 11:51:43 +
@@ -52,6 +52,7 @@
 THIS_FINANCIAL_YEAR,
 LAST_FINANCIAL_YEAR,
 LAST_5_FINANCIAL_YEARS,
+LAST_WEEK,
 LAST_4_WEEKS,
 LAST_12_WEEKS,
 LAST_52_WEEKS;
@@ -61,7 +62,7 @@
 MONTHS_THIS_YEAR.toString(), QUARTERS_THIS_YEAR.toString(), THIS_YEAR.toString(), MONTHS_LAST_YEAR.toString(), QUARTERS_LAST_YEAR.toString(),
 LAST_YEAR.toString(), LAST_5_YEARS.toString(), LAST_12_MONTHS.toString(), LAST_3_MONTHS.toString(), LAST_6_BIMONTHS.toString(), 
 LAST_4_QUARTERS.toString(), LAST_2_SIXMONTHS.toString(), THIS_FINANCIAL_YEAR.toString(), LAST_FINANCIAL_YEAR.toString(), 
-LAST_5_FINANCIAL_YEARS.toString(), LAST_4_WEEKS.toString(), LAST_12_WEEKS.toString(), LAST_52_WEEKS.toString() ) );
+LAST_5_FINANCIAL_YEARS.toString(), LAST_WEEK.toString(), LAST_4_WEEKS.toString(), LAST_12_WEEKS.toString(), LAST_52_WEEKS.toString() ) );
 } };
 
 public static boolean contains( String relativePeriod )

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java	2013-03-14 10:12:47 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java	2013-03-14 11:51:43 +
@@ -51,6 +51,7 @@
 
 private static final List NO = new ArrayList();
 
+public static final String LAST_WEEK = "last_week";
 public static final String REPORTING_MONTH = "reporting_month";
 public static final String REPORTING_BIMONTH = "reporting_bimonth";
 public static final String REPORTING_QUARTER = "reporting_quarter";
@@ -189,6 +190,8 @@
 
 private boolean last5FinancialYears = false;
 
+private boolean lastWeek = false;
+
 private boolean last4Weeks = false;
 
 private boolean last12Weeks = false;
@@ -204,28 +207,36 @@
 }
 
 /**
- * @param reportingMonth   reporting month
- * @param reportingBimonth reporting bi-month
- * @param reportingQuarter reporting quarter
- * @param monthsThisYear   months this year
- * @param quartersThisYear quarters this year
- * @param thisYear this year
- * @param monthsLastYear   months last year
- * @param quartersLastYear quarters last year
- * @param lastYear last year
- * @param last5Years   last 5 years
- * @param last12Months last 12 months
- * @param last3Months  last 3 months
- * @param last6BiMonthslast 6 bi-months
- * @param last4Quarterslast 4 quarters
- * @param last2SixMonths   last 2 six-months
+ * @param reportingMonthreporting month
+ * @param reportingBimonth  reporting bi-month
+ * @param reportingQuarter  reporting quarter
+ * @param lastSixMonth  last six month
+ * @param monthsThisYearmonths this year
+ * @param quartersThisYear  quarters this year
+ * @param thisYear  this year
+ * @param monthsLastYearmonths last year
+ * @param quartersLastYear  quarters last year
+ * @param lastYear  last year
+ * @param last5Yearslast 5 years
+ * @param last12Months  last 12 months
+ * @param last3Months   last 3 months
+ * @param last6BiMonths last 6 bi-months
+ * @param last4Quarters last 4 quarters
+ * @param last2SixMonthslast 2 six-months
+ * @param thisFinancialYear this financial year
+ * @param lastFinancialYear last financial year
+ * @param last5FinancialYears   last 5 financial years
+ * @param lastWeek  last week
+ * @param last4Weekslast 4 weeks
+ * @param last12Weeks   last 1

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10217: Minor

2013-03-14 Thread noreply

revno: 10217
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 13:24:38 +0100
message:
  Minor
modified:
  
dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/RelativePeriods.hbm.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
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/RelativePeriods.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/RelativePeriods.hbm.xml	2012-09-23 15:49:44 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/RelativePeriods.hbm.xml	2013-03-14 12:24:38 +
@@ -33,6 +33,9 @@
 
 
 
+
+
+
 
 
   

___
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 10218: (PT) Option implemented: Show/hide (grand) totals.

2013-03-14 Thread noreply
Merge authors:
  Jan Henrik Øverland (janhenrik-overland)

revno: 10218 [merge]
committer: Jan Henrik Overland 
branch nick: dhis2
timestamp: Thu 2013-03-14 13:59:07 +0100
message:
  (PT) Option implemented: Show/hide (grand) totals.
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java
  
dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/reporttable/hibernate/ReportTable.hbm.xml
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/plugin.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-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java	2013-03-14 10:12:47 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java	2013-03-14 12:56:36 +
@@ -306,6 +306,11 @@
 /**
  * Indicates rendering of sub-totals for the table.
  */
+private boolean totals;
+
+/**
+ * Indicates rendering of sub-totals for the table.
+ */
 private boolean subtotals;
 
 /**
@@ -316,7 +321,7 @@
 /**
  * Indicates rendering of number formatting for the table.
  */
-private String numberFormatting;
+private String digitGroupSeparator;
 
 /**
  * The display density of the text in the table.
@@ -1385,6 +1390,19 @@
 @JsonProperty
 @JsonView( {DetailedView.class, ExportView.class} )
 @JacksonXmlProperty( namespace = DxfNamespaces.DXF_2_0)
+public boolean isTotals()
+{
+return totals;
+}
+
+public void setTotals( boolean totals )
+{
+this.totals = totals;
+}
+
+@JsonProperty
+@JsonView( {DetailedView.class, ExportView.class} )
+@JacksonXmlProperty( namespace = DxfNamespaces.DXF_2_0)
 public boolean isSubtotals()
 {
 return subtotals;
@@ -1411,14 +1429,14 @@
 @JsonProperty
 @JsonView( {DetailedView.class, ExportView.class} )
 @JacksonXmlProperty( namespace = DxfNamespaces.DXF_2_0)
-public String getNumberFormatting()
+public String getDigitGroupSeparator()
 {
-return numberFormatting;
+return digitGroupSeparator;
 }
 
-public void setNumberFormatting( String numberFormatting )
+public void setDigitGroupSeparator( String digitGroupSeparator )
 {
-this.numberFormatting = numberFormatting;
+this.digitGroupSeparator = digitGroupSeparator;
 }
 
 @JsonProperty
@@ -1650,9 +1668,10 @@
 reportParams = reportTable.getReportParams() == null ? reportParams : reportTable.getReportParams();
 sortOrder = reportTable.getSortOrder() == null ? sortOrder : reportTable.getSortOrder();
 topLimit = reportTable.getTopLimit() == null ? topLimit : reportTable.getTopLimit();
+totals = reportTable.isTotals();
 subtotals = reportTable.isSubtotals();
 hideEmptyRows = reportTable.isHideEmptyRows();
-numberFormatting = reportTable.getNumberFormatting();
+digitGroupSeparator = reportTable.getDigitGroupSeparator();
 displayDensity = reportTable.getDisplayDensity();
 fontSize = reportTable.getFontSize();
 userOrganisationUnit = reportTable.isUserOrganisationUnit();

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 11:51:43 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 12:57:16 +
@@ -429,13 +429,14 @@
 executeSql( "update reporttable set lastfinancialyear = false where lastfinancialyear is null" );
 executeSql( "update reporttable set last5financialyears = false where last5financialyears is null" );
 executeSql( "update reporttable set cumulative = false where cumulative is null" );
-executeSql( "update reporttable set subtotals = false where subtotals is null" );
 executeSql( "update reporttable set userorganisationunit = false where userorganisationunit is null" );
 executeSql( "update reporttable set userorganisationunitchildren = false where userorganisationunitchildren is null" );
+executeSql( "update reporttable set totals = true where totals is null" );
+executeSql( "update repor

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10219: Analytics, fixed bug

2013-03-14 Thread noreply

revno: 10219
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 14:07:10 +0100
message:
  Analytics, fixed bug
modified:
  
dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/DataQueryParams.java
  
dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultAnalyticsService.java
  
dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultQueryPlanner.java
  
dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/table/PartitionUtils.java
  
dhis-2/dhis-support/dhis-support-system/src/main/resources/html-report-template.html


--
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-analytics/src/main/java/org/hisp/dhis/analytics/DataQueryParams.java'
--- dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/DataQueryParams.java	2013-03-12 17:07:05 +
+++ dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/DataQueryParams.java	2013-03-14 13:07:10 +
@@ -159,7 +159,7 @@
  */
 public boolean filterSpansMultiplePartitions()
 {
-return tableNamePeriodMap != null && !tableNamePeriodMap.isEmpty();
+return tableNamePeriodMap != null && tableNamePeriodMap.size() > 1;
 }
 
 /**

=== modified file 'dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultAnalyticsService.java'
--- dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultAnalyticsService.java	2013-03-12 17:07:05 +
+++ dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultAnalyticsService.java	2013-03-14 13:07:10 +
@@ -339,16 +339,22 @@
 
 public Map getAggregatedDataValueMap( DataQueryParams params )
 {
+queryPlanner.validate( params );
+
 return getAggregatedValueMap( params, ANALYTICS_TABLE_NAME );
 }
 
 public Map getAggregatedCompletenessValueMap( DataQueryParams params )
 {
+queryPlanner.validate( params );
+
 return getAggregatedValueMap( params, COMPLETENESS_TABLE_NAME );
 }
 
 private Map getAggregatedCompletenessTargetMap( DataQueryParams params )
 {
+queryPlanner.validate( params );
+
 return getAggregatedValueMap( params, COMPLETENESS_TARGET_TABLE_NAME );
 }
 
@@ -359,8 +365,6 @@
  */
 private Map getAggregatedValueMap( DataQueryParams params, String tableName )
 {
-queryPlanner.validate( params );
-
 Timer t = new Timer().start();
 
 int optimalQueries = MathUtils.getWithin( SystemUtils.getCpuCores(), 1, MAX_QUERIES );

=== modified file 'dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultQueryPlanner.java'
--- dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultQueryPlanner.java	2013-03-11 08:24:17 +
+++ dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/DefaultQueryPlanner.java	2013-03-14 13:07:10 +
@@ -269,7 +269,8 @@
 /**
  * Groups the given query into sub queries based on its periods and which 
  * partition it should be executed against. Sets the partition table name on
- * each query. Queries are grouped based on both dimensions and filters.
+ * each query. Queries are grouped based on periods if appearing as a 
+ * dimension.
  */
 private List groupByPartition( DataQueryParams params, String tableName )
 {
@@ -297,7 +298,8 @@
 ListMap tableNamePeriodMap = PartitionUtils.getTableNamePeriodMap( params.getFilterPeriods(), tableName );
 
 DataQueryParams query = new DataQueryParams( params );
-query.setTableNamePeriodMap( tableNamePeriodMap );
+query.setTableNamePeriodMap( tableNamePeriodMap );
+query.setTableName( tableNamePeriodMap.keySet().iterator().next() );
 queries.add( query );
 }
 else

=== modified file 'dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/table/PartitionUtils.java'
--- dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/table/PartitionUtils.java	2013-03-10 16:13:56 +
+++ dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/table/PartitionUtils.java	2013-03-14 13:07:10 +
@@ -29,16 +29,15 @@
 
 import java.util.ArrayList;
 import java.util.Arrays;
-import java.util.Collection;
 import java.util.Date;
 i

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10220: Minor

2013-03-14 Thread noreply

revno: 10220
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 14:15:56 +0100
message:
  Minor
modified:
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.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/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 12:57:16 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 13:15:56 +
@@ -536,6 +536,8 @@
 executeSql( "ALTER TABLE usergroup DROP CONSTRAINT usergroup_name_key" );
 executeSql( "ALTER TABLE datadictionary DROP CONSTRAINT datadictionary_name_key" );
 
+executeSql( "ALTER TABLE relativeperiods set lastweek = false where lastweek is null" );
+
 upgradeChartRelativePeriods();
 upgradeReportTableRelativePeriods();
 upgradeReportTableColumns();

___
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 10221: Allow to enter custom filter values for string-fields in tabular report.

2013-03-14 Thread noreply

revno: 10221
committer: Tran Chau 
branch nick: dhis2
timestamp: Thu 2013-03-14 20:30:46 +0700
message:
  Allow to enter custom filter values for string-fields in tabular report.
modified:
  
dhis-2/dhis-api/src/main/java/org/hisp/dhis/patientreport/TabularReportColumn.java
  
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateTabularReportAction.java
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/cacheManifest.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonPatientProperties.vm
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/addProgramStageForm.vm
  
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/updateProgramStageForm.vm


--
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/patientreport/TabularReportColumn.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/patientreport/TabularReportColumn.java	2012-10-16 04:05:28 +
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/patientreport/TabularReportColumn.java	2013-03-14 13:30:46 +
@@ -18,6 +18,8 @@
 private String query;
 
 private String name;
+
+private boolean dateType = false;
 
 // -
 // Constructor
@@ -133,4 +135,14 @@
 {
 this.name = name;
 }
+
+public boolean isDateType()
+{
+return dateType;
+}
+
+public void setDateType( boolean dateType )
+{
+this.dateType = dateType;
+}
 }

=== modified file 'dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java	2013-03-14 05:03:19 +
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java	2013-03-14 13:30:46 +
@@ -674,7 +674,7 @@
 sql = getAggregateReportSQL8( programStage, orgunitIds, facilityLB, filterSQL, deGroupBy, periods
 .iterator().next(), aggregateType, limit, useCompletedEvents, format );
 }
-
+
 if ( !sql.isEmpty() )
 {
 SqlRowSet rowSet = jdbcTemplate.queryForRowSet( sql );
@@ -875,7 +875,14 @@
 
 if ( column.hasQuery() )
 {
-where += operator + "lower(" + column.getIdentifier() + ") " + column.getQuery() + " ";
+if ( column.isDateType() )
+{
+where += operator + column.getIdentifier() + " " + column.getQuery() + " ";
+}
+else
+{
+where += operator + "lower(" + column.getIdentifier() + ") " + column.getQuery() + " ";
+}
 operator = "and ";
 }
 }
@@ -890,7 +897,15 @@
 
 if ( column.hasQuery() )
 {
-where += operator + "lower(identifier_" + column.getIdentifier() + ") " + column.getQuery() + " ";
+if ( column.isDateType() )
+{
+where += operator + "identifier_" + column.getIdentifier() + " " + column.getQuery() + " ";
+}
+else
+{
+where += operator + "lower(identifier_" + column.getIdentifier() + ") " + column.getQuery()
++ " ";
+}
 operator = "and ";
 }
 }
@@ -905,7 +920,15 @@
 
 if ( column.hasQuery() )
 {
-where += operator + "lower(attribute_" + column.getIdentifier() + ") " + column.getQuery() + " ";
+if ( column.isDateType() )
+{
+where += operator + "attribute_" + column.getIdentifier() + " " + column.getQuery() + " ";
+}
+else
+{
+where += operator + "lower(attribute_" + column.getIdentifier() + ") " + column.getQuery()
++ " ";
+}
  

[Dhis2-devs] [Branch ~dhis2-documenters/dhis2/dhis2-docbook-docs] Rev 689: Fixed incositent copy path

2013-03-14 Thread noreply

revno: 689
committer: Lars Helge Øverland 
branch nick: dhis2-docbook-docs
timestamp: Thu 2013-03-14 14:50:06 +0100
message:
  Fixed incositent copy path
modified:
  pom.xml


--
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs

Your team DHIS 2 developers is subscribed to branch 
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs.
To unsubscribe from this branch go to 
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs/+edit-subscription
=== modified file 'pom.xml'
--- pom.xml	2013-02-28 07:11:09 +
+++ pom.xml	2013-03-14 13:50:06 +
@@ -199,7 +199,7 @@
   dhis2_user_manual_en.xml,dhis2_end_user_manual.xml,dhis2_implementation_guide_en.xml
   ${docbook.source}/en/
   
-
+
 
 
   

___
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 10222: Analytics, fixed bug

2013-03-14 Thread noreply

revno: 10222
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 15:31:25 +0100
message:
  Analytics, fixed bug
modified:
  
dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/JdbcAnalyticsManager.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-analytics/src/main/java/org/hisp/dhis/analytics/data/JdbcAnalyticsManager.java'
--- dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/JdbcAnalyticsManager.java	2013-03-10 16:13:56 +
+++ dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/data/JdbcAnalyticsManager.java	2013-03-14 14:31:25 +
@@ -214,9 +214,22 @@
 
 for ( DataQueryParams filterParams : params.getPartitionFilterParams() )
 {
-sql += "select " + getCommaDelimitedString( filterParams.getQueryDimensions() ) + ", value as value ";
-
-sql += getFromWhereClause( filterParams );
+sql += "select " + getCommaDelimitedString( filterParams.getQueryDimensions() ) + ", ";
+
+if ( params.isAggregationType( AVERAGE_INT ) )
+{
+sql += "daysxvalue";
+}
+else if ( params.isAggregationType( AVERAGE_BOOL ) )
+{
+sql += "daysxvalue, daysno";
+}
+else
+{
+sql += "value";
+}
+
+sql += " " + getFromWhereClause( filterParams );
 
 sql += "union all ";
 }

___
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 10223: (PT) Favorite crud issues fixed.

2013-03-14 Thread noreply
Merge authors:
  Jan Henrik Øverland (janhenrik-overland)

revno: 10223 [merge]
committer: Jan Henrik Overland 
branch nick: dhis2
timestamp: Thu 2013-03-14 15:38:18 +0100
message:
  (PT) Favorite crud issues fixed.
modified:
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/plugin.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-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js	2013-03-14 12:56:36 +
+++ dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js	2013-03-14 14:33:39 +
@@ -132,11 +132,11 @@
 			}
 		};
 
-		util.pivot.getSettingsConfig = function() {
+		util.pivot.getLayoutConfig = function() {
 			var data = {},
-setup = pt.viewport.settingsWindow ? pt.viewport.settingsWindow.getSetup() : {},
+setup = pt.viewport.layoutWindow ? pt.viewport.layoutWindow.getSetup() : {},
 getData,
-extendSettings,
+extendLayout,
 config;
 
 			config = {
@@ -170,7 +170,7 @@
 }
 			}();
 
-			extendSettings = function() {
+			extendLayout = function() {
 for (var i = 0, dimensionName; i < setup.col.length; i++) {
 	dimensionName = setup.col[i];
 	config.col.push({
@@ -408,7 +408,7 @@
 		return cmp;
 	};
 
-	PT.app.SettingsWindow = function() {
+	PT.app.LayoutWindow = function() {
 		var dimension,
 			dimensionStore,
 			dimensionOrder,
@@ -532,8 +532,8 @@
 			style: 'margin-right:' + margin + 'px; margin-bottom:0px',
 			valueField: 'id',
 			displayField: 'name',
-			dragGroup: 'settingsDD',
-			dropGroup: 'settingsDD',
+			dragGroup: 'layoutDD',
+			dropGroup: 'layoutDD',
 			ddReorder: false,
 			store: dimensionStore,
 			tbar: {
@@ -562,8 +562,8 @@
 			style: 'margin-bottom:0px',
 			valueField: 'id',
 			displayField: 'name',
-			dragGroup: 'settingsDD',
-			dropGroup: 'settingsDD',
+			dragGroup: 'layoutDD',
+			dropGroup: 'layoutDD',
 			store: rowStore,
 			tbar: {
 height: 25,
@@ -596,8 +596,8 @@
 			style: 'margin-bottom:' + margin + 'px',
 			valueField: 'id',
 			displayField: 'name',
-			dragGroup: 'settingsDD',
-			dropGroup: 'settingsDD',
+			dragGroup: 'layoutDD',
+			dropGroup: 'layoutDD',
 			store: colStore,
 			tbar: {
 height: 25,
@@ -630,8 +630,8 @@
 			style: 'margin-right:' + margin + 'px; margin-bottom:' + margin + 'px',
 			valueField: 'id',
 			displayField: 'name',
-			dragGroup: 'settingsDD',
-			dropGroup: 'settingsDD',
+			dragGroup: 'layoutDD',
+			dropGroup: 'layoutDD',
 			store: filterStore,
 			tbar: {
 height: 25,
@@ -975,16 +975,16 @@
 		getBody = function() {
 			var favorite;
 
-			if (pt.xSettings) {
-favorite = Ext.clone(pt.xSettings.options);
+			if (pt.xLayout) {
+favorite = Ext.clone(pt.xLayout.options);
 
 // Server sync
 favorite.totals = favorite.showTotals;
 favorite.subtotals = favorite.showSubTotals;
 
 // Dimensions
-for (var i = 0, obj, key, items; i < pt.xSettings.objects.length; i++) {
-	obj = pt.xSettings.objects[i];
+for (var i = 0, obj, key, items; i < pt.xLayout.objects.length; i++) {
+	obj = pt.xLayout.objects[i];
 
 	if (obj.objectName === pt.conf.finals.dimension.period.objectName) {
 		for (var j = 0, item; j < obj.items.length; j++) {
@@ -1044,32 +1044,37 @@
 	}
 }
 
+// Relative periods PUT workaround
+if (!favorite.relativePeriods) {
+	favorite.relativePeriods = {};
+}
+
 // Setup
-if (pt.xSettings.col) {
+if (pt.xLayout.col) {
 	var a = [];
 
-	for (var i = 0; i < pt.xSettings.col.length; i++) {
-		a.push(pt.xSettings.col[i].dimensionName);
+	for (var i = 0; i < pt.xLayout.col.length; i++) {
+		a.push(pt.xLayout.col[i].dimensionName);
 	}
 
 	favorite['columnDimensions'] = a;
 }
 
-if (pt.xSettings.row) {
+if (pt.xLayout.row) {
 	var a = [];
 
-	for (var i = 0; i < pt.xSettings.row.length; i++) {
-		a.push(pt.xSettings.row[i].dimensionName);
+	for (var i = 0; i < pt.xLayout.row.length; i++) {
+		a.push(pt.xLayout.row[i].dimensionName);
 	}
 
 	favorite['rowDimensions'] = a;
 }
 
-if (pt.xSettings.filter) {
+if (pt.xLayout.filter) {
 	var a = [];
 
-	for (var i = 0; i < pt.xSettings.filter.length; i++) {
-		a.push(pt.xSettings.filter[i].dimensionName);
+	for (var i = 0; i < pt.xLayout.filter.length; i++) {
+		a.push(pt.xLayout.filter[i].dimensionName);
 	}
 
 	favorite['filterDimensions'] = a;

[Dhis2-devs] [Branch ~dhis2-documenters/dhis2/dhis2-docbook-docs] Rev 690: Minor

2013-03-14 Thread noreply

revno: 690
committer: Lars Helge Øverland 
branch nick: dhis2-docbook-docs
timestamp: Thu 2013-03-14 15:56:36 +0100
message:
  Minor
modified:
  src/docbkx/en/dhis2_user_man_web_api.xml


--
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs

Your team DHIS 2 developers is subscribed to branch 
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs.
To unsubscribe from this branch go to 
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs/+edit-subscription
=== modified file 'src/docbkx/en/dhis2_user_man_web_api.xml'
--- src/docbkx/en/dhis2_user_man_web_api.xml	2013-03-12 17:07:23 +
+++ src/docbkx/en/dhis2_user_man_web_api.xml	2013-03-14 14:56:36 +
@@ -116,7 +116,7 @@
 LAST_MONTH, LAST_BIMONTH, LAST_QUARTER, LAST_SIX_MONTH, MONTHS_THIS_YEAR, QUARTERS_THIS_YEAR, 
 THIS_YEAR, MONTHS_LAST_YEAR, QUARTERS_LAST_YEAR, LAST_YEAR, LAST_5_YEARS, LAST_12_MONTHS, 
 LAST_3_MONTHS, LAST_6_BIMONTHS, LAST_4_QUARTERS, LAST_2_SIXMONTHS, THIS_FINANCIAL_YEAR, 
-LAST_FINANCIAL_YEAR, LAST_5_FINANCIAL_YEARS, LAST_4_WEEKS, LAST_12_WEEKS, LAST_52_WEEKS
+LAST_FINANCIAL_YEAR, LAST_5_FINANCIAL_YEARS, LAST_WEEK, LAST_4_WEEKS, LAST_12_WEEKS, LAST_52_WEEKS
   
   
 Browsing the Web API

___
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] Fwd: [Dhis2-users] Invitation to the DHIS2 Academy 2013 in Entebbe Uganda

2013-03-14 Thread Ayub Manya
Thank you. Kazungu, Tom have and I have shown interest in attending.

 

From: dhis2-devs-bounces+ayubmanya=gmail@lists.launchpad.net 
[mailto:dhis2-devs-bounces+ayubmanya=gmail@lists.launchpad.net] On Behalf 
Of Ola Hodne Titlestad
Sent: 14 March 2013 12:16 PM
To: dhis2-devs
Subject: [Dhis2-devs] Fwd: [Dhis2-users] Invitation to the DHIS2 Academy 2013 
in Entebbe Uganda

 

-- Forwarded message --

From: Prosper BT 
Date: 9 March 2013 10:14
Subject: [Dhis2-users] Invitation to the DHIS2 Academy 2013 in Entebbe Uganda
To: dhis2-us...@lists.launchpad.net


Dear Team,

 

On behalf of HISP EA, am delighted to announce the 2013 East and Southern 
African DHIS2 Academy, please find attached an invitation letter.

 

For more information please us the contacts in the invitation letter.

 

Regards and looking forward,

 

-- 
Prosper Behumbiize, MPH
Phone:+256 414 320076  
Cell:+256 752 751776  
   +256 702 762707   





 

-- 
Prosper Behumbiize, MPH
Phone:+256 414 320076  
Cell:+256 752 751776  
   +256 702 762707   


___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-us...@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
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 10224: Minor

2013-03-14 Thread noreply

revno: 10224
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 16:05:25 +0100
message:
  Minor
modified:
  
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.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/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 13:15:56 +
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java	2013-03-14 15:05:25 +
@@ -536,7 +536,9 @@
 executeSql( "ALTER TABLE usergroup DROP CONSTRAINT usergroup_name_key" );
 executeSql( "ALTER TABLE datadictionary DROP CONSTRAINT datadictionary_name_key" );
 
-executeSql( "ALTER TABLE relativeperiods set lastweek = false where lastweek is null" );
+executeSql( "update relativeperiods set lastweek = false where lastweek is null" );
+executeSql( "update relativeperiods set last4weeks = false where last4weeks is null" );
+executeSql( "update relativeperiods set last12weeks = false where last12weeks is null" );
 
 upgradeChartRelativePeriods();
 upgradeReportTableRelativePeriods();

___
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 10226: Clean up code

2013-03-14 Thread noreply

revno: 10226
committer: Tran Chau 
branch nick: dhis2
timestamp: Thu 2013-03-14 22:48:51 +0700
message:
  Clean up code
modified:
  
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.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-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java	2013-03-14 15:42:22 +
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java	2013-03-14 15:48:51 +
@@ -674,7 +674,7 @@
 sql = getAggregateReportSQL8( programStage, orgunitIds, facilityLB, filterSQL, deGroupBy, periods
 .iterator().next(), aggregateType, limit, useCompletedEvents, format );
 }
-System.out.println("\n\n " + sql );
+
 if ( !sql.isEmpty() )
 {
 SqlRowSet rowSet = jdbcTemplate.queryForRowSet( sql );

___
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 10225: Sort fixed periods chronologically; only allow to select multiple values in filter fields with op...

2013-03-14 Thread noreply

revno: 10225
committer: Tran Chau 
branch nick: dhis2
timestamp: Thu 2013-03-14 22:42:22 +0700
message:
   Sort fixed periods chronologically; only allow to select multiple values in 
filter fields with operator IN in tabular report.
modified:
  
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateAggregateReportAction.java
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.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-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java	2013-03-14 13:30:46 +
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java	2013-03-14 15:42:22 +
@@ -674,7 +674,7 @@
 sql = getAggregateReportSQL8( programStage, orgunitIds, facilityLB, filterSQL, deGroupBy, periods
 .iterator().next(), aggregateType, limit, useCompletedEvents, format );
 }
-
+System.out.println("\n\n " + sql );
 if ( !sql.isEmpty() )
 {
 SqlRowSet rowSet = jdbcTemplate.queryForRowSet( sql );
@@ -1289,11 +1289,11 @@
 sql += " psi_1.executiondate >= '" + startDate + "' AND ";
 sql += " psi_1.executiondate <= '" + endDate + "' ";
 sql += filterSQL + " LIMIT 1 )  as " + aggregateType + ") ";
-sql += " UNION ";
+sql += " UNION ALL ";
 }
 }
 
-sql = sql.substring( 0, sql.length() - 6 );
+sql = sql.substring( 0, sql.length() - 10 );
 if ( limit != null )
 {
 sql += " LIMIT " + limit;
@@ -1466,11 +1466,11 @@
 }
 sql += "GROUP BY dataelementid ";
 
-sql += ") UNION ";
+sql += ") UNION ALL ";
 
 }
 
-sql = sql.substring( 0, sql.length() - 6 );
+sql = sql.substring( 0, sql.length() - 10 );
 
 if ( limit != null )
 {
@@ -1543,10 +1543,10 @@
 }
 sql += "GROUP BY dataelementid ";
 
-sql += ") UNION ";
+sql += ") UNION ALL ";
 }
 
-sql = sql.substring( 0, sql.length() - 6 );
+sql = sql.substring( 0, sql.length() - 10 );
 if ( limit != null )
 {
 sql += " LIMIT " + limit;
@@ -1823,12 +1823,12 @@
 sql += ") as \"" + periodName + "\",";
 }
 sql = sql.substring( 0, sql.length() - 1 );
-sql += " ) UNION ";
+sql += " ) UNION ALL ";
 }
 
 if ( !sql.isEmpty() )
 {
-sql = sql.substring( 0, sql.length() - 6 );
+sql = sql.substring( 0, sql.length() - 10 );
 if ( periods.size() == 1 )
 {
 sql += "ORDER BY  \"" + firstPeriodName + "\" desc ";
@@ -2163,7 +2163,7 @@
 {
 if ( rowSet.getMetaData().getColumnType( j + 2 ) != Types.VARCHAR )
 {
-total += (Double) columnValues.get( i ).get( j );
+total += (Long) columnValues.get( i ).get( j );
 }
 }
 if ( total == (int) total )

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateAggregateReportAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateAggregateReportAction.java	2013-02-22 04:49:30 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateAggregateReportAction.java	2013-03-14 15:42:22 +
@@ -29,6 +29,7 @@
 
 import java.util.ArrayList;
 import java.util.Collection;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
@@ -43,6 +44,7 @@
 import org.hisp.dhis.period.PeriodService;
 import org.hisp.dhis.period.PeriodType;
 import org.hisp.dhis.period.RelativePeriods;
+import org.hisp.dhis.period.comparator.AscendingPeriodComparator;
 import org.hisp.dhis.program.ProgramStage;
 import org.hisp.dhis.program.ProgramStageInstanceService;
 import org.hisp.dhis.program.ProgramStageService;
@@ -294,14 +296,18 @@
 }
 
 // Fixed p

[Dhis2-devs] [Branch ~dhis2-documenters/dhis2/dhis2-docbook-docs] Rev 691: HTML based standard reports

2013-03-14 Thread noreply

revno: 691
committer: Lars Helge Øverland 
branch nick: dhis2-docbook-docs
timestamp: Thu 2013-03-14 17:42:29 +0100
message:
  HTML based standard reports
modified:
  src/docbkx/en/dhis2_user_man_creating_reporting.xml


--
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs

Your team DHIS 2 developers is subscribed to branch 
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs.
To unsubscribe from this branch go to 
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs/+edit-subscription
=== modified file 'src/docbkx/en/dhis2_user_man_creating_reporting.xml'
--- src/docbkx/en/dhis2_user_man_creating_reporting.xml	2012-11-15 11:21:48 +
+++ src/docbkx/en/dhis2_user_man_creating_reporting.xml	2013-03-14 16:42:29 +
@@ -1177,8 +1177,8 @@
 
 
   Designing SQL based standard reports
-  A standard report might also be based on SQL queries. This is useful when you need to
-access multiple tables in the DHIS database and do custom selects and joins. 
+  A standard report might be based on SQL queries. This is useful when you need to access
+multiple tables in the DHIS database and do custom selects and joins. 
   - This step is optional, but handy when you need to debug your reports and when you have
 direct access to the database you want to use. Click on the "report datasources" button,
 "New", "Database JDBC connection" and click "next". In this window you can give you
@@ -1254,5 +1254,69 @@
 parameters. Click save. This will redirect you to the list of reports, where you can click
 the green "create" icon next to your report to render it.
 
+
+  Designing HTML based standard reports
+  A standard report can be designed using purely HTML and Javascript. This requires a
+little bit of development experience in the mentioned subjects. The benefit of HTML based
+standard reports is that it allows for maximum flexibility. Using HTML you can design
+exactly the report you want, positioning tables, logos and values on the page acccording to
+your design needs. You can write and save your standard report design in a regular text
+file. To upload your HTML based standard report to DHIS 2 do the following:
+  
+
+  Navigate to standard reports and click "Add new".
+
+
+  Give the report a name.
+
+
+  Select "HTML report" as type.
+
+
+  If you want to you can download a report template by clicking on "Get HTML report
+template".
+
+
+  Select desired relative periods - these will be available in Javascript in your
+report.
+
+
+  Select report parameters - these will be available in Javascript in your
+report.
+
+  
+  The report template, which you can download after selecting report type, is a useful
+starting point for developing HTML based standar reports. It gives you the basic structure
+and suggests how you can use Javascript and CSS in the report. Javascript and CSS can easily
+be included using standard script and style tags.
+  If you selected relative periods when creating the standard report you can access these
+in Javascript like this:
+  var periods = dhis2.report.periods; // An array with period identifiers
+var period = periods[0];
+  If you selected the organisation unit report parameter when creating the standard report
+you can access the selected organisation unit in Javascript like this:
+  var orgUnit = dhis2.report.organisationUnit; // An object
+var id = orgUnit.id; 
+var name = orgUnit.name;
+var code = orgUnit.code;
+  When designing these reports you can utilize the analytics Web API resource in order to
+retrieve aggregated data in Javascript. Have a look in the Web API chapter in this guide for
+a closer description. As an example you can retrieve analytics data after the report has
+been loaded and use that data to set the inner text of an HTML element like this:
+  
+  A few other tips: To include graphics you can convert an image to SVG and embed that SVG
+content directly in the report - DHIS 2 is based on HTML 5 where SVG tags are valid markup.
+To include charts and maps in your report you can use the charts and maps resources in the
+Web API. You can use the full capability of the Web API from J

[Dhis2-devs] [Branch ~dhis2-documenters/dhis2/dhis2-docbook-docs] Rev 692: Minor

2013-03-14 Thread noreply

revno: 692
committer: Lars Helge Øverland 
branch nick: dhis2-docbook-docs
timestamp: Thu 2013-03-14 17:47:47 +0100
message:
  Minor
modified:
  src/docbkx/en/dhis2_user_man_creating_reporting.xml


--
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs

Your team DHIS 2 developers is subscribed to branch 
lp:~dhis2-documenters/dhis2/dhis2-docbook-docs.
To unsubscribe from this branch go to 
https://code.launchpad.net/~dhis2-documenters/dhis2/dhis2-docbook-docs/+edit-subscription
=== modified file 'src/docbkx/en/dhis2_user_man_creating_reporting.xml'
--- src/docbkx/en/dhis2_user_man_creating_reporting.xml	2013-03-14 16:42:29 +
+++ src/docbkx/en/dhis2_user_man_creating_reporting.xml	2013-03-14 16:47:47 +
@@ -1286,7 +1286,7 @@
 
   
   The report template, which you can download after selecting report type, is a useful
-starting point for developing HTML based standar reports. It gives you the basic structure
+starting point for developing HTML based standard reports. It gives you the basic structure
 and suggests how you can use Javascript and CSS in the report. Javascript and CSS can easily
 be included using standard script and style tags.
   If you selected relative periods when creating the standard report you can access these
@@ -1301,8 +1301,9 @@
 var code = orgUnit.code;
   When designing these reports you can utilize the analytics Web API resource in order to
 retrieve aggregated data in Javascript. Have a look in the Web API chapter in this guide for
-a closer description. As an example you can retrieve analytics data after the report has
-been loaded and use that data to set the inner text of an HTML element like this:
+a closer description. As a complete, minimal example you can retrieve analytics data after
+the report has been loaded and use that data to set the inner text of an HTML element like
+this:
   
+
+
+
BGG coverage:
+
FIC coverage:
A few other tips: To include graphics you can convert an image to SVG and embed that SVG content directly in the report - DHIS 2 is based on HTML 5 where SVG tags are valid markup. To include charts and maps in your report you can use the charts and maps resources in the ___ 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 10227: Added last week, last 4 weeks, last 12 weeks relative periods to report table

2013-03-14 Thread noreply

revno: 10227
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 18:20:25 +0100
message:
  Added last week, last 4 weeks, last 12 weeks relative periods to report table
modified:
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js
  
dhis-2/dhis-web/dhis-web-reporting/src/main/resources/org/hisp/dhis/reporting/i18n_module.properties
  
dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/relativePeriodsInput.vm


--
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-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js	2013-03-05 14:39:17 +
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js	2013-03-14 17:20:25 +
@@ -1574,7 +1574,10 @@
  isChecked( "last2SixMonths" ) ||
  isChecked( "thisFinancialYear" ) ||
  isChecked( "lastFinancialYear" ) ||
- isChecked( "last5FinancialYears" ) )
+ isChecked( "last5FinancialYears" ) ||
+ isChecked( "lastWeek" ) ||
+ isChecked( "last4Weeks" ) ||
+ isChecked( "last12Weeks" ) )
 {
 return true;
 }

=== modified file 'dhis-2/dhis-web/dhis-web-reporting/src/main/resources/org/hisp/dhis/reporting/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/resources/org/hisp/dhis/reporting/i18n_module.properties	2013-03-05 19:00:51 +
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/resources/org/hisp/dhis/reporting/i18n_module.properties	2013-03-14 17:20:25 +
@@ -37,6 +37,9 @@
 this_year=This year
 reporting_sixmonth=Reporting six-month
 last_2_sixmonths=Last 2 six-months
+last_week=Last week
+last_4_weeks=Last 4 weeks
+last_12_weeks=Last 12 weeks
 months_last_year=Months last year
 quarters_last_year=Quarters last year
 last_year=Last year

=== modified file 'dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/relativePeriodsInput.vm'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/relativePeriodsInput.vm	2012-09-23 15:49:44 +
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/relativePeriodsInput.vm	2013-03-14 17:20:25 +
@@ -24,17 +24,24 @@
  
 $i18n.getString( "last_financial_year" )
 
-
-$i18n.getString( "last_5_years" )
- 
+
+$i18n.getString( "last_week" )
+ 
+$i18n.getString( "last_4_weeks" )
+ 
+$i18n.getString( "last_12_weeks" )
+ 
+$i18n.getString( "last_3_months" )
+
+
 $i18n.getString( "last_12_months" )
  
 $i18n.getString( "last_4_quarters" )
  
 $i18n.getString( "last_2_sixmonths" )
-
+ 
+$i18n.getString( "last_5_years" )
+
 
-$i18n.getString( "last_3_months" )
- 
 $i18n.getString( "last_5_financial_years" )
 
\ No newline at end of file

___
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 10228: Impl crud operations for chart in web api

2013-03-14 Thread noreply

revno: 10228
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 18:35:51 +0100
message:
  Impl crud operations for chart in web api
modified:
  
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/ChartController.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/api/controller/ChartController.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/ChartController.java	2013-02-06 14:45:08 +
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/api/controller/ChartController.java	2013-03-14 17:35:51 +
@@ -27,33 +27,45 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
+import static org.hisp.dhis.common.IdentifiableObjectUtils.getUids;
+
 import java.io.IOException;
+import java.io.InputStream;
 import java.util.Date;
 
+import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
 import org.hisp.dhis.api.utils.ContextUtils;
 import org.hisp.dhis.api.utils.ContextUtils.CacheStrategy;
 import org.hisp.dhis.chart.Chart;
 import org.hisp.dhis.chart.ChartService;
+import org.hisp.dhis.dataelement.DataElementService;
+import org.hisp.dhis.dataset.DataSetService;
+import org.hisp.dhis.dxf2.utils.JacksonUtils;
 import org.hisp.dhis.i18n.I18nFormat;
 import org.hisp.dhis.i18n.I18nManager;
 import org.hisp.dhis.i18n.I18nManagerException;
 import org.hisp.dhis.indicator.Indicator;
 import org.hisp.dhis.indicator.IndicatorService;
 import org.hisp.dhis.organisationunit.OrganisationUnit;
+import org.hisp.dhis.organisationunit.OrganisationUnitGroupService;
 import org.hisp.dhis.organisationunit.OrganisationUnitService;
 import org.hisp.dhis.period.Period;
+import org.hisp.dhis.period.PeriodService;
 import org.hisp.dhis.system.util.CodecUtils;
+import org.hisp.dhis.user.UserService;
 import org.jfree.chart.ChartUtilities;
 import org.jfree.chart.JFreeChart;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.format.annotation.DateTimeFormat;
+import org.springframework.http.HttpStatus;
 import org.springframework.stereotype.Controller;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMethod;
 import org.springframework.web.bind.annotation.RequestParam;
+import org.springframework.web.bind.annotation.ResponseStatus;
 
 /**
  * @author Morten Olav Hansen 
@@ -70,17 +82,91 @@
 private ChartService chartService;
 
 @Autowired
+private DataElementService dataElementService;
+
+@Autowired
+private DataSetService dataSetService;
+
+@Autowired
+private PeriodService periodService;
+
+@Autowired
+private UserService userService;
+
+@Autowired
 private IndicatorService indicatorService;
 
 @Autowired
 private OrganisationUnitService organisationUnitService;
 
 @Autowired
+private OrganisationUnitGroupService organisationUnitGroupService;
+
+@Autowired
 private I18nManager i18nManager;
 
 @Autowired
 private ContextUtils contextUtils;
 
+//--
+// CRUD
+//--
+
+@Override
+@RequestMapping( method = RequestMethod.POST, consumes = "application/json" )
+public void postJsonObject( HttpServletResponse response, HttpServletRequest request, InputStream input ) throws Exception
+{
+Chart chart = JacksonUtils.fromJson( input, Chart.class );
+
+mergeChart( chart );
+
+chartService.addChart( chart );
+
+ContextUtils.createdResponse( response, "Chart created", RESOURCE_PATH + "/" + chart.getUid() );
+}
+
+@Override
+@RequestMapping( value = "/{uid}", method = RequestMethod.PUT, consumes = "application/json" )
+@ResponseStatus( value = HttpStatus.NO_CONTENT )
+public void putJsonObject( HttpServletResponse response, HttpServletRequest request, @PathVariable( "uid" ) String uid, InputStream input ) throws Exception
+{
+Chart chart = chartService.getChart( uid );
+
+if ( chart == null )
+{
+ContextUtils.notFoundResponse( response, "Chart does not exist: " + uid );
+return;
+}
+
+Chart newChart = JacksonUtils.fromJson( input, Chart.class );
+
+mergeChart( newChart );
+
+chart.mergeWith( newChart );
+
+chartService.updateChart( chart );
+}
+
+@O

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10229: Import-export ui fix

2013-03-14 Thread noreply

revno: 10229
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 19:14:45 +0100
message:
  Import-export ui fix
modified:
  
dhis-2/dhis-web/dhis-web-importexport/src/main/java/org/hisp/dhis/importexport/action/dxf2/MetaDataImportAction.java
  
dhis-2/dhis-web/dhis-web-importexport/src/main/resources/org/hisp/dhis/importexport/i18n_module.properties
  
dhis-2/dhis-web/dhis-web-importexport/src/main/webapp/dhis-web-importexport/dxf2MetaDataExport.vm
  
dhis-2/dhis-web/dhis-web-importexport/src/main/webapp/dhis-web-importexport/dxf2MetaDataImport.vm
  
dhis-2/dhis-web/dhis-web-importexport/src/main/webapp/dhis-web-importexport/index.vm
  
dhis-2/dhis-web/dhis-web-importexport/src/main/webapp/dhis-web-importexport/mainMenu.vm


--
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-importexport/src/main/java/org/hisp/dhis/importexport/action/dxf2/MetaDataImportAction.java'
--- dhis-2/dhis-web/dhis-web-importexport/src/main/java/org/hisp/dhis/importexport/action/dxf2/MetaDataImportAction.java	2012-07-04 20:16:23 +
+++ dhis-2/dhis-web/dhis-web-importexport/src/main/java/org/hisp/dhis/importexport/action/dxf2/MetaDataImportAction.java	2013-03-14 18:14:45 +
@@ -27,9 +27,10 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-import com.opensymphony.xwork2.Action;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.InputStream;
+
 import org.hisp.dhis.dxf2.metadata.ImportOptions;
 import org.hisp.dhis.dxf2.metadata.ImportService;
 import org.hisp.dhis.importexport.ImportStrategy;
@@ -41,9 +42,7 @@
 import org.hisp.dhis.user.CurrentUserService;
 import org.springframework.beans.factory.annotation.Autowired;
 
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.InputStream;
+import com.opensymphony.xwork2.Action;
 
 /**
  * @author Morten Olav Hansen 
@@ -51,8 +50,6 @@
 public class MetaDataImportAction
 implements Action
 {
-private static final Log log = LogFactory.getLog( MetaDataImportAction.class );
-
 // -
 // Dependencies
 // -

=== modified file 'dhis-2/dhis-web/dhis-web-importexport/src/main/resources/org/hisp/dhis/importexport/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-importexport/src/main/resources/org/hisp/dhis/importexport/i18n_module.properties	2013-02-22 06:30:40 +
+++ dhis-2/dhis-web/dhis-web-importexport/src/main/resources/org/hisp/dhis/importexport/i18n_module.properties	2013-03-14 18:14:45 +
@@ -261,22 +261,21 @@
 intro_DHIS14_data_export=Do an export of data values or facts. DHIS 1.4 is the predecessor of DHIS 2.
 intro_pdf_metadata_export=Portable Document Format (PDF) is a commonly used file format for document exchange.
 intro_xls_metadata_export=Excel Spreadsheet (XLS) is a commonly used spreadsheet file format from Microsoft.
-intro_import=This is the regular import function which imports data from the DHIS 2 exchange format called DXF.
-intro_xml_data_import=Import data values on the DXF XML format which is used for data exchange by DHIS and other software.
-intro_csv_data_import=Import data values on the CSV format which is used for data exchange by DHIS and other third-party software.
+intro_xml_data_import=Import data values on the DXF 2 XML format which is used for data exchange by DHIS 2 and other software.
+intro_csv_data_import=Import data values on the CSV format which is used for data exchange by DHIS 2 and other third-party software.
 intro_dhis14_import=Import data from DHIS 1.4 installations. DHIS 1.4 is the predecessor of DHIS 2.
-intro_data_export=Export data values. This is the regular export function which exports data to the DHIS 2 exchange format called DXF.
-intro_metadata_export=Export meta data to the DHIS 2 exchange format. Meta meta implies data elements and other objects describing the data.
-intro_detailed_metadata_export=Do a detailed meta data export of data elements and indicators to the DHIS 2 exchange format.
-intro_export_to_other_systems=Export data and meta data to formats such as PDF, Excel and DHIS 1.4.
+intro_data_export=Export data values. This is the regular export function which exports data to the DHIS 2 exchange format called DXF 2.
+intro_metadata_export=Export meta data like data elements and organisation units to the standard DHIS 2 exchange format.
+intro_export_to_other_systems=Export data and meta data to formats such as PDF, Excel and the DHIS 1.4 exchange format.
 intro_dhis14_file_configuration=

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10230: (PT) Last week, last 4 weeks and last 12 weeks supported.

2013-03-14 Thread noreply
Merge authors:
  Jan Henrik Øverland (janhenrik-overland)

revno: 10230 [merge]
committer: Jan Henrik Overland 
branch nick: dhis2
timestamp: Thu 2013-03-14 19:38:41 +0100
message:
  (PT) Last week, last 4 weeks and last 12 weeks supported.
modified:
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js
  
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.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-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js	2013-03-14 14:33:39 +
+++ dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js	2013-03-14 15:38:54 +
@@ -2387,14 +2387,56 @@
 valueComponentMap: {},
 items: [
 	{
-		xtype: 'panel',
+		xtype: 'container',
 		layout: 'column',
 		bodyStyle: 'border-style:none',
 		items: [
 			{
 xtype: 'panel',
-layout: 'anchor',
-bodyStyle: 'border-style:none; padding:0 0 0 10px',
+columnWidth: 0.35,
+bodyStyle: 'border-style:none; padding:0 0 0 8px',
+defaults: {
+	labelSeparator: '',
+	style: 'margin-bottom:2px',
+	listeners: {
+		added: function(chb) {
+			if (chb.xtype === 'checkbox') {
+pt.cmp.dimension.relativePeriod.checkbox.push(chb);
+relativePeriod.valueComponentMap[chb.relativePeriodId] = chb;
+			}
+		},
+		change: function() {
+			rewind.xable();
+		}
+	}
+},
+items: [
+	{
+		xtype: 'label',
+		text: 'Weeks', //i18n pt.i18n.months,
+		cls: 'pt-label-period-heading'
+	},
+	{
+		xtype: 'checkbox',
+		relativePeriodId: 'LAST_WEEK',
+		boxLabel: 'Last week', //i18n pt.i18n.last_month
+	},
+	{
+		xtype: 'checkbox',
+		relativePeriodId: 'LAST_4_WEEKS',
+		boxLabel: 'Last 4 weeks', //i18n pt.i18n.last_3_months
+	},
+	{
+		xtype: 'checkbox',
+		relativePeriodId: 'LAST_12_WEEKS',
+		boxLabel: 'Last 12 weeks' //i18n pt.i18n.last_12_months,
+	}
+]
+			},
+			{
+xtype: 'panel',
+columnWidth: 0.32,
+bodyStyle: 'border-style:none',
 defaults: {
 	labelSeparator: '',
 	style: 'margin-bottom:2px',
@@ -2436,8 +2478,8 @@
 			},
 			{
 xtype: 'panel',
-layout: 'anchor',
-bodyStyle: 'border-style:none; padding:0 0 0 32px',
+columnWidth: 0.33,
+bodyStyle: 'border-style:none',
 defaults: {
 	labelSeparator: '',
 	style: 'margin-bottom:2px',
@@ -2470,11 +2512,18 @@
 		boxLabel: 'Last 4 quarters', //i18n pt.i18n.last_4_quarters
 	}
 ]
-			},
+			}
+		]
+	},
+	{
+		xtype: 'container',
+		layout: 'column',
+		bodyStyle: 'border-style:none',
+		items: [
 			{
 xtype: 'panel',
-layout: 'anchor',
-bodyStyle: 'border-style:none; padding:0 0 0 32px',
+columnWidth: 0.35,
+bodyStyle: 'border-style:none; padding:5px 0 0 10px',
 defaults: {
 	labelSeparator: '',
 	style: 'margin-bottom:2px',
@@ -2504,21 +2553,14 @@
 	{
 		xtype: 'checkbox',
 		relativePeriodId: 'LAST_2_SIXMONTHS',
-		boxLabel: 'Last two six-months', //i18n pt.i18n.last_two_six_month
+		boxLabel: 'Last 2 six-months', //i18n pt.i18n.last_two_six_month
 	}
 ]
-			}
-		]
-	},
-	{
-		xtype: 'panel',
-		layout: 'column',
-		bodyStyle: 'border-style:none',
-		items: [
+			},
 			{
 xtype: 'panel',
-layout: 'anchor',
-bodyStyle: 'border-style:none; padding:5px 0 0 10px',
+columnWidth: 0.32,
+bodyStyle: 'border-style:none; padding:5px 0 0',
 defaults: {
 	labelSeparator: '',
 	style: 'margin-bottom:2px',
@@ -2557,6 +2599,7 @@
 	}
 ]
 			}
+
 			//{
 //xtype: 'panel',
 //layout: 'anchor',
@@ -2763,7 +2806,7 @@
 	{
 		xtype: 'panel',
 		layout: 'column',
-		bodyStyle: 'border-style:none; padding-bottom:6px',
+		bodyStyle: 'border-style:none; padding-bottom:4px',
 		items: [
 			fixedPeriodAvailable,
 			fixedPeriodSelected

=== modified file 'dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js'
--- dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10231: Impl page for overview of functions under help and profile top menu items. Useful for touch-devices.

2013-03-14 Thread noreply

revno: 10231
committer: Lars Helge Øverland 
branch nick: dhis2
timestamp: Thu 2013-03-14 20:05:13 +0100
message:
  Impl page for overview of functions under help and profile top menu items. 
Useful for touch-devices.
added:
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/about/functions.vm
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-about-dhis2.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-account.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-help-center.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-log-out.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-profile.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-settings.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-supportive-software.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-system-overview.png
  
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-web-api.png
modified:
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js
  dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml
  dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties


--
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-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/about/functions.vm'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/about/functions.vm	1970-01-01 00:00:00 +
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/about/functions.vm	2013-03-14 19:05:13 +
@@ -0,0 +1,24 @@
+
+
+	
+
+
+	#introListImgItem( "../dhis-web-commons-about/help.action", "help_center", "function-help-center" )
+#introListImgItem( "../dhis-web-commons-about/software.action", "supportive_software", "function-supportive-software" )
+#introListImgItem( "../dhis-web-commons-about/modules.action", "system_overview", "function-system-overview" )
+#introListImgItem( "../api", "web_api", "function-web-api" )
+#introListImgItem( "../dhis-web-commons-about/about.action", "about_dhis2", "function-about-dhis2" )
+
+
+
+
+
+#introListImgItem( "../dhis-web-commons-about/userSettings.action", "settings", "function-settings" )
+#introListImgItem( "../dhis-web-commons-about/showUpdateUserProfileForm.action", "profile", "function-profile" )
+#introListImgItem( "../dhis-web-commons-about/showUpdateUserAccountForm.action", "account", "function-account" )
+#introListImgItem( "../dhis-web-commons-security/logout.action", "log_out", "function-log-out" )
+
+
+
+
+
\ No newline at end of file

=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-about-dhis2.png'
Binary files dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-about-dhis2.png	1970-01-01 00:00:00 + and dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-about-dhis2.png	2013-03-14 19:05:13 + differ
=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-account.png'
Binary files dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-account.png	1970-01-01 00:00:00 + and dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-account.png	2013-03-14 19:05:13 + differ
=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-help-center.png'
Binary files dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-help-center.png	1970-01-01 00:00:00 + and dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-help-center.png	2013-03-14 19:05:13 + differ
=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-log-out.png'
Binary files dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-log-out.png	1970-01-01 00:00:00 + and dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-log-out.png	2013-03-14 19:05:13 + differ
=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-profile.png'
Binary files dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-profile.png	1970-01-01 00:00:00 + and dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-profile.png	2013-03-14 19:05:13 + differ
=== added file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/icons/function-settings.png'
Binary files dhis-2/dhis-

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10232: Enable re-enroll button when to click completed program in Dashboard.

2013-03-14 Thread noreply

revno: 10232
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 10:30:15 +0700
message:
  Enable re-enroll button when to click completed program in Dashboard.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm


--
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-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm	2013-03-14 08:30:49 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientDashboard.vm	2013-03-15 03:30:15 +
@@ -99,7 +99,7 @@
 			• $i18n.getString("enroll")
 		
 		
-			
+			
 #foreach( $programInstance in $activeProgramInstances )
 	#set($programStageInstanceId = '')
 	#if($programInstance.program.type==1)
@@ -150,7 +150,7 @@
 			• $i18n.getString("enroll")
 		
 		
-			
+			
 #foreach($programInstance in $completedProgramInstances)
 	#set($programStageInstanceId = '')
 	#if($programInstance.program.type==2)

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm	2013-03-14 08:30:49 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm	2013-03-15 03:30:15 +
@@ -150,6 +150,12 @@
 			jQuery("[id=tab-4] :input").prop('disabled', true);
 			jQuery("[id=tab-5] :input").prop('disabled', true);
 			jQuery("[id=tab-3] :input").datepicker("destroy");
+			jQuery("#completeProgram").attr('disabled', true);
+			jQuery("#incompleteProgram").attr('disabled', false);
+			jQuery("img").removeAttr("onclick");
+		#else
+			jQuery("#completeProgram").attr('disabled', false);
+			jQuery("#incompleteProgram").attr('disabled', true);
 		#end
 	});
 

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-14 09:12:54 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-15 03:30:15 +
@@ -13,8 +13,8 @@
 			
 			
 
-
-
+
+
 			
 		
 	
@@ -103,16 +103,5 @@
 #end
 
 
-	#if( $!programInstance )
-		showById('unenrollBtn');
-	#end
-	#if( $programInstance.completed=='false')
-		datePickerInRangeValid( 'dateOfIncident' , 'enrollmentDate' );
-	#else
-		jQuery(":input").attr('disabled', true);
-		jQuery("#incompleteProgram").attr('disabled', false);
-		jQuery("img").removeAttr("onclick");
-	#end
-	
 	var i18n_insert_a_due_date = '$encoder.jsEscape( $i18n.getString( "insert_a_due_date" ) , "'")';
 
\ No newline at end of file

___
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 10233: ( Dashboard ) Not allow to delete events of a completed program.

2013-03-14 Thread noreply

revno: 10233
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 11:08:40 +0700
message:
  ( Dashboard ) Not allow to delete events of a completed program.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm


--
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-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-03-11 07:46:26 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-03-15 04:08:40 +
@@ -1431,7 +1431,10 @@
 jQuery("[id=tab-3] :input").datepicker("destroy");
 jQuery("#completeProgram").attr('disabled', true);
 jQuery("#incompleteProgram").attr('disabled', false);
-
+
+// disable remove event icons
+$('[id=tab-3]').find('img').parent().removeAttr("href");
+			
 showSuccessMessage( i18n_unenrol_success );
 			}
 		});
@@ -1474,6 +1477,12 @@
 jQuery("#incompleteProgram").attr('disabled', true);
 jQuery("[id=tab-3] :input").datepicker("destroy");
 
+// enable remove event icons
+$('[id=tab-3]').find('img').parent().each(function(){
+	var e = jQuery(this);
+	e.attr( 'href',e.attr("link") );
+});
+
 showSuccessMessage( i18n_reenrol_success );
 			}
 		});

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js	2013-03-07 13:46:43 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js	2013-03-15 04:08:40 +
@@ -527,7 +527,7 @@
 	var eventBox = jQuery('#ps_' + getFieldValue('programStageInstanceId'));
 	eventBox.attr('status',1);
 	resetActiveEvent( eventBox.attr("pi") );
-			
+	
 	hideLoader();
 	
 	if( isCreateEvent ){

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm	2013-03-15 03:30:15 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programEnrollmentForm.vm	2013-03-15 04:08:40 +
@@ -152,7 +152,7 @@
 			jQuery("[id=tab-3] :input").datepicker("destroy");
 			jQuery("#completeProgram").attr('disabled', true);
 			jQuery("#incompleteProgram").attr('disabled', false);
-			jQuery("img").removeAttr("onclick");
+			$('[id=tab-3]').find('img').parent().removeAttr("href");
 		#else
 			jQuery("#completeProgram").attr('disabled', false);
 			jQuery("#incompleteProgram").attr('disabled', true);

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-15 03:30:15 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-15 04:08:40 +
@@ -92,7 +92,7 @@
 			
 			#if( $auth.hasAccess( "dhis-web-caseentry", "removeCurrentEncounter" ) )
 			
-
+
 			
 			#end
 		

___
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 10234: Enable non-skip event box after to click Re-enroll button in Dashboard.

2013-03-14 Thread noreply

revno: 10234
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 11:20:33 +0700
message:
  Enable non-skip event box after to click Re-enroll button in Dashboard.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm


--
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-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-03-15 04:08:40 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-03-15 04:20:33 +
@@ -1469,6 +1469,9 @@
 jQuery('#completedTB [id=tr1_' + programInstanceId + ']').remove();
 jQuery('#completedTB [id=tr2_' + programInstanceId + ']').remove();
 
+jQuery("[id=tab-1] :input").prop('disabled', false);
+// Disable skipped events
+jQuery("[id=tab-1] [status=5]").prop('disabled', true);
 jQuery("[id=tab-2] :input").prop('disabled', false);
 jQuery("[id=tab-3] :input").prop('disabled', false);
 jQuery("[id=tab-4] :input").prop('disabled', false);
@@ -1478,7 +1481,7 @@
 jQuery("[id=tab-3] :input").datepicker("destroy");
 
 // enable remove event icons
-$('[id=tab-3]').find('img').parent().each(function(){
+jQuery('[id=tab-3]').find('img').parent().each(function(){
 	var e = jQuery(this);
 	e.attr( 'href',e.attr("link") );
 });

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-15 04:08:40 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/visitSchedule.vm	2013-03-15 04:20:33 +
@@ -24,7 +24,7 @@
 #if( $programStageInstances.size() > 0 )
 	
 		
-			
+			
 			
 			
 			
@@ -33,7 +33,7 @@
 			  
 		
 		
-			$i18n.getString( "nr" )
+			$i18n.getString( "#" )
 			$i18n.getString( "program_stage" )   
 			$i18n.getString( "due_date" )   
 			$i18n.getString( "status" )
@@ -103,5 +103,13 @@
 #end
 
 
+	#if( $programInstance.completed=='false')
+		datePickerInRangeValid( 'dateOfIncident' , 'enrollmentDate' );
+		jQuery("#incompleteProgram").attr('disabled', true);
+	#else
+		jQuery(":input").attr('disabled', true);
+		jQuery("#incompleteProgram").attr('disabled', false);
+		$('[id=tab-3]').find('img').parent().removeAttr("href");
+	#end
 	var i18n_insert_a_due_date = '$encoder.jsEscape( $i18n.getString( "insert_a_due_date" ) , "'")';
 
\ No newline at end of file

___
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 10235: Display suggested date for next visit when to click on Create new event button in Dataentry tab o...

2013-03-14 Thread noreply

revno: 10235
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 11:29:23 +0700
message:
  Display suggested date for next visit when to click on Create new event 
button in Dataentry tab of dashboard.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.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-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-03-15 04:20:33 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-03-15 04:29:23 +
@@ -568,6 +568,9 @@
 			lastVisit = reportDate;
 		}
 	});
+	if( lastVisit == ''){
+		lastVisit = getCurrentDate();
+	}
 	
 	var standardInterval = jQuery('#repeatableProgramStage_' + programInstanceId + ' option:selected').attr('standardInterval');
 	var date = $.datepicker.parseDate( dateFormat, lastVisit );

___
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 10236: implemented proper validation for multi-org units

2013-03-14 Thread noreply

revno: 10236
committer: Morten Olav Hansen 
branch nick: dhis2
timestamp: Fri 2013-03-15 11:53:19 +0700
message:
  implemented proper validation for multi-org units
modified:
  
dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/ValidationAction.java
  
dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js
  
dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/validationResult.vm


--
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-dataentry/src/main/java/org/hisp/dhis/de/action/ValidationAction.java'
--- dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/ValidationAction.java	2013-03-07 05:40:43 +
+++ dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/ValidationAction.java	2013-03-15 04:53:19 +
@@ -27,16 +27,7 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-import static org.hisp.dhis.system.util.ListUtils.getCollection;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-
+import com.opensymphony.xwork2.Action;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
@@ -54,7 +45,14 @@
 import org.hisp.dhis.validation.ValidationRule;
 import org.hisp.dhis.validation.ValidationRuleService;
 
-import com.opensymphony.xwork2.Action;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.TreeMap;
+
+import static org.hisp.dhis.system.util.ListUtils.getCollection;
 
 /**
  * @author Margrethe Store
@@ -152,30 +150,30 @@
 // Output
 // -
 
-private List results;
-
-public List getResults()
-{
-return results;
-}
-
-private Map leftsideFormulaMap;
-
-public Map getLeftsideFormulaMap()
-{
-return leftsideFormulaMap;
-}
-
-private Map rightsideFormulaMap;
-
-public Map getRightsideFormulaMap()
-{
-return rightsideFormulaMap;
-}
-
-private Collection dataValues = new HashSet();
-
-public Collection getDataValues()
+private Map> validationResults = new TreeMap>();
+
+public Map> getValidationResults()
+{
+return validationResults;
+}
+
+private Map> leftSideFormulaMap = new HashMap>();
+
+public Map> getLeftSideFormulaMap()
+{
+return leftSideFormulaMap;
+}
+
+private Map> rightSideFormulaMap = new HashMap>();
+
+public Map> getRightSideFormulaMap()
+{
+return rightSideFormulaMap;
+}
+
+private Map> dataValues = new TreeMap>();
+
+public Map> getDataValues()
 {
 return dataValues;
 }
@@ -193,88 +191,89 @@
 
 Period selectedPeriod = PeriodType.createPeriodExternalId( periodId );
 
-Period period = null;
-
-if ( selectedPeriod != null )
-{
-period = periodService.getPeriod( selectedPeriod.getStartDate(), selectedPeriod.getEndDate(),
-selectedPeriod.getPeriodType() );
-
-if ( validationCheck( orgUnit, dataSet, period ).equals( INPUT ) )
-{
-return INPUT;
-}
-}
-
-if ( multiOrganisationUnit && selectedPeriod != null )
-{
-List children = new ArrayList( orgUnit.getChildren() );
-
-Collections.sort( children, IdentifiableObjectNameComparator.INSTANCE );
-
-for ( OrganisationUnit child : children )
-{
-if ( validationCheck( child, dataSet, period ).equals( INPUT ) )
-{
-return INPUT;
-}
-}
-}
-
-return dataValues.size() == 0 && results.size() == 0 ? SUCCESS : INPUT;
-}
-
-// -
-// Supportive methods
-// -
-
-private String validationCheck( OrganisationUnit unit, DataSet dataSet, Period period )
-{
-if ( unit != null )
-{
-// -
-// Min-max and outlier analysis
-// -
-
-dataValues = minMaxOutlierAnalysisService.analyse( getCollection( unit ), dataSet.getDa

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10237: Display all programs available into combo box list which belong to the current user.

2013-03-14 Thread noreply

revno: 10237
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 12:48:16 +0700
message:
   Display all programs available into combo box list which belong to the 
current user.
modified:
  dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/activityPlan.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-caseentry/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml	2013-03-14 07:36:22 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml	2013-03-15 05:48:16 +
@@ -1056,7 +1056,7 @@
 
 
 
+  class="org.hisp.dhis.caseentry.action.patient.SelectAction">
   
   /main.vm
   /dhis-web-caseentry/activityPlanSelect.vm

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/activityPlan.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/activityPlan.js	2013-03-05 14:47:06 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/activityPlan.js	2013-03-15 05:48:16 +
@@ -3,20 +3,8 @@
 function orgunitSelected( orgUnits, orgUnitNames )
 {
 	hideById("listPatientDiv");
-	clearListById('programIdAddPatient');
-	$('#contentDataRecord').html('');
 	setFieldValue('orgunitName', orgUnitNames[0]);
 	setFieldValue('orgunitId', orgUnits[0]);
-	jQuery( '#programIdAddPatient').append( '' + i18n_please_select + '' );
-	jQuery.get("getPrograms.action",{}, 
-		function(json)
-		{
-			for ( i in json.programs ) {
-if(json.programs[i].type==1){
-	jQuery( '#programIdAddPatient').append( '' + json.programs[i].name + '' );
-}
-			}
-		});
 }
 
 selection.setListenerFunction( orgunitSelected );

___
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 10238: Check validate before to save report as favorite in Tabular report.

2013-03-14 Thread noreply

revno: 10238
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 13:11:20 +0700
message:
  Check validate before to save report as favorite in Tabular report.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.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-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js	2013-03-14 15:42:22 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js	2013-03-15 06:11:20 +
@@ -1002,6 +1002,15 @@
 
 caseBasedReport:{
 	create: function(fn, isupdate) {
+		// Validation
+		
+		if( !TR.state.caseBasedReport.validation.objects() )
+		{
+			return;
+		}
+		
+		// Save favorite
+		
 		TR.util.mask.showMask(TR.cmp.caseBasedFavorite.window, TR.i18n.saving + '...');
 		var p = TR.state.caseBasedReport.getParams(false);
 		p.name = TR.cmp.caseBasedFavorite.name.getValue();
@@ -1170,6 +1179,15 @@
 
 aggregateReport:{
 	create: function(fn, isupdate) {
+		// Validation
+		
+		if( !TR.state.aggregateReport.validation.objects() )
+		{
+			return;
+		}
+		
+		// Save favorite
+		
 		TR.util.mask.showMask(TR.cmp.aggregateFavorite.window, TR.i18n.saving + '...');
 		var p = TR.state.getParams();
 		p.name = TR.cmp.aggregateFavorite.name.getValue();

___
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] [Bug 1155468] [NEW] Personal attributes can only be used in one programme

2013-03-14 Thread Ingvild Indrebø
Public bug reported:

If you add some extra personal attributes and use them in one programme,
the following programmes can not use the same attributes. One attribute
can only be used once. Is this intentionally? Trunk 2.11 chrome

** 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/1155468

Title:
  Personal attributes can only be used in one programme

Status in DHIS 2 - District Health Information Software:
  New

Bug description:
  If you add some extra personal attributes and use them in one
  programme, the following programmes can not use the same attributes.
  One attribute can only be used once. Is this intentionally? Trunk 2.11
  chrome

To manage notifications about this bug go to:
https://bugs.launchpad.net/dhis2/+bug/1155468/+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


[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 10239: Re-set relative periods when to run aggregate favorite in tabular report.

2013-03-14 Thread noreply

revno: 10239
committer: Tran Chau 
branch nick: dhis2
timestamp: Fri 2013-03-15 13:47:49 +0700
message:
  Re-set relative periods when to run aggregate favorite in tabular report.
modified:
  
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.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-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js	2013-03-15 06:11:20 +
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js	2013-03-15 06:47:49 +
@@ -1280,12 +1280,19 @@
 
 // Relative periods
 
+Ext.Array.each(TR.cmp.params.relativeperiod.checkbox, function(item) {
+	if(item.getValue() && !item.hidden){
+		item.setValue(false);
+	}
+});
 for (var i = 0; i < f.relativePeriods.length; i++) {
 	TR.util.getCmp('checkbox[paramName="' + f.relativePeriods[i] + '"]').setValue(true);
 }
 
 // Fixed periods
 
+TR.store.fixedperiod.selected.removeAll();
+
 var periods = [];
 for (var i = 0; i < f.fixedPeriods.length; i++) {
 	periods[i]={

___
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