Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
RvApp
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
1
Merge Requests
1
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
lify
RvApp
Commits
8ef87adb
Commit
8ef87adb
authored
Dec 19, 2019
by
jianglx
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master-invoice' of
http://113.105.137.151:22280/lify/rvapp
into master-invoice-john
parents
b3657a2e
9bff3d9e
Changes
22
Hide whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
493 additions
and
130 deletions
+493
-130
build.gradle
RvClient/build.gradle
+2
-2
MainActivity.java
RvClient/src/main/java/com/xxfc/rv/MainActivity.java
+6
-0
rv_dialog_conference_event.xml
...dialog/src/main/res/layout/rv_dialog_conference_event.xml
+2
-2
dimens.xml
component_dialog/src/main/res/values-hdpi/dimens.xml
+9
-0
dimens.xml
component_dialog/src/main/res/values-xhdpi/dimens.xml
+9
-0
dimens.xml
component_dialog/src/main/res/values-xxhdpi/dimens.xml
+11
-0
icon_fragment_video_hint.png
.../src/main/res/drawable-xhdpi/icon_fragment_video_hint.png
+0
-0
OrderListActivity.java
.../home/rv/module/ui/main/home/order/OrderListActivity.java
+8
-8
TransformationUtils10.java
...c/main/java/com/rv/share/utils/TransformationUtils10.java
+41
-0
RvWebView.java
plugin_share/src/main/java/com/rv/share/view/RvWebView.java
+2
-2
activity_reative_bill.xml
plugin_share/src/main/res/layout/activity_reative_bill.xml
+2
-1
activity_web_view.xml
plugin_share/src/main/res/layout/activity_web_view.xml
+0
-1
CommentVideoAdapter.java
...main/java/com/xxrv/video/adapter/CommentVideoAdapter.java
+30
-0
AutoScrollLayoutManager.java
...n/java/com/xxrv/video/weight/AutoScrollLayoutManager.java
+42
-0
JcvTrillVideo.java
...eo/src/main/java/com/xxrv/video/weight/JcvTrillVideo.java
+34
-7
layout_jcv_trill.xml
plugin_video/src/main/res/layout/layout_jcv_trill.xml
+11
-3
rv_item_comment_video.xml
plugin_video/src/main/res/layout/rv_item_comment_video.xml
+17
-0
SetPayPwdActivity2.java
...ain/java/com/xxrv/wallet/activity/SetPayPwdActivity2.java
+21
-0
WalletActivity.java
...rc/main/java/com/xxrv/wallet/activity/WalletActivity.java
+117
-14
WithdrawActivity.java
.../main/java/com/xxrv/wallet/activity/WithdrawActivity.java
+127
-67
AccountNumberListBean.java
...main/java/com/xxrv/wallet/bean/AccountNumberListBean.java
+0
-9
rv_dialog_third_party_binding.xml
...let/src/main/res/layout/rv_dialog_third_party_binding.xml
+2
-14
No files found.
RvClient/build.gradle
View file @
8ef87adb
...
@@ -8,8 +8,8 @@ android {
...
@@ -8,8 +8,8 @@ android {
minSdkVersion
rootProject
.
ext
.
minSdkVersion
minSdkVersion
rootProject
.
ext
.
minSdkVersion
targetSdkVersion
rootProject
.
ext
.
targetSdkVersion
targetSdkVersion
rootProject
.
ext
.
targetSdkVersion
flavorDimensions
"default"
flavorDimensions
"default"
versionCode
15
5
versionCode
15
7
versionName
"1.5.
5
"
versionName
"1.5.
7
"
multiDexEnabled
true
multiDexEnabled
true
...
...
RvClient/src/main/java/com/xxfc/rv/MainActivity.java
View file @
8ef87adb
...
@@ -9,6 +9,7 @@ import android.content.Context;
...
@@ -9,6 +9,7 @@ import android.content.Context;
import
android.content.Intent
;
import
android.content.Intent
;
import
android.content.IntentFilter
;
import
android.content.IntentFilter
;
import
android.content.ServiceConnection
;
import
android.content.ServiceConnection
;
import
android.graphics.Bitmap
;
import
android.location.LocationManager
;
import
android.location.LocationManager
;
import
android.net.ConnectivityManager
;
import
android.net.ConnectivityManager
;
import
android.net.Uri
;
import
android.net.Uri
;
...
@@ -24,6 +25,7 @@ import android.text.TextUtils;
...
@@ -24,6 +25,7 @@ import android.text.TextUtils;
import
android.util.Log
;
import
android.util.Log
;
import
android.view.KeyEvent
;
import
android.view.KeyEvent
;
import
android.view.View
;
import
android.view.View
;
import
android.view.ViewGroup
;
import
android.widget.ImageView
;
import
android.widget.ImageView
;
import
android.widget.TextView
;
import
android.widget.TextView
;
import
android.widget.Toast
;
import
android.widget.Toast
;
...
@@ -31,6 +33,8 @@ import android.widget.Toast;
...
@@ -31,6 +33,8 @@ import android.widget.Toast;
import
com.alibaba.android.arouter.launcher.ARouter
;
import
com.alibaba.android.arouter.launcher.ARouter
;
import
com.base.utils.ui.image.round.RoundImageView
;
import
com.base.utils.ui.image.round.RoundImageView
;
import
com.bumptech.glide.Glide
;
import
com.bumptech.glide.Glide
;
import
com.bumptech.glide.request.target.SimpleTarget
;
import
com.bumptech.glide.request.transition.Transition
;
import
com.frame.base.url.Constance
;
import
com.frame.base.url.Constance
;
import
com.frame.base.url.ImageUrl
;
import
com.frame.base.url.ImageUrl
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.frame.rv.config.RvFrameConfig
;
...
@@ -81,6 +85,7 @@ import com.rv.plugin.calendar.bean.PreRentDaysBean;
...
@@ -81,6 +85,7 @@ import com.rv.plugin.calendar.bean.PreRentDaysBean;
import
com.rv.rvmine.MineFragment
;
import
com.rv.rvmine.MineFragment
;
import
com.rv.share.WebViewActivity
;
import
com.rv.share.WebViewActivity
;
import
com.rv.share.utils.TransformationUtils
;
import
com.rv.share.utils.TransformationUtils
;
import
com.rv.share.utils.TransformationUtils10
;
import
com.rv.share.view.PromotionDialog
;
import
com.rv.share.view.PromotionDialog
;
import
com.rv.tourism.R2
;
import
com.rv.tourism.R2
;
import
com.rv.tourism.TourismFragment
;
import
com.rv.tourism.TourismFragment
;
...
@@ -736,6 +741,7 @@ public class MainActivity extends BaseActivity<CommonPresenter> implements DownL
...
@@ -736,6 +741,7 @@ public class MainActivity extends BaseActivity<CommonPresenter> implements DownL
if
(
codeInfoBean
==
null
||
codeInfoBean
.
getData
()
==
null
)
{
if
(
codeInfoBean
==
null
||
codeInfoBean
.
getData
()
==
null
)
{
return
;
return
;
}
}
new
ConferenceEventDialog
(
mActivity
)
{
new
ConferenceEventDialog
(
mActivity
)
{
@Override
@Override
public
void
helper
(
ViewHolder
helper
)
{
public
void
helper
(
ViewHolder
helper
)
{
...
...
component_dialog/src/main/res/layout/rv_dialog_conference_event.xml
View file @
8ef87adb
...
@@ -44,8 +44,8 @@
...
@@ -44,8 +44,8 @@
android:layout_marginLeft=
"@dimen/size_10"
android:layout_marginLeft=
"@dimen/size_10"
android:layout_marginTop=
"@dimen/size_20"
android:layout_marginTop=
"@dimen/size_20"
android:layout_marginRight=
"@dimen/size_10"
android:layout_marginRight=
"@dimen/size_10"
android:minWidth=
"@dimen/
size_150
"
android:minWidth=
"@dimen/
dialog_act_width
"
android:minHeight=
"@dimen/
size_150
"
/>
android:minHeight=
"@dimen/
dialog_act_height
"
/>
<TextView
<TextView
...
...
component_dialog/src/main/res/values-hdpi/dimens.xml
0 → 100644
View file @
8ef87adb
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen
name=
"dialog_width"
>
150dp
</dimen>
<dimen
name=
"dialog_min_height"
>
150dp
</dimen>
<dimen
name=
"dialog_act_width"
>
150dp
</dimen>
<dimen
name=
"dialog_act_height"
>
150dp
</dimen>
<dimen
name=
"height_share_ruler_top"
>
108.34dp
</dimen>
</resources>
component_dialog/src/main/res/values-xhdpi/dimens.xml
0 → 100644
View file @
8ef87adb
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen
name=
"dialog_width"
>
200dp
</dimen>
<dimen
name=
"dialog_min_height"
>
200dp
</dimen>
<dimen
name=
"dialog_act_width"
>
200dp
</dimen>
<dimen
name=
"dialog_act_height"
>
200dp
</dimen>
<dimen
name=
"height_share_ruler_top"
>
240.45dp
</dimen>
</resources>
component_dialog/src/main/res/values-xxhdpi/dimens.xml
0 → 100644
View file @
8ef87adb
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen
name=
"dialog_width"
>
300dp
</dimen>
<dimen
name=
"dialog_min_height"
>
300dp
</dimen>
<dimen
name=
"dialog_act_width"
>
300dp
</dimen>
<dimen
name=
"dialog_act_height"
>
300dp
</dimen>
<dimen
name=
"height_share_ruler_top"
>
216.67dp
</dimen>
</resources>
component_resource/src/main/res/drawable-xhdpi/icon_fragment_video_hint.png
View replaced file @
b3657a2e
View file @
8ef87adb
2 KB
|
W:
|
H:
1.65 KB
|
W:
|
H:
2-up
Swipe
Onion skin
module_home/src/main/java/com/rv/home/rv/module/ui/main/home/order/OrderListActivity.java
View file @
8ef87adb
...
@@ -63,14 +63,14 @@ public class OrderListActivity extends BaseStatusActivity<PickerPresenter> {
...
@@ -63,14 +63,14 @@ public class OrderListActivity extends BaseStatusActivity<PickerPresenter> {
protected
void
initView
(
Bundle
savedInstanceState
,
TitleView
titleView
,
Intent
intent
)
{
protected
void
initView
(
Bundle
savedInstanceState
,
TitleView
titleView
,
Intent
intent
)
{
menuPosition
=
intent
.
getIntExtra
(
"position"
,
0
);
menuPosition
=
intent
.
getIntExtra
(
"position"
,
0
);
titleView
.
setTitle
(
mActivity
.
getString
(
R
.
string
.
rv_my_order
));
titleView
.
setTitle
(
mActivity
.
getString
(
R
.
string
.
rv_my_order
));
//
titleView.setText(R.id.tv_title_right, "开发票");
/*
titleView.setText(R.id.tv_title_right, "开发票");
//
titleView.setChildClickListener(R.id.tv_title_right, new View.OnClickListener() {
titleView.setChildClickListener(R.id.tv_title_right, new View.OnClickListener() {
//
@Override
@Override
//
public void onClick(View v) {
public void onClick(View v) {
//
ARouter.getInstance().build(Constance.ACTIVITY_URL_INVOICINGACTIVITY)
ARouter.getInstance().build(Constance.ACTIVITY_URL_INVOICINGACTIVITY)
//
.navigation();
.navigation();
//
}
}
// });
});*/
initRecyclerView
();
initRecyclerView
();
initViewpager
();
initViewpager
();
...
...
plugin_share/src/main/java/com/rv/share/utils/TransformationUtils10.java
0 → 100644
View file @
8ef87adb
package
com
.
rv
.
share
.
utils
;
import
android.graphics.Bitmap
;
import
android.view.ViewGroup
;
import
android.widget.ImageView
;
import
com.bumptech.glide.request.target.ImageViewTarget
;
public
class
TransformationUtils10
extends
ImageViewTarget
<
Bitmap
>
{
private
int
width
;
private
int
height
;
private
ImageView
target
;
public
TransformationUtils10
(
ImageView
target
,
int
width
,
int
height
)
{
super
(
target
);
this
.
target
=
target
;
this
.
width
=
width
;
this
.
height
=
height
;
}
@Override
protected
void
setResource
(
Bitmap
resource
)
{
target
.
setImageBitmap
(
resource
);
if
(
resource
==
null
)
return
;
//获取原图的宽高
// int width = resource.getWidth();
// int height = resource.getHeight();
//获取imageView的宽
int
imageViewWidth
=
target
.
getWidth
();
//计算缩放比例
float
sy
=
(
float
)
(
imageViewWidth
*
0.1
)
/
(
float
)
(
width
*
0.1
);
//计算图片等比例放大后的高
int
imageViewHeight
=
(
int
)
(
height
*
sy
);
ViewGroup
.
LayoutParams
params
=
target
.
getLayoutParams
();
params
.
height
=
imageViewHeight
;
target
.
setLayoutParams
(
params
);
}
}
\ No newline at end of file
plugin_share/src/main/java/com/rv/share/view/RvWebView.java
View file @
8ef87adb
...
@@ -50,13 +50,13 @@ public class RvWebView extends WebView {
...
@@ -50,13 +50,13 @@ public class RvWebView extends WebView {
// 支持 Js 使用
// 支持 Js 使用
webSettings
.
setJavaScriptEnabled
(
true
);
webSettings
.
setJavaScriptEnabled
(
true
);
// 开启DOM缓存,默认状态下是不支持LocalStorage的
// 开启DOM缓存,默认状态下是不支持LocalStorage的
webSettings
.
setDomStorageEnabled
(
true
);
//
webSettings.setDomStorageEnabled(true);
// 开启数据库缓存
// 开启数据库缓存
webSettings
.
setDatabaseEnabled
(
true
);
webSettings
.
setDatabaseEnabled
(
true
);
// 支持自动加载图片
// 支持自动加载图片
webSettings
.
setLoadsImagesAutomatically
(
hasKitkat
());
webSettings
.
setLoadsImagesAutomatically
(
hasKitkat
());
// 设置 WebView 的缓存模式
// 设置 WebView 的缓存模式
webSettings
.
setCacheMode
(
WebSettings
.
LOAD_DEFAULT
);
//
webSettings.setCacheMode(WebSettings.LOAD_DEFAULT);
// 支持启用缓存模式
// 支持启用缓存模式
webSettings
.
setAppCacheEnabled
(
true
);
webSettings
.
setAppCacheEnabled
(
true
);
// 设置 AppCache 最大缓存值(现在官方已经不提倡使用,已废弃)
// 设置 AppCache 最大缓存值(现在官方已经不提倡使用,已废弃)
...
...
plugin_share/src/main/res/layout/activity_reative_bill.xml
View file @
8ef87adb
...
@@ -101,7 +101,8 @@
...
@@ -101,7 +101,8 @@
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"邀请你一起参加"
android:text=
"邀请你一起参加"
android:textColor=
"@color/text_Gray"
android:textColor=
"@color/text_Gray"
android:textSize=
"@dimen/text_10"
/>
android:textSize=
"@dimen/text_10"
android:visibility=
"gone"
/>
<TextView
<TextView
android:id=
"@+id/tv_invitation_code"
android:id=
"@+id/tv_invitation_code"
...
...
plugin_share/src/main/res/layout/activity_web_view.xml
View file @
8ef87adb
...
@@ -25,7 +25,6 @@
...
@@ -25,7 +25,6 @@
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_centerVertical=
"true"
android:layout_toRightOf=
"@id/iv_title_left"
android:gravity=
"center"
android:gravity=
"center"
android:padding=
"@dimen/size_10"
android:padding=
"@dimen/size_10"
android:textColor=
"@color/textMain"
android:textColor=
"@color/textMain"
...
...
plugin_video/src/main/java/com/xxrv/video/adapter/CommentVideoAdapter.java
0 → 100644
View file @
8ef87adb
package
com
.
xxrv
.
video
.
adapter
;
import
android.widget.ImageView
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.chad.library.adapter.base.BaseViewHolder
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.rv.component.utils.DateUtils
;
import
com.xxrv.video.R
;
import
com.xxrv.video.bean.circle.Comment
;
import
com.xxrv.video.bean.circle.VideoFile
;
/**
* 评论
*/
public
class
CommentVideoAdapter
extends
BaseQuickAdapter
<
Comment
,
BaseViewHolder
>
{
public
CommentVideoAdapter
()
{
super
(
R
.
layout
.
rv_item_comment_video
);
}
@Override
protected
void
convert
(
BaseViewHolder
helper
,
Comment
item
)
{
if
(
item
==
null
)
{
return
;
}
helper
.
setText
(
R
.
id
.
tv_content
,
item
.
getBody
());
}
}
plugin_video/src/main/java/com/xxrv/video/weight/AutoScrollLayoutManager.java
0 → 100644
View file @
8ef87adb
package
com
.
xxrv
.
video
.
weight
;
import
android.content.Context
;
import
android.graphics.PointF
;
import
android.support.annotation.Nullable
;
import
android.support.v7.widget.LinearLayoutManager
;
import
android.support.v7.widget.LinearSmoothScroller
;
import
android.support.v7.widget.RecyclerView
;
import
android.util.DisplayMetrics
;
public
class
AutoScrollLayoutManager
extends
LinearLayoutManager
{
public
AutoScrollLayoutManager
(
Context
context
)
{
super
(
context
);
}
// 客制化需要实现该方法;
@Override
public
void
smoothScrollToPosition
(
RecyclerView
recyclerView
,
RecyclerView
.
State
state
,
int
position
)
{
LinearSmoothScroller
linearSmoothScroller
=
new
LinearSmoothScroller
(
recyclerView
.
getContext
())
{
@Nullable
@Override
public
PointF
computeScrollVectorForPosition
(
int
targetPosition
)
{
return
AutoScrollLayoutManager
.
this
.
computeScrollVectorForPosition
(
targetPosition
);
}
@Override
protected
float
calculateSpeedPerPixel
(
DisplayMetrics
displayMetrics
)
{
// 计算滑动每个像素需要的时间,这里应该与屏幕适配;
return
15
f
/
displayMetrics
.
density
;
}
};
linearSmoothScroller
.
setTargetPosition
(
position
);
startSmoothScroll
(
linearSmoothScroller
);
}
}
plugin_video/src/main/java/com/xxrv/video/weight/JcvTrillVideo.java
View file @
8ef87adb
...
@@ -3,6 +3,7 @@ package com.xxrv.video.weight;
...
@@ -3,6 +3,7 @@ package com.xxrv.video.weight;
import
android.content.Context
;
import
android.content.Context
;
import
android.support.annotation.NonNull
;
import
android.support.annotation.NonNull
;
import
android.support.annotation.Nullable
;
import
android.support.annotation.Nullable
;
import
android.support.v7.widget.RecyclerView
;
import
android.text.TextUtils
;
import
android.text.TextUtils
;
import
android.util.AttributeSet
;
import
android.util.AttributeSet
;
import
android.util.Log
;
import
android.util.Log
;
...
@@ -15,7 +16,6 @@ import android.view.animation.LinearInterpolator;
...
@@ -15,7 +16,6 @@ import android.view.animation.LinearInterpolator;
import
android.widget.FrameLayout
;
import
android.widget.FrameLayout
;
import
android.widget.ImageView
;
import
android.widget.ImageView
;
import
android.widget.ProgressBar
;
import
android.widget.ProgressBar
;
import
android.widget.RelativeLayout
;
import
android.widget.TextView
;
import
android.widget.TextView
;
import
com.alibaba.android.arouter.launcher.ARouter
;
import
com.alibaba.android.arouter.launcher.ARouter
;
...
@@ -23,17 +23,15 @@ import com.base.utils.ui.datetime.selector.util.TextUtil;
...
@@ -23,17 +23,15 @@ import com.base.utils.ui.datetime.selector.util.TextUtil;
import
com.danikula.videocache.HttpProxyCacheServer
;
import
com.danikula.videocache.HttpProxyCacheServer
;
import
com.frame.base.url.Constance
;
import
com.frame.base.url.Constance
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.ruiwenliu.wrapper.SPConstance
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseStatusActivity
;
import
com.ruiwenliu.wrapper.base.BaseStatusActivity
;
import
com.ruiwenliu.wrapper.base.BaseView
;
import
com.ruiwenliu.wrapper.base.BaseView
;
import
com.ruiwenliu.wrapper.presenter.MvpPresenter
;
import
com.ruiwenliu.wrapper.presenter.WrapperPresenter
;
import
com.ruiwenliu.wrapper.presenter.WrapperPresenter
;
import
com.ruiwenliu.wrapper.util.glide.GlideApp
;
import
com.ruiwenliu.wrapper.util.glide.GlideApp
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.rv.component.utils.Cookie
;
import
com.xxrv.video.R
;
import
com.xxrv.video.R
;
import
com.xxrv.video.activity.TriListActivity
;
import
com.xxrv.video.activity.TriListActivity
;
import
com.xxrv.video.adapter.CommentVideoAdapter
;
import
com.xxrv.video.api.VideoApi
;
import
com.xxrv.video.api.VideoApi
;
import
com.xxrv.video.base.Proxy
;
import
com.xxrv.video.base.Proxy
;
import
com.xxrv.video.bean.circle.Comment
;
import
com.xxrv.video.bean.circle.Comment
;
...
@@ -41,8 +39,6 @@ import com.xxrv.video.bean.circle.DiscoveryDataBean;
...
@@ -41,8 +39,6 @@ import com.xxrv.video.bean.circle.DiscoveryDataBean;
import
com.xxrv.video.bean.circle.VideoIMTokenBean
;
import
com.xxrv.video.bean.circle.VideoIMTokenBean
;
import
com.xxrv.video.dialog.TrillCommDialog
;
import
com.xxrv.video.dialog.TrillCommDialog
;
import
com.xxrv.video.presenter.VideoPresenter
;
import
com.xxrv.video.presenter.VideoPresenter
;
import
com.xxrv.video.weight.likeView.LikeAnimationView
;
import
com.xxrv.video.weight.likeView.LikeRelativeLayout
;
import
com.yuyife.okgo.OkGoUtil
;
import
com.yuyife.okgo.OkGoUtil
;
import
java.lang.reflect.ParameterizedType
;
import
java.lang.reflect.ParameterizedType
;
...
@@ -55,7 +51,6 @@ import java.util.Map;
...
@@ -55,7 +51,6 @@ import java.util.Map;
import
fm.jiecao.jcvideoplayer_lib.JCVideoPlayer
;
import
fm.jiecao.jcvideoplayer_lib.JCVideoPlayer
;
import
fm.jiecao.jcvideoplayer_lib.JCVideoViewbyXuan
;
import
fm.jiecao.jcvideoplayer_lib.JCVideoViewbyXuan
;
import
fm.jiecao.jcvideoplayer_lib.OnJcvdListener
;
import
fm.jiecao.jcvideoplayer_lib.OnJcvdListener
;
import
okhttp3.Call
;
public
class
JcvTrillVideo
extends
FrameLayout
implements
BaseView
,
View
.
OnClickListener
{
public
class
JcvTrillVideo
extends
FrameLayout
implements
BaseView
,
View
.
OnClickListener
{
TriListActivity
mShareListener
;
TriListActivity
mShareListener
;
...
@@ -102,6 +97,8 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
...
@@ -102,6 +97,8 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
private
TextView
tvConmmentHint2
;
private
TextView
tvConmmentHint2
;
private
TextView
tvConmmentHint3
;
private
TextView
tvConmmentHint3
;
private
TextView
tvAddress
;
private
TextView
tvAddress
;
private
RecyclerView
rvContent
;
private
CommentVideoAdapter
commentVideoAdapter
;
private
OnJcvdListener
mVideoListener
=
new
OnJcvdListener
()
{
private
OnJcvdListener
mVideoListener
=
new
OnJcvdListener
()
{
@Override
@Override
...
@@ -204,6 +201,7 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
...
@@ -204,6 +201,7 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
tvConmmentHint2
=
findViewById
(
R
.
id
.
tv_conmment_hint2
);
tvConmmentHint2
=
findViewById
(
R
.
id
.
tv_conmment_hint2
);
tvConmmentHint3
=
findViewById
(
R
.
id
.
tv_conmment_hint3
);
tvConmmentHint3
=
findViewById
(
R
.
id
.
tv_conmment_hint3
);
tvAddress
=
findViewById
(
R
.
id
.
tv_address
);
tvAddress
=
findViewById
(
R
.
id
.
tv_address
);
rvContent
=
findViewById
(
R
.
id
.
rv_content
);
ivAvatar
.
setOnClickListener
(
this
);
ivAvatar
.
setOnClickListener
(
this
);
findViewById
(
R
.
id
.
iv_follow
).
setOnClickListener
(
this
);
// 关注
findViewById
(
R
.
id
.
iv_follow
).
setOnClickListener
(
this
);
// 关注
...
@@ -213,8 +211,35 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
...
@@ -213,8 +211,35 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
mVideoView
.
addOnJcvdListener
(
mVideoListener
);
mVideoView
.
addOnJcvdListener
(
mVideoListener
);
initGestureAndAnimation
(
context
);
initGestureAndAnimation
(
context
);
// AutoScrollLayoutManager autoScrollLayoutManager = new AutoScrollLayoutManager(context);
// rvContent.setLayoutManager(autoScrollLayoutManager);
// commentVideoAdapter = new CommentVideoAdapter();
// rvContent.setAdapter(commentVideoAdapter);
//
//
// rvContent.setOnScrollListener(new RecyclerView.OnScrollListener() {
// @Override
// public void onScrollStateChanged(RecyclerView recyclerView, int newState) {
// super.onScrollStateChanged(recyclerView, newState);
//
// if (newState == RecyclerView.SCROLL_STATE_IDLE) {
// // 如果自动滑动到最后一个位置,则此处状态为SCROLL_STATE_IDLE
// AutoScrollLayoutManager lm = (AutoScrollLayoutManager) recyclerView
// .getLayoutManager();
//
// int position = lm.findLastCompletelyVisibleItemPosition();
// int count = lm.getItemCount();
// if (position == count - 1) {
// lm.scrollToPosition(0);
// rvContent.smoothScrollToPosition(commentVideoAdapter.getItemCount());
// }
// }
// }
// });
}
}
private
void
initGestureAndAnimation
(
Context
context
)
{
private
void
initGestureAndAnimation
(
Context
context
)
{
mGestureDetector
=
new
GestureDetector
(
context
,
new
GestureDetector
.
SimpleOnGestureListener
()
{
mGestureDetector
=
new
GestureDetector
(
context
,
new
GestureDetector
.
SimpleOnGestureListener
()
{
@Override
@Override
...
@@ -324,6 +349,8 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
...
@@ -324,6 +349,8 @@ public class JcvTrillVideo extends FrameLayout implements BaseView, View.OnClick
tvAddress
.
setText
(
bean
.
getLocation
());
tvAddress
.
setText
(
bean
.
getLocation
());
}
}
// commentVideoAdapter.addData(bean.getComments());
List
<
Comment
>
comments
=
bean
.
getComments
();
List
<
Comment
>
comments
=
bean
.
getComments
();
if
(
comments
!=
null
&&
comments
.
size
()
>
0
)
{
if
(
comments
!=
null
&&
comments
.
size
()
>
0
)
{
tvConmmentHint1
.
setVisibility
(
VISIBLE
);
tvConmmentHint1
.
setVisibility
(
VISIBLE
);
...
...
plugin_video/src/main/res/layout/layout_jcv_trill.xml
View file @
8ef87adb
...
@@ -201,6 +201,11 @@
...
@@ -201,6 +201,11 @@
android:layout_marginBottom=
"12dp"
android:layout_marginBottom=
"12dp"
android:orientation=
"vertical"
>
android:orientation=
"vertical"
>
<android.support.v7.widget.RecyclerView
android:id=
"@+id/rv_content"
android:visibility=
"gone"
android:layout_width=
"wrap_content"
android:layout_height=
"@dimen/size_60"
/>
<TextView
<TextView
android:id=
"@+id/tv_conmment_hint1"
android:id=
"@+id/tv_conmment_hint1"
...
@@ -213,7 +218,8 @@
...
@@ -213,7 +218,8 @@
android:paddingBottom=
"@dimen/size_8"
android:paddingBottom=
"@dimen/size_8"
android:text=
"今年一定要去这里..."
android:text=
"今年一定要去这里..."
android:textColor=
"@color/colorWrite"
android:textColor=
"@color/colorWrite"
android:textSize=
"@dimen/text_12"
/>
android:textSize=
"@dimen/text_12"
android:visibility=
"visible"
/>
<TextView
<TextView
android:id=
"@+id/tv_conmment_hint2"
android:id=
"@+id/tv_conmment_hint2"
...
@@ -227,7 +233,8 @@
...
@@ -227,7 +233,8 @@
android:paddingBottom=
"@dimen/size_8"
android:paddingBottom=
"@dimen/size_8"
android:text=
"各种颜色的集装箱,绝对是打卡圣地"
android:text=
"各种颜色的集装箱,绝对是打卡圣地"
android:textColor=
"@color/colorWrite"
android:textColor=
"@color/colorWrite"
android:textSize=
"@dimen/text_12"
/>
android:textSize=
"@dimen/text_12"
android:visibility=
"visible"
/>
<TextView
<TextView
android:id=
"@+id/tv_conmment_hint3"
android:id=
"@+id/tv_conmment_hint3"
...
@@ -241,7 +248,8 @@
...
@@ -241,7 +248,8 @@
android:paddingBottom=
"@dimen/size_8"
android:paddingBottom=
"@dimen/size_8"
android:text=
"住在里面真的是面朝大海,春暖花开呀 很安静..."
android:text=
"住在里面真的是面朝大海,春暖花开呀 很安静..."
android:textColor=
"@color/colorWrite"
android:textColor=
"@color/colorWrite"
android:textSize=
"@dimen/text_12"
/>
android:textSize=
"@dimen/text_12"
android:visibility=
"visible"
/>
<TextView
<TextView
android:id=
"@+id/tv_name"
android:id=
"@+id/tv_name"
...
...
plugin_video/src/main/res/layout/rv_item_comment_video.xml
0 → 100644
View file @
8ef87adb
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:paddingLeft=
"@dimen/size_15"
android:paddingRight=
"@dimen/size_15"
>
<TextView
android:id=
"@+id/tv_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textColor=
"@color/colorYellow"
android:textSize=
"@dimen/text_22"
/>
</LinearLayout>
\ No newline at end of file
plugin_wallet/src/main/java/com/xxrv/wallet/activity/SetPayPwdActivity2.java
View file @
8ef87adb
...
@@ -7,6 +7,8 @@ import android.text.Editable;
...
@@ -7,6 +7,8 @@ import android.text.Editable;
import
android.text.TextUtils
;
import
android.text.TextUtils
;
import
android.text.TextWatcher
;
import
android.text.TextWatcher
;
import
android.util.Log
;
import
android.util.Log
;
import
android.view.KeyEvent
;
import
android.view.View
;
import
android.widget.EditText
;
import
android.widget.EditText
;
import
com.frame.base.bus.RxBus
;
import
com.frame.base.bus.RxBus
;
...
@@ -120,6 +122,25 @@ public class SetPayPwdActivity2 extends BaseStatusActivity<CommonPresenter> {
...
@@ -120,6 +122,25 @@ public class SetPayPwdActivity2 extends BaseStatusActivity<CommonPresenter> {
}
else
if
(
edtPwd6
.
isFocused
())
{
}
else
if
(
edtPwd6
.
isFocused
())
{
edtPwd6
.
requestFocus
();
edtPwd6
.
requestFocus
();
}
}
}
else
{
if
(
edtPwd6
.
isFocused
())
{
edtPwd6
.
clearFocus
();
edtPwd5
.
requestFocus
();
}
else
if
(
edtPwd5
.
isFocused
())
{
edtPwd5
.
clearFocus
();
edtPwd4
.
requestFocus
();
}
else
if
(
edtPwd4
.
isFocused
())
{
edtPwd4
.
clearFocus
();
edtPwd3
.
requestFocus
();
}
else
if
(
edtPwd3
.
isFocused
())
{
edtPwd3
.
clearFocus
();
edtPwd2
.
requestFocus
();
}
else
if
(
edtPwd2
.
isFocused
())
{
edtPwd2
.
clearFocus
();
edtPwd1
.
requestFocus
();
}
else
if
(
edtPwd1
.
isFocused
())
{
edtPwd1
.
requestFocus
();
}
}
}
}
}
};
};
...
...
plugin_wallet/src/main/java/com/xxrv/wallet/activity/WalletActivity.java
View file @
8ef87adb
package
com
.
xxrv
.
wallet
.
activity
;
package
com
.
xxrv
.
wallet
.
activity
;
import
android.annotation.SuppressLint
;
import
android.annotation.SuppressLint
;
import
android.app.ProgressDialog
;
import
android.content.Intent
;
import
android.content.Intent
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.os.Handler
;
import
android.os.Handler
;
...
@@ -27,6 +28,10 @@ import com.ruiwenliu.wrapper.weight.TitleView;
...
@@ -27,6 +28,10 @@ import com.ruiwenliu.wrapper.weight.TitleView;
import
com.rv.component.dialog.VerifiedTipsDialog
;
import
com.rv.component.dialog.VerifiedTipsDialog
;
import
com.rv.component.dialog.WalletTipsDialog
;
import
com.rv.component.dialog.WalletTipsDialog
;
import
com.rv.home.rv.module.ApiConfig
;
import
com.rv.home.rv.module.ApiConfig
;
import
com.umeng.socialize.UMAuthListener
;
import
com.umeng.socialize.UMShareAPI
;
import
com.umeng.socialize.bean.SHARE_MEDIA
;
import
com.umeng.socialize.utils.SocializeUtils
;
import
com.xxrv.wallet.R
;
import
com.xxrv.wallet.R
;
import
com.xxrv.wallet.R2
;
import
com.xxrv.wallet.R2
;
import
com.xxrv.wallet.api.WalletApi
;
import
com.xxrv.wallet.api.WalletApi
;
...
@@ -40,6 +45,7 @@ import com.xxrv.wallet.event.SetPasswordSuccessEvent;
...
@@ -40,6 +45,7 @@ import com.xxrv.wallet.event.SetPasswordSuccessEvent;
import
com.xxrv.wallet.presenter.WalletPresenter
;
import
com.xxrv.wallet.presenter.WalletPresenter
;
import
com.yuyife.okgo.OkGoUtil
;
import
com.yuyife.okgo.OkGoUtil
;
import
java.util.HashMap
;
import
java.util.LinkedHashMap
;
import
java.util.LinkedHashMap
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -51,7 +57,7 @@ import io.reactivex.schedulers.Schedulers;
...
@@ -51,7 +57,7 @@ import io.reactivex.schedulers.Schedulers;
* 钱包
* 钱包
*/
*/
@Route
(
path
=
Constance
.
ACTIVITY_URL_WALLET
)
@Route
(
path
=
Constance
.
ACTIVITY_URL_WALLET
)
public
class
WalletActivity
extends
BaseStatusActivity
<
WalletPresenter
>
{
public
class
WalletActivity
extends
BaseStatusActivity
<
WalletPresenter
>
implements
UMAuthListener
{
@BindView
(
R2
.
id
.
tv_wallet_balance
)
@BindView
(
R2
.
id
.
tv_wallet_balance
)
TextView
tvWalletBalance
;
TextView
tvWalletBalance
;
...
@@ -67,7 +73,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -67,7 +73,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
private
BeanUserInfo
.
UserInfo
userInfo
;
private
BeanUserInfo
.
UserInfo
userInfo
;
private
static
final
int
SDK_AUTH_FLAG
=
2
;
private
static
final
int
SDK_AUTH_FLAG
=
2
;
private
String
isFrozen
;
private
String
isFrozen
;
public
ProgressDialog
dialog
;
@Override
@Override
protected
int
setLayout
()
{
protected
int
setLayout
()
{
...
@@ -85,6 +91,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -85,6 +91,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
showTitle
(
false
);
showTitle
(
false
);
initRxbus
();
initRxbus
();
userInfo
=
getUserInfo
();
userInfo
=
getUserInfo
();
dialog
=
new
ProgressDialog
(
this
);
}
}
private
void
initRxbus
()
{
private
void
initRxbus
()
{
...
@@ -136,18 +143,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -136,18 +143,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
private
void
isAccountNumber
(
AccountNumberListBean
result
)
{
private
void
isAccountNumber
(
AccountNumberListBean
result
)
{
if
(
result
!=
null
&&
result
.
getData
()
!=
null
&&
result
.
getData
().
size
()
>
0
)
{
////1支付宝 2微信
if
(
result
!=
null
&&
result
.
getData
()
!=
null
&&
result
.
getData
().
size
()
>
0
)
{
////1支付宝 2微信
int
num
=
0
;
getCheckSetPwd
();
for
(
int
i
=
0
;
i
<
result
.
getData
().
size
();
i
++)
{
if
(
1
==
result
.
getData
().
get
(
i
).
getType
())
{
num
++;
}
}
if
(
num
>
0
)
{
getCheckSetPwd
();
}
else
{
showBindingDialog
();
}
}
else
{
}
else
{
showBindingDialog
();
showBindingDialog
();
}
}
...
@@ -168,6 +164,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -168,6 +164,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
dismiss
();
dismiss
();
}
else
if
(
id
==
R
.
id
.
ll_item_wechat
)
{
}
else
if
(
id
==
R
.
id
.
ll_item_wechat
)
{
//微信绑定
//微信绑定
bindThirdParty
(
SHARE_MEDIA
.
WEIXIN
);
dismiss
();
dismiss
();
}
}
}
}
...
@@ -312,6 +309,9 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -312,6 +309,9 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
2
,
WalletApi
.
HTTP_URL_WALLET_UNAUTH_GETPARAM
,
WalletAuthInfoBean
.
class
,
map
,
false
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
2
,
WalletApi
.
HTTP_URL_WALLET_UNAUTH_GETPARAM
,
WalletAuthInfoBean
.
class
,
map
,
false
);
}
}
/**
* 获取帐号信息
*/
private
void
getAccountNumber
()
{
private
void
getAccountNumber
()
{
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
if
(
OkGoUtil
.
getToken
()
!=
null
)
if
(
OkGoUtil
.
getToken
()
!=
null
)
...
@@ -373,6 +373,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -373,6 +373,7 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
}
}
};
};
private
void
putAlipayCode
(
String
code
)
{
private
void
putAlipayCode
(
String
code
)
{
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
if
(
OkGoUtil
.
getToken
()
!=
null
)
if
(
OkGoUtil
.
getToken
()
!=
null
)
...
@@ -382,4 +383,106 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
...
@@ -382,4 +383,106 @@ public class WalletActivity extends BaseStatusActivity<WalletPresenter> {
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
3
,
WalletApi
.
HTTP_URL_WALLET_ALIPAY_GETUSERINFO
,
BaseBean
.
class
,
map
,
headMap
,
false
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
3
,
WalletApi
.
HTTP_URL_WALLET_ALIPAY_GETUSERINFO
,
BaseBean
.
class
,
map
,
headMap
,
false
);
}
}
private
void
bindThirdParty
(
SHARE_MEDIA
share_media
)
{
UMShareAPI
.
get
(
mActivity
).
getPlatformInfo
(
mActivity
,
share_media
,
this
);
}
@Override
public
void
onStart
(
SHARE_MEDIA
share_media
)
{
SocializeUtils
.
safeShowDialog
(
dialog
);
}
@Override
public
void
onComplete
(
SHARE_MEDIA
share_media
,
int
i
,
Map
<
String
,
String
>
map
)
{
if
(
dialog
!=
null
)
{
SocializeUtils
.
safeCloseDialog
(
dialog
);
}
String
type
=
share_media
.
getName
();
if
(
share_media
!=
null
&&
"wxsession"
.
equals
(
type
))
{
// 微信
String
openid
=
map
.
get
(
"openid"
);
String
unionid
=
map
.
get
(
"unionid"
);
String
nickName
=
map
.
get
(
"name"
);
authorize
(
openid
,
unionid
,
nickName
,
"wx"
);
}
}
/**
* 微信绑定
*
* @param openid
* @param unionid
* @param nickName
* @param type
*/
private
void
authorize
(
String
openid
,
String
unionid
,
String
nickName
,
String
type
)
{
if
(!
TextUtils
.
isEmpty
(
OkGoUtil
.
getToken
()))
{
Map
<
String
,
String
>
heads
=
new
HashMap
<>();
heads
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
mPresenter
.
postBodyData
(
10
,
ApiConfig
.
HTTP_URL_USER_BIND
,
BaseBean
.
class
,
new
AccountBindDto
(
openid
,
unionid
,
nickName
,
type
),
heads
,
false
);
}
}
@Override
public
void
onError
(
SHARE_MEDIA
share_media
,
int
i
,
Throwable
throwable
)
{
SocializeUtils
.
safeCloseDialog
(
dialog
);
showToast
(
mActivity
.
getString
(
com
.
rv
.
home
.
R
.
string
.
rv_login_authorization_failure
)
+
throwable
.
getMessage
());
}
@Override
public
void
onCancel
(
SHARE_MEDIA
share_media
,
int
i
)
{
SocializeUtils
.
safeCloseDialog
(
dialog
);
}
private
class
AccountBindDto
{
private
String
openId
;
private
String
unionId
;
private
String
nickName
;
private
String
type
;
public
AccountBindDto
(
String
openId
,
String
unionId
,
String
nickName
,
String
type
)
{
this
.
openId
=
openId
;
this
.
unionId
=
unionId
;
this
.
nickName
=
nickName
;
this
.
type
=
type
;
}
public
String
getOpenId
()
{
return
openId
;
}
public
void
setOpenId
(
String
openId
)
{
this
.
openId
=
openId
;
}
public
String
getUnionId
()
{
return
unionId
;
}
public
void
setUnionId
(
String
unionId
)
{
this
.
unionId
=
unionId
;
}
public
String
getNickName
()
{
return
nickName
;
}
public
void
setNickName
(
String
nickName
)
{
this
.
nickName
=
nickName
;
}
public
String
getType
()
{
return
type
;
}
public
void
setType
(
String
type
)
{
this
.
type
=
type
;
}
}
}
}
plugin_wallet/src/main/java/com/xxrv/wallet/activity/WithdrawActivity.java
View file @
8ef87adb
...
@@ -47,6 +47,7 @@ import com.xxrv.wallet.presenter.WalletPresenter;
...
@@ -47,6 +47,7 @@ import com.xxrv.wallet.presenter.WalletPresenter;
import
com.xxrv.wallet.view.PayPassView
;
import
com.xxrv.wallet.view.PayPassView
;
import
com.yuyife.okgo.OkGoUtil
;
import
com.yuyife.okgo.OkGoUtil
;
import
java.util.HashMap
;
import
java.util.LinkedHashMap
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -81,6 +82,8 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -81,6 +82,8 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
private
static
final
int
SDK_AUTH_FLAG
=
2
;
private
static
final
int
SDK_AUTH_FLAG
=
2
;
public
ProgressDialog
dialog
;
public
ProgressDialog
dialog
;
private
AccountTypeSelectionDialog
accountTypeSelectionDialog
;
private
AccountTypeSelectionDialog
accountTypeSelectionDialog
;
private
boolean
selectType
;
AccountNumberListBean
.
DataBean
selectDataBean
=
null
;
public
static
Intent
getIntent
(
Context
context
,
String
balance
)
{
public
static
Intent
getIntent
(
Context
context
,
String
balance
)
{
return
new
Intent
(
context
,
WithdrawActivity
.
class
)
return
new
Intent
(
context
,
WithdrawActivity
.
class
)
...
@@ -140,16 +143,15 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -140,16 +143,15 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
@Override
@Override
protected
void
loadData
(
Bundle
savedInstanceState
,
Intent
intent
)
{
protected
void
loadData
(
Bundle
savedInstanceState
,
Intent
intent
)
{
super
.
loadData
(
savedInstanceState
,
intent
);
super
.
loadData
(
savedInstanceState
,
intent
);
getAccountNumber
();
getAccountNumber
(
5
);
// getAliPayList();
getWithdrawalRules
();
getWithdrawalRules
();
}
}
private
void
getAccountNumber
()
{
private
void
getAccountNumber
(
int
type
)
{
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
if
(
OkGoUtil
.
getToken
()
!=
null
)
if
(
OkGoUtil
.
getToken
()
!=
null
)
headMap
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
headMap
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
mPresenter
.
getDataHead
(
RvFrameConfig
.
HOST
,
5
,
WalletApi
.
HTTP_URL_WALLET_ACCOUNT_NUMBER
,
AccountNumberListBean
.
class
,
headMap
,
false
);
mPresenter
.
getDataHead
(
RvFrameConfig
.
HOST
,
type
,
WalletApi
.
HTTP_URL_WALLET_ACCOUNT_NUMBER
,
AccountNumberListBean
.
class
,
headMap
,
false
);
}
}
...
@@ -196,10 +198,15 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -196,10 +198,15 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
alipayAuthV2
((
WalletAuthInfoBean
)
result
);
alipayAuthV2
((
WalletAuthInfoBean
)
result
);
break
;
break
;
case
7
:
case
7
:
getAccountNumber
();
if
(
accountTypeSelectionDialog
!=
null
)
{
if
(
accountTypeSelectionDialog
!=
null
)
{
accountTypeSelectionDialog
.
dismiss
();
accountTypeSelectionDialog
.
dismiss
();
}
}
getAccountNumber
(
10
);
break
;
case
10
:
AccountNumberListBean
bean5
=
(
AccountNumberListBean
)
result
;
accountNumberList
=
bean5
.
getData
();
setAccountNumber
(
bean5
);
selectShow
();
selectShow
();
break
;
break
;
}
}
...
@@ -212,20 +219,14 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -212,20 +219,14 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
*/
*/
private
void
setAccountNumber
(
AccountNumberListBean
result
)
{
private
void
setAccountNumber
(
AccountNumberListBean
result
)
{
if
(
result
!=
null
&&
result
.
getData
()
!=
null
&&
result
.
getData
().
size
()
>
0
)
{
if
(
result
!=
null
&&
result
.
getData
()
!=
null
&&
result
.
getData
().
size
()
>
0
)
{
for
(
int
i
=
0
;
i
<
result
.
getData
().
size
();
i
++)
{
AccountNumberListBean
.
DataBean
dataBean
=
result
.
getData
().
get
(
0
);
if
(
1
==
result
.
getData
().
get
(
i
).
getType
())
{
selectAccountNumber
=
dataBean
;
AccountNumberListBean
.
DataBean
dataBean
=
result
.
getData
().
get
(
0
);
if
(
dataBean
.
getType
()
==
1
)
{
//1支付宝 2微信
selectAccountNumber
=
dataBean
;
ivAccountNumberIcon
.
setImageResource
(
R
.
drawable
.
common_icon_wallet_alipay_small
);
dataBean
.
setCheck
(
true
);
tvAccountNumber
.
setText
(
"支付宝余额("
+
dataBean
.
getNickname
()
+
")"
);
if
(
dataBean
.
getType
()
==
1
)
{
//1支付宝 2微信
}
else
if
(
dataBean
.
getType
()
==
0
)
{
ivAccountNumberIcon
.
setImageResource
(
R
.
drawable
.
common_icon_wallet_alipay_small
);
ivAccountNumberIcon
.
setImageResource
(
R
.
drawable
.
common_icon_wallet_weiwx_small
);
tvAccountNumber
.
setText
(
"支付宝余额("
+
dataBean
.
getNickname
()
+
")"
);
tvAccountNumber
.
setText
(
"微信零钱("
+
dataBean
.
getNickname
()
+
")"
);
}
else
if
(
dataBean
.
getType
()
==
2
)
{
ivAccountNumberIcon
.
setImageResource
(
R
.
drawable
.
common_icon_wallet_weiwx_small
);
tvAccountNumber
.
setText
(
"微信零钱("
+
dataBean
.
getNickname
()
+
")"
);
}
break
;
}
}
}
}
}
}
}
...
@@ -288,7 +289,7 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -288,7 +289,7 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
.
withInt
(
"type"
,
20
)
.
withInt
(
"type"
,
20
)
.
navigation
();
.
navigation
();
}
else
if
(
id
==
R
.
id
.
ll_item_select_account_number
)
{
}
else
if
(
id
==
R
.
id
.
ll_item_select_account_number
)
{
//
selectShow();
selectShow
();
}
}
}
}
...
@@ -307,20 +308,13 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -307,20 +308,13 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
helper
.
setText
(
R
.
id
.
tv_name1
,
"支付宝余额("
+
dataBean1
.
getNickname
()
+
")"
);
helper
.
setText
(
R
.
id
.
tv_name1
,
"支付宝余额("
+
dataBean1
.
getNickname
()
+
")"
);
helper
.
setImageResource
(
R
.
id
.
iv_icon1
,
R
.
drawable
.
common_icon_wallet_alipay
);
helper
.
setImageResource
(
R
.
id
.
iv_icon1
,
R
.
drawable
.
common_icon_wallet_alipay
);
helper
.
setText
(
R
.
id
.
tv_name3
,
"添加微信提现,绑定微信"
);
helper
.
setText
(
R
.
id
.
tv_name3
,
"添加微信提现,绑定微信"
);
}
else
if
(
dataBean1
.
getType
()
==
2
)
{
}
else
if
(
dataBean1
.
getType
()
==
0
)
{
helper
.
setText
(
R
.
id
.
tv_name1
,
"微信零钱("
+
dataBean1
.
getNickname
()
+
")"
);
helper
.
setText
(
R
.
id
.
tv_name1
,
"微信零钱("
+
dataBean1
.
getNickname
()
+
")"
);
helper
.
setImageResource
(
R
.
id
.
iv_icon1
,
R
.
drawable
.
common_icon_wallet_weiwx
);
helper
.
setImageResource
(
R
.
id
.
iv_icon1
,
R
.
drawable
.
common_icon_wallet_weiwx
);
helper
.
setText
(
R
.
id
.
tv_name3
,
"添加支付宝提现,绑定支付宝"
);
helper
.
setText
(
R
.
id
.
tv_name3
,
"添加支付宝提现,绑定支付宝"
);
isType
=
true
;
isType
=
true
;
}
}
ImageView
select1
=
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_select1
);
if
(
dataBean1
.
getCheck
())
{
select1
.
setSelected
(
true
);
}
else
{
select1
.
setSelected
(
false
);
}
helper
.
setVisible
(
R
.
id
.
ll_item_select2
,
false
);
helper
.
setVisible
(
R
.
id
.
ll_item_select2
,
false
);
helper
.
setVisible
(
R
.
id
.
ll_item_select3
,
true
);
helper
.
setVisible
(
R
.
id
.
ll_item_select3
,
true
);
...
@@ -331,61 +325,62 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -331,61 +325,62 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
if
(
dataBean2
.
getType
()
==
1
)
{
if
(
dataBean2
.
getType
()
==
1
)
{
helper
.
setText
(
R
.
id
.
tv_name2
,
"支付宝余额("
+
dataBean2
.
getNickname
()
+
")"
);
helper
.
setText
(
R
.
id
.
tv_name2
,
"支付宝余额("
+
dataBean2
.
getNickname
()
+
")"
);
helper
.
setImageResource
(
R
.
id
.
iv_icon2
,
R
.
drawable
.
common_icon_wallet_alipay
);
helper
.
setImageResource
(
R
.
id
.
iv_icon2
,
R
.
drawable
.
common_icon_wallet_alipay
);
}
else
if
(
dataBean2
.
getType
()
==
2
)
{
}
else
if
(
dataBean2
.
getType
()
==
0
)
{
helper
.
setText
(
R
.
id
.
tv_name2
,
"微信零钱("
+
dataBean2
.
getNickname
()
+
")"
);
helper
.
setText
(
R
.
id
.
tv_name2
,
"微信零钱("
+
dataBean2
.
getNickname
()
+
")"
);
helper
.
setImageResource
(
R
.
id
.
iv_icon2
,
R
.
drawable
.
common_icon_wallet_weiwx
);
helper
.
setImageResource
(
R
.
id
.
iv_icon2
,
R
.
drawable
.
common_icon_wallet_weiwx
);
}
}
ImageView
select2
=
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_select2
);
if
(
dataBean2
.
getCheck
())
{
select2
.
setSelected
(
true
);
}
else
{
select2
.
setSelected
(
false
);
}
}
}
}
}
final
ImageView
select1
=
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_select1
);
final
ImageView
select2
=
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_select2
);
if
(
selectType
)
{
select2
.
setSelected
(
true
);
}
else
{
select1
.
setSelected
(
true
);
}
helper
.
setOnClickListener
(
new
View
.
OnClickListener
()
{
helper
.
setOnClickListener
(
new
View
.
OnClickListener
()
{
@Override
@Override
public
void
onClick
(
View
v
)
{
public
void
onClick
(
View
v
)
{
int
id
=
v
.
getId
();
int
id
=
v
.
getId
();
AccountNumberListBean
.
DataBean
dataBean
=
null
;
if
(
id
==
R
.
id
.
iv_close
)
{
if
(
id
==
R
.
id
.
iv_close
)
{
dismiss
();
dismiss
();
}
else
if
(
id
==
R
.
id
.
ll_item_select1
)
{
}
else
if
(
id
==
R
.
id
.
ll_item_select1
)
{
dataBean
=
accountNumberList
.
get
(
0
);
selectDataBean
=
accountNumberList
.
get
(
0
);
ImageView
select
=
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_select1
);
select2
.
setSelected
(
false
);
if
(
dataBean
.
getCheck
())
{
select1
.
setSelected
(
true
);
select
.
setSelected
(
true
);
selectType
=
false
;
}
else
{
select
.
setSelected
(
false
);
}
}
else
if
(
id
==
R
.
id
.
ll_item_select2
)
{
}
else
if
(
id
==
R
.
id
.
ll_item_select2
)
{
dataBean
=
accountNumberList
.
get
(
1
);
selectDataBean
=
accountNumberList
.
get
(
1
);
ImageView
select
=
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_select2
);
select1
.
setSelected
(
false
);
if
(
dataBean
.
getCheck
())
{
select2
.
setSelected
(
true
);
select
.
setSelected
(
true
);
selectType
=
true
;
}
else
{
select
.
setSelected
(
false
);
}
}
else
if
(
id
==
R
.
id
.
ll_item_select3
)
{
}
else
if
(
id
==
R
.
id
.
ll_item_select3
)
{
if
(
isType
)
{
if
(
isType
)
{
//绑定支付宝
//绑定支付宝
getAuthInfo
();
getAuthInfo
();
}
else
{
}
else
{
//绑定微信
//绑定微信
if
(!
IsAppInstall
.
isWeixinAvilible
(
mActivity
))
{
if
(!
IsAppInstall
.
isWeixinAvilible
(
mActivity
))
{
showToast
(
"亲,您微信还没有安装呢"
);
showToast
(
"亲,您微信还没有安装呢"
);
return
;
return
;
}
}
bindThirdParty
(
SHARE_MEDIA
.
WEIXIN
);
bindThirdParty
(
SHARE_MEDIA
.
WEIXIN
);
}
}
dismiss
();
}
else
if
(
id
==
R
.
id
.
tv_ok
)
{
}
else
if
(
id
==
R
.
id
.
tv_ok
)
{
selectAccountNumber
=
dataBean
;
selectAccountNumber
=
selectDataBean
;
if
(
selectAccountNumber
.
getType
()
==
1
)
{
//1支付宝 2微信
ivAccountNumberIcon
.
setImageResource
(
R
.
drawable
.
common_icon_wallet_alipay_small
);
tvAccountNumber
.
setText
(
"支付宝余额("
+
selectAccountNumber
.
getNickname
()
+
")"
);
}
else
if
(
selectAccountNumber
.
getType
()
==
0
)
{
ivAccountNumberIcon
.
setImageResource
(
R
.
drawable
.
common_icon_wallet_weiwx_small
);
tvAccountNumber
.
setText
(
"微信零钱("
+
selectAccountNumber
.
getNickname
()
+
")"
);
}
dismiss
();
dismiss
();
}
}
}
}
...
@@ -418,7 +413,6 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -418,7 +413,6 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
showToast
(
"提现金额不能为空!"
);
showToast
(
"提现金额不能为空!"
);
return
;
return
;
}
}
checkWithdraw
();
checkWithdraw
();
}
}
...
@@ -473,7 +467,7 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -473,7 +467,7 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
Map
<
String
,
Object
>
headMap
=
new
LinkedHashMap
<>();
if
(
OkGoUtil
.
getToken
()
!=
null
)
if
(
OkGoUtil
.
getToken
()
!=
null
)
headMap
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
headMap
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
mPresenter
.
postBodyData
(
RvFrameConfig
.
VEHICLE_ORDER
,
4
,
WalletApi
.
HTTP_URL_WALLET_APPLYCATH
,
WithdrawBean
.
class
,
new
Withdraw
(
withdrawalAmount
,
passContent
,
selectAccountNumber
.
getTxAlipay
(),
selectAccountNumber
.
getNickname
(),
"1"
),
headMap
,
true
);
mPresenter
.
postBodyData
(
RvFrameConfig
.
VEHICLE_ORDER
,
4
,
WalletApi
.
HTTP_URL_WALLET_APPLYCATH
,
WithdrawBean
.
class
,
new
Withdraw
(
withdrawalAmount
,
passContent
,
selectAccountNumber
.
getTxAlipay
(),
selectAccountNumber
.
getNickname
(),
selectAccountNumber
.
getType
()
),
headMap
,
true
);
}
}
...
@@ -536,7 +530,22 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -536,7 +530,22 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
Map
<
String
,
Object
>
map
=
new
LinkedHashMap
<>();
Map
<
String
,
Object
>
map
=
new
LinkedHashMap
<>();
map
.
put
(
"code"
,
code
);
map
.
put
(
"code"
,
code
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
7
,
WalletApi
.
HTTP_URL_WALLET_ALIPAY_GETUSERINFO
,
BaseBean
.
class
,
map
,
headMap
,
false
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
7
,
WalletApi
.
HTTP_URL_WALLET_ALIPAY_GETUSERINFO
,
BaseBean
.
class
,
map
,
headMap
,
false
);
}
/**
* 微信绑定
*
* @param openid
* @param unionid
* @param nickName
* @param type
*/
private
void
authorize
(
String
openid
,
String
unionid
,
String
nickName
,
String
type
)
{
if
(!
TextUtils
.
isEmpty
(
OkGoUtil
.
getToken
()))
{
Map
<
String
,
String
>
heads
=
new
HashMap
<>();
heads
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
mPresenter
.
postBodyData
(
7
,
ApiConfig
.
HTTP_URL_USER_BIND
,
BaseBean
.
class
,
new
AccountBindDto
(
openid
,
unionid
,
nickName
,
type
),
heads
,
false
);
}
}
}
...
@@ -552,14 +561,17 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -552,14 +561,17 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
}
}
@Override
@Override
public
void
onComplete
(
SHARE_MEDIA
share_media
,
int
i
,
Map
<
String
,
String
>
data
)
{
public
void
onComplete
(
SHARE_MEDIA
share_media
,
int
i
,
Map
<
String
,
String
>
map
)
{
if
(
dialog
!=
null
)
{
if
(
dialog
!=
null
)
{
SocializeUtils
.
safeCloseDialog
(
dialog
);
SocializeUtils
.
safeCloseDialog
(
dialog
);
}
}
data
.
get
(
"iconurl"
);
String
type
=
share_media
.
getName
();
// mUnionid = data.get("unionid");
if
(
share_media
!=
null
&&
"wxsession"
.
equals
(
type
))
{
// 微信
// mWXOpenid = data.get("openid");
String
openid
=
map
.
get
(
"openid"
);
// mName = data.get("name");
String
unionid
=
map
.
get
(
"unionid"
);
String
nickName
=
map
.
get
(
"name"
);
authorize
(
openid
,
unionid
,
nickName
,
"wx"
);
}
}
}
...
@@ -590,10 +602,10 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -590,10 +602,10 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
private
String
amount
;
private
String
amount
;
private
String
password
;
private
String
password
;
private
String
accountNumber
;
private
String
accountNumber
;
private
String
cathType
;
private
int
cathType
;
private
String
accountName
;
private
String
accountName
;
public
Withdraw
(
String
amount
,
String
password
,
String
accountNumber
,
String
accountName
,
String
cathType
)
{
public
Withdraw
(
String
amount
,
String
password
,
String
accountNumber
,
String
accountName
,
int
cathType
)
{
this
.
amount
=
amount
;
this
.
amount
=
amount
;
this
.
password
=
password
;
this
.
password
=
password
;
this
.
accountNumber
=
accountNumber
;
this
.
accountNumber
=
accountNumber
;
...
@@ -625,11 +637,11 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -625,11 +637,11 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
this
.
accountNumber
=
accountNumber
;
this
.
accountNumber
=
accountNumber
;
}
}
public
String
getCathType
()
{
public
int
getCathType
()
{
return
cathType
;
return
cathType
;
}
}
public
void
setCathType
(
String
cathType
)
{
public
void
setCathType
(
int
cathType
)
{
this
.
cathType
=
cathType
;
this
.
cathType
=
cathType
;
}
}
...
@@ -641,4 +653,52 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
...
@@ -641,4 +653,52 @@ public class WithdrawActivity extends BaseStatusActivity<WalletPresenter> implem
this
.
accountName
=
accountName
;
this
.
accountName
=
accountName
;
}
}
}
}
private
class
AccountBindDto
{
private
String
openId
;
private
String
unionId
;
private
String
nickName
;
private
String
type
;
public
AccountBindDto
(
String
openId
,
String
unionId
,
String
nickName
,
String
type
)
{
this
.
openId
=
openId
;
this
.
unionId
=
unionId
;
this
.
nickName
=
nickName
;
this
.
type
=
type
;
}
public
String
getOpenId
()
{
return
openId
;
}
public
void
setOpenId
(
String
openId
)
{
this
.
openId
=
openId
;
}
public
String
getUnionId
()
{
return
unionId
;
}
public
void
setUnionId
(
String
unionId
)
{
this
.
unionId
=
unionId
;
}
public
String
getNickName
()
{
return
nickName
;
}
public
void
setNickName
(
String
nickName
)
{
this
.
nickName
=
nickName
;
}
public
String
getType
()
{
return
type
;
}
public
void
setType
(
String
type
)
{
this
.
type
=
type
;
}
}
}
}
plugin_wallet/src/main/java/com/xxrv/wallet/bean/AccountNumberListBean.java
View file @
8ef87adb
...
@@ -40,15 +40,6 @@ public class AccountNumberListBean extends BaseBean {
...
@@ -40,15 +40,6 @@ public class AccountNumberListBean extends BaseBean {
private
int
isDel
;
//":0,
private
int
isDel
;
//":0,
private
String
nickname
;
//":"PeakLin",
private
String
nickname
;
//":"PeakLin",
private
int
type
;
//":1
private
int
type
;
//":1
private
boolean
check
;
public
boolean
getCheck
()
{
return
check
;
}
public
void
setCheck
(
boolean
check
)
{
this
.
check
=
check
;
}
public
String
getId
()
{
public
String
getId
()
{
return
id
;
return
id
;
...
...
plugin_wallet/src/main/res/layout/rv_dialog_third_party_binding.xml
View file @
8ef87adb
...
@@ -35,21 +35,10 @@
...
@@ -35,21 +35,10 @@
android:layout_marginLeft=
"@dimen/size_15"
android:layout_marginLeft=
"@dimen/size_15"
android:layout_marginRight=
"@dimen/size_15"
android:layout_marginRight=
"@dimen/size_15"
android:layout_marginBottom=
"@dimen/size_26"
android:layout_marginBottom=
"@dimen/size_26"
android:text=
"
支持提现到支付余额,请绑定支付宝。
"
android:text=
"
提现有2种方式,提现到微信零钱或支付宝余额。需至少绑定一种方式:
"
android:textColor=
"@color/textGray"
android:textColor=
"@color/textGray"
android:textSize=
"@dimen/size_16"
/>
android:textSize=
"@dimen/size_16"
/>
<!--<TextView-->
<!--android:id="@+id/tv_content"-->
<!--android:layout_width="wrap_content"-->
<!--android:layout_height="wrap_content"-->
<!--android:layout_marginLeft="@dimen/size_15"-->
<!--android:layout_marginRight="@dimen/size_15"-->
<!--android:layout_marginBottom="@dimen/size_26"-->
<!--android:text="提现有2种方式,提现到微信零钱或支付宝余额。需至少绑定一种方式:"-->
<!--android:textColor="@color/textGray"-->
<!--android:textSize="@dimen/size_16" />-->
<LinearLayout
<LinearLayout
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
...
@@ -95,8 +84,7 @@
...
@@ -95,8 +84,7 @@
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:layout_weight=
"1"
android:gravity=
"center_horizontal"
android:gravity=
"center_horizontal"
android:orientation=
"vertical"
android:orientation=
"vertical"
>
android:visibility=
"gone"
>
<TextView
<TextView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
...
...
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