Commit c7d8a3f1 authored by maxiaoliang's avatar maxiaoliang

提交代码

parent a42f7c81
...@@ -39,7 +39,7 @@ public class GenerateTestUserSig { ...@@ -39,7 +39,7 @@ public class GenerateTestUserSig {
* 它是腾讯云用于区分客户的唯一标识。 * 它是腾讯云用于区分客户的唯一标识。
*/ */
// public static final int SDKAPPID = 1400605334; // public static final int SDKAPPID = 1400605334;
public static final int SDKAPPID = 1400655771; public static final int SDKAPPID = 1400813486;
/** /**
......
...@@ -50,6 +50,7 @@ ...@@ -50,6 +50,7 @@
<activity <activity
android:name="com.zhangxin.starlight.activity.MainActivity" android:name="com.zhangxin.starlight.activity.MainActivity"
android:exported="true" android:exported="true"
android:screenOrientation="portrait"
android:launchMode="singleTask"> android:launchMode="singleTask">
<intent-filter> <intent-filter>
<action android:name="android.intent.action.VIEW" /> <action android:name="android.intent.action.VIEW" />
......
...@@ -27,7 +27,7 @@ public class Constant { ...@@ -27,7 +27,7 @@ public class Constant {
public static String WX_APPID = "wx7fc1506d059d5ac1"; public static String WX_APPID = "wx7fc1506d059d5ac1";
public static String WX_APPKEY = "77202c1939fbe6421f2e9c998a0bbec0"; public static String WX_APPKEY = "77202c1939fbe6421f2e9c998a0bbec0";
// public static int SDKAPPID = 1400605334; // public static int SDKAPPID = 1400605334;
public static int SDKAPPID = 1400655771; public static int SDKAPPID = 1400813486;
public static String PAY_RESULT = "pay_result"; public static String PAY_RESULT = "pay_result";
......
...@@ -54,7 +54,9 @@ public class NetConfig { ...@@ -54,7 +54,9 @@ public class NetConfig {
BASE_FEED_URL = "https://feedapi-sandbox.zhangxinhulian.com/"; BASE_FEED_URL = "https://feedapi-sandbox.zhangxinhulian.com/";
break; break;
default: default:
BASE_URL = "http://feedapitest4.zhangxinhulian.com/"; // BASE_URL = "http://feedapitest4.zhangxinhulian.com/";
// BASE_URL = "http://8.218.187.222:19897/";
BASE_URL = "http://192.168.124.59:19898/";
BASE_WEB_URL = "http://feedapitest4.zhangxinhulian.com/"; BASE_WEB_URL = "http://feedapitest4.zhangxinhulian.com/";
BASE_NEW_URL = "http://feedapitest4.zhangxinhulian.com/"; BASE_NEW_URL = "http://feedapitest4.zhangxinhulian.com/";
BASE_FEED_URL = "http://feedapitest4.zhangxinhulian.com/"; BASE_FEED_URL = "http://feedapitest4.zhangxinhulian.com/";
...@@ -206,18 +208,18 @@ public class NetConfig { ...@@ -206,18 +208,18 @@ public class NetConfig {
} }
public static class H5 { public static class H5 {
public static String WEB_URL_USER = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xgchat/hk/StarlightTermsOfService.html?version="+ Constant.Param.vn+"&appName=StarLight&company=北京志信博文科技发展有限公司"; public static String WEB_URL_USER = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xgchat/hk/StarlightTermsOfService.html?version=" + Constant.Param.vn + "&appName=StarLight&company=北京志信博文科技发展有限公司";
public static String WEB_URL_PRIVACY = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xgchat/hk/StarlightPrivacyPolicy.html?version="+ Constant.Param.vn+"&appName=StarLight&company=北京志信博文科技发展有限公司"; public static String WEB_URL_PRIVACY = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xgchat/hk/StarlightPrivacyPolicy.html?version=" + Constant.Param.vn + "&appName=StarLight&company=北京志信博文科技发展有限公司";
public static String WEB_URL_ABOUT_US = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xingyunmohe/aboutMe.html?version="+ Constant.Param.vn+"&appName=StarLight&company=北京志信博文科技发展有限公司"; public static String WEB_URL_ABOUT_US = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xingyunmohe/aboutMe.html?version=" + Constant.Param.vn + "&appName=StarLight&company=北京志信博文科技发展有限公司";
//public static String WEB_URL_CUSTOMER_SERVICE = "https://1568685.s4.udesk.cn/im_client/?web_plugin_id=25351"; //public static String WEB_URL_CUSTOMER_SERVICE = "https://1568685.s4.udesk.cn/im_client/?web_plugin_id=25351";
public static String WEB_URL_BUYER_KNOW = "https://newspool.zhangxinhulian.com//sspapiNovel/su/custom/xgchat/add_value.html?version="+ Constant.Param.vn+"&appName=StarLight&company=北京志信博文科技发展有限公司"; public static String WEB_URL_BUYER_KNOW = "https://newspool.zhangxinhulian.com//sspapiNovel/su/custom/xgchat/add_value.html?version=" + Constant.Param.vn + "&appName=StarLight&company=北京志信博文科技发展有限公司";
public static String WEB_URL_INVITE; public static String WEB_URL_INVITE;
public static String WEB_URL_CUSTOMER_SERVICE="http://cdn-apph5.zhangxinzhixun.com/favorite/newService?pkg=com.zhangxin.starlight"; public static String WEB_URL_CUSTOMER_SERVICE = "http://cdn-apph5.zhangxinzhixun.com/favorite/newService?pkg=com.zhangxin.starlight";
public static String WEB_URL_WINTER_RULE="https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xingyunmohe/winter_mh_activity_ruleV1.0.6.html"; public static String WEB_URL_WINTER_RULE = "https://newspool.zhangxinhulian.com/sspapiNovel/su/custom/xingyunmohe/winter_mh_activity_ruleV1.0.6.html";
} }
...@@ -276,16 +278,16 @@ public class NetConfig { ...@@ -276,16 +278,16 @@ public class NetConfig {
public static final String HOME_STAR_LIGHT_CLOSE_ROOM = "app/v1/game/star/closeRoom";//语音房版本 - 关闭房间 public static final String HOME_STAR_LIGHT_CLOSE_ROOM = "app/v1/game/star/closeRoom";//语音房版本 - 关闭房间
public static final String HOME_STAR_LIGHT_IN_ROOM = "app/v1/game/star/inRoom";//语音房版本 - 进入房间 public static final String HOME_STAR_LIGHT_IN_ROOM = "app/v1/game/star/inRoom";//语音房版本 - 进入房间
public static final String HOME_STAR_LIGHT_OUT_ROOM = "app/v1/game/star/outRoom";//语音房版本 - 离开房间 public static final String HOME_STAR_LIGHT_OUT_ROOM = "app/v1/game/star/outRoom";//语音房版本 - 离开房间
public static final String HOME_STAR_LIGHT_GIFT= "app/v1/game/star/room/gift";//语音房版本 - 送礼物 public static final String HOME_STAR_LIGHT_GIFT = "app/v1/game/star/room/gift";//语音房版本 - 送礼物
public static final String HOME_STAR_GIFT_WALL ="app/v1/game/star/giftWall";//语音房版本 - 礼物墙 public static final String HOME_STAR_GIFT_WALL = "app/v1/game/star/giftWall";//语音房版本 - 礼物墙
public static final String HOME_STAR_LIGHT_GET_RECENT_CONTACTS = "app/v1/game/star/getRecentContacts";//语音房版本 - 获取最近联系人(邀请) public static final String HOME_STAR_LIGHT_GET_RECENT_CONTACTS = "app/v1/game/star/getRecentContacts";//语音房版本 - 获取最近联系人(邀请)
public static final String HOME_STAR_LIGHT_GET_ROOM_USER = "app/v1/game/star/roomUser";//语音房版本 - 获取当前房内用户 public static final String HOME_STAR_LIGHT_GET_ROOM_USER = "app/v1/game/star/roomUser";//语音房版本 - 获取当前房内用户
public static final String HOME_STAR_LIGHT_BLACKLIST = "app/v1/hk/game/star/blacklist";//我的 - 黑名单列表 public static final String HOME_STAR_LIGHT_BLACKLIST = "app/v1/hk/game/star/blacklist";//我的 - 黑名单列表
public static final String HOME_STAR_BLACK= "app/v1/hk/game/star/black";//拉黑/取消拉黑 public static final String HOME_STAR_BLACK = "app/v1/hk/game/star/black";//拉黑/取消拉黑
public static final String HOME_STAR_CONSTELLATION_PAIRING= "app/v1/hk/game/star/constellationPairing";//星座配对头像列表 public static final String HOME_STAR_CONSTELLATION_PAIRING = "app/v1/hk/game/star/constellationPairing";//星座配对头像列表
public static final String HOME_STAR_CONSTELLATION_RESLUT= "app/v1/hk/game/star/constellationPairing";//星座配对 - 结果获取 public static final String HOME_STAR_CONSTELLATION_RESLUT = "app/v1/hk/game/star/constellationPairing";//星座配对 - 结果获取
public static final String HOME_STAR_MY_LIKE_LIST= "app/v1/hk/game/star/myLikeList";//我的 - 我喜欢列表 public static final String HOME_STAR_MY_LIKE_LIST = "app/v1/hk/game/star/myLikeList";//我的 - 我喜欢列表
} }
......
...@@ -20,7 +20,7 @@ object ApiClient { ...@@ -20,7 +20,7 @@ object ApiClient {
override fun intercept(chain: Interceptor.Chain): Response { override fun intercept(chain: Interceptor.Chain): Response {
val request = chain.request() val request = chain.request()
val builder = request.url.newBuilder() val builder = request.url.newBuilder()
return if (request.url.host.toString().contains("zhangxinhulian.com")) { return if (!request.url.host.contains("zhangxinhulian.com")) {
val builder = request.url.newBuilder() val builder = request.url.newBuilder()
PhoneUtils.addParam(request, builder) PhoneUtils.addParam(request, builder)
chain.proceed(request.newBuilder().url(builder.build()).build()) chain.proceed(request.newBuilder().url(builder.build()).build())
......
...@@ -46,7 +46,7 @@ object EventApiClient { ...@@ -46,7 +46,7 @@ object EventApiClient {
.connectTimeout(10000, TimeUnit.MILLISECONDS) .connectTimeout(10000, TimeUnit.MILLISECONDS)
.readTimeout(10000, TimeUnit.MILLISECONDS) .readTimeout(10000, TimeUnit.MILLISECONDS)
.addInterceptor(logInterceptor.apply { .addInterceptor(logInterceptor.apply {
level = HttpLoggingInterceptor.Level.BODY level = HttpLoggingInterceptor.Level.NONE
}) })
.hostnameVerifier { hostname, session -> .hostnameVerifier { hostname, session ->
true true
......
...@@ -36,7 +36,7 @@ public interface IUserInfoApi { ...@@ -36,7 +36,7 @@ public interface IUserInfoApi {
* @return * @return
*/ */
@GET(NetConfig.User.URL_USER_GET_USERINFO_) @GET(NetConfig.User.URL_USER_GET_USERINFO_)
Observable<Response<UserInfo>> getUserInfo(); Observable<Response<UserInfo>> getUserInfo(@Query("uid") String uid);
/** /**
...@@ -80,7 +80,8 @@ public interface IUserInfoApi { ...@@ -80,7 +80,8 @@ public interface IUserInfoApi {
*/ */
@GET(NetConfig.User.VERIFY_PAY_URL) @GET(NetConfig.User.VERIFY_PAY_URL)
Observable<Response<PayVerifyEntity>> verifyPay(@Query("outTradeNo") String outTradeNo, @Query("tradeNo") String tradeNo, @Query("payType") int payType); Observable<Response<PayVerifyEntity>> verifyPay(@Query("outTradeNo") String outTradeNo, @Query("tradeNo") String tradeNo, @Query("payType") int payType);
/**
/**
* 获取用户资料 * 获取用户资料
* *
* @return * @return
...@@ -95,29 +96,33 @@ public interface IUserInfoApi { ...@@ -95,29 +96,33 @@ public interface IUserInfoApi {
*/ */
@POST(NetConfig.User.USER_FREE_PROGRESS) @POST(NetConfig.User.USER_FREE_PROGRESS)
Observable<Response<VideoProcessEntity>> getuserProgress(); Observable<Response<VideoProcessEntity>> getuserProgress();
/** /**
* 判断弹窗 * 判断弹窗
* *
* @return * @return
*/ */
@POST(NetConfig.User.USER_CHECK_FREE_TRIALV3) @POST(NetConfig.User.USER_CHECK_FREE_TRIALV3)
Observable<Response<VideoProcessEntity>> checkFreeTrial(); Observable<Response<VideoProcessEntity>> checkFreeTrial();
/** /**
* 视频上报 * 视频上报
* *
* @return * @return
*/ */
@POST(NetConfig.User.USER_FREE_REPORT) @POST(NetConfig.User.USER_FREE_REPORT)
Observable<Response<VideoResultEntity>> freeReport(); Observable<Response<VideoResultEntity>> freeReport();
/** /**
* 支付配置-v2 - 支持打折 和 优惠卷 * 支付配置-v2 - 支持打折 和 优惠卷
* *
* @return * @return
*/ */
@GET(NetConfig.User.USER_PAY_CONFIG) @GET(NetConfig.User.USER_PAY_CONFIG)
Observable<Response<MemberEntity>> userPayConfig(@Query("payMode") String payMode); Observable<Response<MemberEntity>> userPayConfig(@Query("payMode") String payMode);
/** /**
* 试用领取 * 试用领取
* *
* @return * @return
*/ */
......
...@@ -7,4 +7,5 @@ package com.zxhl.cms.net.model.other ...@@ -7,4 +7,5 @@ package com.zxhl.cms.net.model.other
class WxBindEntity { class WxBindEntity {
var flushToken:String? = null var flushToken:String? = null
var token:String? = null var token:String? = null
var uid:String? = ""
} }
\ No newline at end of file
...@@ -57,7 +57,7 @@ class GoogleLoginUtil { ...@@ -57,7 +57,7 @@ class GoogleLoginUtil {
* google登录 * google登录
*/ */
fun googleLogin(callBack: LoginCallBack) { fun googleLogin(callBack: LoginCallBack) {
mLoginCallBack = callBack; mLoginCallBack = callBack
val account = GoogleSignIn.getLastSignedInAccount(mActivity) val account = GoogleSignIn.getLastSignedInAccount(mActivity)
if (account != null) { if (account != null) {
bindGoogle(account.id, account.displayName, account.photoUrl.toString()) bindGoogle(account.id, account.displayName, account.photoUrl.toString())
...@@ -110,6 +110,7 @@ class GoogleLoginUtil { ...@@ -110,6 +110,7 @@ class GoogleLoginUtil {
.subscribe(object : BaseObserver<WxBindEntity>() { .subscribe(object : BaseObserver<WxBindEntity>() {
override fun onSuccess(result: WxBindEntity?) { override fun onSuccess(result: WxBindEntity?) {
SettingPreference.saveToken(result?.token) SettingPreference.saveToken(result?.token)
SettingPreference.setUid(result?.uid)
UserDataUtils.updateUserInfo(null) UserDataUtils.updateUserInfo(null)
Constant.Switch.isLogin = true Constant.Switch.isLogin = true
mLoginCallBack?.onLoginSuccess() mLoginCallBack?.onLoginSuccess()
......
...@@ -41,7 +41,7 @@ public class GenerateTestUserSig { ...@@ -41,7 +41,7 @@ public class GenerateTestUserSig {
* 进入腾讯云云通信[控制台](https://console.cloud.tencent.com/avc ) 创建应用,即可看到 SDKAppId, * 进入腾讯云云通信[控制台](https://console.cloud.tencent.com/avc ) 创建应用,即可看到 SDKAppId,
* 它是腾讯云用于区分客户的唯一标识。 * 它是腾讯云用于区分客户的唯一标识。
*/ */
public static final int SDKAPPID = 1400605334; public static final int SDKAPPID = 1400813486;
/** /**
* 签名过期时间,建议不要设置的过短 * 签名过期时间,建议不要设置的过短
......
...@@ -13,7 +13,7 @@ import com.zxhl.cms.net.model.uc.UserInfo ...@@ -13,7 +13,7 @@ import com.zxhl.cms.net.model.uc.UserInfo
object UserDataUtils { object UserDataUtils {
fun updateUserInfo(callback: AdCallback<String>?) { fun updateUserInfo(callback: AdCallback<String>?) {
userInfoAPi.userInfo.compose<Response<UserInfo>>(RxSchedulers.observableIO2Main()) userInfoAPi.getUserInfo(SettingPreference.getUid()).compose<Response<UserInfo>>(RxSchedulers.observableIO2Main())
.subscribe(object : BaseObserver<UserInfo>() { .subscribe(object : BaseObserver<UserInfo>() {
override fun onSuccess(result: UserInfo) { override fun onSuccess(result: UserInfo) {
SettingPreference.saveUserInfo(result) SettingPreference.saveUserInfo(result)
......
...@@ -237,6 +237,10 @@ class LoginBeforeActivity : BaseActivity(), ImLoginContract.View { ...@@ -237,6 +237,10 @@ class LoginBeforeActivity : BaseActivity(), ImLoginContract.View {
} }
override fun getSignFail() { override fun getSignFail() {
JumpUtils.activityJump(
RounterBus.getRounter(RounterApi::class.java).getIntentActivityMain()
)
finish()
} }
} }
\ No newline at end of file
...@@ -266,7 +266,7 @@ class PopularFragment : BaseFragment(), HomeContract.View, OnRecycleItemClickLis ...@@ -266,7 +266,7 @@ class PopularFragment : BaseFragment(), HomeContract.View, OnRecycleItemClickLis
R.id.id_img_video->{ R.id.id_img_video->{
Log.e("MXL:","status:"+chatEntity?.chatStatus) Log.e("MXL:","status:"+chatEntity?.chatStatus)
chatEntity=data chatEntity=data
JumpUtils.startC2CChatActivity(1,"128814", data?.nickname) JumpUtils.startC2CChatActivity(1,data?.uid, data?.nickname)
// TUIUtils.CallVideo("128814") // TUIUtils.CallVideo("128814")
} }
R.id.id_rl_play_audio -> { R.id.id_rl_play_audio -> {
......
...@@ -4,6 +4,7 @@ import android.util.Log ...@@ -4,6 +4,7 @@ import android.util.Log
import com.zxhl.cms.ad.upload.model.Response import com.zxhl.cms.ad.upload.model.Response
import com.zxhl.cms.net.ApiClient import com.zxhl.cms.net.ApiClient
import com.zxhl.cms.net.RxSchedulers import com.zxhl.cms.net.RxSchedulers
import com.zxhl.cms.net.SettingPreference
import com.zxhl.cms.net.callback.BaseObserver import com.zxhl.cms.net.callback.BaseObserver
import com.zxhl.cms.net.model.chat.PictureEntity import com.zxhl.cms.net.model.chat.PictureEntity
import com.zxhl.cms.net.model.uc.UserInfo import com.zxhl.cms.net.model.uc.UserInfo
...@@ -19,7 +20,7 @@ class EditUserInfoPresenter : EditUserInfoContract.Presenter { ...@@ -19,7 +20,7 @@ class EditUserInfoPresenter : EditUserInfoContract.Presenter {
} }
override fun getUserInfo() { override fun getUserInfo() {
ApiClient.userInfoAPi.userInfo.compose<Response<UserInfo>>(RxSchedulers.observableIO2Main()) ApiClient.userInfoAPi.getUserInfo(SettingPreference.getUid()).compose<Response<UserInfo>>(RxSchedulers.observableIO2Main())
.subscribe(object : BaseObserver<UserInfo>() { .subscribe(object : BaseObserver<UserInfo>() {
override fun onSuccess(result: UserInfo) { override fun onSuccess(result: UserInfo) {
mView.setData(result) mView.setData(result)
......
...@@ -76,7 +76,7 @@ class LoginPresenter : LoginContract.Presenter { ...@@ -76,7 +76,7 @@ class LoginPresenter : LoginContract.Presenter {
override fun getUserInfo() { override fun getUserInfo() {
ApiClient.userInfoAPi.getUserInfo().compose(RxSchedulers.observableIO2Main()) ApiClient.userInfoAPi.getUserInfo(SettingPreference.getUid()).compose(RxSchedulers.observableIO2Main())
.subscribe(object : BaseObserver<UserInfo>() { .subscribe(object : BaseObserver<UserInfo>() {
override fun onSuccess(result: UserInfo) { override fun onSuccess(result: UserInfo) {
val uid = result.uid val uid = result.uid
......
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