← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 5886: minor fixes.. i18n and deletionhandler

 

------------------------------------------------------------
revno: 5886
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2012-02-08 19:16:23 +0700
message:
  minor fixes.. i18n and deletionhandler
modified:
  dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lockexception/RemoveLockExceptionAction.java
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.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
=== modified file 'dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java'
--- dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java	2012-02-08 04:05:53 +0000
+++ dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java	2012-02-08 12:16:23 +0000
@@ -32,17 +32,12 @@
 import org.hisp.dhis.concept.Concept;
 import org.hisp.dhis.constant.Constant;
 import org.hisp.dhis.datadictionary.DataDictionary;
-import org.hisp.dhis.dataelement.DataElement;
-import org.hisp.dhis.dataelement.DataElementCategory;
-import org.hisp.dhis.dataelement.DataElementCategoryCombo;
-import org.hisp.dhis.dataelement.DataElementCategoryOption;
-import org.hisp.dhis.dataelement.DataElementCategoryOptionCombo;
-import org.hisp.dhis.dataelement.DataElementGroup;
-import org.hisp.dhis.dataelement.DataElementGroupSet;
+import org.hisp.dhis.dataelement.*;
 import org.hisp.dhis.dataentryform.DataEntryForm;
 import org.hisp.dhis.datamart.DataMartExport;
 import org.hisp.dhis.dataset.CompleteDataSetRegistration;
 import org.hisp.dhis.dataset.DataSet;
+import org.hisp.dhis.dataset.LockException;
 import org.hisp.dhis.dataset.Section;
 import org.hisp.dhis.datavalue.DataValue;
 import org.hisp.dhis.document.Document;
@@ -61,30 +56,17 @@
 import org.hisp.dhis.organisationunit.OrganisationUnitGroup;
 import org.hisp.dhis.organisationunit.OrganisationUnitGroupSet;
 import org.hisp.dhis.organisationunit.OrganisationUnitLevel;
-import org.hisp.dhis.patient.Patient;
-import org.hisp.dhis.patient.PatientAttribute;
-import org.hisp.dhis.patient.PatientAttributeGroup;
-import org.hisp.dhis.patient.PatientIdentifier;
-import org.hisp.dhis.patient.PatientIdentifierType;
+import org.hisp.dhis.patient.*;
 import org.hisp.dhis.patientattributevalue.PatientAttributeValue;
 import org.hisp.dhis.patientdatavalue.PatientDataValue;
 import org.hisp.dhis.period.Period;
-import org.hisp.dhis.program.Program;
-import org.hisp.dhis.program.ProgramInstance;
-import org.hisp.dhis.program.ProgramStage;
-import org.hisp.dhis.program.ProgramStageDataElement;
-import org.hisp.dhis.program.ProgramStageInstance;
-import org.hisp.dhis.program.ProgramValidation;
+import org.hisp.dhis.program.*;
 import org.hisp.dhis.programattributevalue.ProgramAttributeValue;
 import org.hisp.dhis.relationship.Relationship;
 import org.hisp.dhis.relationship.RelationshipType;
 import org.hisp.dhis.report.Report;
 import org.hisp.dhis.reporttable.ReportTable;
-import org.hisp.dhis.user.User;
-import org.hisp.dhis.user.UserAuthorityGroup;
-import org.hisp.dhis.user.UserCredentials;
-import org.hisp.dhis.user.UserGroup;
-import org.hisp.dhis.user.UserSetting;
+import org.hisp.dhis.user.*;
 import org.hisp.dhis.validation.ValidationCriteria;
 import org.hisp.dhis.validation.ValidationRule;
 import org.hisp.dhis.validation.ValidationRuleGroup;
@@ -95,16 +77,16 @@
  * DataElementGroup should override the deleteDataElement(..) method which
  * should remove the DataElement from all DataElementGroups. Also, it should
  * override the allowDeleteDataElement() method and return a non-null String value
- * if there exists objects that are dependent on the DataElement and are 
+ * if there exists objects that are dependent on the DataElement and are
  * considered not be deleted. The return value could be a hint for which object
  * is denying the delete, like the name.
- * 
+ *
  * @author Lars Helge Overland
  */
 public abstract class DeletionHandler
 {
     protected final String ERROR = "";
-    
+
     // -------------------------------------------------------------------------
     // Abstract methods
     // -------------------------------------------------------------------------
@@ -403,7 +385,7 @@
         return null;
     }
 
-    public String allowDeleteUserGroup ( UserGroup userGroup )
+    public String allowDeleteUserGroup( UserGroup userGroup )
     {
         return null;
     }
@@ -411,7 +393,7 @@
     public void deleteUserGroup( UserGroup userGroup )
     {
     }
-    
+
     public void deleteUserSetting( UserSetting userSetting )
     {
     }
@@ -465,11 +447,11 @@
     {
         return null;
     }
-    
+
     public void deleteLegend( Legend legend )
     {
     }
-    
+
     public String allowDeleteLegend( Legend legend )
     {
         return null;
@@ -609,12 +591,12 @@
     public void deletePatientDataValue( PatientDataValue patientDataValue )
     {
     }
-    
+
     public String allowDeleteProgramValidation( ProgramValidation programValidation )
     {
         return null;
     }
-    
+
     public void deleteProgramValidation( ProgramValidation programValidation )
     {
     }
@@ -654,7 +636,7 @@
     public void deleteCaseAggregationCondition( CaseAggregationCondition caseAggregationCondition )
     {
     }
-    
+
     public String allowDeleteOptionSet( OptionSet optionSet )
     {
         return null;
@@ -663,4 +645,13 @@
     public void deleteOptionSet( OptionSet optionSet )
     {
     }
+
+    public String allowDeleteLockException( LockException lockException )
+    {
+        return null;
+    }
+
+    public void deleteLockException( LockException lockException )
+    {
+    }
 }

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lockexception/RemoveLockExceptionAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lockexception/RemoveLockExceptionAction.java	2012-02-08 12:04:46 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lockexception/RemoveLockExceptionAction.java	2012-02-08 12:16:23 +0000
@@ -52,11 +52,11 @@
     // Input & Output
     // -------------------------------------------------------------------------
 
-    private int lockExceptionId;
+    private int id;
 
-    public void setLockExceptionId( int lockExceptionId )
+    public void setId( int id )
     {
-        this.lockExceptionId = lockExceptionId;
+        this.id = id;
     }
 
     // -------------------------------------------------------------------------
@@ -66,7 +66,7 @@
     @Override
     public String execute() throws Exception
     {
-        LockException lockException = dataSetService.getLockException( lockExceptionId );
+        LockException lockException = dataSetService.getLockException( id );
 
         if ( lockException != null )
         {

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties	2012-02-08 12:04:46 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties	2012-02-08 12:16:23 +0000
@@ -396,3 +396,5 @@
 object_not_deleted_associated_by_objects=Object not deleted because it is associated by objects of type >>>>>>> MERGE-SOURCE
 lock_exception_management=Lock Exception Management
 lock_exception=Lock Exception
+confirm_delete_lock_exception=Do you want to delete this lock exception?
+create_new_lock_exception=Create new lock exception