AnsweredAssumed Answered

SugarCRM 7.7.0.0 recordList for modules API

Question asked by Atif Hussain on Jul 18, 2016
Latest reply on Jul 19, 2016 by Atif Hussain

I am calling this API http://{site_url}/SugarPro/rest/v10/Accounts

I need to sort accounts in ascending order with respect to their distance from current logged in user (I will calculate distance using address of logged in user and specific account). I tried to use {before_respond} API logic hook to calculate distances and sort the response. But it looks a bad practice to use this hook as it will be fired for every API request.

 

The other way around is to extend the API that is being used for this request. But I am unable to find the file that is being used in this request. Can someone please guide me to find which Api file is being used in this request?

Or any other better way to get the desired result.

 

Note: I want this behavior only for mobile view of SugarCRM and SugarCRM Mobile app

 

Thanks

Outcomes