Commit 142b65bf by 霍志良

feat:修改UI

parent d5c66832
......@@ -14,8 +14,7 @@ buildscript {
ydlrouter_version = '1.2.3'
constrait_support_version = '1.0.2'
componentVersion = "0.3.0.26-SNAPSHO*-" +
"T"
componentVersion = "0.3.0.27-SNAPSHOT"
}
repositories {
mavenCentral()
......
......@@ -1065,7 +1065,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
hideSoftInput()
appbar_layout.setExpanded(false)
appbar_layout.postDelayed({
// showSortPopupWindow()
updateFilterTextViewStatus(tvSort, FILTER_STATUS_OPEN)
showPricePopupWindow()
}, 300)
......@@ -1369,12 +1369,15 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
tempFilter, this
)
pricePopup!!.setOnDismissListener {
if (tempFilter.priceRanges != null) {
updateFilterTextViewStatus(tvSort, FILTER_STATUS_FILTERED)
} else {
updateFilterTextViewStatus(tvSort, FILTER_STATUS_NORMAL)
}
}
pricePopup!!.showAsDropDown(viewSep2)
} else {
ToastUtil.toastShort("数据初始化失败,请重试")
}
}
......@@ -1473,6 +1476,8 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
}
locationRegionItem?.let { locationHistoryList?.add(0, it) }
showAreaPoPup(agreeLocation)
} else {
ErrorLocate(false)
}
}, {
ErrorLocate(false)
......@@ -1721,7 +1726,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
}
FILTER_STATUS_OPEN -> {
tv.typeface = Typeface.DEFAULT_BOLD
tv.setTextColor(ContextCompat.getColor(mContext, R.color.platform_colorTextDefault))
tv.setTextColor(ContextCompat.getColor(mContext, R.color.platform_main_theme))
tv.setCompoundDrawablesWithIntrinsicBounds(
0,
0,
......@@ -1757,7 +1762,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
}
FILTER_STATUS_OPEN -> {
tv.typeface = Typeface.DEFAULT_BOLD
tv.setTextColor(ContextCompat.getColor(this, R.color.platform_colorTextDefault))
tv.setTextColor(ContextCompat.getColor(this, R.color.platform_main_theme))
tv.setCompoundDrawablesWithIntrinsicBounds(
0,
0,
......
......@@ -952,6 +952,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
hideSoftInput()
appbar_layout.setExpanded(false)
appbar_layout.postDelayed({
updateFilterTextViewStatus(tvSort, FILTER_STATUS_OPEN)
showPricePopupWindow()
}, 300)
......@@ -1010,7 +1011,11 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
tempFilter, this
)
pricePopup!!.setOnDismissListener {
if (tempFilter.priceRanges != null) {
updateFilterTextViewStatus(tvSort, FILTER_STATUS_FILTERED)
} else {
updateFilterTextViewStatus(tvSort, FILTER_STATUS_NORMAL)
}
}
pricePopup!!.showAsDropDown(viewSep2)
} else {
......@@ -1353,9 +1358,18 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
locationRegionItem?.let { locationHistoryList?.add(0, it) }
showAreaPoPup(agreeLocation)
} else {
ErrorLocate(false)
}
}, {})
}, {
ErrorLocate(false)
})
} else {
ErrorLocate(agreeLocation)
}
}
private fun ErrorLocate(agreeLocation: Boolean) {
locationList?.clear()
subLocationItem?.code = null
subLocationItem?.key = null
......@@ -1373,7 +1387,6 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
locationRegionItem?.let { locationHistoryList?.add(0, it) }
showAreaPoPup(agreeLocation)
}
}
//显示地区弹窗
private fun showAreaPopupWindow(isAgreeLocation: Boolean) {
......@@ -1596,7 +1609,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
FILTER_STATUS_OPEN -> {
tv.typeface = Typeface.DEFAULT_BOLD
tv.setTextColor(ContextCompat.getColor(mContext, R.color.platform_colorTextDefault))
tv.setTextColor(ContextCompat.getColor(mContext, R.color.platform_main_theme))
tv.setCompoundDrawablesWithIntrinsicBounds(
0,
0,
......@@ -1632,7 +1645,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
FILTER_STATUS_OPEN -> {
tv.typeface = Typeface.DEFAULT_BOLD
tv.setTextColor(ContextCompat.getColor(mContext, R.color.platform_colorTextDefault))
tv.setTextColor(ContextCompat.getColor(mContext, R.color.platform_main_theme))
tv.setCompoundDrawablesWithIntrinsicBounds(
0,
0,
......
......@@ -76,8 +76,13 @@ class ExpertSearchPresenter : SimplePresenter<IExpertSearchView>() {
filterMap["__keywords"] = allFilter.searchWord
}
val categoryList = ArrayList<Any>()
//首页金刚位传过来的搜索MAP结果集
if (mapFilter != null) {
filterMap.putAll(mapFilter)
}
map["filter"] = filterMap
// 八大类一级标签
if (allFilter.categoryId2List.size>0){
if (allFilter.categoryId2List.size > 0) {
val categoryMap2 = HashMap<String, Any>()
val categoryIdMap2 = HashMap<String, Any>()
categoryIdMap2["in"] = allFilter.categoryId2List.toSortedSet().toList()
......@@ -85,7 +90,7 @@ class ExpertSearchPresenter : SimplePresenter<IExpertSearchView>() {
categoryList.add(categoryMap2)
}
// 八大类二级标签
if (allFilter.categoryId3List.size>0){
if (allFilter.categoryId3List.size > 0) {
val categoryMap3 = HashMap<String, Any>()
val categoryIdMap3 = HashMap<String, Any>()
categoryIdMap3["in"] = allFilter.categoryId3List.toSortedSet().toList()
......@@ -204,11 +209,7 @@ class ExpertSearchPresenter : SimplePresenter<IExpertSearchView>() {
filterMap["gender"] = genderMap
}
}
//首页金刚位传过来的搜索MAP结果集
if (mapFilter != null) {
filterMap.putAll(mapFilter)
}
map["filter"] = filterMap
// sorts
if (allFilter.reorder.key != null) {
......
......@@ -14,6 +14,7 @@ import com.ydl.ydlcommon.utils.actionutil.ActionCountUtils
import com.ydl.ydlcommon.view.dialog.CommonDialog
import com.yidianling.common.tools.RxDeviceTool
import com.yidianling.common.tools.RxImageTool
import com.yidianling.common.tools.ToastUtil
import com.yidianling.consultant.R
import com.yidianling.consultant.adapter.RegionRecyclerViewAdapter
import com.yidianling.consultant.adapter.SubRecyclerViewAdapter
......@@ -171,6 +172,8 @@ class AreaPopupWindow(
locationList?.let { it1 -> subList.addAll(it1) }
subAdapter.notifyDataSetChanged()
regionAdapter.notifyDataSetChanged()
} else {
ToastUtil.toastShort(it.msg)
}
}, {})
} else {
......
......@@ -31,6 +31,8 @@
android:layout_width="0dp"
android:layout_weight="1"
android:width="0dp"
android:ellipsize="end"
android:singleLine="true"
android:drawableEnd="@drawable/platform_ic_arrow_drop_down_grey_500_18dp"
android:drawableRight="@drawable/platform_ic_arrow_drop_down_grey_500_18dp"
android:text="困扰"
......
......@@ -19,7 +19,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginStart="@dimen/platform_dp_10"
android:orientation="vertical">
<TextView
......@@ -45,6 +45,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/platform_dp_28"
android:text="排序"
android:layout_marginStart="@dimen/platform_dp_4"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold" />
......@@ -60,6 +61,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/platform_dp_28"
android:text="咨询方式"
android:layout_marginStart="@dimen/platform_dp_4"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold" />
......@@ -74,6 +76,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/platform_dp_28"
android:text="年龄选择"
android:layout_marginStart="@dimen/platform_dp_4"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold" />
......@@ -89,6 +92,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/platform_dp_28"
android:text="资质选择"
android:layout_marginStart="@dimen/platform_dp_4"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold" />
......@@ -108,6 +112,7 @@
android:text="擅长人群"
android:textColor="@color/platform_color_242424"
android:textSize="16sp"
android:layout_marginStart="@dimen/platform_dp_4"
android:textStyle="bold" />
<cn.lankton.flowlayout.FlowLayout
......@@ -125,6 +130,7 @@
android:text="学历选择"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:layout_marginStart="@dimen/platform_dp_4"
android:textStyle="bold" />
<FrameLayout
......@@ -168,6 +174,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/platform_dp_28"
android:text="其他选择"
android:layout_marginStart="@dimen/platform_dp_4"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold" />
......
......@@ -10,7 +10,6 @@
android:layout_height="match_parent"
android:background="@color/platform_color_F7F7F7"
android:layout_weight="1"
android:paddingTop="10dp"
android:overScrollMode="never"/>
<androidx.recyclerview.widget.RecyclerView
......
......@@ -8,8 +8,8 @@
<ImageView
android:id="@+id/category_img"
android:layout_width="@dimen/platform_dp_38"
android:layout_height="@dimen/platform_dp_38" />
android:layout_width="@dimen/platform_dp_30"
android:layout_height="@dimen/platform_dp_30" />
<TextView
android:id="@+id/category_text"
......
......@@ -58,7 +58,7 @@ class HomeCategoryContainer(private val mContext: Context, private var homeEvent
count = bean.goldList?.size?.toDouble()?.div(5)?.let { Math.ceil(it).toInt() }!!
val params = RelativeLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT,
RxImageTool.dip2px(72f * count)
RxImageTool.dip2px(65f * count)
)
vp_category.layoutParams = params
......
......@@ -6,13 +6,15 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:orientation="horizontal"
android:gravity="center_horizontal"
android:layout_marginStart="@dimen/platform_dp_12"
android:layout_marginEnd="@dimen/platform_dp_12"
android:paddingTop="@dimen/platform_dp_8">
<RelativeLayout
android:id="@+id/homeModuleButtonBannerFirst"
android:layout_width="82dp"
android:layout_height="82dp"
app:layout_constraintHorizontal_chainStyle="spread"
android:layout_width="87dp"
android:layout_height="87dp"
app:layout_constraintHorizontal_chainStyle="spread_inside"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toLeftOf="@id/homeModuleButtonBannerFourth"
app:layout_constraintTop_toTopOf="parent"
......@@ -38,8 +40,8 @@
<RelativeLayout
android:id="@+id/homeModuleButtonBannerFourth"
android:layout_width="82dp"
android:layout_height="82dp"
android:layout_width="87dp"
android:layout_height="87dp"
app:layout_constraintHorizontal_chainStyle="spread"
app:layout_constraintLeft_toRightOf="@id/homeModuleButtonBannerFirst"
app:layout_constraintRight_toLeftOf="@id/homeModuleButtonBannerThird"
......@@ -67,8 +69,8 @@
<RelativeLayout
android:id="@+id/homeModuleButtonBannerThird"
android:layout_width="82dp"
android:layout_height="82dp"
android:layout_width="87dp"
android:layout_height="87dp"
app:layout_constraintHorizontal_chainStyle="spread"
app:layout_constraintLeft_toRightOf="@id/homeModuleButtonBannerFourth"
app:layout_constraintRight_toLeftOf="@id/homeModuleButtonBannerSecond"
......@@ -85,19 +87,20 @@
android:textColor="@color/black"
android:textSize="@dimen/platform_dp_16"
android:text="心理课堂"/>
<TextView
android:layout_below="@+id/homeModuleButtonBannerThirdTitle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/homeModuleButtonBannerThirdTitle"
android:text="学习与成长"
android:textColor="@color/black"
android:textSize="@dimen/platform_dp_12"
android:text="学习与成长"/>
android:textSize="@dimen/platform_dp_12" />
</RelativeLayout>
<FrameLayout
android:id="@+id/homeModuleButtonBannerSecond"
android:layout_width="82dp"
android:layout_height="82dp"
android:layout_width="87dp"
android:layout_height="87dp"
app:layout_constraintHorizontal_chainStyle="spread"
app:layout_constraintLeft_toRightOf="@id/homeModuleButtonBannerThird"
app:layout_constraintRight_toRightOf="parent"
......@@ -106,8 +109,8 @@
<RelativeLayout
android:id="@+id/homeModuleButtonBannerSecondFrame"
android:layout_width="82dp"
android:layout_height="82dp"
android:layout_width="87dp"
android:layout_height="87dp"
android:gravity="center">
<TextView
......
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