Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
android
/
dayu
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
209c7003
authored
Sep 27, 2020
by
mReturn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
V2.6.6
parent
7008a8c2
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
81 additions
and
30 deletions
app/src/main/java/com/dayu/bigfish/presenter/setting/SettingPresenter.java
app/src/main/res/layout/activity_setting.xml
baseSDK/src/main/java/com/dayu/common/Constants.java
baseSDK/src/main/res/values/strings.xml
orderCenter/src/main/java/com/dayu/order/api/OrderService.java
orderCenter/src/main/java/com/dayu/order/ui/fragment/MultiOrderDetailFragment.java
userCenter/src/main/java/com/dayu/usercenter/ui/activity/AgreementActivity.java
userCenter/src/main/java/com/dayu/usercenter/ui/fragment/HomeUserFragment.java
app/src/main/java/com/dayu/bigfish/presenter/setting/SettingPresenter.java
View file @
209c7003
...
...
@@ -11,8 +11,10 @@ import com.dayu.bigfish.R;
import
com.dayu.bigfish.api.ApiFactory
;
import
com.dayu.bigfish.ui.AboutUsActivity
;
import
com.dayu.bigfish.ui.FeedBackActivity
;
import
com.dayu.common.BaseApplication
;
import
com.dayu.common.Constants
;
import
com.dayu.event.UserInfo
;
import
com.dayu.usercenter.ui.activity.AgreementActivity
;
import
com.dayu.usercenter.ui.activity.SmsLoginActivity
;
import
com.dayu.utils.AppManager
;
import
com.dayu.utils.AppUtils
;
...
...
@@ -188,4 +190,10 @@ public class SettingPresenter extends SettingContract.Presenter {
MobclickAgent
.
onEvent
(
MyApplication
.
getContext
(),
"feed_back"
);
}
public
void
dumpToPrivacy
()
{
Constants
.
isPrivacy
=
true
;
mView
.
startActivity
(
AgreementActivity
.
class
);
MobclickAgent
.
onEvent
(
BaseApplication
.
getContext
(),
"customer_agreement"
);
}
}
app/src/main/res/layout/activity_setting.xml
View file @
209c7003
...
...
@@ -216,6 +216,33 @@
<TextView
style=
"@style/line"
/>
<RelativeLayout
android:id=
"@+id/rl_privacy"
android:layout_width=
"match_parent"
android:layout_height=
"54dp"
android:background=
"@color/cl_white"
android:onClick=
"@{()->presenter.dumpToPrivacy()}"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginLeft=
"13.3dp"
android:text=
"@string/privacy_protocol"
android:textColor=
"@color/cl_home_title_text_color"
android:textSize=
"14.7sp"
/>
<ImageView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"13.3dp"
android:src=
"@mipmap/list_more"
/>
</RelativeLayout>
<TextView
style=
"@style/line"
/>
<Button
android:id=
"@+id/exit_button"
android:layout_width=
"match_parent"
...
...
baseSDK/src/main/java/com/dayu/common/Constants.java
View file @
209c7003
...
...
@@ -60,19 +60,19 @@ public class Constants {
/**
* uat测试环境配置.
*/
public
static
String
ENVIROMENT
=
"uat"
;
public
static
int
LOG_LEVEL
=
LogUtils
.
LEVEL_ALL
;
public
static
String
BASE_URL
=
"http://47.95.223.6:3112"
;
public
static
String
WEB_SOP
=
"http://47.95.223.6:9004/#/sop"
;
public
static
String
WEB_SOP_DETAIL
=
"http://47.95.223.6:9004/#/sopdetail"
;
public
static
String
WEB_ZHI_SHI
=
"http://47.95.223.6:9004/#/detail"
;
public
static
String
CHECK_MULTI_WEB_SOP
=
"http://47.95.223.6:9004/#/manyServiceResult"
;
public
static
String
MULTI_WEB_SOP
=
"http://47.95.223.6:9004/#/manySop"
;
public
static
final
String
UP_PHOTO
=
"/file/uploadMore?targetPath=test/sp/mobile/android/business/checkApply"
;
public
static
final
String
UP_VIDEO
=
"/file/uploadVideoOne?targetPath=test/video"
;
public
static
final
boolean
IS_DEBUG
=
false
;
public
static
String
VIDEO_SHARE_URL
=
"http://uat.kf.ai:9099/#/shareVideo?type=_type&id="
;
//uat 学习视频分享链接 type(课程: course 直播: live)
public
static
int
XLR_PID
=
14
;
//小绿人商家id
//
public static String ENVIROMENT = "uat";
//
public static int LOG_LEVEL = LogUtils.LEVEL_ALL;
//
public static String BASE_URL = "http://47.95.223.6:3112";
//
public static String WEB_SOP = "http://47.95.223.6:9004/#/sop";
//
public static String WEB_SOP_DETAIL = "http://47.95.223.6:9004/#/sopdetail";
//
public static String WEB_ZHI_SHI = "http://47.95.223.6:9004/#/detail";
//
public static String CHECK_MULTI_WEB_SOP = "http://47.95.223.6:9004/#/manyServiceResult";
//
public static String MULTI_WEB_SOP = "http://47.95.223.6:9004/#/manySop";
//
public static final String UP_PHOTO = "/file/uploadMore?targetPath=test/sp/mobile/android/business/checkApply";
//
public static final String UP_VIDEO = "/file/uploadVideoOne?targetPath=test/video";
//
public static final boolean IS_DEBUG = false;
//
public static String VIDEO_SHARE_URL = "http://uat.kf.ai:9099/#/shareVideo?type=_type&id="; //uat 学习视频分享链接 type(课程: course 直播: live)
//
public static int XLR_PID = 14; //小绿人商家id
...
...
@@ -80,19 +80,19 @@ public class Constants {
/**
* 正式环境.
*/
//
public static String ENVIROMENT = "release";
//
public static int LOG_LEVEL = LogUtils.LEVEL_OFF;
//
public static String BASE_URL = "https://mobile.kf.ai";
//
public static String WEB_SOP = "https://sop.kf.ai/#/sop";
//
public static String WEB_SOP_DETAIL = "https://sop.kf.ai/#/sopdetail";
//
public static String WEB_ZHI_SHI = "https://sop.kf.ai/#/detail";
//
public static String CHECK_MULTI_WEB_SOP = "https://sop.kf.ai/#/manyServiceResult";
//
public static String MULTI_WEB_SOP = "https://sop.kf.ai/#/manySop";
//
public static final String UP_PHOTO = "/file/uploadMore?targetPath=online/sp/mobile/android/business/checkApply";
//
public static final String UP_VIDEO = "/file/uploadVideoOne?targetPath=online/video";
//
public static final boolean IS_DEBUG = false;
//
public static String VIDEO_SHARE_URL = "http://app.dl.kf.ai/ext/#/shareVideo?type=_type&id="; //学习视频分享链接 type(课程: course 直播: live)
//
public static int XLR_PID = 1936; //小绿人商家id
public
static
String
ENVIROMENT
=
"release"
;
public
static
int
LOG_LEVEL
=
LogUtils
.
LEVEL_OFF
;
public
static
String
BASE_URL
=
"https://mobile.kf.ai"
;
public
static
String
WEB_SOP
=
"https://sop.kf.ai/#/sop"
;
public
static
String
WEB_SOP_DETAIL
=
"https://sop.kf.ai/#/sopdetail"
;
public
static
String
WEB_ZHI_SHI
=
"https://sop.kf.ai/#/detail"
;
public
static
String
CHECK_MULTI_WEB_SOP
=
"https://sop.kf.ai/#/manyServiceResult"
;
public
static
String
MULTI_WEB_SOP
=
"https://sop.kf.ai/#/manySop"
;
public
static
final
String
UP_PHOTO
=
"/file/uploadMore?targetPath=online/sp/mobile/android/business/checkApply"
;
public
static
final
String
UP_VIDEO
=
"/file/uploadVideoOne?targetPath=online/video"
;
public
static
final
boolean
IS_DEBUG
=
false
;
public
static
String
VIDEO_SHARE_URL
=
"http://app.dl.kf.ai/ext/#/shareVideo?type=_type&id="
;
//学习视频分享链接 type(课程: course 直播: live)
public
static
int
XLR_PID
=
1936
;
//小绿人商家id
...
...
@@ -307,5 +307,5 @@ public class Constants {
public
static
final
int
BY_MODIFY_PART
=
2
;
public
static
boolean
isPrivacy
=
false
;
}
baseSDK/src/main/res/values/strings.xml
View file @
209c7003
...
...
@@ -547,6 +547,7 @@
<string
name=
"customer_server_mobile"
>
客服电话
</string>
<string
name=
"abount_us"
>
关于我们
</string>
<string
name=
"problem_feedback"
>
问题反馈
</string>
<string
name=
"privacy_protocol"
>
隐私协议
</string>
<string
name=
"personal_info"
>
我的资料
</string>
<string
name=
"modify_personal_info"
>
修改资料
</string>
<string
name=
"submission_of_audit"
>
提交审核
</string>
...
...
orderCenter/src/main/java/com/dayu/order/api/OrderService.java
View file @
209c7003
...
...
@@ -558,6 +558,7 @@ public interface OrderService {
*/
@GET
(
Constants
.
API_7600
+
"/guarantee/sn/{sn}"
)
Observable
<
BaseResponse
<
OrderDetailDeviceInfoBean
>>
getDeviceInfo
(
@Path
(
"sn"
)
String
sn
,
@Query
(
"companyId"
)
int
companyId
,
@Query
(
"type"
)
int
type
);
/**
...
...
orderCenter/src/main/java/com/dayu/order/ui/fragment/MultiOrderDetailFragment.java
View file @
209c7003
...
...
@@ -192,7 +192,7 @@ public class MultiOrderDetailFragment extends BaseFragment<SImplePresenter, Frag
if
(!
TextUtils
.
isEmpty
(
detail
.
getSn
())){
showDialog
();
mBind
.
tvDeviceSn
.
setText
(
detail
.
getSn
());
Api
.
getService
(
OrderService
.
class
).
getDeviceInfo
(
detail
.
getSn
(),
2
).
compose
(
Api
.
applySchedulers
())
Api
.
getService
(
OrderService
.
class
).
getDeviceInfo
(
detail
.
getSn
(),
detail
.
getCreateProviderId
(),
2
).
compose
(
Api
.
applySchedulers
())
.
subscribe
(
mPresenter
.
baseObserver
(
result
->{
if
(
result
!=
null
){
mBind
.
tvDeviceTime
.
setText
(
result
.
getGuaranteeEndDate
());
...
...
userCenter/src/main/java/com/dayu/usercenter/ui/activity/AgreementActivity.java
View file @
209c7003
package
com
.
dayu
.
usercenter
.
ui
.
activity
;
import
com.dayu.base.ui.activity.DataBindingActivity
;
import
com.dayu.common.Constants
;
import
com.dayu.usercenter.R
;
import
com.dayu.usercenter.databinding.ActivityAgreementBinding
;
...
...
@@ -17,8 +18,17 @@ public class AgreementActivity extends DataBindingActivity<ActivityAgreementBind
@Override
public
void
initView
()
{
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
title_agreement
));
if
(
Constants
.
isPrivacy
){
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
privacy_protocol
));
}
else
{
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
title_agreement
));
}
mBind
.
toolbar
.
setNavigationOnClickListener
(
o
->
finish
());
}
@Override
protected
void
onDestroy
()
{
super
.
onDestroy
();
Constants
.
isPrivacy
=
false
;
}
}
userCenter/src/main/java/com/dayu/usercenter/ui/fragment/HomeUserFragment.java
View file @
209c7003
...
...
@@ -176,6 +176,7 @@ public class HomeUserFragment extends BaseFragment<HomeUserPresenter, FragmentHo
public
void
getPersonalInfoSuccess
(
EngineerInfo
info
)
{
// mBind.tvStartLive.setVisibility(View.VISIBLE);
setUserNick
(
info
.
getNickName
());
saveUserInfo
(
info
);
mBind
.
tvStartLive
.
setVisibility
(
info
.
getLiveStatus
()
==
1
?
View
.
VISIBLE
:
View
.
GONE
);
if
(
TextUtils
.
isEmpty
(
info
.
getIdentity
()))
{
SPUtils
.
put
(
"USER_IDENTITY"
,
""
);
...
...
@@ -209,6 +210,10 @@ public class HomeUserFragment extends BaseFragment<HomeUserPresenter, FragmentHo
SPUtils
.
put
(
"USER_PHONE"
,
mUserPhone
);
SPUtils
.
put
(
"USER_NAME"
,
mUserName
);
mPresenter
.
mUrl
.
set
(
info
.
getAccountUrl
());
}
//保存用户信息
private
void
saveUserInfo
(
EngineerInfo
info
)
{
UserInfo
userInfo
=
UserManager
.
getInstance
().
getUser
();
if
(
userInfo
!=
null
)
{
userInfo
.
setAccountName
(
info
.
getRealName
());
...
...
@@ -217,7 +222,6 @@ public class HomeUserFragment extends BaseFragment<HomeUserPresenter, FragmentHo
userInfo
.
setLiveStatus
(
info
.
getLiveStatus
());
userInfo
.
setLianmaiStatus
(
info
.
getLianmaiStatus
());
UserManager
.
getInstance
().
saveUser
(
userInfo
);
}
}
...
...
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