public global::Properties SearchCommercialLeaseProperties(
string searchString,
PropertySortOrder sortOrder,
int? page,
int? rows,
int? region,
int? district,
int? suburb,
DateTime dateFrom,
int? priceMin,
int? priceMax,
int? areaMax,
int? areaMin,
int? landAreaMin,
int? landAreaMax,
bool? adjacentSuburbs,
PropertyUsage usage)
{
var url = String.Format(Constants.Culture, "{0}{1}/{2}/CommercialLease{3}", _connection.BaseUrl, Constants.SEARCH, Constants.PROPERTY, Constants.XML);
_addAnd = false;
var conditions = "?";
// create the parameters for the query string
conditions += this.RuralPropertiesHelper(
searchString,
sortOrder.ToString(),
page,
rows,
region,
district,
suburb,
dateFrom,
priceMin,
priceMax,
areaMax,
areaMin,
landAreaMin,
landAreaMax,
adjacentSuburbs,
usage.ToString());
// add the parametrs to the query string if there are any
if (conditions.Equals("?"))
{
url += conditions;
}
// perform the request
return this.PropertyConnectionHelper(url);
}