------------------------------------------------------------
revno: 4592
committer: Morten Olav Hansen <[email protected]>
branch nick: dhis2
timestamp: Thu 2011-09-15 15:36:33 +0200
message:
changed from id to uuid in jsonp
modified:
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/resources/DataSetsResourceP.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/web/api/resources/DataSetsResourceP.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/resources/DataSetsResourceP.java 2011-09-15 13:33:15 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/resources/DataSetsResourceP.java 2011-09-15 13:36:33 +0000
@@ -75,19 +75,19 @@
}
@GET
- @Path("dataSets/{id}")
+ @Path("dataSets/{uuid}")
@Produces( { "application/x-javascript" } )
- public JSONWithPadding getDataSet( @PathParam("id") Integer id, @QueryParam( "callback" ) @DefaultValue( "callback" ) String callback )
+ public JSONWithPadding getDataSet( @PathParam("uuid") String uuid, @QueryParam( "callback" ) @DefaultValue( "callback" ) String callback )
{
- DataSet dataSet = dataSetService.getDataSet( id );
+ DataSet dataSet = dataSetService.getDataSet( uuid );
if ( dataSet == null )
{
- throw new IllegalArgumentException( "No dataset with id " + id );
+ throw new IllegalArgumentException( "No dataset with uuid " + uuid );
}
Map<String, Object> dataSetMap = new HashMap<String, Object>();
- dataSetMap.put( "id", dataSet.getId() );
+ dataSetMap.put( "uuid", dataSet.getUuid() );
dataSetMap.put( "name", dataSet.getName() );
return new JSONWithPadding( dataSetMap, callback );
_______________________________________________
Mailing list: https://launchpad.net/~dhis2-devs
Post to : [email protected]
Unsubscribe : https://launchpad.net/~dhis2-devs
More help : https://help.launchpad.net/ListHelp