← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 10396: fixed auto-complete orgunit search encoding bug

 

------------------------------------------------------------
revno: 10396
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-03-22 15:23:51 +0700
message:
  fixed auto-complete orgunit search encoding bug
modified:
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ouwt/responseSearch.vm
  dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.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-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ouwt/responseSearch.vm'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ouwt/responseSearch.vm	2012-09-19 11:41:19 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/ouwt/responseSearch.vm	2013-03-22 08:23:51 +0000
@@ -1,6 +1,2 @@
 #set( $size = $organisationUnits.size() )
-[
-#foreach( $unit in $organisationUnits )
-{"value":"$encoder.htmlEncode( $unit.name )"}#if( $velocityCount < $size ),#end
-#end
-]
\ No newline at end of file
+[#foreach( $unit in $organisationUnits ){"value":"$encoder.jsonEncode( $unit.name )"}#if( $velocityCount < $size ),#end#end]
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml'
--- dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml	2013-03-20 07:28:44 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml	2013-03-22 08:23:51 +0000
@@ -251,9 +251,7 @@
     </action>
 
     <action name="getOrganisationUnitsByName" class="org.hisp.dhis.ouwt.action.GetOrganisationUnitsByNameAction">
-      <result name="success" type="velocity-json">
-        /dhis-web-commons/ouwt/responseSearch.vm
-      </result>
+      <result name="success" type="velocity-json">/dhis-web-commons/ouwt/responseSearch.vm</result>
       <param name="onExceptionReturn">plainTextError</param>
     </action>