← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 16266: Fixed bug - Display program translation.

 

------------------------------------------------------------
revno: 16266
committer: Tran Chau<tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2014-07-28 16:24:17 +0700
message:
  Fixed bug - Display program translation.
modified:
  dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/program/DefaultProgramService.java
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/programStage.vm
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramForm.vm
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/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-tracker/src/main/java/org/hisp/dhis/program/DefaultProgramService.java'
--- dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/program/DefaultProgramService.java	2014-05-16 15:26:10 +0000
+++ dhis-2/dhis-services/dhis-service-tracker/src/main/java/org/hisp/dhis/program/DefaultProgramService.java	2014-07-28 09:24:17 +0000
@@ -178,13 +178,13 @@
     @Override
     public Integer getProgramCountByName( String name )
     {
-        return programStore.getCountLikeName( name );
+        return i18n( i18nService, programStore.getCountLikeName( name ));
     }
 
     @Override
     public Collection<Program> getProgramBetweenByName( String name, int min, int max )
     {
-        return programStore.getAllLikeNameOrderedName( name, min, max );
+        return i18n( i18nService, programStore.getAllLikeNameOrderedName( name, min, max ));
     }
 
     @Override
@@ -196,7 +196,7 @@
     @Override
     public Collection<Program> getProgramsBetween( int min, int max )
     {
-        return programStore.getAllOrderedName( min, max );
+        return i18n( i18nService, programStore.getAllOrderedName( min, max ) );
     }
     
     // -------------------------------------------------------------------------

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/programStage.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/programStage.vm	2014-07-27 12:49:21 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/programStage.vm	2014-07-28 09:24:17 +0000
@@ -33,7 +33,6 @@
 				<thead>
 					<tr>
 						<th>$i18n.getString( "name" )</th>
-						<th>$i18n.getString( "description" )</th>
 					</tr>
 				</thead>
 		  
@@ -46,7 +45,6 @@
 							data-can-manage-template-message="#if($programStage.program.type!=3)true#{else}false#end"
 						    data-can-remove="#if( $program.type=='1' )true#{else}false#end">
 						    <td>$encoder.htmlEncode( $!programStage.displayName )</td>
-						    <td>$encoder.htmlEncode( $!programStage.description )</td>
 						</tr>
 					#end
 				</tbody>

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramForm.vm	2014-07-27 15:02:58 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramForm.vm	2014-07-28 09:24:17 +0000
@@ -70,7 +70,7 @@
     <tbody>
 		<tr>
 			<td><label for="name">$i18n.getString( "name" ) <em title="$i18n.getString( "required" )" class="required">*</em></label></td>
-			<td><input type="text" id="name" name="name" value="$encoder.htmlEncode( $program.displayName )" class="{validate:{required:true,minlength:4}}"></td>
+			<td><input type="text" id="name" name="name" value="$encoder.htmlEncode( $program.name )" class="{validate:{required:true,minlength:4}}"></td>
 			<td></td>
 		</tr>	
 		

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramStageForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramStageForm.vm	2014-07-27 15:02:58 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/updateProgramStageForm.vm	2014-07-28 09:24:17 +0000
@@ -29,7 +29,7 @@
 		<tbody>
 			<tr>
 				<td><label for="name">$i18n.getString( "name" ) <em title="$i18n.getString( 'required' )" class="required">*</em></label></td>
-				<td><input type="text" id="name" name="name" value="$encoder.htmlEncode( $programStage.displayName )" class="{validate:{required:true,rangelength:[4,160]}}"/></td>
+				<td><input type="text" id="name" name="name" value="$encoder.htmlEncode( $programStage.name )" class="{validate:{required:true,rangelength:[4,160]}}"/></td>
 			</tr>
 
 			<tr>