lib/real_savvy/adapter/collection.rb in real_savvy-0.0.10 vs lib/real_savvy/adapter/collection.rb in real_savvy-0.0.12
- old
+ new
@@ -14,17 +14,17 @@
def remove(id:, property_ids:)
delete("./api/v3/#{path_prefix}/#{id}/remove", {property_ids: property_ids})
end
- def search(id:, filter: {}, market_id: nil, page_size: nil, page_number: nil, page: {})
+ def search(id:, market_id: nil, page_size: nil, page_number: nil, page: {}, sort: {}, filter: {})
page[:size] ||= page_size
page[:number] ||= page_number
- post("./api/v3/#{path_prefix}/#{id}/properties/search", {filter: filter, market_id: market_id, page: page})
+ post("./api/v3/#{path_prefix}/#{id}/properties/search", {filter: filter, market_id: market_id, page: page, sort: sort})
end
- def cluster(id:, filter: {}, market_id: nil, page_size: nil, page_number: nil, page: {}, precision: nil)
+ def cluster(id:, market_id: nil, page_size: nil, page_number: nil, page: {}, sort: {}, filter: {}, precision: nil)
page[:size] ||= page_size
page[:number] ||= page_number
- post("./api/v3/#{path_prefix}/#{id}/properties/map/clusters", {filter: filter, market_id: market_id, page: page, precision: precision})
+ post("./api/v3/#{path_prefix}/#{id}/properties/map/clusters", {filter: filter, market_id: market_id, page: page, sort: sort, precision: precision})
end
end