I am building a real estate listings map, which dynamically refreshes its filter whenever the user moves the map. The page never refreshes when a change is made. Think Zillow/Trulia.
There are 2 main filters:
I see 2 methods of approaching this problem.
On initial visit, pass ALL properties in the database to the user. And then filter these properties whenever the user moves his map or changes his filter selection.
Create an ajax call whenever the user moves his map or changes his filter selection. The ajax call will only return the properties that match the user's current requirements.
Which method is preferable? I estimate there will be maybe 200k-300k records in my database.
I am building a real estate listings map, which dynamically refreshes its filter whenever the user moves the map. The page never refreshes when a change is made. Think Zillow/Trulia.
There are 2 main filters:
- Filter properties within the user's viewport
- Filter properties according to user's custom filter (e.g. property type, # of bedrooms, etc.)
I see 2 methods of approaching this problem.
On initial visit, pass ALL properties in the database to the user. And then filter these properties whenever the user moves his map or changes his filter selection.
Create an ajax call whenever the user moves his map or changes his filter selection. The ajax call will only return the properties that match the user's current requirements.
Which method is preferable? I estimate there will be maybe 200k-300k records in my database.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/7e6179d4-2274-4aec-aa83-27fbfdc1238c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.