Commit 0b1e72ce by 刘鹏

feat: 测评会员埋点+接口修改

parent 1c40e8cb
ext {
dev_mode = true//组件发布的时候需要设置为false
ydl2PublishVersion = "0.2.0.17"
dev_mode = false//组件发布的时候需要设置为false
ydl2PublishVersion = "0.2.0.17-lp"
ydlPublishVersion = [
// -------------- 业务模块 --------------
//第三步 若干
......
......@@ -92,6 +92,8 @@ class UserMyPageEvent{
const val YDL_USER_MY_PAGE_STAY_VISIT=YDL_USER_MY_PAGE+"YDL_USER_MY_PAGE_STAY_VISIT"
const val YDL_USER_MY_TOP_TYPE_CLICK= YDL_USER_MY_PAGE+"ydl_user_my_top_type_click"
const val YDL_USER_MY_MIDDLE_TYPE_CLICK= YDL_USER_MY_PAGE+"ydl_user_my_middle_type_click"
//app我的页_会员中心区域点击
const val YDL_USER_MY_MEMBER_CENTRE_CLICK = YDL_USER_MY_PAGE + "member_centre_click"
const val YDL_USER_MY_BOTTOM_TYPE_CLICK= YDL_USER_MY_PAGE+"ydl_user_my_bottom_type_click"
}
}
......
......@@ -68,6 +68,7 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
private var mShareDialog: YDLShareDialog? = null
private var startTime: Long = 0
private var endTime: Long = 0
private var isSecondTime: Boolean = false
override fun layoutResId(): Int {
return R.layout.user_mine_fragment_mine
}
......@@ -144,6 +145,10 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
override fun onResume() {
super.onResume()
updateUI()
if (isSecondTime) {
isSecondTime = false
refreshCouponData()
}
}
override fun setUserVisibleHint(isVisibleToUser: Boolean) {
......@@ -161,10 +166,12 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
if (isVisibleToUser && isResumed) {
onResume()
}
}
override fun onPause() {
super.onPause()
isSecondTime = true
if (startTime != 0L) {
endTime = System.currentTimeMillis()
count(UserMyPageEvent.YDL_USER_MY_PAGE_STAY_VISIT, (endTime - startTime).toString())
......@@ -578,12 +585,10 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
NewH5Activity.start(it, h5Params3)
}
} else if (id == R.id.me_card_vip) { //vip
// count(UserMyPageEvent.YDL_USER_MY_MIDDLE_TYPE_CLICK, "冥想")
} else if (id == R.id.me_card_vip) {
//测评vip
count(UserMyPageEvent.YDL_USER_MY_MEMBER_CENTRE_CLICK)
mActivity?.let {
if (!startLoginByStatus(it, true)) {
return
}
val h5Params3 = H5Params(MH5_URL + "ceshi/vip/detail", null)
NewH5Activity.start(it, h5Params3)
}
......
......@@ -109,7 +109,7 @@ interface MineApi {
/**
* 检查该用户是否是会员
*/
@GET("marketing/equity/effectivity")
@GET("user/equity/effectivity")
@Headers(YDL_DOMAIN + YDL_DOMAIN_JAVA)
fun effectivity(): Observable<BaseAPIResponse<MutableList<EffectivityBean>>>
......
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