From 508649e409ebc56362fc97c536be4d1012dcecab Mon Sep 17 00:00:00 2001 From: John Chilton Date: Wed, 22 Aug 2012 17:05:53 -0500 Subject: [PATCH] Include created history url in json rendered by histories API on successful history creation. Dannon verified this is the desired behvaior in the comments on issue 802 in bitbucket. --- lib/galaxy/web/api/histories.py | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/galaxy/web/api/histories.py b/lib/galaxy/web/api/histories.py index 59a45da2760..ee1b21b3867 100644 --- a/lib/galaxy/web/api/histories.py +++ b/lib/galaxy/web/api/histories.py @@ -109,6 +109,7 @@ class HistoriesController( BaseAPIController, UsesHistoryMixin ): trans.sa_session.add( new_history ) trans.sa_session.flush() item = new_history.get_api_value(view='element', value_mapper={'id':trans.security.encode_id}) + item['url'] = url_for( 'history', id=item['id'] ) return item @web.expose_api