Self hosted FLOSS fitness/workout, nutrition and weight tracker
No need to transform the AJAX response
Peter van der Does7cc07cf4176e
diff --git a/wger/exercises/templates/mobile/exercise/overview.html b/wger/exercises/templates/mobile/exercise/overview.htmlindex b78390f06..2f7311d28 100644--- a/wger/exercises/templates/mobile/exercise/overview.html+++ b/wger/exercises/templates/mobile/exercise/overview.html@@ -21,19 +21,7 @@ $(document).ready(function() {window.location.href = '/exercise/' + suggestion.data.id + '/view/'},groupBy: 'category',- paramName: 'term',- transformResult: function(response) {- // why is response not already a JSON object??- var jsonResponse = $.parseJSON(response);- return {- suggestions: $.map(jsonResponse, function(item) {- return {value: item.value, data: {id: item.id,- category: item.category,- image: item.image,- thumbnail: item.image_thumbnail}};- })- };- }+ paramName: 'term'});});</script>