Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_vedio
Project
Project
Details
Activity
Releases
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
android
android_vedio
Commits
12ff6164
Commit
12ff6164
authored
Feb 19, 2024
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加授权支付
parent
2ff828b3
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
9 deletions
+26
-9
UserBean.java
.../main/java/com/duben/happyplaylet/mvp/model/UserBean.java
+4
-4
VipBean.java
...c/main/java/com/duben/happyplaylet/mvp/model/VipBean.java
+9
-0
VipActivity.kt
...n/java/com/duben/happyplaylet/ui/activitys/VipActivity.kt
+13
-5
No files found.
video/app/src/main/java/com/duben/happyplaylet/mvp/model/UserBean.java
View file @
12ff6164
...
@@ -18,7 +18,7 @@ public class UserBean implements Serializable {
...
@@ -18,7 +18,7 @@ public class UserBean implements Serializable {
private
int
activiteFlag
=
0
;
// 1-匹配用户
private
int
activiteFlag
=
0
;
// 1-匹配用户
private
String
openid
;
private
String
openid
;
private
boolean
isForever
;
//true-永久会员
private
boolean
isForever
;
//true-永久会员
private
boolean
alipaySet
;
//支付宝授权
private
boolean
hasAlipayUserId
;
//支付宝授权
private
long
expireTime
;
// vip到期时间 0-非vip
private
long
expireTime
;
// vip到期时间 0-非vip
private
long
pk_id
;
// 用户id
private
long
pk_id
;
// 用户id
private
long
createTime
;
// 用户id
private
long
createTime
;
// 用户id
...
@@ -100,10 +100,10 @@ public class UserBean implements Serializable {
...
@@ -100,10 +100,10 @@ public class UserBean implements Serializable {
}
}
public
boolean
isAlipaySet
()
{
public
boolean
isAlipaySet
()
{
return
alipaySet
;
return
hasAlipayUserId
;
}
}
public
void
setAlipaySet
(
boolean
alipaySet
)
{
public
void
setAlipaySet
(
boolean
hasAlipayUserId
)
{
this
.
alipaySet
=
alipaySet
;
this
.
hasAlipayUserId
=
hasAlipayUserId
;
}
}
}
}
video/app/src/main/java/com/duben/happyplaylet/mvp/model/VipBean.java
View file @
12ff6164
...
@@ -23,6 +23,7 @@ public class VipBean implements Serializable {
...
@@ -23,6 +23,7 @@ public class VipBean implements Serializable {
private
boolean
alipay
;
private
boolean
alipay
;
private
boolean
showCycTips
;
// 判断是否提示
private
boolean
showCycTips
;
// 判断是否提示
private
double
firstPayPrice
;
private
double
firstPayPrice
;
private
double
trialTrialBack
;
private
double
oldPrice
;
private
double
oldPrice
;
private
int
days
;
private
int
days
;
private
int
trial
;
//是否签约 0-没签约 1-签约
private
int
trial
;
//是否签约 0-没签约 1-签约
...
@@ -113,5 +114,13 @@ public class VipBean implements Serializable {
...
@@ -113,5 +114,13 @@ public class VipBean implements Serializable {
public
int
getTrial
()
{
public
int
getTrial
()
{
return
trial
;
return
trial
;
}
}
public
double
getTrialTrialBack
()
{
return
trialTrialBack
;
}
public
void
setTrialTrialBack
(
double
trialTrialBack
)
{
this
.
trialTrialBack
=
trialTrialBack
;
}
}
}
}
}
video/app/src/main/java/com/duben/happyplaylet/ui/activitys/VipActivity.kt
View file @
12ff6164
...
@@ -236,12 +236,20 @@ class VipActivity : BaseActivity(), VipView, View.OnClickListener,
...
@@ -236,12 +236,20 @@ class VipActivity : BaseActivity(), VipView, View.OnClickListener,
return
return
}
}
// 授权 支付
if
(
vipList
!=
null
&&
vipList
!!
.
size
>
0
)
{
val
vipBean
=
vipList
!!
[
vipAdapter
.
getPosition
()]
if
(
vipBean
.
trialTrialBack
>
0
)
{
// 授权支付
if
(
userBean
?.
isAlipaySet
!!
)
{
if
(
userBean
?.
isAlipaySet
!!
)
{
alipay
(
paramsBean
)
alipay
(
paramsBean
)
}
else
{
}
else
{
alipayLoginDialog
(
paramsBean
)
alipayLoginDialog
(
paramsBean
)
}
}
}
else
{
// 普通支付
alipay
(
paramsBean
)
}
}
}
}
}
}
}
}
...
...
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