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
ad285164
Commit
ad285164
authored
Jul 20, 2019
by
linfeng
Browse files
Options
Browse Files
Download
Plain Diff
钱包
parents
3e8069aa
073956c6
Changes
16
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
607 additions
and
230 deletions
+607
-230
WelcomeActivity.java
RvClient/src/main/java/com/xxfc/rv/WelcomeActivity.java
+1
-0
ApiConfig.java
...e_home/src/main/java/com/rv/home/rv/module/ApiConfig.java
+3
-1
activity_mine.xml
module_mine/src/main/res/layout/activity_mine.xml
+24
-1
ReativeBillActivity.java
...share/src/main/java/com/rv/share/ReativeBillActivity.java
+18
-3
ShareActivity.java
plugin_share/src/main/java/com/rv/share/ShareActivity.java
+14
-8
WebViewActivity.java
plugin_share/src/main/java/com/rv/share/WebViewActivity.java
+1
-4
IncomeListAdapter.java
...src/main/java/com/rv/share/adapter/IncomeListAdapter.java
+18
-2
IncomeRecordsBean.java
...re/src/main/java/com/rv/share/bean/IncomeRecordsBean.java
+93
-110
ActivationFragment.java
...c/main/java/com/rv/share/fragment/ActivationFragment.java
+86
-3
InComeRecordFragment.java
...main/java/com/rv/share/fragment/InComeRecordFragment.java
+61
-7
InviteFragment.java
...e/src/main/java/com/rv/share/fragment/InviteFragment.java
+113
-8
BillPresenter.java
...e/src/main/java/com/rv/share/presenter/BillPresenter.java
+8
-2
activity_reative_bill.xml
plugin_share/src/main/res/layout/activity_reative_bill.xml
+103
-76
activity_share.xml
plugin_share/src/main/res/layout/activity_share.xml
+3
-3
fragment_income_record.xml
plugin_share/src/main/res/layout/fragment_income_record.xml
+9
-1
item_income.xml
plugin_share/src/main/res/layout/item_income.xml
+52
-1
No files found.
RvClient/src/main/java/com/xxfc/rv/WelcomeActivity.java
View file @
ad285164
...
@@ -51,6 +51,7 @@ public class WelcomeActivity extends BaseActivity<CommonPresenter> {
...
@@ -51,6 +51,7 @@ public class WelcomeActivity extends BaseActivity<CommonPresenter> {
public
void
onGetInfoFinish
(
String
info
)
{
public
void
onGetInfoFinish
(
String
info
)
{
// 客户端获取到的参数是json字符串格式
// 客户端获取到的参数是json字符串格式
LogUtil
.
d
(
"ShareInstall"
,
"info = "
+
info
);
LogUtil
.
d
(
"ShareInstall"
,
"info = "
+
info
);
// info ="{\"from\":\"singlemessage\",\"code\":\"qRj5igja_P0101\"}";
if
(
info
.
contains
(
"code"
))
if
(
info
.
contains
(
"code"
))
try
{
try
{
JSONObject
object
=
new
JSONObject
(
info
);
JSONObject
object
=
new
JSONObject
(
info
);
...
...
module_home/src/main/java/com/rv/home/rv/module/ApiConfig.java
View file @
ad285164
...
@@ -86,5 +86,7 @@ public class ApiConfig {
...
@@ -86,5 +86,7 @@ public class ApiConfig {
public
static
String
HTTP_URL_PERSON_SHARE_INFO
=
RvFrameConfig
.
HOST
+
"/api/admin/team/promote"
;
public
static
String
HTTP_URL_PERSON_SHARE_INFO
=
RvFrameConfig
.
HOST
+
"/api/admin/team/promote"
;
public
static
String
HTTP_URL_INCOME_RECORD
=
RvFrameConfig
.
HOST
+
"api/activity/activityPopularize/app/unauth/popularize-list"
;
public
static
String
HTTP_URL_INCOME_RECORD
=
RvFrameConfig
.
HOST
+
"/api/admin/sellingwater/page"
;
public
static
String
HTTP_URL_INVITE_LIST
=
RvFrameConfig
.
HOST
+
"/api/admin/relation/pages"
;
}
}
module_mine/src/main/res/layout/activity_mine.xml
View file @
ad285164
...
@@ -556,17 +556,40 @@
...
@@ -556,17 +556,40 @@
android:layout_alignParentBottom=
"true"
android:layout_alignParentBottom=
"true"
android:layout_centerHorizontal=
"true"
android:layout_centerHorizontal=
"true"
android:layout_marginTop=
"@dimen/size_18"
android:layout_marginTop=
"@dimen/size_18"
android:text=
"分享"
android:text=
"分享
有礼
"
android:textColor=
"@color/colorMain"
android:textColor=
"@color/colorMain"
android:textSize=
"@dimen/size_12"
/>
android:textSize=
"@dimen/size_12"
/>
</RelativeLayout>
</RelativeLayout>
<RelativeLayout
<RelativeLayout
android:id=
"@+id/rl_item_integral"
android:id=
"@+id/rl_item_integral"
android:layout_width=
"0dp"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/size_60"
android:layout_height=
"@dimen/size_60"
android:layout_weight=
"1"
android:layout_weight=
"1"
android:orientation=
"vertical"
>
android:orientation=
"vertical"
>
<ImageView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerHorizontal=
"true"
android:src=
"@drawable/mycenter_icon_visitors"
/>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignParentBottom=
"true"
android:layout_centerHorizontal=
"true"
android:layout_marginTop=
"@dimen/size_18"
android:text=
"分享"
android:textColor=
"@color/colorMain"
android:textSize=
"@dimen/size_12"
/>
</RelativeLayout>
<RelativeLayout
android:layout_width=
"0dp"
android:layout_height=
"@dimen/size_60"
android:layout_weight=
"1"
android:orientation=
"vertical"
>
<ImageView
<ImageView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
...
...
plugin_share/src/main/java/com/rv/share/ReativeBillActivity.java
View file @
ad285164
...
@@ -4,11 +4,12 @@ import android.content.Context;
...
@@ -4,11 +4,12 @@ import android.content.Context;
import
android.content.Intent
;
import
android.content.Intent
;
import
android.graphics.Bitmap
;
import
android.graphics.Bitmap
;
import
android.graphics.BitmapFactory
;
import
android.graphics.BitmapFactory
;
import
android.support.v7.app.AppCompatActivity
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.text.TextUtils
;
import
android.text.TextUtils
;
import
android.view.View
;
import
android.widget.Button
;
import
android.widget.Button
;
import
android.widget.ImageView
;
import
android.widget.ImageView
;
import
android.widget.LinearLayout
;
import
android.widget.TextView
;
import
android.widget.TextView
;
import
com.base.utils.ui.image.round.RoundImageView
;
import
com.base.utils.ui.image.round.RoundImageView
;
...
@@ -20,12 +21,14 @@ import com.ruiwenliu.wrapper.weight.TitleView;
...
@@ -20,12 +21,14 @@ import com.ruiwenliu.wrapper.weight.TitleView;
import
com.rv.component.utils.DisplayUtil
;
import
com.rv.component.utils.DisplayUtil
;
import
com.rv.component.utils.ZxingUtils
;
import
com.rv.component.utils.ZxingUtils
;
import
com.rv.home.rv.module.basic.BaseStatusActivity
;
import
com.rv.home.rv.module.basic.BaseStatusActivity
;
import
com.rv.
home.rv.module.basic.presenter.Common
Presenter
;
import
com.rv.
share.presenter.ReativeBill
Presenter
;
import
com.yuyife.okgo.OkGoUtil
;
import
com.yuyife.okgo.OkGoUtil
;
import
butterknife.BindView
;
import
butterknife.BindView
;
import
butterknife.OnClick
;
public
class
ReativeBillActivity
extends
BaseStatusActivity
<
ReativeBillPresenter
>
{
public
class
ReativeBillActivity
extends
BaseStatusActivity
<
CommonPresenter
>
{
private
String
url
;
private
String
url
;
@BindView
(
R2
.
id
.
ring_header
)
@BindView
(
R2
.
id
.
ring_header
)
RoundImageView
roundImageView
;
RoundImageView
roundImageView
;
...
@@ -37,6 +40,8 @@ public class ReativeBillActivity extends BaseStatusActivity<CommonPresenter> {
...
@@ -37,6 +40,8 @@ public class ReativeBillActivity extends BaseStatusActivity<CommonPresenter> {
Button
btnSaveBill
;
Button
btnSaveBill
;
@BindView
(
R2
.
id
.
btn_share
)
@BindView
(
R2
.
id
.
btn_share
)
Button
btnShare
;
Button
btnShare
;
@BindView
(
R2
.
id
.
ll_bill_content
)
LinearLayout
llBillContent
;
public
static
Intent
getIntent
(
Context
context
,
String
url
)
{
public
static
Intent
getIntent
(
Context
context
,
String
url
)
{
Intent
intent
=
new
Intent
(
context
,
ReativeBillActivity
.
class
);
Intent
intent
=
new
Intent
(
context
,
ReativeBillActivity
.
class
);
...
@@ -71,6 +76,16 @@ public class ReativeBillActivity extends BaseStatusActivity<CommonPresenter> {
...
@@ -71,6 +76,16 @@ public class ReativeBillActivity extends BaseStatusActivity<CommonPresenter> {
@Override
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
}
@OnClick
({
R2
.
id
.
btn_save_bill
,
R2
.
id
.
btn_share
})
public
void
onViewClicked
(
View
view
)
{
int
id
=
view
.
getId
();
if
(
id
==
R
.
id
.
btn_save_bill
)
{
mPresenter
.
saveBill
(
llBillContent
);
}
else
if
(
id
==
R
.
id
.
btn_share
)
{
mPresenter
.
saveShare
(
llBillContent
);
}
}
}
}
}
plugin_share/src/main/java/com/rv/share/ShareActivity.java
View file @
ad285164
...
@@ -10,7 +10,9 @@ import android.widget.TextView;
...
@@ -10,7 +10,9 @@ import android.widget.TextView;
import
com.base.utils.ui.datetime.selector.util.TextUtil
;
import
com.base.utils.ui.datetime.selector.util.TextUtil
;
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.util.UtilsManager
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.ruiwenliu.wrapper.weight.TitleView
;
import
com.ruiwenliu.wrapper.weight.TitleView
;
import
com.rv.component.utils.DisplayUtil
;
import
com.rv.component.utils.DisplayUtil
;
...
@@ -50,7 +52,7 @@ public class ShareActivity extends BaseStatusActivity<SharePresenter> {
...
@@ -50,7 +52,7 @@ public class ShareActivity extends BaseStatusActivity<SharePresenter> {
@BindView
(
R2
.
id
.
tv_more_detail
)
@BindView
(
R2
.
id
.
tv_more_detail
)
TextView
tvMoreDetail
;
TextView
tvMoreDetail
;
private
String
shareUrl
;
@Override
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
...
@@ -68,8 +70,9 @@ public class ShareActivity extends BaseStatusActivity<SharePresenter> {
...
@@ -68,8 +70,9 @@ public class ShareActivity extends BaseStatusActivity<SharePresenter> {
tvPersonInval
.
setText
(
data
.
getInviteNumber
()
+
"人"
);
tvPersonInval
.
setText
(
data
.
getInviteNumber
()
+
"人"
);
tvPersonUse
.
setText
(
data
.
getActivatedNumber
()
+
"人"
);
tvPersonUse
.
setText
(
data
.
getActivatedNumber
()
+
"人"
);
if
(
TextUtils
.
isEmpty
(
data
.
getLeaderHeadUrl
())
&&
TextUtil
.
isEmpty
(
data
.
getLeaderUsername
()))
{
if
(
TextUtils
.
isEmpty
(
data
.
getLeaderHeadUrl
())
&&
TextUtil
.
isEmpty
(
data
.
getLeaderUsername
()))
{
//
((View) tvParentPhone.getParent().getParent()).setVisibility(View.GONE);
((
View
)
tvParentPhone
.
getParent
().
getParent
()).
setVisibility
(
View
.
GONE
);
}
else
{
}
else
{
((
View
)
tvParentPhone
.
getParent
().
getParent
()).
setVisibility
(
View
.
VISIBLE
);
if
(!
TextUtils
.
isEmpty
(
data
.
getLeaderHeadUrl
()))
{
if
(!
TextUtils
.
isEmpty
(
data
.
getLeaderHeadUrl
()))
{
GlideManager
.
getInstance
(
getApplicationContext
()).
loadImage
(
data
.
getLeaderHeadUrl
(),
imgParent
);
GlideManager
.
getInstance
(
getApplicationContext
()).
loadImage
(
data
.
getLeaderHeadUrl
(),
imgParent
);
}
}
...
@@ -105,18 +108,21 @@ public class ShareActivity extends BaseStatusActivity<SharePresenter> {
...
@@ -105,18 +108,21 @@ public class ShareActivity extends BaseStatusActivity<SharePresenter> {
}
}
@OnClick
({
R2
.
id
.
tv_weixin
,
R2
.
id
.
tv_weixin_circle
,
R2
.
id
.
tv_bill
,
R2
.
id
.
tv_more
,
R2
.
id
.
tv_more_detail
})
@OnClick
({
R2
.
id
.
tv_weixin
,
R2
.
id
.
tv_weixin_circle
,
R2
.
id
.
tv_bill
,
R2
.
id
.
tv_more
,
R2
.
id
.
tv_more_detail
})
public
void
onViewClicked
(
View
view
)
{
public
void
onViewClicked
(
View
view
)
{
int
id
=
view
.
getId
();
int
id
=
view
.
getId
();
if
(
TextUtils
.
isEmpty
(
shareUrl
))
{
String
code
=
UtilsManager
.
getInstance
(
OkGoUtil
.
application
).
getSPInstance
(
SPConstance
.
USER_JSON
).
getString
(
SPConstance
.
USER_JSON_CODE
,
""
);
shareUrl
=
RvFrameConfig
.
HOST
+
"/h5/appHtml/view/download.html?code="
+
code
+
"_P0101"
;
}
if
(
id
==
R
.
id
.
tv_weixin
)
{
if
(
id
==
R
.
id
.
tv_weixin
)
{
mPresenter
.
shareWx
(
RvFrameConfig
.
HOST
+
"/h5/appHtml/view/download.html"
,
"【滴房车】"
,
"新人专享大礼包,快去领!"
);
mPresenter
.
shareWx
(
shareUrl
,
"【滴房车】"
,
"新人专享大礼包,快去领!"
);
}
else
if
(
id
==
R
.
id
.
tv_weixin_circle
)
{
}
else
if
(
id
==
R
.
id
.
tv_weixin_circle
)
{
mPresenter
.
shareWxC
(
RvFrameConfig
.
HOST
+
"/h5/appHtml/view/download.html"
,
"【滴房车】"
,
"新人专享大礼包,快去领!"
);
mPresenter
.
shareWxC
(
shareUrl
,
"【滴房车】"
,
"新人专享大礼包,快去领!"
);
}
else
if
(
id
==
R
.
id
.
tv_bill
)
{
}
else
if
(
id
==
R
.
id
.
tv_bill
)
{
startActivity
(
ReativeBillActivity
.
getIntent
(
this
,
RvFrameConfig
.
HOST
+
"/h5/appHtml/view/download.html"
));
startActivity
(
ReativeBillActivity
.
getIntent
(
this
,
shareUrl
));
}
else
if
(
id
==
R
.
id
.
tv_more
)
{
}
else
if
(
id
==
R
.
id
.
tv_more
)
{
mPresenter
.
shareMore
(
RvFrameConfig
.
HOST
+
"/h5/appHtml/view/download.html"
,
"【滴房车】"
,
"新人专享大礼包,快去领!"
);
mPresenter
.
shareMore
(
shareUrl
,
"【滴房车】"
,
"新人专享大礼包,快去领!"
);
}
else
if
(
id
==
R
.
id
.
tv_more_detail
)
{
}
else
if
(
id
==
R
.
id
.
tv_more_detail
)
{
startActivity
(
new
Intent
(
this
,
PopularizeActivity
.
class
));
startActivity
(
new
Intent
(
this
,
PopularizeActivity
.
class
));
}
}
...
...
plugin_share/src/main/java/com/rv/share/WebViewActivity.java
View file @
ad285164
...
@@ -9,14 +9,11 @@ import android.widget.LinearLayout;
...
@@ -9,14 +9,11 @@ import android.widget.LinearLayout;
import
android.widget.Toast
;
import
android.widget.Toast
;
import
com.base.utils.tools.android.NetworkUtil
;
import
com.base.utils.tools.android.NetworkUtil
;
import
com.ruiwenliu.wrapper.SPConstance
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.util.UtilsManager
;
import
com.ruiwenliu.wrapper.weight.TitleView
;
import
com.ruiwenliu.wrapper.weight.TitleView
;
import
com.rv.home.rv.module.basic.BaseStatusActivity
;
import
com.rv.home.rv.module.basic.BaseStatusActivity
;
import
com.rv.share.presenter.WebViewPresenter
;
import
com.rv.share.presenter.WebViewPresenter
;
import
com.rv.share.view.RvWebView
;
import
com.rv.share.view.RvWebView
;
import
com.yuyife.okgo.OkGoUtil
;
import
butterknife.BindView
;
import
butterknife.BindView
;
...
@@ -92,7 +89,7 @@ public class WebViewActivity extends BaseStatusActivity<WebViewPresenter> {
...
@@ -92,7 +89,7 @@ public class WebViewActivity extends BaseStatusActivity<WebViewPresenter> {
private
RvWebView
.
WebViewListener
listener
=
new
RvWebView
.
WebViewListener
()
{
private
RvWebView
.
WebViewListener
listener
=
new
RvWebView
.
WebViewListener
()
{
@Override
@Override
public
void
share
(
String
url
,
String
title
,
String
desc
)
{
public
void
share
(
String
url
,
String
title
,
String
desc
)
{
mPresenter
.
showShareDialog
(
url
+
UtilsManager
.
getInstance
(
OkGoUtil
.
application
).
getSPInstance
(
SPConstance
.
USER_JSON
).
getString
(
SPConstance
.
USER_JSON_CODE
,
""
)
,
title
,
desc
);
mPresenter
.
showShareDialog
(
url
,
title
,
desc
);
}
}
@Override
@Override
...
...
plugin_share/src/main/java/com/rv/share/adapter/IncomeListAdapter.java
View file @
ad285164
package
com
.
rv
.
share
.
adapter
;
package
com
.
rv
.
share
.
adapter
;
import
android.support.annotation.Nullable
;
import
android.support.annotation.Nullable
;
import
android.widget.TextView
;
import
com.base.utils.ui.image.round.RoundImageView
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.chad.library.adapter.base.BaseViewHolder
;
import
com.chad.library.adapter.base.BaseViewHolder
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.rv.component.utils.DateUtils
;
import
com.rv.home.rv.module.ui.main.home.order.bean.OrderListBean
;
import
com.rv.home.rv.module.ui.main.home.order.bean.OrderListBean
;
import
com.rv.share.R
;
import
com.rv.share.R
;
import
com.rv.share.bean.IncomeRecordsBean
;
import
com.rv.share.bean.IncomeRecordsBean
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
public
class
IncomeListAdapter
extends
BaseQuickAdapter
<
IncomeRecordsBean
.
IncomeItem
,
BaseViewHolder
>
{
public
class
IncomeListAdapter
extends
BaseQuickAdapter
<
IncomeRecordsBean
.
IncomeItem
,
BaseViewHolder
>
{
public
IncomeListAdapter
()
{
super
(
R
.
layout
.
item_income
,
null
);
public
IncomeListAdapter
(
@Nullable
List
<
IncomeRecordsBean
.
IncomeItem
>
data
)
{
super
(
R
.
layout
.
item_income
,
data
);
}
}
@Override
@Override
protected
void
convert
(
BaseViewHolder
helper
,
IncomeRecordsBean
.
IncomeItem
item
)
{
protected
void
convert
(
BaseViewHolder
helper
,
IncomeRecordsBean
.
IncomeItem
item
)
{
StringBuilder
buffer
=
new
StringBuilder
();
buffer
.
append
(
item
.
getUsername
()).
append
(
"成交"
).
append
(
item
.
getPrice
()).
append
(
"元"
);
helper
.
setText
(
R
.
id
.
tv_income_record
,
buffer
.
toString
());
helper
.
setText
(
R
.
id
.
tv_income_time
,
DateUtils
.
timestampToString1
(
item
.
getCrtTime
()));
StringBuilder
builder
=
new
StringBuilder
();
builder
.
append
(
"+"
).
append
(
item
.
getCommission
()).
append
(
"元"
);
helper
.
setText
(
R
.
id
.
tv_income_price
,
builder
.
toString
());
GlideManager
.
getInstance
(
mContext
).
loadImage
(
item
.
getHeadUrl
(),
(
RoundImageView
)
helper
.
itemView
.
findViewById
(
R
.
id
.
rimg_header
));
}
}
}
}
plugin_share/src/main/java/com/rv/share/bean/IncomeRecordsBean.java
View file @
ad285164
...
@@ -2,6 +2,7 @@ package com.rv.share.bean;
...
@@ -2,6 +2,7 @@ package com.rv.share.bean;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
java.math.BigDecimal
;
import
java.util.List
;
import
java.util.List
;
public
class
IncomeRecordsBean
extends
BaseBean
{
public
class
IncomeRecordsBean
extends
BaseBean
{
...
@@ -25,116 +26,82 @@ public class IncomeRecordsBean extends BaseBean {
...
@@ -25,116 +26,82 @@ public class IncomeRecordsBean extends BaseBean {
}
}
public
static
class
IncomeRecordData
{
public
static
class
IncomeRecordData
{
private
int
id
;
private
BigDecimal
totalIncome
;
private
long
crtTime
;
private
List
<
IncomeItem
>
sellingWaters
;
private
long
updTime
;
private
int
pageNum
;
private
String
name
;
private
int
pageSize
;
private
String
descr
;
private
int
totalCount
;
private
String
value
;
private
int
totalPage
;
private
int
progress
;
private
int
type
;
private
String
code
;
private
List
<
IncomeItem
>
items
;
public
int
getId
()
{
return
id
;
}
public
void
setId
(
int
id
)
{
this
.
id
=
id
;
}
public
long
getCrtTime
()
{
return
crtTime
;
}
public
void
setCrtTime
(
long
crtTime
)
{
this
.
crtTime
=
crtTime
;
}
public
long
getUpdTime
()
{
return
updTime
;
}
public
void
setUpdTime
(
long
updTime
)
{
this
.
updTime
=
updTime
;
}
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
String
getDescr
()
{
public
int
getPageNum
()
{
return
descr
;
return
pageNum
;
}
}
public
void
set
Descr
(
String
descr
)
{
public
void
set
PageNum
(
int
pageNum
)
{
this
.
descr
=
descr
;
this
.
pageNum
=
pageNum
;
}
}
public
String
getValu
e
()
{
public
int
getPageSiz
e
()
{
return
valu
e
;
return
pageSiz
e
;
}
}
public
void
set
Value
(
String
valu
e
)
{
public
void
set
PageSize
(
int
pageSiz
e
)
{
this
.
value
=
valu
e
;
this
.
pageSize
=
pageSiz
e
;
}
}
public
int
get
Progress
()
{
public
int
get
TotalCount
()
{
return
progress
;
return
totalCount
;
}
}
public
void
set
Progress
(
int
progress
)
{
public
void
set
TotalCount
(
int
totalCount
)
{
this
.
progress
=
progress
;
this
.
totalCount
=
totalCount
;
}
}
public
int
getT
yp
e
()
{
public
int
getT
otalPag
e
()
{
return
t
yp
e
;
return
t
otalPag
e
;
}
}
public
void
setT
ype
(
int
typ
e
)
{
public
void
setT
otalPage
(
int
totalPag
e
)
{
this
.
t
ype
=
typ
e
;
this
.
t
otalPage
=
totalPag
e
;
}
}
public
String
getCod
e
()
{
public
BigDecimal
getTotalIncom
e
()
{
return
cod
e
;
return
totalIncom
e
;
}
}
public
void
set
Code
(
String
cod
e
)
{
public
void
set
TotalIncome
(
BigDecimal
totalIncom
e
)
{
this
.
code
=
cod
e
;
this
.
totalIncome
=
totalIncom
e
;
}
}
public
List
<
IncomeItem
>
get
Item
s
()
{
public
List
<
IncomeItem
>
get
SellingWater
s
()
{
return
item
s
;
return
sellingWater
s
;
}
}
public
void
set
Items
(
List
<
IncomeItem
>
item
s
)
{
public
void
set
SellingWaters
(
List
<
IncomeItem
>
sellingWater
s
)
{
this
.
items
=
item
s
;
this
.
sellingWaters
=
sellingWater
s
;
}
}
}
}
public
static
class
IncomeItem
{
public
static
class
IncomeItem
{
private
int
id
;
private
BigDecimal
commission
;
private
long
crtTime
;
private
long
crtTime
;
private
long
updTime
;
private
int
goodNumber
;
private
String
name
;
private
String
headUrl
;
private
String
descr
;
private
String
img
;
private
int
popularizeId
;
private
String
nickName
;
private
int
progress
;
private
BigDecimal
price
;
private
int
type
;
private
int
sort
;
private
int
status
;
private
int
status
;
private
String
title
;
private
long
updTime
;
private
String
username
;
private
int
waiting
;
public
int
getId
()
{
public
BigDecimal
getCommission
()
{
return
id
;
return
commission
;
}
}
public
void
set
Id
(
int
id
)
{
public
void
set
Commission
(
BigDecimal
commission
)
{
this
.
id
=
id
;
this
.
commission
=
commission
;
}
}
public
long
getCrtTime
()
{
public
long
getCrtTime
()
{
...
@@ -145,68 +112,84 @@ public class IncomeRecordsBean extends BaseBean {
...
@@ -145,68 +112,84 @@ public class IncomeRecordsBean extends BaseBean {
this
.
crtTime
=
crtTime
;
this
.
crtTime
=
crtTime
;
}
}
public
long
getUpdTime
()
{
public
int
getGoodNumber
()
{
return
updTime
;
return
goodNumber
;
}
}
public
void
set
UpdTime
(
long
updTime
)
{
public
void
set
GoodNumber
(
int
goodNumber
)
{
this
.
updTime
=
updTime
;
this
.
goodNumber
=
goodNumber
;
}
}
public
String
get
Name
()
{
public
String
get
HeadUrl
()
{
return
name
;
return
headUrl
;
}
}
public
void
set
Name
(
String
name
)
{
public
void
set
HeadUrl
(
String
headUrl
)
{
this
.
name
=
name
;
this
.
headUrl
=
headUrl
;
}
}
public
String
get
Descr
()
{
public
String
get
Img
()
{
return
descr
;
return
img
;
}
}
public
void
set
Descr
(
String
descr
)
{
public
void
set
Img
(
String
img
)
{
this
.
descr
=
descr
;
this
.
img
=
img
;
}
}
public
int
getPopularizeId
()
{
public
String
getNickName
()
{
return
popularizeId
;
return
nickName
;
}
}
public
void
set
PopularizeId
(
int
popularizeId
)
{
public
void
set
NickName
(
String
nickName
)
{
this
.
popularizeId
=
popularizeId
;
this
.
nickName
=
nickName
;
}
}
public
int
getProgress
()
{
public
BigDecimal
getPrice
()
{
return
pr
ogress
;
return
pr
ice
;
}
}
public
void
setPr
ogress
(
int
progress
)
{
public
void
setPr
ice
(
BigDecimal
price
)
{
this
.
pr
ogress
=
progress
;
this
.
pr
ice
=
price
;
}
}
public
int
get
Type
()
{
public
int
get
Status
()
{
return
type
;
return
status
;
}
}
public
void
set
Type
(
int
type
)
{
public
void
set
Status
(
int
status
)
{
this
.
type
=
type
;
this
.
status
=
status
;
}
}
public
int
getSort
()
{
public
String
getTitle
()
{
return
sort
;
return
title
;
}
}
public
void
set
Sort
(
int
sort
)
{
public
void
set
Title
(
String
title
)
{
this
.
sort
=
sort
;
this
.
title
=
title
;
}
}
public
int
getStatus
()
{
public
long
getUpdTime
()
{
return
status
;
return
updTime
;
}
}
public
void
setStatus
(
int
status
)
{
public
void
setUpdTime
(
long
updTime
)
{
this
.
status
=
status
;
this
.
updTime
=
updTime
;
}
public
String
getUsername
()
{
return
username
;
}
public
void
setUsername
(
String
username
)
{
this
.
username
=
username
;
}
public
int
getWaiting
()
{
return
waiting
;
}
public
void
setWaiting
(
int
waiting
)
{
this
.
waiting
=
waiting
;
}
}
}
}
}
}
plugin_share/src/main/java/com/rv/share/fragment/ActivationFragment.java
View file @
ad285164
package
com
.
rv
.
share
.
fragment
;
package
com
.
rv
.
share
.
fragment
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.support.v7.widget.LinearLayoutManager
;
import
android.support.v7.widget.RecyclerView
;
import
android.text.TextUtils
;
import
android.widget.LinearLayout
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.weight.refresh.SimpleRefreshLayout
;
import
com.ruiwenliu.wrapper.weight.refresh.SimpleRefreshView
;
import
com.rv.home.rv.module.ApiConfig
;
import
com.rv.home.rv.module.basic.presenter.CommonPresenter
;
import
com.rv.home.rv.module.basic.presenter.CommonPresenter
;
import
com.rv.share.R
;
import
com.rv.share.R
;
import
com.rv.share.R2
;
import
com.rv.share.adapter.ActivationListAdapter
;
import
com.rv.share.adapter.InviteListAdapter
;
import
com.rv.share.bean.InviteListBean
;
import
com.yuyife.okgo.OkGoUtil
;
public
class
ActivationFragment
extends
BaseFragment
<
CommonPresenter
>
{
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.Map
;
import
butterknife.BindView
;
public
class
ActivationFragment
extends
BaseFragment
<
CommonPresenter
>
implements
BaseQuickAdapter
.
RequestLoadMoreListener
,
SimpleRefreshLayout
.
OnSimpleRefreshListener
{
@BindView
(
R2
.
id
.
recyclerView
)
RecyclerView
recyclerView
;
@BindView
(
R2
.
id
.
refresh
)
SimpleRefreshLayout
refreshLayout
;
private
ActivationListAdapter
adapter
;
private
int
currentPage
=
1
;
private
int
pageSize
=
10
;
private
int
pageTotal
=
0
;
public
static
ActivationFragment
getInstance
()
{
public
static
ActivationFragment
getInstance
()
{
ActivationFragment
fragment
=
new
ActivationFragment
();
ActivationFragment
fragment
=
new
ActivationFragment
();
...
@@ -16,21 +47,73 @@ public class ActivationFragment extends BaseFragment<CommonPresenter> {
...
@@ -16,21 +47,73 @@ public class ActivationFragment extends BaseFragment<CommonPresenter> {
@Override
@Override
public
int
getViewLayout
()
{
public
int
getViewLayout
()
{
return
R
.
layout
.
fragment_
activation
;
return
R
.
layout
.
fragment_
income_record
;
}
}
@Override
@Override
protected
void
initView
(
Bundle
savedInstanceState
)
{
protected
void
initView
(
Bundle
savedInstanceState
)
{
recyclerView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
(),
LinearLayout
.
VERTICAL
,
false
));
adapter
=
new
ActivationListAdapter
(
new
ArrayList
<
InviteListBean
.
inviteMember
>());
adapter
.
setOnLoadMoreListener
(
this
,
recyclerView
);
refreshLayout
.
setHeaderView
(
new
SimpleRefreshView
(
getContext
()));
refreshLayout
.
setOnSimpleRefreshListener
(
this
);
recyclerView
.
setAdapter
(
adapter
);
}
}
@Override
@Override
protected
void
loadData
(
Bundle
savedInstanceState
)
{
protected
void
loadData
(
Bundle
savedInstanceState
)
{
getActivationData
();
}
}
@Override
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
if
(
requestType
==
0
)
{
InviteListBean
bean
=
(
InviteListBean
)
result
;
if
(
bean
.
isRel
()
&&
bean
.
getData
()
!=
null
&&
bean
.
getData
().
getInviteMembers
()
!=
null
)
{
if
(
currentPage
==
1
)
{
pageTotal
=
bean
.
getData
().
getTotalPage
();
refreshLayout
.
onRefreshComplete
();
if
(
bean
.
getData
().
getInviteMembers
().
size
()
==
0
)
{
adapter
.
setEmptyView
(
getEmptyView
(
recyclerView
,
-
1
,
getString
(
R
.
string
.
rv_select_not_data
)));
adapter
.
notifyDataSetChanged
();
}
else
{
adapter
.
setNewData
(
bean
.
getData
().
getInviteMembers
());
}
}
else
{
adapter
.
addData
(
bean
.
getData
().
getInviteMembers
());
adapter
.
loadMoreComplete
();
}
}
}
}
private
void
getActivationData
()
{
if
(!
TextUtils
.
isEmpty
(
OkGoUtil
.
getToken
()))
{
Map
<
String
,
Object
>
header
=
new
HashMap
<>();
header
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"state"
,
1
);
map
.
put
(
"page"
,
currentPage
);
map
.
put
(
"limit"
,
pageSize
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
0
,
ApiConfig
.
HTTP_URL_INVITE_LIST
,
InviteListBean
.
class
,
map
,
header
,
true
);
}
}
@Override
public
void
onLoadMoreRequested
()
{
if
(
currentPage
>=
pageTotal
)
{
adapter
.
loadMoreEnd
();
}
else
{
currentPage
++;
getActivationData
();
}
}
@Override
public
void
onRefresh
()
{
currentPage
=
1
;
getActivationData
();
}
}
}
}
plugin_share/src/main/java/com/rv/share/fragment/InComeRecordFragment.java
View file @
ad285164
package
com
.
rv
.
share
.
fragment
;
package
com
.
rv
.
share
.
fragment
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.support.v7.widget.LinearLayoutManager
;
import
android.support.v7.widget.RecyclerView
;
import
android.text.TextUtils
;
import
android.text.TextUtils
;
import
android.widget.LinearLayout
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.google.gson.Gson
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.weight.refresh.SimpleRefreshLayout
;
import
com.ruiwenliu.wrapper.weight.refresh.SimpleRefreshView
;
import
com.rv.home.rv.module.ApiConfig
;
import
com.rv.home.rv.module.ApiConfig
;
import
com.rv.home.rv.module.basic.presenter.CommonPresenter
;
import
com.rv.home.rv.module.basic.presenter.CommonPresenter
;
import
com.rv.share.R
;
import
com.rv.share.R
;
import
com.rv.share.R2
;
import
com.rv.share.adapter.IncomeListAdapter
;
import
com.rv.share.bean.IncomeRecordsBean
;
import
com.rv.share.bean.IncomeRecordsBean
;
import
com.yuyife.okgo.OkGoUtil
;
import
com.yuyife.okgo.OkGoUtil
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.Map
;
import
java.util.Map
;
public
class
InComeRecordFragment
extends
BaseFragment
<
CommonPresenter
>
{
import
butterknife.BindView
;
public
class
InComeRecordFragment
extends
BaseFragment
<
CommonPresenter
>
implements
BaseQuickAdapter
.
RequestLoadMoreListener
,
SimpleRefreshLayout
.
OnSimpleRefreshListener
{
@BindView
(
R2
.
id
.
recyclerView
)
RecyclerView
recyclerView
;
@BindView
(
R2
.
id
.
refresh
)
SimpleRefreshLayout
refreshLayout
;
private
IncomeListAdapter
adapter
;
private
int
currentPage
=
1
;
private
int
pageSize
=
10
;
private
int
pageTotal
=
0
;
public
static
InComeRecordFragment
getInstance
()
{
public
static
InComeRecordFragment
getInstance
()
{
InComeRecordFragment
fragment
=
new
InComeRecordFragment
();
InComeRecordFragment
fragment
=
new
InComeRecordFragment
();
...
@@ -29,14 +52,17 @@ public class InComeRecordFragment extends BaseFragment<CommonPresenter> {
...
@@ -29,14 +52,17 @@ public class InComeRecordFragment extends BaseFragment<CommonPresenter> {
@Override
@Override
protected
void
initView
(
Bundle
savedInstanceState
)
{
protected
void
initView
(
Bundle
savedInstanceState
)
{
recyclerView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
(),
LinearLayout
.
VERTICAL
,
false
));
adapter
=
new
IncomeListAdapter
(
new
ArrayList
<
IncomeRecordsBean
.
IncomeItem
>());
adapter
.
setOnLoadMoreListener
(
this
,
recyclerView
);
refreshLayout
.
setHeaderView
(
new
SimpleRefreshView
(
getContext
()));
refreshLayout
.
setOnSimpleRefreshListener
(
this
);
recyclerView
.
setAdapter
(
adapter
);
}
}
@Override
@Override
protected
void
loadData
(
Bundle
savedInstanceState
)
{
protected
void
loadData
(
Bundle
savedInstanceState
)
{
getIncomeData
();
getIncomeData
();
}
}
private
void
getIncomeData
()
{
private
void
getIncomeData
()
{
...
@@ -45,7 +71,8 @@ public class InComeRecordFragment extends BaseFragment<CommonPresenter> {
...
@@ -45,7 +71,8 @@ public class InComeRecordFragment extends BaseFragment<CommonPresenter> {
header
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
header
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"code"
,
"0101"
);
map
.
put
(
"pageNo"
,
currentPage
);
map
.
put
(
"pageSize"
,
pageSize
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
0
,
ApiConfig
.
HTTP_URL_INCOME_RECORD
,
IncomeRecordsBean
.
class
,
map
,
header
,
true
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
0
,
ApiConfig
.
HTTP_URL_INCOME_RECORD
,
IncomeRecordsBean
.
class
,
map
,
header
,
true
);
}
}
}
}
...
@@ -54,10 +81,37 @@ public class InComeRecordFragment extends BaseFragment<CommonPresenter> {
...
@@ -54,10 +81,37 @@ public class InComeRecordFragment extends BaseFragment<CommonPresenter> {
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
if
(
requestType
==
0
)
{
if
(
requestType
==
0
)
{
IncomeRecordsBean
bean
=
(
IncomeRecordsBean
)
result
;
IncomeRecordsBean
bean
=
(
IncomeRecordsBean
)
result
;
if
(
bean
.
isRel
()
&&
bean
.
getData
()
!=
null
)
{
if
(
bean
.
isRel
()
&&
bean
.
getData
()
!=
null
&&
bean
.
getData
().
getSellingWaters
()
!=
null
)
{
if
(
currentPage
==
1
)
{
pageTotal
=
bean
.
getData
().
getTotalPage
();
adapter
.
setNewData
(
bean
.
getData
().
getSellingWaters
());
refreshLayout
.
onRefreshComplete
();
if
(
bean
.
getData
().
getSellingWaters
().
size
()
==
0
)
{
adapter
.
setEmptyView
(
getEmptyView
(
recyclerView
,
-
1
,
getString
(
R
.
string
.
rv_select_not_data
)));
adapter
.
notifyDataSetChanged
();
}
}
else
{
adapter
.
addData
(
bean
.
getData
().
getSellingWaters
());
adapter
.
loadMoreComplete
();
}
}
}
}
}
}
@Override
public
void
onLoadMoreRequested
()
{
if
(
currentPage
>=
pageTotal
)
{
adapter
.
loadMoreEnd
();
}
else
{
currentPage
++;
getIncomeData
();
}
}
@Override
public
void
onRefresh
()
{
currentPage
=
1
;
getIncomeData
();
}
}
}
}
plugin_share/src/main/java/com/rv/share/fragment/InviteFragment.java
View file @
ad285164
package
com
.
rv
.
share
.
fragment
;
package
com
.
rv
.
share
.
fragment
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.support.v7.widget.LinearLayoutManager
;
import
android.support.v7.widget.RecyclerView
;
import
android.text.TextUtils
;
import
android.widget.LinearLayout
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.frame.rv.config.RvFrameConfig
;
import
com.google.gson.Gson
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.weight.refresh.SimpleRefreshLayout
;
import
com.ruiwenliu.wrapper.weight.refresh.SimpleRefreshView
;
import
com.rv.home.rv.module.ApiConfig
;
import
com.rv.home.rv.module.basic.presenter.CommonPresenter
;
import
com.rv.home.rv.module.basic.presenter.CommonPresenter
;
import
com.rv.share.R
;
import
com.rv.share.R
;
import
com.rv.share.R2
;
import
com.rv.share.adapter.InviteListAdapter
;
import
com.rv.share.bean.InviteListBean
;
import
com.yuyife.okgo.OkGoUtil
;
public
class
InviteFragment
extends
BaseFragment
<
CommonPresenter
>
{
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.Map
;
import
butterknife.BindView
;
public
class
InviteFragment
extends
BaseFragment
<
CommonPresenter
>
implements
BaseQuickAdapter
.
RequestLoadMoreListener
,
SimpleRefreshLayout
.
OnSimpleRefreshListener
{
@BindView
(
R2
.
id
.
recyclerView
)
RecyclerView
recyclerView
;
@BindView
(
R2
.
id
.
refresh
)
SimpleRefreshLayout
refreshLayout
;
private
InviteListAdapter
adapter
;
private
int
currentPage
=
1
;
private
int
pageSize
=
10
;
private
int
pageTotal
=
0
;
private
long
failureTime
;
public
static
InviteFragment
getInstance
()
{
public
static
InviteFragment
getInstance
()
{
InviteFragment
fragment
=
new
InviteFragment
();
InviteFragment
fragment
=
new
InviteFragment
();
...
@@ -16,27 +48,100 @@ public class InviteFragment extends BaseFragment<CommonPresenter> {
...
@@ -16,27 +48,100 @@ public class InviteFragment extends BaseFragment<CommonPresenter> {
@Override
@Override
public
int
getViewLayout
()
{
public
int
getViewLayout
()
{
return
R
.
layout
.
fragment_in
vite
;
return
R
.
layout
.
fragment_in
come_record
;
}
}
@Override
@Override
protected
void
initView
(
Bundle
savedInstanceState
)
{
protected
void
initView
(
Bundle
savedInstanceState
)
{
recyclerView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
(),
LinearLayout
.
VERTICAL
,
false
));
adapter
=
new
InviteListAdapter
(
new
ArrayList
<
InviteListBean
.
inviteMember
>());
adapter
.
setOnLoadMoreListener
(
this
,
recyclerView
);
refreshLayout
.
setHeaderView
(
new
SimpleRefreshView
(
getContext
()));
refreshLayout
.
setOnSimpleRefreshListener
(
this
);
recyclerView
.
setAdapter
(
adapter
);
}
}
@Override
@Override
protected
void
loadData
(
Bundle
savedInstanceState
)
{
protected
void
loadData
(
Bundle
savedInstanceState
)
{
getIn
com
eData
();
getIn
vit
eData
();
}
}
@Override
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
if
(
requestType
==
0
)
{
InviteListBean
bean
=
(
InviteListBean
)
result
;
if
(
bean
.
isRel
()
&&
bean
.
getData
()
!=
null
&&
bean
.
getData
().
getInviteMembers
()
!=
null
)
{
if
(
currentPage
==
1
)
{
failureTime
=
bean
.
getData
().
getFailureTime
();
pageTotal
=
bean
.
getData
().
getTotalPage
();
refreshLayout
.
onRefreshComplete
();
if
(
bean
.
getData
().
getInviteMembers
().
size
()
==
0
)
{
adapter
.
setEmptyView
(
getEmptyView
(
recyclerView
,
-
1
,
getString
(
R
.
string
.
rv_select_not_data
)));
adapter
.
notifyDataSetChanged
();
}
else
{
adapter
.
setEffTime
(
failureTime
*
1000
);
adapter
.
setNewData
(
bean
.
getData
().
getInviteMembers
());
}
}
else
{
adapter
.
addData
(
bean
.
getData
().
getInviteMembers
());
adapter
.
loadMoreComplete
();
}
}
}
}
//
// private void getInviteData() {
// String result = "{\"status\":200,\"message\":\"Success\",\"data\":{\"failureTime\":5184000,\"inviteMembers\":[ {\n" +
// " \"username\": \"15814005696\",\n" +
// " \"headUrl\": \"https://xxtest.upyuns.com/image/app/default_%20avatar.png\",\n" +
// " \"joinTime\": 1562402775992,\n" +
// " \"bindTime\": 1562402775992\n" +
// " },\n" +
// " {\n" +
// " \"username\": \"18552854696\",\n" +
// " \"headUrl\": \"https://xxtest.upyuns.com/image/app/default_%20avatar.png\",\n" +
// " \"joinTime\": 1563346993152,\n" +
// " \"bindTime\": 1563346993152\n" +
// " },\n" +
// " {\n" +
// " \"username\": \"17612025866\",\n" +
// " \"headUrl\": \"http://thirdwx.qlogo.cn/mmopen/vi_32/IEiawcHX9Y3HpqxALj6cFL7WSc8UxH7BDIHUf9gthntPdM7Ly0xnZ6sVpXic281kPb1w3oTHVbosTjc7z7Ef7naQ/132\",\n" +
// " \"joinTime\": 1563346993152,\n" +
// " \"bindTime\": 1563346993152\n" +
// " }],\"page\":1,\"limit\":10},\"rel\":true}";
// InviteListBean bean = new Gson().fromJson(result, InviteListBean.class);
// onShowResult(0, bean);
// }
private
void
getInviteData
()
{
if
(!
TextUtils
.
isEmpty
(
OkGoUtil
.
getToken
()))
{
Map
<
String
,
Object
>
header
=
new
HashMap
<>();
header
.
put
(
"Authorization"
,
OkGoUtil
.
getToken
());
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"state"
,
2
);
map
.
put
(
"page"
,
currentPage
);
map
.
put
(
"limit"
,
pageSize
);
mPresenter
.
getData
(
RvFrameConfig
.
HOST
,
0
,
ApiConfig
.
HTTP_URL_INVITE_LIST
,
InviteListBean
.
class
,
map
,
header
,
true
);
}
}
}
/*****
@Override
* 获取收益记录记录
public
void
onLoadMoreRequested
()
{
*/
private
void
getIncomeData
()
{
if
(
currentPage
>=
pageTotal
)
{
adapter
.
loadMoreEnd
();
}
else
{
currentPage
++;
getInviteData
();
}
}
@Override
public
void
onRefresh
()
{
currentPage
=
1
;
getInviteData
();
}
}
}
}
plugin_share/src/main/java/com/rv/share/presenter/BillPresenter.java
View file @
ad285164
...
@@ -171,13 +171,19 @@ public class BillPresenter extends CommonPresenter {
...
@@ -171,13 +171,19 @@ public class BillPresenter extends CommonPresenter {
shareDeal
();
shareDeal
();
}
}
if
(
image
!=
null
)
{
if
(
image
!=
null
)
{
share
(
SHARE_MEDIA
.
WEIXIN
,
image
,
"
hello
"
);
share
(
SHARE_MEDIA
.
WEIXIN
,
image
,
""
);
}
}
}
}
@Override
@Override
public
void
wxCShare
()
{
public
void
wxCShare
()
{
share
(
SHARE_MEDIA
.
WEIXIN_CIRCLE
,
"hello"
);
if
(
image
==
null
)
{
shareDeal
();
}
if
(
image
!=
null
)
{
share
(
SHARE_MEDIA
.
WEIXIN_CIRCLE
,
image
,
""
);
}
}
}
@Override
@Override
...
...
plugin_share/src/main/res/layout/activity_reative_bill.xml
View file @
ad285164
...
@@ -4,114 +4,141 @@
...
@@ -4,114 +4,141 @@
xmlns:tools=
"http://schemas.android.com/tools"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_height=
"match_parent"
android:background=
"#FEE8C3"
android:orientation=
"vertical"
android:orientation=
"vertical"
android:weightSum=
"19"
tools:context=
".ReativeBillActivity"
>
tools:context=
".ReativeBillActivity"
>
<ImageView
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/size_140"
android:scaleType=
"fitXY"
android:src=
"@drawable/bg_bill"
/>
<LinearLayout
<LinearLayout
android:id=
"@+id/ll_bill_content"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"
match_parent
"
android:layout_height=
"
0dp
"
android:
background=
"#FEE8C3
"
android:
layout_weight=
"17
"
android:orientation=
"vertical"
android:orientation=
"vertical"
android:padding=
"@dimen/dp_10"
android:weightSum=
"17"
>
android:weightSum=
"15"
>
<
android.support.v7.widget.CardView
<
LinearLayout
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_height=
"0dp"
android:layout_weight=
"11"
android:layout_weight=
"15"
android:background=
"@color/white"
android:orientation=
"vertical"
>
app:cardCornerRadius=
"@dimen/size_10"
>
<
LinearLayout
<
ImageView
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_height=
"@dimen/size_140"
android:gravity=
"center"
android:scaleType=
"fitXY"
android:orientation=
"vertical"
>
android:src=
"@drawable/bg_bill"
/>
<android.support.v7.widget.CardView
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_marginLeft=
"@dimen/dp_10"
android:layout_marginTop=
"@dimen/dp_10"
android:layout_marginRight=
"@dimen/dp_10"
android:layout_weight=
"1"
android:background=
"@color/white"
app:cardCornerRadius=
"@dimen/size_10"
>
<LinearLayout
<LinearLayout
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_cont
ent"
android:layout_height=
"
match_par
ent"
android:gravity=
"center"
android:gravity=
"center"
android:orientation=
"
horizont
al"
>
android:orientation=
"
vertic
al"
>
<com.base.utils.ui.image.round.RoundImageView
<LinearLayout
android:id=
"@+id/ring_header"
android:layout_width=
"match_parent"
android:layout_width=
"@dimen/dp_40"
android:layout_height=
"wrap_content"
android:layout_height=
"@dimen/dp_40"
/>
android:gravity=
"center"
android:orientation=
"horizontal"
>
<com.base.utils.ui.image.round.RoundImageView
android:id=
"@+id/ring_header"
android:layout_width=
"@dimen/dp_40"
android:layout_height=
"@dimen/dp_40"
/>
<TextView
android:id=
"@+id/tv_phone"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"@dimen/size_3"
android:text=
"155****5918 邀请你一起参与"
android:textColor=
"@color/gray_707070"
android:textSize=
"@dimen/sp_12"
/>
</LinearLayout>
<ImageView
android:id=
"@+id/img_qrcode"
android:layout_width=
"@dimen/size_150"
android:layout_height=
"@dimen/size_150"
/>
<TextView
<TextView
android:id=
"@+id/tv_phone"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"@dimen/size_3"
android:layout_marginTop=
"@dimen/size_8"
android:text=
"155****5918 邀请你一起参与"
android:text=
"长按识别二维码领奖励"
android:textColor=
"@color/gray_707070"
android:textSize=
"@dimen/sp_14"
/>
android:textSize=
"@dimen/sp_12"
/>
</LinearLayout>
<ImageView
android:id=
"@+id/img_qrcode"
android:layout_width=
"@dimen/size_150"
android:layout_height=
"@dimen/size_150"
/>
<TextView
</LinearLayout>
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/size_8"
android:text=
"长按识别二维码领奖励"
android:textSize=
"@dimen/sp_14"
/>
</
LinearLayout
>
</
android.support.v7.widget.CardView
>
</
android.support.v7.widget.CardView
>
</
LinearLayout
>
<
Linear
Layout
<
Relative
Layout
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_height=
"0dp"
android:layout_weight=
"4"
android:layout_weight=
"2"
>
android:gravity=
"center_horizontal|bottom"
>
<LinearLayout
<ImageView
android:layout_width=
"match_parent"
android:layout_width=
"@dimen/size_80"
android:layout_height=
"wrap_content"
android:layout_height=
"@dimen/size_40"
android:layout_marginLeft=
"@dimen/size_10"
android:layout_alignParentBottom=
"true"
android:layout_marginRight=
"@dimen/size_10"
android:layout_centerHorizontal=
"true"
android:orientation=
"horizontal"
>
android:src=
"@drawable/icon_reative_bill"
/>
</RelativeLayout>
<Button
android:id=
"@+id/btn_save_bill"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/dp_40"
android:layout_weight=
"1"
android:background=
"@drawable/bg_btn_bill_save"
android:gravity=
"center"
android:text=
"保存海报"
android:textColor=
"@color/colorYellow"
android:textSize=
"@dimen/sp_16"
/>
<Button
android:id=
"@+id/btn_share"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/dp_40"
android:layout_marginLeft=
"@dimen/size_10"
android:layout_weight=
"1"
android:background=
"@drawable/bg_bill_share"
android:gravity=
"center"
android:text=
"分享朋友圈"
android:textColor=
"@color/white"
android:textSize=
"@dimen/sp_16"
/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_weight=
"2"
android:gravity=
"center_horizontal|top"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:gravity=
"center_vertical"
android:layout_marginLeft=
"@dimen/size_10"
android:layout_marginRight=
"@dimen/size_10"
android:orientation=
"horizontal"
>
<Button
android:id=
"@+id/btn_save_bill"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/dp_40"
android:layout_weight=
"1"
android:background=
"@drawable/bg_btn_bill_save"
android:gravity=
"center"
android:text=
"保存海报"
android:textColor=
"@color/colorYellow"
android:textSize=
"@dimen/sp_16"
/>
<Button
android:id=
"@+id/btn_share"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/dp_40"
android:layout_marginLeft=
"@dimen/size_10"
android:layout_weight=
"1"
android:background=
"@drawable/bg_bill_share"
android:gravity=
"center"
android:text=
"分享朋友圈"
android:textColor=
"@color/white"
android:textSize=
"@dimen/sp_16"
/>
</LinearLayout>
</LinearLayout>
</LinearLayout>
</LinearLayout>
...
...
plugin_share/src/main/res/layout/activity_share.xml
View file @
ad285164
...
@@ -159,7 +159,7 @@
...
@@ -159,7 +159,7 @@
android:id=
"@+id/tv_amount"
android:id=
"@+id/tv_amount"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"
1
0元"
/>
android:text=
"0元"
/>
<TextView
<TextView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
...
@@ -188,7 +188,7 @@
...
@@ -188,7 +188,7 @@
android:id=
"@+id/tv_person_inval"
android:id=
"@+id/tv_person_inval"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"
1
0人"
/>
android:text=
"0人"
/>
<TextView
<TextView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
...
@@ -217,7 +217,7 @@
...
@@ -217,7 +217,7 @@
android:id=
"@+id/tv_person_use"
android:id=
"@+id/tv_person_use"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"
1
0人"
/>
android:text=
"0人"
/>
<TextView
<TextView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
...
...
plugin_share/src/main/res/layout/fragment_income_record.xml
View file @
ad285164
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<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=
"match_parent"
>
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<View
android:layout_width=
"match_parent"
android:layout_height=
"8dp"
android:background=
"@color/white"
/>
<include
layout=
"@layout/common_refresh"
/>
</LinearLayout>
</LinearLayout>
plugin_share/src/main/res/layout/item_income.xml
View file @
ad285164
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<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=
"@dimen/size_50"
>
android:layout_height=
"@dimen/size_60"
android:gravity=
"center"
>
<RelativeLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_marginLeft=
"@dimen/size_10"
android:layout_marginTop=
"@dimen/size_5"
android:layout_marginRight=
"@dimen/size_10"
android:layout_marginBottom=
"@dimen/size_5"
android:background=
"@drawable/bg_income_item"
>
<com.base.utils.ui.image.round.RoundImageView
android:id=
"@+id/rimg_header"
android:layout_width=
"@dimen/size_30"
android:layout_height=
"@dimen/size_30"
android:layout_alignParentLeft=
"true"
android:layout_centerVertical=
"true"
android:layout_marginLeft=
"@dimen/size_5"
/>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"match_parent"
android:layout_marginLeft=
"@dimen/size_5"
android:layout_toRightOf=
"@id/rimg_header"
android:gravity=
"center_vertical"
android:orientation=
"vertical"
>
<TextView
android:id=
"@+id/tv_income_record"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"@dimen/sp_14"
/>
<TextView
android:id=
"@+id/tv_income_time"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textColor=
"@color/colorGray"
android:textSize=
"@dimen/text_10"
/>
</LinearLayout>
<TextView
android:id=
"@+id/tv_income_price"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"@dimen/text_10"
android:textColor=
"@color/gray_707070"
android:textSize=
"@dimen/sp_14"
/>
</RelativeLayout>
</LinearLayout>
</LinearLayout>
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