Commit fb03f606 authored by jyx's avatar jyx

我的,邀请页面接口对接

parent 52a3949f
......@@ -15,10 +15,14 @@
<uses-permission android:name="android.permission.WRITE_SETTINGS" />
<uses-permission android:name="android.permission.READ_CONTACTS" />
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />
<uses-permission android:name="android.permission.PACKAGE_USAGE_STATS"
<uses-permission
android:name="android.permission.PACKAGE_USAGE_STATS"
tools:ignore="ProtectedPermissions" />
<permission android:name="com.mints.goodmoney.permission.JPUSH_MESSAGE"
<permission
android:name="com.mints.goodmoney.permission.JPUSH_MESSAGE"
android:protectionLevel="signature" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<uses-permission android:name="com.mints.goodmoney.permission.JPUSH_MESSAGE" />
<uses-permission android:name="android.permission.RECEIVE_USER_PRESENT" />
......@@ -108,12 +112,13 @@
android:screenOrientation="portrait" />
<activity
android:name=".ui.activitys.SettingsActivity"
android:screenOrientation="portrait"/>
<activity android:name=".ui.activitys.GuideActivity"/>
<activity android:name=".ui.activitys.LiebaoGameActivity"/>
<activity android:name=".ui.activitys.DrawcashActivity"/>
<activity android:name=".ui.activitys.WaterActivity"/>
<activity android:name=".ui.activitys.WalkActivity"/>
android:screenOrientation="portrait" />
<activity android:name=".ui.activitys.GuideActivity" />
<activity android:name=".ui.activitys.LiebaoGameActivity" />
<activity android:name=".ui.activitys.DrawcashActivity" />
<activity android:name=".ui.activitys.WaterActivity" />
<activity android:name=".ui.activitys.WalkActivity" />
<activity android:name=".ui.activitys.AboutusActivity" />
<service
android:name=".service.UpdateService"
......
......@@ -8,15 +8,11 @@ import android.text.TextUtils
import cn.jpush.android.api.BasicPushNotificationBuilder
import cn.jpush.android.api.JPushInterface
import com.mints.goodmoney.common.Constant
import com.mints.goodmoney.manager.LiebaoManager
import com.mints.goodmoney.manager.OaidManager
import com.mints.goodmoney.manager.ShumeiManager
import com.mints.library.utils.CommonUtils
import com.mob.MobSDK
import com.orhanobut.logger.AndroidLogAdapter
import com.orhanobut.logger.FormatStrategy
import com.orhanobut.logger.Logger
import com.orhanobut.logger.PrettyFormatStrategy
import com.orhanobut.logger.*
import com.tendcloud.tenddata.TCAgent
import com.umeng.commonsdk.UMConfigure
import com.yilan.sdk.ui.YLUIInit
......
......@@ -91,6 +91,7 @@ object Constant {
const val CARRIER_DAILY_TURN = "DAILY_TURN" //每日大转盘
const val CARRIER_CHALLENGE_TURN = "CHALLENGE_TURN" //挑战大转盘
const val CARRIER_SIGNIN_HOMEPAGE_CARD = "SIGNIN_HOMEPAGE_CARD" //签到翻倍
const val CARRIER_SIGNIN_HOMEPAGE_AWARD = "SIGNIN_HOMEPAGE_AWARD" //签到奖励
const val CARRIER_OFFLINE_DOUBLE = "OFFLINE_DOUBLE" //离线收益
const val CARRIER_CHALLENGE_CARD = "CHALLENGE_CARD" //挑战刮刮乐
const val CARRIER_ONLINE_INCOME = "ONLINE_INCOME" //在线收益
......@@ -125,9 +126,13 @@ object Constant {
const val CARRIER_CHALLENGE_HEALTH_STAND = "CHALLENGE_HEALTH_STAND" //小健康-站一站
const val CARRIER_CHALLENGE_HEALTH_FRUIT = "CHALLENGE_HEALTH_FRUIT" //小健康-吃水果
const val CARRIER_CHALLENGE_HEALTH_EYE = "CHALLENGE_HEALTH_EYE" //小健康-放松眼
const val CARRIER_FRIENDS = "CARRIER_FRIENDS" //邀请好友
const val CARRIER_NEW_USER = "CARRIER_NEW_USER" //新用户5000红包
// 邀请好友
const val CHALLENGE_SHAREFRIEND = "CHALLENGE_SHAREFRIEND" //邀请好友
const val AD_SOURCE_LY = "LIYAN"
const val AD_SOURCE_CSJ = "CSJ"
......@@ -174,4 +179,9 @@ object Constant {
const val EVENT_TYPE_TIME = "TIME"
const val EVENT_TYPE_ADCLICK = "GAME_AD_CLICK"
const val EVENT_TYPE_GAMEINFO = "GAMEINFO"
// 热门活动类型
const val HOT_ACTIVITY_WATER = "water"
const val HOT_ACTIVITY_WALK = "walk"
const val HOT_ACTIVITY_CARD = "card"
}
\ No newline at end of file
package com.mints.goodmoney.mvp.model;
import java.util.List;
public class FriendsTaskBean {
/**
* challenge : {"complete":0,"list":[{"button":"去邀请","rewardCoin":100,"title":"任务一","remarks":"邀请1个好友 (0/1)","status":0},{"button":"去邀请","rewardCoin":200,"title":"任务二","remarks":"邀请5个好友 (0/5)","status":0},{"button":"去邀请","rewardCoin":300,"title":"任务三","remarks":"邀请10个好友 (0/10)","status":0},{"button":"去邀请","rewardCoin":400,"title":"任务四","remarks":"邀请20个好友 (0/20)","status":0},{"button":"去邀请","rewardCoin":500,"title":"任务五","remarks":"邀请50个好友 (0/50)","status":0},{"button":"去邀请","rewardCoin":600,"title":"任务六","remarks":"邀请100个好友 (0/100)","status":0}]}
* friends : {"friendSum":1,"list":[{"head":"","rcoin":0,"nickName":"","mobile":"186****1554","ruid":2028614250701500000,"time":"10月14日","cashout":0}]}
*/
private ChallengeBean challenge;
private FriendsBean friends;
public ChallengeBean getChallenge() {
return challenge;
}
public void setChallenge(ChallengeBean challenge) {
this.challenge = challenge;
}
public FriendsBean getFriends() {
return friends;
}
public void setFriends(FriendsBean friends) {
this.friends = friends;
}
public static class ChallengeBean {
/**
* complete : 0
* list : [{"button":"去邀请","rewardCoin":100,"title":"任务一","remarks":"邀请1个好友 (0/1)","status":0},{"button":"去邀请","rewardCoin":200,"title":"任务二","remarks":"邀请5个好友 (0/5)","status":0},{"button":"去邀请","rewardCoin":300,"title":"任务三","remarks":"邀请10个好友 (0/10)","status":0},{"button":"去邀请","rewardCoin":400,"title":"任务四","remarks":"邀请20个好友 (0/20)","status":0},{"button":"去邀请","rewardCoin":500,"title":"任务五","remarks":"邀请50个好友 (0/50)","status":0},{"button":"去邀请","rewardCoin":600,"title":"任务六","remarks":"邀请100个好友 (0/100)","status":0}]
*/
private int complete;
private List<ListBean> list;
public int getComplete() {
return complete;
}
public void setComplete(int complete) {
this.complete = complete;
}
public List<ListBean> getList() {
return list;
}
public void setList(List<ListBean> list) {
this.list = list;
}
public static class ListBean {
/**
* button : 去邀请
* rewardCoin : 100
* title : 任务一
* remarks : 邀请1个好友 (0/1)
* status : 0
*/
private String button;
private int rewardCoin;
private String title;
private String remarks;
private int status;
public String getButton() {
return button;
}
public void setButton(String button) {
this.button = button;
}
public int getRewardCoin() {
return rewardCoin;
}
public void setRewardCoin(int rewardCoin) {
this.rewardCoin = rewardCoin;
}
public String getTitle() {
return title;
}
public void setTitle(String title) {
this.title = title;
}
public String getRemarks() {
return remarks;
}
public void setRemarks(String remarks) {
this.remarks = remarks;
}
public int getStatus() {
return status;
}
public void setStatus(int status) {
this.status = status;
}
}
}
public static class FriendsBean {
/**
* friendSum : 1
* list : [{"head":"","rcoin":0,"nickName":"","mobile":"186****1554","ruid":2028614250701500000,"time":"10月14日","cashout":0}]
*/
private int friendSum;
private List<ListBeanX> list;
public int getFriendSum() {
return friendSum;
}
public void setFriendSum(int friendSum) {
this.friendSum = friendSum;
}
public List<ListBeanX> getList() {
return list;
}
public void setList(List<ListBeanX> list) {
this.list = list;
}
public static class ListBeanX {
/**
* head :
* rcoin : 0
* nickName :
* mobile : 186****1554
* ruid : 2028614250701500000
* time : 10月14日
* cashout : 0
*/
private String head;
private int rcoin;
private String nickName;
private String mobile;
private long ruid;
private String time;
private int cashout;
public String getHead() {
return head;
}
public void setHead(String head) {
this.head = head;
}
public int getRcoin() {
return rcoin;
}
public void setRcoin(int rcoin) {
this.rcoin = rcoin;
}
public String getNickName() {
return nickName;
}
public void setNickName(String nickName) {
this.nickName = nickName;
}
public String getMobile() {
return mobile;
}
public void setMobile(String mobile) {
this.mobile = mobile;
}
public long getRuid() {
return ruid;
}
public void setRuid(long ruid) {
this.ruid = ruid;
}
public String getTime() {
return time;
}
public void setTime(String time) {
this.time = time;
}
public int getCashout() {
return cashout;
}
public void setCashout(int cashout) {
this.cashout = cashout;
}
}
}
}
......@@ -3,14 +3,176 @@ package com.mints.goodmoney.mvp.model;
import java.io.Serializable;
public class MyInfo implements Serializable {
private int coin;
private String idcode;
public int getCoin() {
return coin;
/**
* taskVeido : {"max":20,"carrierType":"CHALLENGE_VEDIO","complete":0}
* taskShareFriend : {"max":20,"carrierType":"CHALLENGE_SHAREFRIEND","complete":0}
* userMsg : {"head":"","realName":null,"surplus":0,"idcode":"20000003","nickName":"","coin":50}
*/
private TaskVeidoBean taskVeido;
private TaskShareFriendBean taskShareFriend;
private UserMsgBean userMsg;
public TaskVeidoBean getTaskVeido() {
return taskVeido;
}
public void setTaskVeido(TaskVeidoBean taskVeido) {
this.taskVeido = taskVeido;
}
public TaskShareFriendBean getTaskShareFriend() {
return taskShareFriend;
}
public void setTaskShareFriend(TaskShareFriendBean taskShareFriend) {
this.taskShareFriend = taskShareFriend;
}
public UserMsgBean getUserMsg() {
return userMsg;
}
public void setUserMsg(UserMsgBean userMsg) {
this.userMsg = userMsg;
}
public String getIdcode() {
return idcode;
public static class TaskVeidoBean {
/**
* max : 20
* carrierType : CHALLENGE_VEDIO
* complete : 0
*/
private int max;
private String carrierType;
private int complete;
public int getMax() {
return max;
}
public void setMax(int max) {
this.max = max;
}
public String getCarrierType() {
return carrierType;
}
public void setCarrierType(String carrierType) {
this.carrierType = carrierType;
}
public int getComplete() {
return complete;
}
public void setComplete(int complete) {
this.complete = complete;
}
}
public static class TaskShareFriendBean {
/**
* max : 20
* carrierType : CHALLENGE_SHAREFRIEND
* complete : 0
*/
private int max;
private String carrierType;
private int complete;
public int getMax() {
return max;
}
public void setMax(int max) {
this.max = max;
}
public String getCarrierType() {
return carrierType;
}
public void setCarrierType(String carrierType) {
this.carrierType = carrierType;
}
public int getComplete() {
return complete;
}
public void setComplete(int complete) {
this.complete = complete;
}
}
public static class UserMsgBean {
/**
* head :
* realName : null
* surplus : 0
* idcode : 20000003
* nickName :
* coin : 50
*/
private String head;
private Object realName;
private int surplus;
private String idcode;
private String nickName;
private int coin;
public String getHead() {
return head;
}
public void setHead(String head) {
this.head = head;
}
public Object getRealName() {
return realName;
}
public void setRealName(Object realName) {
this.realName = realName;
}
public int getSurplus() {
return surplus;
}
public void setSurplus(int surplus) {
this.surplus = surplus;
}
public String getIdcode() {
return idcode;
}
public void setIdcode(String idcode) {
this.idcode = idcode;
}
public String getNickName() {
return nickName;
}
public void setNickName(String nickName) {
this.nickName = nickName;
}
public int getCoin() {
return coin;
}
public void setCoin(int coin) {
this.coin = coin;
}
}
}
......@@ -4,59 +4,18 @@ public class TaskBean {
private int imageSrc;
private String title;
private String coin;
private int coinSrc;
private String info;
private String progressStr;
private String btnStr;
private Boolean isNeedTimer = false;
private int time;
private int type;
public TaskBean(int imageSrc, String title, String coin, int coinSrc, String info, String btnStr, Boolean isNeedTimer, int time, int type) {
public TaskBean(int imageSrc, String title, String progressStr, String btnStr, int type) {
this.imageSrc = imageSrc;
this.title = title;
this.coin = coin;
this.coinSrc = coinSrc;
this.info = info;
this.progressStr = progressStr;
this.btnStr = btnStr;
this.isNeedTimer = isNeedTimer;
this.time = time;
this.type = type;
}
public TaskBean(int imageSrc, String title, String coin, int coinSrc, String info, String btnStr) {
this.imageSrc = imageSrc;
this.title = title;
this.coin = coin;
this.coinSrc = coinSrc;
this.info = info;
this.btnStr = btnStr;
}
public int getType() {
return type;
}
public void setType(int type) {
this.type = type;
}
public Boolean getNeedTimer() {
return isNeedTimer;
}
public void setNeedTimer(Boolean needTimer) {
isNeedTimer = needTimer;
}
public int getTime() {
return time;
}
public void setTime(int time) {
this.time = time;
}
public int getImageSrc() {
return imageSrc;
}
......@@ -73,28 +32,12 @@ public class TaskBean {
this.title = title;
}
public String getCoin() {
return coin;
}
public void setCoin(String coin) {
this.coin = coin;
}
public int getCoinSrc() {
return coinSrc;
}
public void setCoinSrc(int coinSrc) {
this.coinSrc = coinSrc;
}
public String getInfo() {
return info;
public String getProgressStr() {
return progressStr;
}
public void setInfo(String info) {
this.info = info;
public void setProgressStr(String progressStr) {
this.progressStr = progressStr;
}
public String getBtnStr() {
......@@ -104,4 +47,12 @@ public class TaskBean {
public void setBtnStr(String btnStr) {
this.btnStr = btnStr;
}
public int getType() {
return type;
}
public void setType(int type) {
this.type = type;
}
}
package com.mints.goodmoney.mvp.presenters
import com.mints.goodmoney.manager.AppHttpManager
import com.mints.goodmoney.mvp.model.BaseResponse
import com.mints.goodmoney.mvp.model.FriendsTaskBean
import com.mints.goodmoney.mvp.views.FriendsView
import com.mints.library.net.neterror.BaseSubscriber
import com.mints.library.net.neterror.Throwable
class FriendsPresenter : BasePresenter<FriendsView>() {
/**
* 世界人民排名
*/
fun getLeaders() {
AppHttpManager.getInstance(loanApplication)
.call(loanService.leaders, object : BaseSubscriber<BaseResponse< FriendsTaskBean.FriendsBean>>() {
override fun onCompleted() {
if (isLinkView) return
}
override fun onError(e: Throwable) {
if (isLinkView) return
}
override fun onNext(baseResponse: BaseResponse< FriendsTaskBean.FriendsBean>) {
if (isLinkView) return
when (baseResponse.status) {
200 -> view.getWorldRank(baseResponse.data)
}
}
})
}
/**
* 好友任务
*/
fun getFriendsMsg() {
AppHttpManager.getInstance(loanApplication)
.call(loanService.friendsMsg, object : BaseSubscriber<BaseResponse<FriendsTaskBean>>() {
override fun onCompleted() {
if (isLinkView) return
}
override fun onError(e: Throwable) {
if (isLinkView) return
}
override fun onNext(baseResponse: BaseResponse<FriendsTaskBean>) {
if (isLinkView) return
when (baseResponse.status) {
200 -> {
view.getFriendsRank(baseResponse.data)
}
}
}
})
}
}
\ No newline at end of file
......@@ -9,6 +9,7 @@ import com.mints.goodmoney.manager.UserManager
import com.mints.goodmoney.mvp.model.*
import com.mints.goodmoney.mvp.views.MyView
import com.mints.goodmoney.utils.DeviceUuidFactory
import com.mints.goodmoney.utils.LogUtil
import com.mints.library.net.neterror.BaseSubscriber
import com.mints.library.net.neterror.Throwable
import net.grandcentrix.tray.AppPreferences
......@@ -20,10 +21,11 @@ class MyPresenter : BasePresenter<MyView>() {
* 获取签到内容
*/
open fun getSignInHomePageMsg() {
// view.showLoading("加载中...");
AppHttpManager.getInstance(loanApplication)
.call(loanService.signInHomePageMsg,
object : BaseSubscriber<BaseResponse<SignCardBean?>?>() {
object : BaseSubscriber<BaseResponse<SignCardBean>>() {
override fun onCompleted() {
if (isLinkView) return
view.hideLoading()
......@@ -35,12 +37,13 @@ class MyPresenter : BasePresenter<MyView>() {
view.showToast(e.message)
}
fun onNext(baseResponse: BaseResponse<SignCardBean?>) {
override fun onNext(baseResponse: BaseResponse<SignCardBean>) {
if (isLinkView) return
val code = baseResponse.getStatus()
val message = baseResponse.getMessage()
val code = baseResponse.status
val message = baseResponse.message
when (code) {
200 -> view.getSignInHomePageMsgSuc(baseResponse.getData())
200 -> view.getSignInHomePageMsgSuc(baseResponse.data)
401 -> {
}
else -> view.showToast(message)
......@@ -56,7 +59,7 @@ class MyPresenter : BasePresenter<MyView>() {
view.showLoading("加载中...")
AppHttpManager.getInstance(loanApplication)
.call(loanService.signInHomePage(),
object : BaseSubscriber<BaseResponse<Any?>?>() {
object : BaseSubscriber<BaseResponse<Any>>() {
override fun onCompleted() {
if (isLinkView) return
view.hideLoading()
......@@ -68,7 +71,7 @@ class MyPresenter : BasePresenter<MyView>() {
view.showToast(e.message)
}
fun onNext(baseResponse: BaseResponse<Any?>) {
override fun onNext(baseResponse: BaseResponse<Any>) {
if (isLinkView) return
val code = baseResponse.status
val message = baseResponse.message
......@@ -79,13 +82,9 @@ class MyPresenter : BasePresenter<MyView>() {
})
}
/**
* isCall -- true 连续调用
* 获取用户配置信息
*/
fun getUserTaskMsg(isCall: Boolean) {
fun getUserHallBaseMsg() {
AppHttpManager.getInstance(loanApplication)
.call(loanService.myInfoMsg, object : BaseSubscriber<BaseResponse<MyInfo>>() {
.call(loanService.userHallBaseMsg, object : BaseSubscriber<BaseResponse<MyInfo>>() {
override fun onCompleted() {
if (isLinkView)
......@@ -101,11 +100,7 @@ class MyPresenter : BasePresenter<MyView>() {
val message: String = baseResponse.getMessage()
when (code) {
200 -> {
if (isCall) {
view.getUserTaskMsgSuc(baseResponse.getData())
} else {
view.getUserTaskMsgSuc(baseResponse.getData())
}
view.getUserTaskMsgSuc(baseResponse.getData())
myHotActivity()
}
401 -> view.getUserTaskMsgFail()
......@@ -148,7 +143,7 @@ class MyPresenter : BasePresenter<MyView>() {
override fun onNext(baseResponse: BaseResponse<BannerBean?>) {
if (isLinkView) return
val data: BannerBean? = baseResponse.getData()
val data: BannerBean? = baseResponse.data
if (data != null) {
view.getMyHotActivitySuc(data)
}
......@@ -208,7 +203,7 @@ class MyPresenter : BasePresenter<MyView>() {
}
vo["androidid"] = deviceInfo.getAndroidId(null)
vo["imei"] = deviceInfo.iMEI
vo["oaid"] = ps.getString(Constant.OAID,"")!!
vo["oaid"] = ps.getString(Constant.OAID, "")!!
vo["os"] = "android"
vo["model"] = deviceInfo.brand + " " + deviceInfo.mobileModel
vo["uuid"] = DeviceUuidFactory().deviceUuid
......@@ -234,11 +229,38 @@ class MyPresenter : BasePresenter<MyView>() {
if (isLinkView) return
val code = baseResponse.status
when (code) {
// 200 -> baseMsg()
200 -> view.userLoginSuc()
}
}
})
}
/**
* 设置邀请成功
*
*/
fun cmtShareStatus() {
val vo = HashMap<String, Any>()
vo["carrierType"] = Constant.CHALLENGE_SHAREFRIEND
vo["value"] = "1"
AppHttpManager.getInstance(loanApplication)
.call(loanService.setStatusInOneDayByCarrierType(vo), object : BaseSubscriber<BaseResponse<Any>>() {
override fun onCompleted() {
if (isLinkView) return
}
override fun onError(e: Throwable) {
if (isLinkView) return
}
override fun onNext(baseResponse: BaseResponse<Any>) {
if (isLinkView) return
when (baseResponse.status) {
// 200 -> baseMsg()
}
}
})
}
}
\ No newline at end of file
package com.mints.goodmoney.mvp.views
import com.mints.goodmoney.mvp.model.FriendsTaskBean
interface FriendsView : BaseView {
fun getWorldRank(data: FriendsTaskBean.FriendsBean)
fun getFriendsRank(data: FriendsTaskBean)
}
......@@ -27,4 +27,9 @@ interface MyView : BaseView {
* 签到成功
*/
fun signInHomePageSuc()
/**
* 游客登录成功
*/
fun userLoginSuc()
}
......@@ -7,6 +7,7 @@ import com.mints.goodmoney.BuildConfig;
import com.mints.goodmoney.mvp.model.BannerBean;
import com.mints.goodmoney.mvp.model.BaseResponse;
import com.mints.goodmoney.mvp.model.DrawcashBean;
import com.mints.goodmoney.mvp.model.FriendsTaskBean;
import com.mints.goodmoney.mvp.model.MyInfo;
import com.mints.goodmoney.mvp.model.SignCardBean;
import com.mints.goodmoney.mvp.model.UserBean;
......@@ -72,15 +73,15 @@ public interface LoanService {
*
* @return
*/
@POST("api/v125/myInfoMsg")
Observable<BaseResponse<MyInfo>> getMyInfoMsg();
@POST("api/getUserHallBaseMsg")
Observable<BaseResponse<MyInfo>> getUserHallBaseMsg();
/**
* 热门活动接口
*
* @return
*/
@POST("api/v125/myHotActivity")
@POST("api/myHotActivity")
Observable<BaseResponse<BannerBean>> myHotActivity(@Body Map<String, Object> vo);
/**
......@@ -99,6 +100,14 @@ public interface LoanService {
@POST("api/getSignInHomePageMsg")
Observable<BaseResponse<SignCardBean>> getSignInHomePageMsg();
/**
* 设置邀请成功
*
* @return
*/
@POST("api/setStatusInOneDayByCarrierType")
Observable<BaseResponse<Object>> setStatusInOneDayByCarrierType(@Body Map<String, Object> vo);
/**
* 获取验证码
*
......@@ -120,7 +129,7 @@ public interface LoanService {
*
* @return
*/
@POST("api/v125/wechatlogin")
@POST("api/wechatlogin")
Observable<BaseResponse<UserBean>> wechatlogin(@Body Map<String, Object> vo);
/**
......@@ -184,7 +193,7 @@ public interface LoanService {
*
* @return
*/
@POST("api/v125/bindingWechat")
@POST("api/bindingWechat")
Observable<BaseResponse<UserBean>> bindingWechat(@Body Map<String, Object> vo);
/**
......@@ -192,9 +201,25 @@ public interface LoanService {
*
* @return
*/
@POST("api/v115/addCashoutReq")
@POST("api/addCashoutReq")
Observable<BaseResponse<Object>> addCashoutReq(@Body Map<String, Object> vo);
/**
* 世界人民排行信息
*
* @return
*/
@POST("api/getLeaders")
Observable<BaseResponse<FriendsTaskBean.FriendsBean>> getLeaders();
/**
* 好友任务信息
*
* @return
*/
@POST("api/getFriendsMsg")
Observable<BaseResponse<FriendsTaskBean>> getFriendsMsg();
/**
* 默认http工厂
*/
......
package com.mints.goodmoney.ui.activitys
import android.os.Bundle
import android.view.View
import com.mints.goodmoney.R
import com.mints.goodmoney.common.Constant
import com.mints.goodmoney.ui.activitys.base.BaseActivity
import com.mints.library.utils.ConstantUtil
import kotlinx.android.synthetic.main.activity_aboutus.*
import kotlinx.android.synthetic.main.header_layout.*
/**
* 描述:关于我们
* 作者:孟崔广
* 时间:2020/9/23 18:39
*/
class AboutusActivity : BaseActivity()
, View.OnClickListener {
override fun getContentViewLayoutID() = R.layout.activity_aboutus
override fun isApplyKitKatTranslucency() = false
override fun initViewsAndEvents() {
tvAboutasVersion.text = getString(R.string.app_name) + " v" + ConstantUtil.getVersionName(context)
tv_title.text = "关于我们"
iv_left_icon.visibility = View.VISIBLE
iv_left_icon.setImageResource(R.mipmap.ic_arrow_back)
initListener()
}
override fun onClick(v: View?) {
when (v?.id) {
R.id.iv_left_icon -> finish()
R.id.tvAboutasService -> {
val bundle = Bundle()
bundle.putString(WebActivity.WEB_TITLE, getString(R.string.register_name))
bundle.putString(WebActivity.WEB_URL, Constant.REGISTER_URL)
readyGo(WebActivity::class.java, bundle)
}
R.id.tvAboutasPolicy -> {
val bundle = Bundle()
bundle.putString(WebActivity.WEB_TITLE, getString(R.string.privacy_name))
bundle.putString(WebActivity.WEB_URL, Constant.PRIVACY_URL)
readyGo(WebActivity::class.java, bundle)
}
}
}
private fun initListener() {
iv_left_icon.setOnClickListener(this)
tvAboutasService.setOnClickListener(this)
tvAboutasPolicy.setOnClickListener(this)
}
}
......@@ -132,10 +132,10 @@ class SettingsActivity : BaseActivity(), View.OnClickListener {
readyGo(WebActivity::class.java, bundle)
}
R.id.item_aboutUs -> {
readyGo(AboutusActivity::class.java)
}
R.id.btn_switch -> {
readyGo(LoginActivity::class.java)
}
R.id.iv_left_icon -> {
onBackPressed()
......
......@@ -2,13 +2,19 @@ package com.mints.goodmoney.ui.adapter
import android.content.Context
import android.view.View
import android.widget.Button
import android.widget.TextView
import com.mints.goodmoney.R
import com.mints.goodmoney.mvp.model.FriendsTaskBean
class BannerTaskAdapter(context: Context) : BannerBaseAdapter<Any>(context) {
class BannerTaskAdapter(context: Context) : BannerBaseAdapter<FriendsTaskBean.ChallengeBean.ListBean>(context) {
override fun getLayoutResID() = R.layout.item_bv_friends_task
override fun convert(convertView: View?, data: Any?) {
override fun convert(convertView: View, data: FriendsTaskBean.ChallengeBean.ListBean) {
convertView.findViewById<TextView>(R.id.item_bv_friends_task_title).text = data.title
convertView.findViewById<TextView>(R.id.item_bv_friends_task_info).text = data.remarks
convertView.findViewById<Button>(R.id.item_bv_friends_task_btn).text = data.button
}
}
\ No newline at end of file
package com.mints.goodmoney.ui.adapter
import android.content.Context
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.ImageView
import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView
import com.mints.goodmoney.R
import com.mints.goodmoney.mvp.model.FriendsTaskBean
import com.mints.library.utils.GlideUtils
class InvitedAdapter(private val invitedData: List<Any>) : RecyclerView.Adapter<InvitedAdapter.InvitedHolder>() {
class InvitedAdapter : RecyclerView.Adapter<InvitedAdapter.InvitedHolder> {
constructor(context: Context, invitedData: MutableList<FriendsTaskBean.FriendsBean.ListBeanX>) {
mContext = context
this.invitedData = invitedData
}
private var mContext: Context
private var invitedData: List<FriendsTaskBean.FriendsBean.ListBeanX>? = null
private var mOnItemClickListener: OnItemClickListener? = null
......@@ -16,19 +28,59 @@ class InvitedAdapter(private val invitedData: List<Any>) : RecyclerView.Adapter<
return InvitedHolder(view)
}
override fun getItemCount() = invitedData.size
override fun getItemCount(): Int {
return if (invitedData == null) {
0
} else {
invitedData!!.size
}
}
override fun onBindViewHolder(holder: InvitedHolder, position: Int) {
when (position) {
0 -> {
holder.tvNum.visibility = View.GONE
holder.ivRanking.visibility = View.VISIBLE
holder.ivRanking.setImageResource(R.mipmap.icon_ranking_first)
}
1 -> {
holder.tvNum.visibility = View.GONE
holder.ivRanking.visibility = View.VISIBLE
holder.ivRanking.setImageResource(R.mipmap.icon_ranking_second)
}
2 -> {
holder.tvNum.visibility = View.GONE
holder.ivRanking.visibility = View.VISIBLE
holder.ivRanking.setImageResource(R.mipmap.icon_ranking_third)
}
else -> {
holder.tvNum.visibility = View.VISIBLE
holder.ivRanking.visibility = View.GONE
holder.tvNum.text = "" + position + 1
}
}
val data = invitedData!![position]
GlideUtils.loadImageViewLoding(mContext, data.head, holder.ivAvatar, R.mipmap.ic_avatar_ph, R.mipmap.ic_avatar_ph)
if (data.nickName.isNotEmpty()) {
holder.tvName.text = data.nickName
} else {
holder.tvName.text = data.mobile
}
holder.tvCoin.text = "" + data.rcoin
holder.ivAvatar
holder.itemView.setOnClickListener {
mOnItemClickListener?.onItemClick(holder.itemView, position)
}
}
inner class InvitedHolder(itemView: View) : RecyclerView.ViewHolder(itemView) {
private val tvNum = itemView.findViewById<TextView>(R.id.item_invited_tv_num)
private val iv = itemView.findViewById<TextView>(R.id.item_invited_iv)
private val tvName = itemView.findViewById<TextView>(R.id.item_invited_tv_name)
private val tvCoin = itemView.findViewById<TextView>(R.id.item_invited_tv_coin)
val tvNum: TextView = itemView.findViewById(R.id.item_invited_tv_num)
val ivAvatar: ImageView = itemView.findViewById(R.id.item_invited_iv_avatar)
val ivRanking: ImageView = itemView.findViewById(R.id.item_invite_iv_ranking)
val tvName: TextView = itemView.findViewById(R.id.item_invited_tv_name)
val tvCoin: TextView = itemView.findViewById(R.id.item_invited_tv_coin)
}
//define interface
......
package com.mints.goodmoney.ui.adapter
import android.content.Context
import android.graphics.Color
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
......@@ -16,16 +17,13 @@ import com.mints.goodmoney.utils.TimeRender
class MainMyAdapter : RecyclerView.Adapter<RecyclerView.ViewHolder> {
companion object {
const val HEALTH_TYPE_BREATH = 0x00000001 // 呼吸
const val HEALTH_TYPE_STAND = 0x00000002 // 站一站
const val HEALTH_TYPE_FRUIT = 0x00000003 // 吃水果
const val HEALTH_TYPE_EYE = 0x00000004 // 放松眼睛
const val TASK_TYPE_VIDEO = 0x00000005 // 看视频
const val TASK_TYPE_INVITE = 0x00000006 // 邀好友
const val TASK_TYPE_GAME = 0x00000007 // 玩游戏
const val TASK_TYPE_FICTION = 0x00000007 // 看小说
const val COUNT_DOWN_INTERVAL = 1000L
const val TASK_TYPE_HOME = 0x00000001
const val TASK_TYPE_INVITE = 0x00000002
const val TASK_TYPE_VIDEO = 0x00000003
const val TASK_TYPE_GAME = 0x00000004
const val TASK_TYPE_FICTION = 0x00000005
const val TASK_TYPE_DEMO = 0x00000006
}
constructor(context: Context, taskData: MutableList<TaskBean>) {
......@@ -39,11 +37,6 @@ class MainMyAdapter : RecyclerView.Adapter<RecyclerView.ViewHolder> {
private var mOnItemClickListener: OnItemClickListener? = null
private var mOnItemChildClickListener: OnItemChildClickListener? = null
private var mBreathTimer: CountDownTimerSupport? = null
private var mStandTimer: CountDownTimerSupport? = null
private var mFruitTimer: CountDownTimerSupport? = null
private var mEyeTimer: CountDownTimerSupport? = null
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder {
val inflater: LayoutInflater = LayoutInflater.from(mContext)
return TaskHolder(inflater.inflate(R.layout.item_fragment_main_my_task, parent, false))
......@@ -68,85 +61,37 @@ class MainMyAdapter : RecyclerView.Adapter<RecyclerView.ViewHolder> {
mOnItemChildClickListener?.onItemChildClick(it2, position)
}
holder.itemTaskTitle.text = taskBean.title
holder.itemTaskInfo.text = taskBean.info
holder.itemTaskMoney.text = taskBean.coin
val gold = mContext.resources.getDrawable(R.mipmap.ic_gold)
gold.setBounds(0, 0, 50, 50)
holder.itemTaskMoney.setCompoundDrawables(gold, null, null, null)
holder.itemTaskImg.setImageDrawable(mContext.resources.getDrawable(taskBean.imageSrc))
if (taskBean.btnStr.isNotEmpty() && !taskBean.needTimer) {
holder.itemTaskClick.text = taskBean.btnStr
if (taskBean.btnStr.isEmpty()) {
holder.itemTaskClick.visibility = View.GONE
} else {
when (taskBean.type) {
HEALTH_TYPE_BREATH -> {
mBreathTimer = CountDownTimerSupport(taskBean.time * COUNT_DOWN_INTERVAL, COUNT_DOWN_INTERVAL)
startTime(mBreathTimer!!, HEALTH_TYPE_BREATH, holder.itemTaskClick, holder.itemTaskTitle)
}
HEALTH_TYPE_EYE -> {
mEyeTimer = CountDownTimerSupport(taskBean.time * COUNT_DOWN_INTERVAL, COUNT_DOWN_INTERVAL)
startTime(mEyeTimer!!, HEALTH_TYPE_EYE, holder.itemTaskClick, holder.itemTaskTitle)
}
HEALTH_TYPE_FRUIT -> {
mFruitTimer = CountDownTimerSupport(taskBean.time * COUNT_DOWN_INTERVAL, COUNT_DOWN_INTERVAL)
startTime(mFruitTimer!!, HEALTH_TYPE_FRUIT, holder.itemTaskClick, holder.itemTaskTitle)
}
HEALTH_TYPE_STAND -> {
mStandTimer = CountDownTimerSupport(taskBean.time * COUNT_DOWN_INTERVAL, COUNT_DOWN_INTERVAL)
startTime(mStandTimer!!, HEALTH_TYPE_STAND, holder.itemTaskClick, holder.itemTaskTitle)
}
}
}
when (taskBean.btnStr) {
"立即领取" -> {
holder.itemTaskClick.background = mContext.resources.getDrawable(R.drawable.shape_tv_gold)
}
"去完成" -> {
holder.itemTaskClick.background = mContext.resources.getDrawable(R.drawable.shape_main_water)
}
else -> {
holder.itemTaskClick.background = mContext.resources.getDrawable(R.drawable.shape_tv_gold_gury)
holder.itemTaskClick.visibility = View.VISIBLE
holder.itemTaskClick.text = taskBean.btnStr
if (taskBean.btnStr == "立即领取") {
holder.itemTaskClick.setBackgroundResource(R.drawable.shape_btn_orange_complete)
holder.itemTaskClick.setTextColor(Color.WHITE)
} else {
holder.itemTaskClick.setBackgroundResource(R.drawable.shape_btn_orange)
holder.itemTaskClick.setTextColor(mContext.resources.getColor(R.color.my_color_orange))
}
}
}
}
}
private fun startTime(timer: CountDownTimerSupport, type: Int, tvClick: TextView, tvTitle: TextView) {
timer.setOnCountDownTimerListener(object : OnCountDownTimerListener {
override fun onFinish() {
val str = tvTitle.text.toString()
var currentIndex = str.substring(str.indexOf("(") + 1, str.indexOf("(") + 2).toInt()
val maxCount = str.substring(str.indexOf(")") - 1, str.indexOf(")")).toInt()
if (currentIndex < maxCount) {
val replaceStr = str.replace(currentIndex.toString(), (currentIndex + 1).toString())
tvTitle.text = replaceStr
tvClick.text = "立即领取"
tvClick.background = mContext.resources.getDrawable(R.drawable.shape_tv_gold)
if (taskBean.progressStr.isEmpty()) {
holder.itemTaskProgress.visibility = View.GONE
} else {
val replaceStr = str.replace(maxCount.toString(), currentIndex.toString())
tvTitle.text = replaceStr
tvClick.text = "已完成"
tvClick.background = mContext.resources.getDrawable(R.drawable.shape_tv_gold_gury)
holder.itemTaskProgress.visibility = View.VISIBLE
holder.itemTaskProgress.text = taskBean.progressStr
}
}
override fun onTick(millisUntilFinished: Long) {
tvClick.text = TimeRender.ms2HMS(millisUntilFinished.toInt())
}
})
timer.start()
}
}
private inner class TaskHolder(itemView: View) : RecyclerView.ViewHolder(itemView) {
val itemTaskImg: ImageView = itemView.findViewById(R.id.item_title_img)
val itemTaskTitle: TextView = itemView.findViewById(R.id.item_task_title)
val itemTaskMoney: TextView = itemView.findViewById(R.id.item_task_money)
val itemTaskInfo: TextView = itemView.findViewById(R.id.item_task_info)
val itemTaskProgress: TextView = itemView.findViewById(R.id.item_task_progress)
val itemTaskClick: TextView = itemView.findViewById(R.id.item_task_click)
}
......
package com.mints.goodmoney.ui.fragment
import android.text.TextUtils
import android.graphics.Typeface
import android.view.View
import android.widget.LinearLayout
import android.widget.TextView
import androidx.recyclerview.widget.DividerItemDecoration
import com.mints.goodmoney.R
import com.mints.goodmoney.common.AppConfig
import com.mints.goodmoney.common.Constant
import com.mints.goodmoney.manager.ShumeiManager
import com.mints.goodmoney.manager.UserManager
import com.mints.goodmoney.mvp.model.BannerBean
import com.mints.goodmoney.ui.adapter.BannerAdapter
import com.mints.goodmoney.mvp.model.FriendsTaskBean
import com.mints.goodmoney.mvp.presenters.FriendsPresenter
import com.mints.goodmoney.mvp.views.FriendsView
import com.mints.goodmoney.ui.adapter.BannerBaseAdapter
import com.mints.goodmoney.ui.adapter.BannerTaskAdapter
import com.mints.goodmoney.ui.adapter.InvitedAdapter
import com.mints.goodmoney.ui.fragment.base.BaseFragment
import com.mints.goodmoney.ui.widgets.tablayout.TabLayout
import com.scwang.smartrefresh.layout.api.RefreshLayout
import com.scwang.smartrefresh.layout.listener.OnRefreshListener
import kotlinx.android.synthetic.main.fragment_main_friends.*
import kotlinx.android.synthetic.main.fragment_main_friends.srl_my
import kotlinx.android.synthetic.main.header_layout.*
import com.mints.goodmoney.utils.LogUtil
/**
* 描述:邀请好友
* 作者:孟崔广
* 时间:2020/9/20 17:30
*/
class FriendsFragment : BaseFragment() {
class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener {
private val friendsPresenter by lazy { FriendsPresenter() }
private val userManager by lazy { UserManager.getInstance() }
private var bvTaskData: List<Any> = arrayListOf()
private var bvBannerData: List<BannerBean.ListBean> = arrayListOf()
private var invitedData: List<Any> = arrayListOf()
private var bvTaskData: MutableList<FriendsTaskBean.ChallengeBean.ListBean> = mutableListOf()
private var invitedData: MutableList<FriendsTaskBean.FriendsBean.ListBeanX> = mutableListOf()
private var bannerTaskAdapter: BannerTaskAdapter? = null
private var invitedAdapter: InvitedAdapter? = null
override fun getContentViewLayoutID() = R.layout.fragment_main_friends
override fun initViewsAndEvents() {
friendsPresenter.attachView(this)
srl_my.setOnRefreshListener(this)
initView()
initRecy()
......@@ -45,48 +53,52 @@ class FriendsFragment : BaseFragment() {
private fun initView() {
tv_title.text = "邀请好友"
view_title1.findViewById<TextView>(R.id.view_title).text = "邀好友 做任务 赚现金"
view_title2.findViewById<TextView>(R.id.view_title).text = "邀好友 赚分红 邀越多 赚越多"
}
private fun initRecy() {
// rg.setOnCheckedChangeListener { group, checkedId ->
// when (checkedId) {
// R.id.rb_my_friends -> {
// showToast("我的好友")
// }
// R.id.rb_world_person -> {
// showToast("世界人民")
// }
// }
//
// }
private fun initRecy() {
tab_friends.addTab(tab_friends.newTab().setText("我的好友").setTag("my_friends"))
tab_friends.addTab(tab_friends.newTab().setText("世界人民").setTag("world_person"))
tab_friends.setOnTabSelectedListener(object : TabLayout.OnTabSelectedListener {
override fun onTabReselected(tab: TabLayout.Tab?) {
}
override fun onTabReselected(tab: TabLayout.Tab?) {}
override fun onTabUnselected(tab: TabLayout.Tab?) {
val title =
((tab_friends.getChildAt(0) as LinearLayout).getChildAt(tab!!.position) as LinearLayout).getChildAt(
1
) as TextView
title.apply {
// setTextAppearance(context, R.style.TabLayoutTextSize)
typeface = Typeface.defaultFromStyle(Typeface.NORMAL)
}
}
override fun onTabSelected(tab: TabLayout.Tab?) {
val title =
((tab_friends.getChildAt(0) as LinearLayout).getChildAt(tab!!.position) as LinearLayout).getChildAt(
1
) as TextView
title.apply {
// setTextAppearance(context, R.style.BigTabLayoutTextStyle)
typeface = Typeface.defaultFromStyle(Typeface.BOLD)
}
tab?.let {
if (it.tag == "我的好友") {
showToast("我的好友")
if (it.tag == "my_friends") {
} else {
showToast("世界人民")
friendsPresenter.getLeaders()
}
}
}
})
// tab_friends.setOnScrollChangeListener(object :.(){})
recy_friends.addItemDecoration(DividerItemDecoration(mContext, DividerItemDecoration.VERTICAL))
val invitedAdapter = InvitedAdapter(invitedData)
invitedAdapter = InvitedAdapter(mContext, invitedData)
recy_friends.adapter = invitedAdapter
invitedAdapter.setOnItemClickListener(object : InvitedAdapter.OnItemClickListener {
invitedAdapter?.setOnItemClickListener(object : InvitedAdapter.OnItemClickListener {
override fun onItemClick(view: View?, position: Int) {
}
......@@ -95,41 +107,24 @@ class FriendsFragment : BaseFragment() {
}
private fun initBanner() {
val bannerTaskAdapter = BannerTaskAdapter(mContext)
bannerTaskAdapter.setData(bvTaskData)
bv_friends_task.setAdapter(bannerTaskAdapter)
bannerTaskAdapter.setOnPageTouchListener(object : BannerBaseAdapter.OnPageTouchListener<Any> {
override fun onPageClick(position: Int, t: Any?) {
}
override fun onPageDown() {
bv_friends_task.stopAutoScroll()
}
override fun onPageUp() {
bv_friends_task.startAutoScroll()
}
})
bannerTaskAdapter = BannerTaskAdapter(mContext)
bannerTaskAdapter?.let {
it.setOnPageTouchListener(object : BannerBaseAdapter.OnPageTouchListener<FriendsTaskBean.ChallengeBean.ListBean> {
override fun onPageClick(position: Int, t: FriendsTaskBean.ChallengeBean.ListBean?) {
val bannerAdapter = BannerAdapter(mContext)
bannerAdapter.setData(bvBannerData)
bv_friends_banner.setAdapter(bannerAdapter)
bannerAdapter.setOnPageTouchListener(object : BannerBaseAdapter.OnPageTouchListener<BannerBean.ListBean> {
override fun onPageClick(position: Int, t: BannerBean.ListBean?) {
}
}
override fun onPageDown() {
bv_friends_task.stopAutoScroll()
}
override fun onPageDown() {
bv_friends_task.stopAutoScroll()
}
override fun onPageUp() {
bv_friends_task.startAutoScroll()
}
override fun onPageUp() {
bv_friends_task.startAutoScroll()
}
})
})
}
bv_friends_task.setAdapter(bannerTaskAdapter)
}
override fun onHiddenChanged(hidden: Boolean) {
......@@ -144,25 +139,41 @@ class FriendsFragment : BaseFragment() {
override fun onResume() {
super.onResume()
if (AppConfig.fragmentClickFlag == Constant.FRAGMENT_CLICK_FRIENDS) {
if (!TextUtils.isEmpty(userManager?.userID)) {
// if (!TextUtils.isEmpty(userManager?.userID)) {
// friendsPresenter.getFriendsMsg()
// }
} else {
}
friendsPresenter.getFriendsMsg()
}
bv_friends_banner.startAutoScroll()
bv_friends_task.stopAutoScroll()
bv_friends_task.startAutoScroll()
}
override fun onPause() {
super.onPause()
bv_friends_banner.startAutoScroll()
bv_friends_task.stopAutoScroll()
}
override fun onDestroy() {
super.onDestroy()
friendsPresenter.detachView()
}
override fun onRefresh(refreshLayout: RefreshLayout) {
if (userManager.userID.isNotEmpty()) {
friendsPresenter.getFriendsMsg()
}
}
override fun getWorldRank(data: FriendsTaskBean.FriendsBean) {
invitedData.clear()
invitedData.addAll(data.list)
invitedAdapter?.notifyDataSetChanged()
}
override fun getFriendsRank(data: FriendsTaskBean) {
bvTaskData = data.challenge.list
bannerTaskAdapter?.setData(bvTaskData)
}
}
\ No newline at end of file
......@@ -179,100 +179,100 @@ public class SignView extends LinearLayout implements View.OnClickListener {
*/
private void setContentLayoutAndBgColor(int days, int status, TextView tvContent, TextView tvDay, boolean isCurFlag) {
Resources resources = getResources();
if (UserManager.getInstance().getAdShowFlag()) {
switch (status) {
case 0:
if (days == 7) {
tvContent.setText("");
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvDay.setTextColor(resources.getColor(R.color.black));
break;
case 1:
if (isCurFlag) {
tvContent.setText("");
tvContent.setTextColor(resources.getColor(R.color.graya));
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_vedio));
tvDay.setTextColor(resources.getColor(R.color.black));
tvDay.setText("可翻倍");
} else {
if (days == 7) {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_open));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_none));
}
tvContent.setText("");
tvContent.setTextColor(resources.getColor(R.color.graya));
tvDay.setTextColor(resources.getColor(R.color.graya));
tvDay.setText("已领");
}
break;
case 2:
if (days == 7) {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_open));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_none));
}
// if (UserManager.getInstance().getAdShowFlag()) {
switch (status) {
case 0:
if (days == 7) {
tvContent.setText("");
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvDay.setTextColor(resources.getColor(R.color.black));
break;
case 1:
if (isCurFlag) {
tvContent.setText("");
tvContent.setTextColor(resources.getColor(R.color.graya));
tvDay.setTextColor(resources.getColor(R.color.graya));
tvDay.setText("已领");
break;
default:
if (days == 7) {
tvContent.setText("");
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_vedio));
tvDay.setTextColor(resources.getColor(R.color.black));
break;
}
} else {
switch (status) {
case 0:
if (days == 7) {
tvContent.setText("");
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
tvDay.setText("可翻倍");
} else {
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvDay.setTextColor(resources.getColor(R.color.black));
break;
case 1:
case 2:
if (days == 7) {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_open));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_none));
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvContent.setText("");
tvContent.setTextColor(resources.getColor(R.color.graya));
tvDay.setTextColor(resources.getColor(R.color.graya));
tvDay.setText("已领");
break;
default:
if (days == 7) {
tvContent.setText("");
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvDay.setTextColor(resources.getColor(R.color.black));
break;
}
}
break;
case 2:
if (days == 7) {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_open));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvContent.setText("");
tvContent.setTextColor(resources.getColor(R.color.graya));
tvDay.setTextColor(resources.getColor(R.color.graya));
tvDay.setText("已领");
break;
default:
if (days == 7) {
tvContent.setText("");
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
} else {
tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
}
tvDay.setTextColor(resources.getColor(R.color.black));
break;
}
// } else {
// switch (status) {
// case 0:
// if (days == 7) {
// tvContent.setText("");
// tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
//
// } else {
// tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
// }
// tvDay.setTextColor(resources.getColor(R.color.black));
// break;
// case 1:
// case 2:
// if (days == 7) {
// tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_open));
//
// } else {
// tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_none));
// }
//
// tvContent.setText("");
// tvContent.setTextColor(resources.getColor(R.color.graya));
// tvDay.setTextColor(resources.getColor(R.color.graya));
// tvDay.setText("已领");
// break;
// default:
// if (days == 7) {
// tvContent.setText("");
// tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_newgift_close));
// } else {
// tvContent.setBackground(resources.getDrawable(R.mipmap.ic_sign_finish));
// }
// tvDay.setTextColor(resources.getColor(R.color.black));
// break;
// }
// }
}
......
<set xmlns:android="http://schemas.android.com/apk/res/android">
<translate
android:duration="500"
android:duration="300"
android:fromYDelta="100%p"
android:toYDelta="0" />
<alpha
android:duration="750"
android:duration="500"
android:fromAlpha="0.0"
android:toAlpha="1.0" />
</set>
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="@color/white" />
<stroke
android:width="1.5dp"
android:color="@color/my_color_orange" />
<corners android:radius="100dp" />
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:angle="270"
android:endColor="#ffff7f2c"
android:startColor="#ffffb032"
android:type="linear"
android:useLevel="true" />
<corners android:radius="100dp" />
</shape>
\ No newline at end of file
<?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="match_parent"
android:background="@color/white"
android:orientation="vertical">
<include layout="@layout/header_layout" />
<TextView
android:id="@+id/tvAboutasVersion"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="30dp"
android:layout_marginBottom="15dp"
android:text="@string/app_name"
android:textColor="@color/text_font"
android:textSize="13sp" />
<ImageView
android:layout_width="80dp"
android:layout_height="80dp"
android:layout_gravity="center_horizontal"
android:src="@mipmap/ic_launcher" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:layout_marginBottom="20dp"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="30dp"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:orientation="horizontal">
<TextView
android:id="@+id/tvAboutasService"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="2dp"
android:padding="5dp"
android:text="@string/register_name"
android:textColor="@color/main_mints"
android:textSize="14sp" />
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:background="@color/main_mints" />
<TextView
android:id="@+id/tvAboutasPolicy"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="2dp"
android:padding="5dp"
android:text="隐私政策"
android:textColor="@color/main_mints"
android:textSize="14sp" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="30dp"
android:layout_marginRight="30dp"
android:gravity="center"
android:text="Copyright © 2020 Inc.."
android:textColor="@color/text_font"
android:textSize="12sp" />
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</LinearLayout>
......@@ -25,14 +25,13 @@
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
app:layout_behavior=".ui.widgets.FlingBehavior">
android:background="@color/white">
<com.google.android.material.appbar.CollapsingToolbarLayout
android:id="@+id/collapsingToolbarLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_scrollFlags="scroll|exitUntilCollapsed">
app:layout_scrollFlags="scroll|enterAlways|enterAlwaysCollapsed">
<LinearLayout
android:layout_width="match_parent"
......@@ -46,32 +45,41 @@
<com.mints.goodmoney.ui.widgets.BannerView
android:id="@+id/bv_friends_task"
android:layout_width="match_parent"
android:layout_height="120dp"
android:layout_height="80dp"
android:layout_marginTop="10dp"
android:layout_marginBottom="10dp"
app:bannerAnimDuration="1500"
app:bannerAnimScroll="true"
app:bannerAutoScroll="true"
app:bannerAutoScroll="false"
app:bannerPageAlpha="0"
app:bannerPageMargin="8dp"
app:bannerPagePercent="0.9"
app:bannerPageScale="0.8"
app:bannerScrollDuration="4000" />
<com.mints.goodmoney.ui.widgets.BannerView
android:id="@+id/bv_friends_banner"
<include layout="@layout/item_divider_gray" />
<!-- <com.mints.goodmoney.ui.widgets.BannerView-->
<!-- android:id="@+id/bv_friends_banner"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="100dp"-->
<!-- app:bannerAnimDuration="1500"-->
<!-- app:bannerAnimScroll="true"-->
<!-- app:bannerAutoScroll="true"-->
<!-- app:bannerPageAlpha="0"-->
<!-- app:bannerPageMargin="8dp"-->
<!-- app:bannerPagePercent="0.9"-->
<!-- app:bannerPageScale="0.8"-->
<!-- app:bannerScrollDuration="4000" />-->
<ImageView
android:layout_width="match_parent"
android:layout_height="120dp"
app:bannerAnimDuration="1500"
app:bannerAnimScroll="true"
app:bannerAutoScroll="true"
app:bannerPageAlpha="0"
app:bannerPageMargin="8dp"
app:bannerPagePercent="0.9"
app:bannerPageScale="0.8"
app:bannerScrollDuration="4000" />
android:layout_height="wrap_content"
android:padding="15dp"
android:scaleType="centerCrop"
android:src="@mipmap/bg_friends" />
<include
android:id="@+id/view_title2"
layout="@layout/view_title" />
<include layout="@layout/item_divider_gray" />
</LinearLayout>
......@@ -83,29 +91,25 @@
android:layout_height="56dp"
android:layout_gravity="center_horizontal"
app:indicatorEndColor="#e73820"
app:indicatorMarginBottom="3dp"
app:indicatorMarginEnd="22dp"
app:indicatorMarginStart="22dp"
app:indicatorMarginEnd="20dp"
app:indicatorMarginStart="20dp"
app:indicatorStartColor="#d6694e"
app:tabIndicatorHeight="4dp"
app:tabMode="scrollable" />
app:tabMode="scrollable"
app:tabSelectedTextColor="@color/my_color_orange"
app:tabTextAppearance="@style/TabLayoutTextSize"
app:tabTextColor="@color/main_bg_text" />
</com.google.android.material.appbar.AppBarLayout>
<androidx.core.widget.NestedScrollView
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recy_friends"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recy_friends"
android:layout_width="match_parent"
android:layout_height="1000dp"
android:background="@color/blue"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
</androidx.core.widget.NestedScrollView>
android:layout_marginStart="15dp"
android:layout_marginEnd="15dp"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
......
......@@ -22,6 +22,7 @@
android:layout_height="wrap_content" />
<androidx.core.widget.NestedScrollView
android:overScrollMode="never"
android:layout_width="match_parent"
android:layout_height="wrap_content">
......
......@@ -2,13 +2,16 @@
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp">
android:layout_height="wrap_content">
<ImageView
android:id="@+id/item_bv_friends_task_iv"
android:layout_width="60dp"
android:layout_height="60dp"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginStart="20dp"
android:layout_marginTop="10dp"
android:layout_marginBottom="10dp"
android:src="@mipmap/ic_friends_task"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
......@@ -18,7 +21,11 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:text="任务1"
android:textColor="@color/black"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toEndOf="@id/item_bv_friends_task_iv"
app:layout_constraintTop_toTopOf="parent" />
......@@ -27,16 +34,20 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginBottom="10dp"
android:text="邀请1名好友"
android:textColor="@color/main_bg_text"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toEndOf="@id/item_bv_friends_task_iv" />
<Button
android:id="@+id/item_bv_friends_task_btn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_width="70dp"
android:layout_height="30dp"
android:layout_marginEnd="20dp"
android:background="@drawable/shape_btn_orange"
android:text="去邀请"
android:textColor="@color/my_color_orange"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
......
......@@ -6,28 +6,30 @@
android:layout_marginStart="6dp"
android:layout_marginEnd="6dp"
android:background="@mipmap/bg_sign"
android:gravity="center_vertical"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="30dp"
android:layout_marginTop="30dp"
android:layout_marginBottom="16dp"
android:gravity="center_vertical"
android:orientation="horizontal">
<ImageView
android:id="@+id/item_clock_sign"
android:layout_width="30dp"
android:layout_height="30dp"
android:src="@mipmap/ic_sign_icon"
android:visibility="visible" />
android:src="@mipmap/ic_sign_icon" />
<TextView
android:id="@+id/item_clock_signday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginStart="16pt" />
android:textColor="@color/black"
android:textSize="16sp"
android:textStyle="bold" />
</LinearLayout>
......@@ -36,7 +38,6 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:visibility="visible" />
android:layout_marginRight="20dp" />
</LinearLayout>
\ No newline at end of file
<?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="100dp"
android:orientation="horizontal"
android:paddingStart="10dp"
android:paddingEnd="10dp">
android:layout_height="60dp"
android:orientation="horizontal">
<ImageView
android:id="@+id/item_title_img"
android:layout_width="60dp"
android:layout_height="60dp"
android:layout_gravity="center_vertical"
android:src="@mipmap/ic_versus_drinkone" />
android:layout_width="26dp"
android:layout_height="26dp"
android:layout_gravity="center_vertical" />
<LinearLayout
<RelativeLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:orientation="vertical">
android:layout_weight="1">
<RelativeLayout
<TextView
android:id="@+id/item_task_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="6dp">
<TextView
android:id="@+id/item_task_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginBottom="6dp"
android:text="首次喝水打卡"
android:textColor="@color/black"
android:textSize="16sp" />
<TextView
android:id="@+id/item_task_money"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginStart="10dp"
android:layout_toEndOf="@+id/item_task_title"
android:drawableStart="@mipmap/ic_gold"
android:drawablePadding="2dp"
android:gravity="center_vertical"
android:text="1000"
android:textColor="@color/main_mints"
android:textSize="12sp" />
</RelativeLayout>
android:layout_centerVertical="true"
android:layout_marginBottom="6dp"
android:text="首次喝水打卡"
android:textColor="@color/black"
android:textSize="16sp" />
<TextView
android:id="@+id/item_task_info"
android:id="@+id/item_task_progress"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="喝水还能赚金币,健康挣钱两不误"
android:textColor="@color/graya"
android:textSize="12sp" />
</LinearLayout>
android:layout_centerVertical="true"
android:layout_marginStart="10dp"
android:layout_toEndOf="@+id/item_task_title"
android:gravity="center_vertical"
android:text="1000"
android:textColor="@color/black"
android:textSize="16sp" />
</RelativeLayout>
<TextView
android:id="@+id/item_task_click"
android:layout_width="90dp"
android:layout_height="30dp"
android:layout_width="80dp"
android:layout_height="32dp"
android:layout_gravity="center_vertical"
android:background="@drawable/shape_main_water"
android:background="@drawable/shape_btn_orange"
android:gravity="center"
android:text="立即领取"
android:textColor="@color/white"
android:textSize="12sp" />
android:textColor="@color/my_color_orange"
android:textSize="14sp" />
</LinearLayout>
\ No newline at end of file
......@@ -46,18 +46,20 @@
android:id="@+id/item_title_invitecode"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/black"
android:layout_gravity="center_vertical"
android:textColor="@color/loan_tv_choose_paycash"
android:textSize="14sp" />
<TextView
android:id="@+id/item_title_invitecode_copy"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="10dp"
android:background="@drawable/shape_tv_gold_gury"
android:paddingLeft="12dp"
android:paddingLeft="10dp"
android:paddingTop="2dp"
android:paddingRight="12dp"
android:paddingRight="10dp"
android:paddingBottom="2dp"
android:text="复制"
android:textColor="@color/main_bg_text"
......@@ -70,7 +72,7 @@
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_gravity="center_vertical"
android:padding="10dp"
android:padding="12dp"
android:src="@mipmap/ic_arrow_more" />
</LinearLayout>
......@@ -85,12 +87,12 @@
android:elevation="2dip"
android:gravity="center_vertical"
android:orientation="horizontal"
android:paddingStart="10dp"
android:paddingEnd="10dp">
android:paddingStart="15dp"
android:paddingEnd="15dp">
<ImageView
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_width="32dp"
android:layout_height="32dp"
android:src="@mipmap/ic_gold" />
<TextView
......@@ -108,14 +110,13 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:text="5434344"
android:textColor="@color/my_color_orange"
android:textSize="26sp" />
android:textSize="30sp" />
<Button
android:id="@+id/btn_withdraw"
android:layout_width="60dp"
android:layout_height="30dp"
android:layout_height="32dp"
android:layout_marginStart="10dp"
android:background="@drawable/shape_btn_switch"
android:text="提现"
......
......@@ -2,24 +2,23 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingTop="4dp"
android:paddingBottom="6dp"
android:orientation="vertical">
android:orientation="vertical"
android:paddingTop="10dp">
<ImageView
android:id="@+id/ic_my_icon"
android:layout_width="38dp"
android:scaleType="fitXY"
android:layout_height="38dp"
android:layout_gravity="center_horizontal"
android:scaleType="fitXY"
android:src="@mipmap/ic_my_gury" />
<TextView
android:id="@+id/tv_my_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="2dp"
android:layout_gravity="center_horizontal"
android:textColor="@color/product_net_text"
android:textSize="12sp" />
android:layout_marginTop="10dp"
android:textColor="@color/color_555"
android:textSize="14sp" />
</LinearLayout>
\ No newline at end of file
<?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:layout_height="50dp"
android:gravity="center_vertical"
android:orientation="horizontal">
android:orientation="horizontal"
android:padding="10dp">
<ImageView
android:id="@+id/item_invite_iv_ranking"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="3dp"
android:visibility="gone" />
<TextView
android:id="@+id/item_invited_tv_num"
......@@ -12,22 +20,34 @@
android:text="1" />
<ImageView
android:id="@+id/item_invited_iv"
android:layout_width="60dp"
android:layout_height="60dp" />
android:id="@+id/item_invited_iv_avatar"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginStart="10dp" />
<TextView
android:layout_weight="1"
android:id="@+id/item_invited_tv_name"
android:layout_width="wrap_content"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="我的好友" />
android:layout_marginStart="10dp"
android:layout_weight="1"
android:text="我的好友"
android:textColor="@color/black_text"
android:textSize="16sp" />
<TextView
android:id="@+id/item_invited_tv_coin"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="99999999金币" />
android:text="999999"
android:textColor="@color/my_color_orange"
android:textSize="20sp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="金币"
android:textColor="@color/my_color_orange"
android:textSize="14sp" />
</LinearLayout>
\ No newline at end of file
......@@ -5,7 +5,7 @@
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="2dp"
android:layout_height="1dp"
android:layout_gravity="center_vertical"
android:layout_marginStart="14dp"
android:layout_marginTop="-7dp"
......@@ -21,14 +21,14 @@
android:id="@+id/ll_sign_firstday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_first"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:textColor="@color/white"
android:textSize="@dimen/font_size_14" />
......@@ -37,6 +37,7 @@
android:id="@+id/tv_sign_firstday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="1天"
android:textColor="@color/main_bg_text"
......@@ -47,14 +48,14 @@
android:id="@+id/ll_sign_twoday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_two"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:textColor="@color/white"
android:textSize="@dimen/font_size_14" />
......@@ -63,6 +64,7 @@
android:id="@+id/tv_sign_twoday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="2天"
android:textColor="@color/main_bg_text"
......@@ -73,14 +75,14 @@
android:id="@+id/ll_sign_threeday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_three"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:textColor="@color/white"
android:textSize="@dimen/font_size_14" />
......@@ -89,6 +91,7 @@
android:id="@+id/tv_sign_threeday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="3天"
android:textColor="@color/main_bg_text"
......@@ -99,14 +102,14 @@
android:id="@+id/ll_sign_fourday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_four"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:textColor="@color/white"
android:textSize="@dimen/font_size_14" />
......@@ -115,6 +118,7 @@
android:id="@+id/tv_sign_fourday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="4天"
android:textColor="@color/main_bg_text"
......@@ -125,14 +129,14 @@
android:id="@+id/ll_sign_fiveday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_five"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:textColor="@color/white"
android:textSize="@dimen/font_size_14" />
......@@ -141,6 +145,7 @@
android:id="@+id/tv_sign_fiveday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="5天"
android:textColor="@color/main_bg_text"
......@@ -151,14 +156,14 @@
android:id="@+id/ll_sign_sixday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_six"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:textColor="@color/white"
android:textSize="@dimen/font_size_14" />
......@@ -167,6 +172,7 @@
android:id="@+id/tv_sign_sixday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="6天"
android:textColor="@color/main_bg_text"
......@@ -177,14 +183,14 @@
android:id="@+id/ll_sign_sevenday"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_sign_seven"
android:layout_width="25dp"
android:layout_height="25dp"
android:layout_width="30dp"
android:layout_height="30dp"
android:gravity="center"
android:text="78"
android:textColor="@color/white"
......@@ -194,6 +200,7 @@
android:id="@+id/tv_sign_sevenday"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical"
android:text="7天"
android:textColor="@color/main_bg_text"
......
......@@ -153,6 +153,7 @@
<color name="my_color_orange">#FB560C</color>
<color name="color_999">#999999</color>
<color name="color_555">#555555</color>
<color name="color_F5F">#F5F5F5</color>
<color name="color_F8F">#F8F8F8</color>
<color name="color_D81B60">#D81B60</color>
......
......@@ -118,4 +118,17 @@
<item name="android:textColor">#cb4a39</item>
<item name="android:fontFamily">sans-serif-condensed</item>
</style>
<!--默认Tablayout字体大小-->
<style name="TabLayoutTextSize">
<item name="android:textSize">@dimen/font_size_18</item>
</style>
<!--设置Tablayout字体加粗-->
<style name="TabLayoutTextStyle">
<item name="android:textStyle">bold</item>
</style>
<!--变大Tablayout字体-->
<style name="BigTabLayoutTextStyle">
<item name="android:textSize">@dimen/font_size_20</item>
</style>
</resources>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment