Commit 48bb8c74 by YKai

feat: 修改筛选框价格文案,价格筛选传值字段使用后端返回的字段

parent 5b4f0e4a
......@@ -116,15 +116,15 @@ class ExpertSearchPresenter : SimplePresenter<IExpertSearchView>() {
filterMap["product_specs.spec_id"] = wayMap
}
// 服务均价
if (allFilter.priceRanges != null) {
allFilter.priceRanges?.let {
val avgPriceMap = HashMap<String, Any?>()
if (!TextUtils.isEmpty(allFilter.priceRanges?.min_price)){
avgPriceMap["gte"] = allFilter.priceRanges?.min_price
if (!TextUtils.isEmpty(it.min_price)){
avgPriceMap["gte"] = it.min_price
}
if (!TextUtils.isEmpty(allFilter.priceRanges?.max_price)) {
avgPriceMap["lte"] = allFilter.priceRanges?.max_price
if (!TextUtils.isEmpty(it.max_price)) {
avgPriceMap["lte"] = it.max_price
}
filterMap[allFilter.priceRanges!!.key1] = avgPriceMap
filterMap[it.key1] = avgPriceMap
}
// 年龄
if (allFilter.ages.isNotEmpty()) {
......
package com.yidianling.consultant.model.bean
import com.google.gson.annotations.SerializedName
data class PriceRangesItem(
@field:SerializedName("min_price")
var min_price: String? = null,
@field:SerializedName("max_price")
var max_price: String? = null,
@SerializedName("recommend_percent")
var recommend_percent: String? = null,
var display_range:String? = null,
var key1:String = "avg_price"
var min_price: String? = null,
var max_price: String? = null,
var recommend_percent: String? = null,
var display_range: String? = null,
var key1: String = "avg_price"
)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment