Commit 4779cea0 by 徐健

私聊改造項目完成

parent 31b740d3
...@@ -529,7 +529,7 @@ public class YDLMessageFragment extends TFragment implements ModuleProxy { ...@@ -529,7 +529,7 @@ public class YDLMessageFragment extends TFragment implements ModuleProxy {
//关注 //关注
@SuppressLint("CheckResult") @SuppressLint("CheckResult")
private void focus() { private void focus() {
if (ActionHandlerStorage.getL(sessionId) != null && ActionHandlerStorage.getL(sessionId).getInfo() != null) if (ActionHandlerStorage.getL(sessionId) != null && ActionHandlerStorage.getL(sessionId).getInfo() != null) {
// 未关注才能进行关注 // 未关注才能进行关注
if (ActionHandlerStorage.getL(sessionId).getInfo().isFollowed == false) { if (ActionHandlerStorage.getL(sessionId).getInfo().isFollowed == false) {
ActionHandlerStorage.getL(sessionId).getInfo().isFollowed = true; ActionHandlerStorage.getL(sessionId).getInfo().isFollowed = true;
...@@ -551,8 +551,10 @@ public class YDLMessageFragment extends TFragment implements ModuleProxy { ...@@ -551,8 +551,10 @@ public class YDLMessageFragment extends TFragment implements ModuleProxy {
} }
}, throwable -> { }, throwable -> {
ActionHandlerStorage.getL(sessionId).getInfo().isFollowed = false; ActionHandlerStorage.getL(sessionId).getInfo().isFollowed = false;
ToastUtil.toastShort(throwable.toString());}); ToastUtil.toastShort(throwable.toString());
});
} }
}
} }
private void showTips() { private void showTips() {
...@@ -560,18 +562,30 @@ public class YDLMessageFragment extends TFragment implements ModuleProxy { ...@@ -560,18 +562,30 @@ public class YDLMessageFragment extends TFragment implements ModuleProxy {
} }
//初始化聊天顶部快捷菜单 //初始化聊天顶部快捷菜单
@SuppressLint("CheckResult")
private void initMenu() { private void initMenu() {
View rela_zixun = rootView.findViewById(R.id.rela_zixun); View rela_zixun = rootView.findViewById(R.id.rela_zixun);
rela_zixun.setOnClickListener(view -> { rela_zixun.setOnClickListener(view -> {
if (ActionHandlerStorage.getL(sessionId) != null) { if (sessionId!= null && ActionHandlerStorage.getL(sessionId) != null && ActionHandlerStorage.getL(sessionId).getInfo() != null) {
if (expertConsultServiceListDialog == null) { if (expertConsultServiceListDialog == null) {
if (getActivity() != null) { ServiceImpl.Companion.getInstance().serviceList(ActionHandlerStorage.getL(sessionId).getInfo().doctorId)
expertConsultServiceListDialog = new ExpertConsultServiceListDialog(getActivity()); .subscribeOn(Schedulers.io())
} .observeOn(AndroidSchedulers.mainThread())
.subscribe(res -> {
if (res.data != null && res.data.size() > 0) {
if (getActivity() != null && expertConsultServiceListDialog == null) {
expertConsultServiceListDialog = new ExpertConsultServiceListDialog(getActivity(), res.data);
expertConsultServiceListDialog.show();
}
}else {
ToastUtil.toastShort("咨询师暂未发布服务");
}
}, throwable -> {
});
}else {
expertConsultServiceListDialog.show();
} }
expertConsultServiceListDialog.show();
} else { } else {
ToastUtil.toastShort("请退出聊天重试"); ToastUtil.toastShort("请退出聊天重试");
} }
......
...@@ -54,4 +54,9 @@ interface ServiceApi{ ...@@ -54,4 +54,9 @@ interface ServiceApi{
@FormUrlEncoded @FormUrlEncoded
@POST("sq-active/focus") @POST("sq-active/focus")
fun focus(@FieldMap params: Map<String, String>): Observable<BaseResponse<FocusBean>> fun focus(@FieldMap params: Map<String, String>): Observable<BaseResponse<FocusBean>>
//服务列表
@GET("consult/expert-page/products")
@Headers(YDL_DOMAIN + YDL_DOMAIN_JAVA)
fun serviceList(@Query("doctorId") doctorId: String): Observable<BaseAPIResponse<List<ServiceItemBean>>>
} }
\ No newline at end of file
...@@ -76,4 +76,11 @@ class ServiceImpl private constructor(){ ...@@ -76,4 +76,11 @@ class ServiceImpl private constructor(){
return RxUtils.mapObservable(param) return RxUtils.mapObservable(param)
.flatMap { YDLHttpUtils.obtainApi(ServiceApi::class.java).focus(it) } .flatMap { YDLHttpUtils.obtainApi(ServiceApi::class.java).focus(it) }
} }
/**
* 服务列表
*/
fun serviceList(doctorId: String): Observable<BaseAPIResponse<List<ServiceItemBean>>> {
return YDLHttpUtils.obtainApi(ServiceApi::class.java).serviceList(doctorId)
}
} }
\ No newline at end of file
package com.yidianling.uikit.custom.widget.expertConsultService.callback package com.yidianling.uikit.custom.widget.expertConsultService.callback
import com.yidianling.uikit.custom.http.response.ServiceItemBean
interface ConsultServiceViewCallback { interface ConsultServiceViewCallback {
fun onCloseClick() {}//关闭按钮点击 fun onCloseClick() {}//关闭按钮点击
fun onBackClick() {}//返回列表点击 fun onBackClick() {}//返回列表点击
fun onItemClick(serviceId: Int) {} //服务列表点击 fun onItemClick(serviceId: ServiceItemBean.ProductsBean) {} //服务列表点击
} }
\ No newline at end of file
...@@ -5,8 +5,14 @@ import android.util.AttributeSet ...@@ -5,8 +5,14 @@ import android.util.AttributeSet
import android.view.View import android.view.View
import android.widget.LinearLayout import android.widget.LinearLayout
import android.widget.RelativeLayout import android.widget.RelativeLayout
import com.ydl.webview.H5Params
import com.ydl.webview.NewH5Activity
import com.ydl.ydlcommon.base.config.GlobalConfig
import com.ydl.ydlcommon.base.config.HttpConfig
import com.ydl.ydlcommon.bean.GlobalInfo
import com.yidianling.common.tools.RxDeviceTool import com.yidianling.common.tools.RxDeviceTool
import com.yidianling.im.R import com.yidianling.im.R
import com.yidianling.uikit.custom.http.response.ServiceItemBean
import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback
import kotlinx.android.synthetic.main.im_expert_consult_service_detail_view.view.* import kotlinx.android.synthetic.main.im_expert_consult_service_detail_view.view.*
...@@ -45,7 +51,89 @@ class ExpertConsultServiceDetailView : RelativeLayout { ...@@ -45,7 +51,89 @@ class ExpertConsultServiceDetailView : RelativeLayout {
/** /**
* 设置数据 * 设置数据
*/ */
fun setData(bean: String) { fun updateData(bean: ServiceItemBean.ProductsBean) {
consult_service_title.text = bean.productDto.name ?: ""
consult_service_desc.text = bean.productDto.desc ?: ""
//是否是套餐
if (bean.productDto.isPackage == 2) {
consult_service_is_package.text = "套餐"
consult_service_times.text = "${bean.productDto.packageNum}次"
consult_service_price_right.text = "/${bean.productSpecDtos.last().spec2}分钟" //例: 套餐展示"/60分钟"
//起售次数展示
consult_service_low_buy_time.visibility = View.VISIBLE
consult_service_low_buy_time.text = "(${bean.productDto.packageNum}次起售)"
} else {
consult_service_is_package.text = "单次"
consult_service_times.text = "1次"
consult_service_price_right.text = "/次"//例: 不是套餐展示"/次"
consult_service_low_buy_time.visibility = View.GONE
}
//可选时间类型
var timeStr = StringBuffer("")
var timeList: ArrayList<String> = ArrayList()
bean.productSpecDtos.forEach {
timeList.add(it.spec2)
}
//去重并按规则拼接
timeList.distinct().forEachIndexed { index, str ->
if (index == 0) {
timeStr.append("${str}分钟")
} else {
timeStr.append("/${str}分钟")
}
}
consult_service_once_time_type.text = timeStr.toString()
//可选服务类型
var serviceTypeStr = StringBuffer("")
var serviceTypeList: ArrayList<String> = ArrayList()
bean.productSpecDtos.forEach {
serviceTypeList.add(it.spec1)
}
//去重并按规则拼接
serviceTypeList.distinct().forEachIndexed { index, str ->
val typeStr = getServiceType(str)
if (typeStr != "未知") {
if (index == 0) {
serviceTypeStr.append("$typeStr")
} else {
serviceTypeStr.append("/$typeStr")
}
}
}
consult_service_service_type.text = serviceTypeStr.toString()
//价格,取productSpecDtos数组最后一个价格,不保留小数
consult_service_service_price.text = String.format(
"%.0f",
(bean.productSpecDtos.last().price)
)
consult_service_btn.setOnClickListener {
NewH5Activity.start(mContext, H5Params(HttpConfig.MH5_URL + "consult/#/pages/DownOrder/DownOrder?product_id=" + bean.productDto.id, null))
}
}
private fun getServiceType(index: String): String {
return when (index) {
"1" -> {
"文字"
}
"2" -> {
"电话"
}
"3" -> {
"当面"
}
"4" -> {
"视频"
}
else -> {
"未知"
}
}
} }
} }
\ No newline at end of file
package com.yidianling.uikit.custom.widget.expertConsultService.view package com.yidianling.uikit.custom.widget.expertConsultService.view
import android.annotation.SuppressLint
import android.content.Context import android.content.Context
import android.util.AttributeSet import android.util.AttributeSet
import android.view.View import android.view.View
import android.widget.LinearLayout import android.widget.LinearLayout
import com.ydl.webview.H5Params
import com.ydl.webview.NewH5Activity
import com.ydl.ydlcommon.base.config.HttpConfig
import com.yidianling.im.R import com.yidianling.im.R
import com.yidianling.uikit.custom.http.response.ServiceItemBean
import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback
import kotlinx.android.synthetic.main.im_expert_consult_service_item_view.view.* import kotlinx.android.synthetic.main.im_expert_consult_service_item_view.view.*
...@@ -36,24 +41,53 @@ class ExpertConsultServiceItemView : LinearLayout { ...@@ -36,24 +41,53 @@ class ExpertConsultServiceItemView : LinearLayout {
orientation = HORIZONTAL orientation = HORIZONTAL
View.inflate(mContext, R.layout.im_expert_consult_service_item_view, this) View.inflate(mContext, R.layout.im_expert_consult_service_item_view, this)
}
/**
* 设置数据
*/
@SuppressLint("SetTextI18n")
fun setData(bean: ServiceItemBean.ProductsBean) {
//是否是套餐
if (bean.productDto.isPackage == 2) {
//展示左上角套餐布局
service_item_package.visibility = View.VISIBLE
//服务名
service_item_title.text = " ${bean.productDto.name}"
//起售次数展示
service_item_low_buy_time.visibility = View.VISIBLE
service_item_low_buy_time.text = "(${bean.productDto.packageNum}次起售)"
} else {
//隐藏套餐布局
service_item_package.visibility = View.GONE
//服务名
service_item_title.text = bean.productDto.name ?: ""
//隐藏起售次数限制
service_item_low_buy_time.visibility = View.GONE
}
//价格,取productSpecDtos数组最后一个价格,不保留小数
service_item_price.text = String.format(
"%.0f",
(bean.productSpecDtos.last().price)
)
//时间,取productSpecDtos数组最后一个的时间
service_item_time.text = "/${bean.productSpecDtos.last().spec2}分钟"
//好评率,*20后 保留1位小数
service_item_feddbackrate.text = String.format(
"%.1f",
(bean.productDto.feedbackRate) * 20f
) + "%"
//销量
service_item_saleout_num.text = "销量${bean.productDto.saleoutAmount}"
setOnClickListener { setOnClickListener {
//todo xj 接接口的时候修改成服务id mListener?.onItemClick(bean)
mListener?.onItemClick(0)
} }
im_expert_service_list_btn.setOnClickListener { im_expert_service_list_btn.setOnClickListener {
//todo 去咨询 NewH5Activity.start(mContext, H5Params(HttpConfig.MH5_URL + "consult/#/pages/DownOrder/DownOrder?product_id=" + bean.productDto.id, null))
} }
}
/**
* 设置数据
*/
fun setData(bean: String) {
} }
} }
\ No newline at end of file
...@@ -16,6 +16,7 @@ import android.widget.ScrollView ...@@ -16,6 +16,7 @@ import android.widget.ScrollView
import com.yidianling.common.tools.RxDeviceTool import com.yidianling.common.tools.RxDeviceTool
import com.yidianling.common.tools.RxImageTool import com.yidianling.common.tools.RxImageTool
import com.yidianling.im.R import com.yidianling.im.R
import com.yidianling.uikit.custom.http.response.ServiceItemBean
import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback
import kotlinx.android.synthetic.main.im_expert_consult_service_list_dialog_layout.* import kotlinx.android.synthetic.main.im_expert_consult_service_list_dialog_layout.*
...@@ -23,11 +24,12 @@ import kotlinx.android.synthetic.main.im_expert_consult_service_list_dialog_layo ...@@ -23,11 +24,12 @@ import kotlinx.android.synthetic.main.im_expert_consult_service_list_dialog_layo
* 专家咨询服务列表弹框 * 专家咨询服务列表弹框
* Created by xj on 2019/8/7. * Created by xj on 2019/8/7.
*/ */
class ExpertConsultServiceListDialog(val mContext: Context): Dialog(mContext, R.style.dialog_default_style) { class ExpertConsultServiceListDialog(val mContext: Context, val mList: List<ServiceItemBean>): Dialog(mContext, R.style.dialog_default_style) {
private var mConsultServiceListView: View? = null private var mConsultServiceListView: ExpertConsultServiceView? = null
private var mConsultServiceDetailView: View? = null private var mConsultServiceDetailView: ExpertConsultServiceDetailView? = null
private var mViewList: ArrayList<View> = ArrayList() private var mViewList: ArrayList<View> = ArrayList()
private var mSelectType: String = "全部"
override fun onCreate(savedInstanceState: Bundle?) { override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState) super.onCreate(savedInstanceState)
...@@ -42,39 +44,26 @@ class ExpertConsultServiceListDialog(val mContext: Context): Dialog(mContext, R. ...@@ -42,39 +44,26 @@ class ExpertConsultServiceListDialog(val mContext: Context): Dialog(mContext, R.
window.attributes = params window.attributes = params
var typeList:ArrayList<String> = ArrayList() var typeList:ArrayList<String> = ArrayList()
typeList.add("全部") typeList.add(mSelectType)//默认选中
typeList.add("婚姻家庭") mList.forEach { item ->
typeList.add("恋爱情感") typeList.add(item.cateName)
typeList.add("性心理") }
typeList.add("亲子关系")
typeList.add("人际社交")
typeList.add("精神疾病")
var serviceList:ArrayList<String> = ArrayList()
serviceList.add("全部")
serviceList.add("婚姻家庭")
serviceList.add("恋爱情感")
serviceList.add("性心理")
serviceList.add("亲子关系")
serviceList.add("人际社交")
serviceList.add("精神疾病")
mConsultServiceListView = mConsultServiceListView =
ExpertConsultServiceView( ExpertConsultServiceView(
mContext mContext
) )
(mConsultServiceListView as ExpertConsultServiceView).setDataAndClick(typeList, serviceList, object : ConsultServiceViewCallback { (mConsultServiceListView as ExpertConsultServiceView).setDataAndClick(typeList, mList, object : ConsultServiceViewCallback {
override fun onCloseClick() { override fun onCloseClick() {
dismiss() dismiss()
} }
override fun onItemClick(serviceId: Int) { override fun onItemClick(serviceBean: ServiceItemBean.ProductsBean) {
// todo 执行右滑动画和接口请求 if (mConsultServiceDetailView != null) {
dialog_bottom_scroll_view.currentItem = 1 mConsultServiceDetailView?.updateData(serviceBean)
dialog_bottom_scroll_view.currentItem = 1
}
} }
}) })
...@@ -85,7 +74,6 @@ class ExpertConsultServiceListDialog(val mContext: Context): Dialog(mContext, R. ...@@ -85,7 +74,6 @@ class ExpertConsultServiceListDialog(val mContext: Context): Dialog(mContext, R.
ExpertConsultServiceDetailView( ExpertConsultServiceDetailView(
mContext, object : ConsultServiceViewCallback { mContext, object : ConsultServiceViewCallback {
override fun onBackClick() { override fun onBackClick() {
// todo 执行左滑动画
dialog_bottom_scroll_view.currentItem = 0 dialog_bottom_scroll_view.currentItem = 0
} }
}) })
......
...@@ -6,6 +6,7 @@ import android.view.View ...@@ -6,6 +6,7 @@ import android.view.View
import android.widget.LinearLayout import android.widget.LinearLayout
import com.yidianling.common.tools.RxDeviceTool import com.yidianling.common.tools.RxDeviceTool
import com.yidianling.im.R import com.yidianling.im.R
import com.yidianling.uikit.custom.http.response.ServiceItemBean
import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback import com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback
import kotlinx.android.synthetic.main.im_expert_consult_service_view.view.* import kotlinx.android.synthetic.main.im_expert_consult_service_view.view.*
...@@ -13,7 +14,9 @@ class ExpertConsultServiceView : LinearLayout { ...@@ -13,7 +14,9 @@ class ExpertConsultServiceView : LinearLayout {
private var typeSelectedIndex: Int = 0 private var typeSelectedIndex: Int = 0
private var mTypeList: ArrayList<String> = ArrayList() private var mTypeList: ArrayList<String> = ArrayList()
private var mServiceList: ArrayList<String> = ArrayList() private var mServiceList: ArrayList<ServiceItemBean> = ArrayList()
private var mListener: ConsultServiceViewCallback? = null
constructor(context: Context) : super(context) { constructor(context: Context) : super(context) {
mContext = context mContext = context
...@@ -59,13 +62,13 @@ class ExpertConsultServiceView : LinearLayout { ...@@ -59,13 +62,13 @@ class ExpertConsultServiceView : LinearLayout {
*/ */
fun setDataAndClick( fun setDataAndClick(
typeList: ArrayList<String>, typeList: ArrayList<String>,
serviceList: ArrayList<String>, allServiceList: List<ServiceItemBean>,
listener: ConsultServiceViewCallback? listener: ConsultServiceViewCallback?
) { ) {
mListener = listener
consult_service_dialog_close.setOnClickListener { consult_service_dialog_close.setOnClickListener {
listener?.onCloseClick() mListener?.onCloseClick()
} }
// 设置顶部滚动类型数据 // 设置顶部滚动类型数据
...@@ -82,30 +85,45 @@ class ExpertConsultServiceView : LinearLayout { ...@@ -82,30 +85,45 @@ class ExpertConsultServiceView : LinearLayout {
) )
item.setData(str, index == typeSelectedIndex) item.setData(str, index == typeSelectedIndex)
item.setOnClickListener { item.setOnClickListener {
resetSelected(index) typeSelectedIndex = index
resetSelected()
selectTypeServiceList()
} }
expert_consult_service_type_list.addView(item) expert_consult_service_type_list.addView(item)
} }
} }
} }
typeSelectedIndex = 0 // 初始化为全部选中
mServiceList.clear()
mServiceList.addAll(allServiceList)
// 设置服务列表数据 // 设置服务列表数据
if (serviceList != null && serviceList.size != 0) { selectTypeServiceList()
mServiceList.clear() }
mServiceList.addAll(serviceList)
mServiceList.forEachIndexed { index, str -> /**
val item = ExpertConsultServiceItemView(mContext!!, listener) * 刷新服务列表数据
expert_consult_service_service_list.addView(item) */
private fun selectTypeServiceList() {
expert_consult_service_service_list.removeAllViews()
if (mServiceList.size != 0) {
mServiceList.forEachIndexed { index, itemBean ->
//当选中String相同的时候,添加view,或者选中typeSelectedIndex==0的时候,展示全部
if (itemBean.cateName == mTypeList[typeSelectedIndex] || typeSelectedIndex == 0) {
itemBean.products.forEach {
val item = ExpertConsultServiceItemView(mContext!!, mListener)
item.setData(it)
expert_consult_service_service_list.addView(item)
}
}
} }
} }
} }
private fun resetSelected(index: Int) { /**
typeSelectedIndex = index * 刷新类型列表数据
*/
private fun resetSelected() {
for (index in 0 until expert_consult_service_type_list.childCount) { for (index in 0 until expert_consult_service_type_list.childCount) {
var view = expert_consult_service_type_list.getChildAt(index) var view = expert_consult_service_type_list.getChildAt(index)
if (view is ExpertConsultServiceTypeItemView) { if (view is ExpertConsultServiceTypeItemView) {
......
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<corners android:radius="1dp"/>
<solid android:color="#FF9500"/>
</shape>
\ No newline at end of file
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
android:src="@drawable/im_expert_service_list_left_back" /> android:src="@drawable/im_expert_service_list_left_back" />
<TextView <TextView
android:id="@+id/consult_service_title"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="调节孕期情绪烦躁,建立积极心态面对新生活" android:text="调节孕期情绪烦躁,建立积极心态面对新生活"
...@@ -73,6 +74,7 @@ ...@@ -73,6 +74,7 @@
android:layout_marginBottom="15dp" android:layout_marginBottom="15dp"
android:text="相互了解,初步建立咨访关系,解答你心中关于咨询本身的一切疑惑,解答你心中关于咨询本身的一切疑惑,解答你心中关于咨询本身的一切疑惑,为你的困扰解决明确咨询目标与方案。相互了解,初步建立咨访关系,解答你心中关于咨询本身的一切疑惑,为你的困扰解决明确咨询目标与方案。相互了解,初步建立咨访关系,解答你心中关于咨询" android:text="相互了解,初步建立咨访关系,解答你心中关于咨询本身的一切疑惑,解答你心中关于咨询本身的一切疑惑,解答你心中关于咨询本身的一切疑惑,为你的困扰解决明确咨询目标与方案。相互了解,初步建立咨访关系,解答你心中关于咨询本身的一切疑惑,为你的困扰解决明确咨询目标与方案。相互了解,初步建立咨访关系,解答你心中关于咨询"
android:textColor="#666666" android:textColor="#666666"
android:fontFamily="sans-serif-thin"
android:textSize="14dp" android:textSize="14dp"
android:textStyle="bold" /> android:textStyle="bold" />
...@@ -127,6 +129,7 @@ ...@@ -127,6 +129,7 @@
android:orientation="horizontal"> android:orientation="horizontal">
<TextView <TextView
android:id="@+id/consult_service_is_package"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
...@@ -135,6 +138,7 @@ ...@@ -135,6 +138,7 @@
android:textSize="14dp" /> android:textSize="14dp" />
<TextView <TextView
android:id="@+id/consult_service_times"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
...@@ -177,6 +181,7 @@ ...@@ -177,6 +181,7 @@
android:orientation="horizontal"> android:orientation="horizontal">
<TextView <TextView
android:id="@+id/consult_service_once_time_type"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
...@@ -185,6 +190,7 @@ ...@@ -185,6 +190,7 @@
android:textSize="14dp" /> android:textSize="14dp" />
<TextView <TextView
android:id="@+id/consult_service_service_type"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
...@@ -322,6 +328,7 @@ ...@@ -322,6 +328,7 @@
android:textSize="10dp" /> android:textSize="10dp" />
<TextView <TextView
android:id="@+id/consult_service_service_price"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="320" android:text="320"
...@@ -330,15 +337,24 @@ ...@@ -330,15 +337,24 @@
android:textStyle="bold" /> android:textStyle="bold" />
<TextView <TextView
android:id="@+id/consult_service_price_right"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="/次" android:text="/次"
android:textColor="#666666" android:textColor="#666666"
android:textSize="10dp" android:textSize="10dp" />
android:textStyle="bold" /> <TextView
android:id="@+id/consult_service_low_buy_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="(几次起售)"
android:visibility="gone"
android:textColor="#666666"
android:textSize="10dp" />
</LinearLayout> </LinearLayout>
<TextView <TextView
android:id="@+id/consult_service_btn"
android:layout_width="125dp" android:layout_width="125dp"
android:layout_height="38dp" android:layout_height="38dp"
android:background="@drawable/im_expert_service_detail_btn_bg" android:background="@drawable/im_expert_service_detail_btn_bg"
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="horizontal"> android:orientation="horizontal">
<LinearLayout <LinearLayout
...@@ -13,13 +14,31 @@ ...@@ -13,13 +14,31 @@
android:paddingTop="10dp" android:paddingTop="10dp"
android:paddingBottom="18dp"> android:paddingBottom="18dp">
<TextView <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="调节孕期情绪烦躁,建立积极心态面对新生活" >
android:textColor="#1A1A1A" <TextView
android:textSize="16dp" android:id="@+id/service_item_title"
android:textStyle="bold" /> android:layout_width="match_parent"
android:layout_height="wrap_content"
tools:text=" 调节孕期情绪烦躁,建立积极心态面对新生活"
android:textColor="#1A1A1A"
android:textSize="16dp"
android:textStyle="bold" />
<TextView
android:id="@+id/service_item_package"
android:layout_width="24dp"
android:layout_height="14dp"
android:gravity="center"
android:text="套餐"
android:visibility="gone"
android:layout_marginTop="3dp"
android:textColor="#ffffff"
android:textSize="10dp"
android:background="@drawable/im_service_package_bg"/>
</RelativeLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
...@@ -42,6 +61,7 @@ ...@@ -42,6 +61,7 @@
android:textSize="10dp" /> android:textSize="10dp" />
<TextView <TextView
android:id="@+id/service_item_price"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="320" android:text="320"
...@@ -51,20 +71,31 @@ ...@@ -51,20 +71,31 @@
</LinearLayout> </LinearLayout>
<TextView <TextView
android:id="@+id/service_item_time"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="/60分钟" android:text="/60分钟"
android:textColor="#999999" android:textColor="#999999"
android:textSize="12dp" /> android:textSize="12dp" />
<TextView
android:id="@+id/service_item_low_buy_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="(几次起售)"
android:visibility="gone"
android:textColor="#999999"
android:textSize="12dp" />
<TextView <TextView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="好评率" android:text="好评率"
android:layout_marginLeft="10dp"
android:textColor="#999999" android:textColor="#999999"
android:textSize="12dp" /> android:textSize="12dp" />
<TextView <TextView
android:id="@+id/service_item_feddbackrate"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="99.9%" android:text="99.9%"
...@@ -94,6 +125,7 @@ ...@@ -94,6 +125,7 @@
android:textStyle="bold" /> android:textStyle="bold" />
<TextView <TextView
android:id="@+id/service_item_saleout_num"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="2dp" android:layout_marginTop="2dp"
......
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