← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 5515: Remove anonymous programs; Change smoother color for program-stage-instance into multi-data-entry...

 

------------------------------------------------------------
revno: 5515
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2011-12-21 14:16:29 +0700
message:
  Remove anonymous programs; Change smoother color for program-stage-instance into multi-data-entry form.
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageInstance.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/GetProgramsByOrgunitAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/MultiDataEntrySelectAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageDataEntryForm.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/ProgramStageInstance.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageInstance.java	2011-12-16 06:45:30 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageInstance.java	2011-12-21 07:16:29 +0000
@@ -41,13 +41,13 @@
      */
     private static final long serialVersionUID = 6239130884678145713L;
 
-    public static final String COLOR_RED = "#ff0000";
+    public static final String COLOR_RED = "#fb4754";
 
-    public static final String COLOR_YELLOW = "#ffff00";
-    
-    public static final String COLOR_GREEN = "#00ff00";
-    
-    public static final String COLOR_LIGHTRED = "#ff00ff";
+    public static final String COLOR_YELLOW = "#f9f95a";
+    
+    public static final String COLOR_GREEN = "#8ffe8f";
+    
+    public static final String COLOR_LIGHTRED = "#fb6bfb";
 
     private int id;
 

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/GetProgramsByOrgunitAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/GetProgramsByOrgunitAction.java	2011-12-20 09:58:33 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/GetProgramsByOrgunitAction.java	2011-12-21 07:16:29 +0000
@@ -90,14 +90,17 @@
     {
         organisationUnit = selectedStateManager.getSelectedOrganisationUnit();
 
-        programs = programService.getPrograms( organisationUnit );
-        Collection<Program> anonymousPrograms = programService.getPrograms( true, true, organisationUnit );
-        programs.removeAll( anonymousPrograms );
+        if ( organisationUnit != null )
+        {
+            programs = programService.getPrograms( organisationUnit );
+            Collection<Program> anonymousPrograms = programService.getPrograms( true, true, organisationUnit );
+            programs.removeAll( anonymousPrograms );
+        }
         
         selectedStateManager.clearSelectedPatient();
         selectedStateManager.clearSelectedProgramInstance();
         selectedStateManager.clearSelectedProgramStageInstance();
-        
+
         return SUCCESS;
     }
 }

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/MultiDataEntrySelectAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/MultiDataEntrySelectAction.java	2011-12-14 11:15:54 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/caseentry/MultiDataEntrySelectAction.java	2011-12-21 07:16:29 +0000
@@ -118,6 +118,8 @@
         if ( organisationUnit != null )
         {
             programs = programService.getPrograms( organisationUnit );
+            Collection<Program> anonymousPrograms = programService.getPrograms( true, true, organisationUnit );
+            programs.removeAll( anonymousPrograms );
         }
         
         return SUCCESS;

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java	2011-09-23 18:54:49 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java	2011-12-21 07:16:29 +0000
@@ -51,10 +51,6 @@
 public class GenerateReportAction
     extends ActionPagingSupport<ProgramInstance>
 {
-    public static final String RED = "#ff0000";
-
-    public static final String YELLOW = "#ffff00";
-
     // -------------------------------------------------------------------------
     // Dependencies
     // -------------------------------------------------------------------------

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageDataEntryForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageDataEntryForm.vm	2011-10-29 14:16:54 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageDataEntryForm.vm	2011-12-21 07:16:29 +0000
@@ -4,14 +4,37 @@
 });
 </script>
 
-<table class="mainPageTable"> 
+<table> 
     <tr>            
         <td>
-            <span class='bold'>$i18n.getString( "full_name" ):</span>$encoder.htmlEncode( $patient.getFullName() )<br>
-            <span class='bold'>$i18n.getString( "gender" ):</span>$i18n.getString( $patient.gender )<br>
-            <span class='bold'>$i18n.getString( "date_of_birth" ):</span>$format.formatDate( $patient.birthDate )<br>
-            <span class='bold'>$i18n.getString( "age" ):</span>$encoder.htmlEncode( $patient.getAge() )
+            <span class='bold'>$i18n.getString( "full_name" ):</span>
+		</td>
+		<td>
+			$encoder.htmlEncode( $patient.getFullName() )
+		<td>
+	</tr>
+	<tr>
+		<td>
+            <span class='bold'>$i18n.getString( "gender" ):</span>
+		</td>
+		<td>
+			$i18n.getString( $patient.gender )
+		</td>
+	</tr>
+	<tr>
+		<td>
+            <span class='bold'>$i18n.getString( "date_of_birth" ):</span>
+		</td>
+		<td>
+			$format.formatDate( $patient.birthDate )
+		</td>
+	<tr>
+		<td>
+            <span class='bold'>$i18n.getString( "age" ):</span>
         </td>
+		<td>
+			$encoder.htmlEncode( $patient.getAge() )
+		</td>
 	</tr>
 </table>
 
@@ -46,7 +69,7 @@
     <tr>
 		<td>&nbsp;</td>
 		<td><input type="button" id="completeBtn" value="$i18n.getString('complete')" onClick="doComplete()" #if($programStageInstance.executionDate) #else disabled #end>
-			<input type="button" id="validationBtn" value="$i18n.getString('validation')" onClick="javascript: runValidation();" style="width:12em " #if($programStageInstance.executionDate) #else disabled #end>
+			<input type="button" id="validationBtn" value="$i18n.getString('run_validation')" onClick="javascript: runValidation();" style="width:12em " #if($programStageInstance.executionDate) #else disabled #end>
 		</td>
 		<td></td>
 		<td></td>