Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YDL-Component-Medical
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨凯
YDL-Component-Medical
Commits
f2f0882b
Commit
f2f0882b
authored
Aug 02, 2022
by
刘鹏
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'fix/lp/lp_fix_sub_pay' into 'release'
咨询支付流程代码合并 See merge request app_android_lib/YDL-Component!282
parents
b6b30d3c
25a80428
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
60 additions
and
42 deletions
+60
-42
WVClickAbstractListener.java
app/src/main/java/com/ydl/component/service/web/WVClickAbstractListener.java
+16
-2
build.gradle
build.gradle
+1
-1
ExpertSearchFragment.kt
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
+14
-15
ConsultSubPayDialog.kt
m-consultant/src/main/java/com/yidianling/consultant/dialog/ConsultSubPayDialog.kt
+8
-4
YDLP2PMessageActivity.java
m-im/src/main/java/com/yidianling/uikit/business/session/activity/YDLP2PMessageActivity.java
+1
-1
ExpertConsultServiceItemView.kt
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceItemView.kt
+1
-1
MineFragment.kt
m-user/src/main/java/com/yidianling/user/mine/MineFragment.kt
+10
-9
AppLocal.kt
m-user/src/main/java/com/yidianling/user/mine/data/AppLocal.kt
+2
-2
AppLocalImpl.kt
m-user/src/main/java/com/yidianling/user/mine/data/AppLocalImpl.kt
+4
-4
user_mine_fragment_mine.xml
m-user/src/main/res/layout/user_mine_fragment_mine.xml
+3
-3
No files found.
app/src/main/java/com/ydl/component/service/web/WVClickAbstractListener.java
View file @
f2f0882b
...
...
@@ -58,7 +58,11 @@ public class WVClickAbstractListener implements WebViewClientClickListener {
@Override
public
void
contactYi
()
{
try
{
ModularServiceManager
.
INSTANCE
.
provide
(
IImService
.
class
)
.
startP2PSession
(
mContext
,
-
1
,
"14"
,
"14"
,
"客服小壹"
,
"14"
);
}
catch
(
Exception
e
)
{
}
}
@Override
...
...
@@ -108,7 +112,17 @@ public class WVClickAbstractListener implements WebViewClientClickListener {
@Override
public
void
chat
(
int
id
,
int
toUid
,
int
canTalk
,
String
accessToken
,
int
isFromQingShu
)
{
if
((
toUid
+
""
).
equals
(
"14"
))
{
//找客服私聊不需要积分
contactYi
();
}
else
{
try
{
ModularServiceManager
.
INSTANCE
.
provide
(
IImService
.
class
)
.
startChatCloseReplaceChat
(
mContext
,
String
.
valueOf
(
toUid
));
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
}
@Override
...
...
build.gradle
View file @
f2f0882b
...
...
@@ -14,7 +14,7 @@ buildscript {
ydlrouter_version
=
'1.2.3'
constrait_support_version
=
'1.0.2'
componentVersion
=
"0.3.0.12"
componentVersion
=
"0.3.0.12
-SNAPSHOT
"
}
repositories
{
mavenCentral
()
...
...
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
View file @
f2f0882b
...
...
@@ -72,7 +72,6 @@ import kotlinx.android.synthetic.main.consultant_layout_search_toolbar.*
import
org.json.JSONObject
import
java.util.concurrent.Executors
import
java.util.concurrent.TimeUnit
import
kotlin.collections.ArrayList
@Route
(
path
=
"/consultant/consultant"
)
class
ExpertSearchFragment
:
BaseMvpFragment
<
IExpertSearchView
,
ExpertSearchPresenter
>(),
...
...
@@ -1485,20 +1484,20 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
needRefresh
=
true
}
//
val orderToPayTime = SharedPreferencesEditor.getString("orderToPayTime")
//
// var
timeLimit = if (TextUtils.isEmpty(orderToPayTime)) {
//
0L
//
} else {
//
orderToPayTime.toLong()
//
}
//
//
//
if (isShow && !(consultSubPayDialog != null && consultSubPayDialog?.isShowing == true)) {
//
if (findRouteService(IUserService::class.java).isLogin() && System.currentTimeMillis() > timeLimit) {
//
getPresenter().fetchPromptPayment()
//
}
//
}
val
orderToPayTime
=
SharedPreferencesEditor
.
getString
(
"orderToPayTime"
)
val
timeLimit
=
if
(
TextUtils
.
isEmpty
(
orderToPayTime
))
{
0L
}
else
{
orderToPayTime
.
toLong
()
}
if
(
isShow
&&
!(
consultSubPayDialog
!=
null
&&
consultSubPayDialog
?.
isShowing
==
true
))
{
if
(
findRouteService
(
IUserService
::
class
.
java
).
isLogin
()
&&
System
.
currentTimeMillis
()
>
timeLimit
)
{
getPresenter
().
fetchPromptPayment
()
}
}
ActionCountUtils
.
count
(
ConsultBIConstants
.
ConsultEvent
.
APP_CONSULT_LIST_PAGE_VISIT
)
ActionCountUtils
.
count
(
"daoyi_advertisement_page|daoyi_advertisement_visit"
,
"6"
)
...
...
m-consultant/src/main/java/com/yidianling/consultant/dialog/ConsultSubPayDialog.kt
View file @
f2f0882b
...
...
@@ -60,7 +60,8 @@ class ConsultSubPayDialog(
findViewById
<
TextView
>(
R
.
id
.
priceTv
).
text
=
"¥$price"
var
format
=
SimpleDateFormat
(
"HH:mm:ss"
);
format
.
timeZone
=
TimeZone
.
getTimeZone
(
"GMT+0"
);
var
millisInFuture
=
promptPaymentBean
.
currentTime
?:
0
-
(
promptPaymentBean
.
toPayTime
?:
0L
)
var
millisInFuture
=
promptPaymentBean
.
toPayTime
?.
minus
(
promptPaymentBean
.
currentTime
?:
0
)
?:
0
mTimer
=
CountDownTimerSupport
(
millisInFuture
,
1000
)
mTimer
?.
setOnCountDownTimerListener
(
object
:
OnCountDownTimerListener
{
override
fun
onTick
(
millisUntilFinished
:
Long
)
{
...
...
@@ -69,7 +70,8 @@ class ConsultSubPayDialog(
}
override
fun
onFinish
()
{
var
nextShowTime
=
System
.
currentTimeMillis
()
+
24
*
60
*
60
*
1000
var
nextShowTime
=
System
.
currentTimeMillis
()
+
((
promptPaymentBean
.
orderToPayTime
?:
1
)
*
1000
)
SharedPreferencesEditor
.
putString
(
"orderToPayTime"
,
nextShowTime
.
toString
())
dismiss
()
}
...
...
@@ -80,7 +82,8 @@ class ConsultSubPayDialog(
})
mTimer
?.
start
()
findViewById
<
TextView
>(
R
.
id
.
tv_close
).
setOnClickListener
{
var
nextShowTime
=
System
.
currentTimeMillis
()
+
24
*
60
*
60
*
1000
var
nextShowTime
=
System
.
currentTimeMillis
()
+
((
promptPaymentBean
.
orderToPayTime
?:
1
)
*
1000
)
SharedPreferencesEditor
.
putString
(
"orderToPayTime"
,
nextShowTime
.
toString
())
mTimer
?.
stop
()
dismiss
()
...
...
@@ -96,7 +99,8 @@ class ConsultSubPayDialog(
ToastUtil
.
toastShort
(
"跳转失败"
)
dismiss
()
}
var
nextShowTime
=
System
.
currentTimeMillis
()
+
24
*
60
*
60
*
1000
var
nextShowTime
=
System
.
currentTimeMillis
()
+
((
promptPaymentBean
.
orderToPayTime
?:
1
)
*
1000
)
SharedPreferencesEditor
.
putString
(
"orderToPayTime"
,
nextShowTime
.
toString
())
}
}
...
...
m-im/src/main/java/com/yidianling/uikit/business/session/activity/YDLP2PMessageActivity.java
View file @
f2f0882b
...
...
@@ -71,7 +71,7 @@ public class YDLP2PMessageActivity extends YDLBaseMessageActivity {
if
(
ActionHandlerStorage
.
getL
(
contactId
)
!=
null
)
{
intent
.
addFlags
(
Intent
.
FLAG_ACTIVITY_CLEAR_TOP
|
Intent
.
FLAG_ACTIVITY_SINGLE_TOP
);
}
else
if
(
contactId
.
equals
(
ImConstants
.
KEFUXIAOYI
))
{
intent
.
addFlags
(
Intent
.
FLAG_ACTIVITY_
CLEAR_TOP
|
Intent
.
FLAG_ACTIVITY_SINGLE_TOP
);
intent
.
addFlags
(
Intent
.
FLAG_ACTIVITY_
NEW_TASK
);
}
ActionHandlerStorage
.
setL
(
contactId
,
l
);
...
...
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceItemView.kt
View file @
f2f0882b
...
...
@@ -168,7 +168,7 @@ class ExpertConsultServiceItemView : LinearLayout {
NewH5Activity
.
start
(
mContext
,
H5Params
(
HttpConfig
.
MH5_URL
+
"consult/#/pages/jieyou/DownOrder?product_id=
"
+
bean
.
productDto
.
id
,
HttpConfig
.
MH5_URL
+
"consult/#/pages/jieyou/DownOrder?product_id=
${bean.productDto.id}&hideNavBar=1"
,
null
)
)
...
...
m-user/src/main/java/com/yidianling/user/mine/MineFragment.kt
View file @
f2f0882b
...
...
@@ -212,28 +212,29 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
val
orderNum
=
response
.
data
?.
consultOrderNum
?:
0
if
(
orderNum
>
0
)
{
iv_order_tip
.
visibility
=
View
.
VISIBLE
if
(
orderNum
>
99
)
{
iv_order_tip
.
text
=
"99+"
val
numberStr
=
if
(
orderNum
>
99
)
{
"99+"
}
else
{
iv_order_tip
.
text
=
"$orderNum"
"$orderNum"
}
getLocal
().
setConsult
(
true
)
iv_order_tip
.
text
=
numberStr
getLocal
().
setConsult
(
orderNum
)
}
else
{
iv_order_tip
.
visibility
=
View
.
GONE
getLocal
().
setConsult
(
false
)
getLocal
().
setConsult
(
0
)
}
}
else
{
getLocal
().
setConfide
(
false
)
getLocal
().
setConsult
(
false
)
getLocal
().
setConsult
(
0
)
}
}
else
{
getLocal
().
setConfide
(
false
)
getLocal
().
setConsult
(
false
)
getLocal
().
setConsult
(
0
)
}
},{
getLocal
().
setConfide
(
false
)
getLocal
().
setConsult
(
false
)
getLocal
().
setConsult
(
0
)
})
}
...
...
@@ -245,7 +246,7 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
private
fun
refreshCouponData
()
{
getLocal
().
setCoupon
(
false
)
getLocal
().
setConfide
(
false
)
getLocal
().
setConsult
(
false
)
getLocal
().
setConsult
(
0
)
val
userInfo
=
getUserInfo
()
...
...
m-user/src/main/java/com/yidianling/user/mine/data/AppLocal.kt
View file @
f2f0882b
...
...
@@ -22,9 +22,9 @@ interface AppLocal {
fun
setCoupon
(
have
:
Boolean
)
fun
getConsult
():
Boolean
fun
getConsult
():
Int
fun
setConsult
(
have
:
Boolean
)
fun
setConsult
(
have
:
Int
)
fun
getConfide
():
Boolean
...
...
m-user/src/main/java/com/yidianling/user/mine/data/AppLocalImpl.kt
View file @
f2f0882b
...
...
@@ -50,12 +50,12 @@ internal class AppLocalImpl private constructor(): AppLocal {
getAppSP
().
edit
().
putBoolean
(
COUPON
,
have
).
apply
()
}
override
fun
getConsult
():
Boolean
{
return
getAppSP
().
get
Boolean
(
CONSULT
,
false
)
override
fun
getConsult
():
Int
{
return
getAppSP
().
get
Int
(
CONSULT
,
0
)
}
override
fun
setConsult
(
have
:
Boolean
)
{
getAppSP
().
edit
().
put
Boolean
(
CONSULT
,
have
).
apply
()
override
fun
setConsult
(
have
:
Int
)
{
getAppSP
().
edit
().
put
Int
(
CONSULT
,
have
).
apply
()
}
override
fun
getConfide
():
Boolean
{
...
...
m-user/src/main/res/layout/user_mine_fragment_mine.xml
View file @
f2f0882b
...
...
@@ -417,18 +417,18 @@
app:layout_constraintTop_toTopOf=
"parent"
/>
<TextView
tools:text=
"11"
android:id=
"@+id/iv_order_tip"
android:layout_width=
"12dp"
android:layout_height=
"12dp"
android:background=
"@drawable/user_mine_background_red_point_new_coupon"
android:gravity=
"center"
android:textSize=
"8dp"
android:textColor=
"@color/white"
android:
background=
"@drawable/user_mine_background_red_point_new_coupon
"
android:
textSize=
"6sp
"
android:visibility=
"gone"
app:layout_constraintCircle=
"@id/iv_trade_order"
app:layout_constraintCircleAngle=
"45"
app:layout_constraintCircleRadius=
"10dp"
tools:text=
"9"
tools:visibility=
"visible"
/>
<TextView
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment