Tell us what you are trying to do?
I am setting up a directory of contractors. While they are setting up their account, I would like for them to specify their service area. Preferably on a map with a radius area. Then while the client is searching for contractors, they will have the option of entering their zip code or address, and the contractor results will only show contractors if the client's zip code or address is within the contractor service area.
Is there any documentation that you are following?
Is there a similar example that we can see?
What is the link to your site?
Hi,
Thank you for contacting us and I'd be happy to assist.
In Toolset, the address/location type field and the distance-based search works slightly differently from what you're planning to achieve.
For each contractor, the address type custom field will allow you to save the exact location coordinates, but not the radius or the range of coverage area.
Likewise, the distance-based search in the views also allows the visitor to search the posts having the exact location coordinates, within a radius with respect to either user's specified location or current location:
https://toolset.com/lesson-placement/lesson-placements-1622939-1161360/
The closest possible workaround that I can suggest is that you can store the exact location coordinates with each contractor along with a separate numeric field that represents the number of kilometers radius within which this contractor can operate.
Then while searching for the contractors, you can show in the results what is the distance value between the visitor's searched location and the contractor's location, using the "toolset-maps-distance-value" ( ref: https://toolset.com/documentation/programmer-reference/maps/maps-shortcodes/#toolset-maps-distance-value ) and then compare whether that distance value is lower or greater than the contractor's specified radius of coverage in kilometers.
I hope this helps and please let me know if you need any further assistance around this.
regards,
Waqar