Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_highgold_pro
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
android_highgold_pro
Commits
7c6571af
Commit
7c6571af
authored
Feb 04, 2021
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
ecd60dcb
Changes
15
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
110 additions
and
77 deletions
+110
-77
build.gradle
app/build.gradle
+1
-2
articlesdk-v1.0.6.202012121917-x.aar
app/libs/articlesdk-v1.0.6.202012121917-x.aar
+0
-0
MintsApplication.java
app/src/main/java/com/mints/goldspace/MintsApplication.java
+0
-3
Constant.kt
app/src/main/java/com/mints/goldspace/common/Constant.kt
+3
-9
CpdSydManager.kt
...rc/main/java/com/mints/goldspace/manager/CpdSydManager.kt
+3
-3
TaskPresenter.kt
.../java/com/mints/goldspace/mvp/presenters/TaskPresenter.kt
+2
-2
WebActivity.kt
...main/java/com/mints/goldspace/ui/activitys/WebActivity.kt
+1
-0
TaskCpdFragment.kt
...n/java/com/mints/goldspace/ui/fragment/TaskCpdFragment.kt
+25
-7
WzFragment.kt
...c/main/java/com/mints/goldspace/ui/fragment/WzFragment.kt
+21
-8
activity_award.xml
app/src/main/res/layout/activity_award.xml
+11
-3
activity_web.xml
app/src/main/res/layout/activity_web.xml
+1
-36
fragment_main_wz.xml
app/src/main/res/layout/fragment_main_wz.xml
+1
-1
item_fragment_main_my_customer_service.xml
...ain/res/layout/item_fragment_main_my_customer_service.xml
+1
-1
web_header_layout.xml
app/src/main/res/layout/web_header_layout.xml
+38
-0
gradle.properties
gradle.properties
+2
-2
No files found.
app/build.gradle
View file @
7c6571af
...
...
@@ -258,8 +258,7 @@ dependencies {
implementation
(
name:
'scenead-2.2'
,
ext:
'aar'
)
implementation
'com.just.agentweb:agentweb:4.1.2'
// 喜马拉雅 已集成
// 微转阅读
// implementation(name: 'articlesdk-v1.0.6.202012121917-x', ext: 'aar')
// 微转阅读(集成h5)
//天卓SDK的珊瑚2.0组件
implementation
(
name:
'adapt-1.3.3'
,
ext:
'aar'
)
implementation
(
name:
'commonbase-1.0.2'
,
ext:
'aar'
)
...
...
app/libs/articlesdk-v1.0.6.202012121917-x.aar
deleted
100644 → 0
View file @
ecd60dcb
File deleted
app/src/main/java/com/mints/goldspace/MintsApplication.java
View file @
7c6571af
...
...
@@ -113,9 +113,6 @@ public class MintsApplication extends MultiDexApplication {
// 移动安全联盟 oaid
initMiitHelper
();
// 按渠道匹配代码位
ChannelManager
.
INSTANCE
.
updataCodeIdForRegisterChannel
(
null
);
// 优量汇
YlhAdManager
.
INSTANCE
.
initYlhAd
(
this
);
...
...
app/src/main/java/com/mints/goldspace/common/Constant.kt
View file @
7c6571af
...
...
@@ -78,9 +78,9 @@ object Constant {
const
val
FRAGMENT_TAG_RSNEWS
=
"FRAGMENT_TAG_RSNEWS"
// 协议地址
var
REGISTER_URL
=
BuildConfig
.
MainIp
+
"g
m
/register.html"
//服务协议
var
PRIVACY_URL
=
BuildConfig
.
MainIp
+
"g
m
/privacy.html"
//隐私协议
var
STRATEGY_URL
=
BuildConfig
.
MainIp
+
"g
m
/strategy.html"
//团长攻略
var
REGISTER_URL
=
BuildConfig
.
MainIp
+
"g
s
/register.html"
//服务协议
var
PRIVACY_URL
=
BuildConfig
.
MainIp
+
"g
s
/privacy.html"
//隐私协议
var
STRATEGY_URL
=
BuildConfig
.
MainIp
+
"g
s
/strategy.html"
//团长攻略
/**
...
...
@@ -229,12 +229,6 @@ object Constant {
// 分页 条数
const
val
PAGE_SIZE
=
15
// 是否是高额任务
const
val
IS_HIGH_TASK
=
"is_high_task"
// 高额任务分享包名变量存储
const
val
HIGH_TASK_PKG_NAME
=
"high_task_pkg_name"
// 外网IP地址
const
val
OUT_NET_IP
=
"out_net_ip"
}
app/src/main/java/com/mints/goldspace/manager/CpdManager.kt
→
app/src/main/java/com/mints/goldspace/manager/Cpd
Syd
Manager.kt
View file @
7c6571af
...
...
@@ -15,10 +15,10 @@ import org.json.JSONObject
/**
* 圣于地Cpd下载
*/
object
CpdManager
{
object
Cpd
Syd
Manager
{
const
val
BUSINESS_ID
=
""
const
val
KEY
=
""
const
val
BUSINESS_ID
=
"
m8909
"
const
val
KEY
=
"
KVPCQQsS9AV68y9DA2S4gIk2orHY4xz6
"
fun
getCpdUrl
():
String
{
val
currentTimeMillis
=
System
.
currentTimeMillis
().
toString
()
...
...
app/src/main/java/com/mints/goldspace/mvp/presenters/TaskPresenter.kt
View file @
7c6571af
...
...
@@ -6,7 +6,7 @@ import com.google.gson.JsonObject
import
com.mints.goldspace.BuildConfig
import
com.mints.goldspace.common.DeviceInfo
import
com.mints.goldspace.manager.AppHttpManager
import
com.mints.goldspace.manager.CpdManager
import
com.mints.goldspace.manager.Cpd
Syd
Manager
import
com.mints.goldspace.mvp.model.BaseResponse
import
com.mints.goldspace.mvp.model.CpdModelBean
import
com.mints.goldspace.mvp.views.TaskView
...
...
@@ -72,7 +72,7 @@ class TaskPresenter : BasePresenter<TaskView>() {
fun
getCpdDetail
(
ip
:
String
)
{
AppHttpManager
.
getInstance
(
loanApplication
)
.
call
(
CpdService
.
Factory
.
getInstance
().
getAdVedio
(
Cpd
Manager
.
getCpdUrl
(),
Cp
dManager
.
getCpdBody
(
ip
)),
.
call
(
CpdService
.
Factory
.
getInstance
().
getAdVedio
(
Cpd
SydManager
.
getCpdUrl
(),
CpdSy
dManager
.
getCpdBody
(
ip
)),
object
:
BaseSubscriber
<
JsonObject
>()
{
override
fun
onCompleted
()
{
}
...
...
app/src/main/java/com/mints/goldspace/ui/activitys/WebActivity.kt
View file @
7c6571af
...
...
@@ -13,6 +13,7 @@ import com.mints.goldspace.manager.DownloadApkManager
import
com.mints.goldspace.ui.activitys.base.BaseActivity
import
com.mints.goldspace.utils.CacheUtil
import
kotlinx.android.synthetic.main.activity_web.*
import
kotlinx.android.synthetic.main.web_header_layout.*
/**
* 描述:WebActivity
...
...
app/src/main/java/com/mints/goldspace/ui/fragment/TaskCpdFragment.kt
View file @
7c6571af
...
...
@@ -5,8 +5,10 @@ import android.content.Context
import
android.content.Intent
import
android.content.IntentFilter
import
android.os.Bundle
import
android.text.TextUtils
import
android.view.View
import
androidx.recyclerview.widget.GridLayoutManager
import
com.mints.goldspace.BuildConfig
import
com.mints.goldspace.R
import
com.mints.goldspace.ad.download.CoralDownload
import
com.mints.goldspace.common.AppConfig
...
...
@@ -158,12 +160,20 @@ class TaskCpdFragment : BaseFragment(), TaskView,
cpdLoadCountTime
=
0
mFakeTaskList
.
clear
()
if
(
shMax
>
0
)
{
// 先加载珊瑚广告,珊瑚回调判断圣于地
for
(
i
in
0
until
shMax
)
{
mCoralDownload
?.
pull
()
}
}
else
if
(
cpdMax
>
0
)
{
// if (shMax > 0) {
// // 先加载珊瑚广告,珊瑚回调判断圣于地
// for (i in 0 until shMax) {
// mCoralDownload?.pull()
// }
// } else if (cpdMax > 0) {
// for (i in 0 until cpdMax) {
// loadCPDData()
// }
// } else {
// notifyDataAndShowAd()
// }
if
(
cpdMax
>
0
)
{
for
(
i
in
0
until
cpdMax
)
{
loadCPDData
()
}
...
...
@@ -176,6 +186,14 @@ class TaskCpdFragment : BaseFragment(), TaskView,
LogUtil
.
d
(
TAG
,
"syd getCpdModelSuc"
)
for
(
material
in
dataBean
.
materials
)
{
// 校验包名、下载apk为空 跳过
if
(
TextUtils
.
isEmpty
(
material
.
app_apk_name
)
||
TextUtils
.
isEmpty
(
material
.
app_url
))
{
if
(
BuildConfig
.
DEBUG
)
{
LogUtil
.
d
(
TAG
,
"syd getCpdModelSuc 校验包名、下载apk为空 跳过${dataBean.uuid}"
)
}
continue
}
val
tzTaskBean
=
TzTaskBean
(
material
.
icons
,
material
.
description
,
material
.
title
,
false
,
mCoin
,
0
,
material
.
app_apk_name
)
tzTaskBean
.
app_url
=
material
.
app_url
tzTaskBean
.
trackerBean
=
material
.
tracker
...
...
@@ -237,7 +255,7 @@ class TaskCpdFragment : BaseFragment(), TaskView,
if
(
flag
)
{
// 添加未安装app
if
(!
DeviceInfo
.
instance
.
isLoadingPkg
(
mFakeTaskList
[
i
].
downLoadPkgName
))
{
if
(!
TextUtils
.
isEmpty
(
mFakeTaskList
[
i
].
downLoadPkgName
)
&&
!
DeviceInfo
.
instance
.
isLoadingPkg
(
mFakeTaskList
[
i
].
downLoadPkgName
))
{
cpdLoadCountTime
--
newPkgData
.
add
(
mFakeTaskList
[
i
])
}
...
...
app/src/main/java/com/mints/goldspace/ui/fragment/WzFragment.kt
View file @
7c6571af
...
...
@@ -19,6 +19,7 @@ import com.mints.goldspace.ui.fragment.base.BaseFragment
import
com.mints.goldspace.utils.ToastUtil
import
kotlinx.android.synthetic.main.fragment_main_wz.*
import
kotlinx.android.synthetic.main.header_layout.*
import
kotlinx.android.synthetic.main.web_header_layout.*
import
java.lang.StringBuilder
import
java.util.HashMap
...
...
@@ -30,18 +31,29 @@ import java.util.HashMap
@SuppressLint
(
"SetJavaScriptEnabled"
)
class
WzFragment
(
private
var
isResume
:
Boolean
=
false
)
:
BaseFragment
(),
BaseView
{
private
val
WZ_URL
=
"http://api.wenlv-kd.com/h5/init.html"
private
val
APP_KEY
=
"taojinkongjian"
private
val
APP_ID
=
"177"
private
val
userManager
by
lazy
{
UserManager
.
getInstance
()
}
override
fun
getContentViewLayoutID
()
=
R
.
layout
.
fragment_main_wz
override
fun
initViewsAndEvents
()
{
tv_title
.
text
=
"新闻分享"
iv_left_icon
.
visibility
=
View
.
VISIBLE
iv_left_icon
.
setImageResource
(
R
.
mipmap
.
ic_arrow_back
)
iv_left_icon
.
setOnClickListener
{
tv_activity_title
.
text
=
"新闻分享"
tv_activity_back
.
setOnClickListener
{
blTurntableWebview
.
goBack
()
}
if
(
isResume
)
{
//包装页进入
iv_activity_quit
.
visibility
=
View
.
VISIBLE
iv_activity_quit
.
setOnClickListener
{
activity
?.
finish
()
}
}
else
{
iv_activity_quit
.
visibility
=
View
.
GONE
}
}
override
fun
onHiddenChanged
(
hidden
:
Boolean
)
{
...
...
@@ -55,8 +67,8 @@ class WzFragment(private var isResume: Boolean = false) : BaseFragment(), BaseVi
override
fun
onResume
()
{
super
.
onResume
()
if
(
AppConfig
.
fragmentClickFlag
==
Constant
.
FRAGMENT_CLICK_FOUR
||
isResume
)
{
if
(
TextUtils
.
isEmpty
(
userManager
?
.
userID
))
{
if
(
AppConfig
.
fragmentClickFlag
==
Constant
.
FRAGMENT_CLICK_FOUR
||
isResume
)
{
if
(
TextUtils
.
isEmpty
(
userManager
.
userID
))
{
// 游客登录
}
else
{
...
...
@@ -84,7 +96,8 @@ class WzFragment(private var isResume: Boolean = false) : BaseFragment(), BaseVi
*/
private
fun
getWzUrl
()
{
val
sb
=
StringBuilder
()
sb
.
append
(
"http://api.wenlv-kd.com/h5/init.html?appkey=taojinkongjian&appid=177"
)
// sb.append("http://api.wenlv-kd.com/h5/init.html?appkey=taojinkongjian&appid=177")
sb
.
append
(
WZ_URL
+
"?appkey="
+
APP_KEY
+
"&appid="
+
APP_ID
)
.
append
(
"&userid="
+
userManager
.
userID
)
.
append
(
"&reward="
+
AppConfig
.
wzReadCoin
)
.
append
(
"&unit="
+
"金币"
)
...
...
app/src/main/res/layout/activity_award.xml
View file @
7c6571af
...
...
@@ -170,13 +170,21 @@
</FrameLayout>
<FrameLayout
android:id=
"@+id/flAwardAd"
android:layout_width=
"wrap_content"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:layout_marginLeft=
"25dp"
android:layout_marginTop=
"10dp"
android:layout_marginRight=
"25dp"
android:background=
"@drawable/shape_bg_
award"
/
>
android:background=
"@drawable/shape_bg_
write"
>
<FrameLayout
android:id=
"@+id/flAwardAd"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:background=
"@color/color_0000"
>
</FrameLayout>
</FrameLayout>
</LinearLayout>
\ No newline at end of file
app/src/main/res/layout/activity_web.xml
View file @
7c6571af
...
...
@@ -4,42 +4,7 @@
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<RelativeLayout
android:layout_width=
"match_parent"
android:layout_height=
"50dp"
android:layout_marginTop=
"20dp"
>
<ImageView
android:id=
"@+id/tv_activity_back"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:padding=
"10dp"
android:src=
"@mipmap/ic_arrow_back"
/>
<ImageView
android:id=
"@+id/iv_activity_quit"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:layout_toEndOf=
"@id/tv_activity_back"
android:padding=
"12dp"
android:src=
"@mipmap/ic_close"
/>
<TextView
android:id=
"@+id/tv_activity_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerInParent=
"true"
android:textColor=
"@color/color_121B32"
android:textSize=
"16sp"
/>
<View
android:layout_width=
"match_parent"
android:layout_height=
"1dp"
android:layout_alignParentBottom=
"true"
android:background=
"@color/color_E6E6E6"
/>
</RelativeLayout>
<include
layout=
"@layout/web_header_layout"
/>
<ProgressBar
android:id=
"@+id/pb_web"
...
...
app/src/main/res/layout/fragment_main_wz.xml
View file @
7c6571af
...
...
@@ -4,7 +4,7 @@
android:orientation=
"vertical"
android:layout_height=
"match_parent"
>
<include
layout=
"@layout/header_layout"
/>
<include
layout=
"@layout/
web_
header_layout"
/>
<WebView
android:id=
"@+id/blTurntableWebview"
...
...
app/src/main/res/layout/item_fragment_main_my_customer_service.xml
View file @
7c6571af
...
...
@@ -23,6 +23,6 @@
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginBottom=
"20dp"
android:text=
"请关注公众号:
金币宝箱
,获取更多赚钱资讯"
/>
android:text=
"请关注公众号:
淘金空间
,获取更多赚钱资讯"
/>
</merge>
\ No newline at end of file
app/src/main/res/layout/web_header_layout.xml
0 → 100644
View file @
7c6571af
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
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=
"50dp"
android:layout_marginTop=
"20dp"
>
<ImageView
android:id=
"@+id/tv_activity_back"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:padding=
"10dp"
android:src=
"@mipmap/ic_arrow_back"
/>
<ImageView
android:id=
"@+id/iv_activity_quit"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:layout_toEndOf=
"@id/tv_activity_back"
android:padding=
"12dp"
android:src=
"@mipmap/ic_close"
/>
<TextView
android:id=
"@+id/tv_activity_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerInParent=
"true"
android:textColor=
"@color/color_121B32"
android:textSize=
"16sp"
/>
<View
android:layout_width=
"match_parent"
android:layout_height=
"1dp"
android:layout_alignParentBottom=
"true"
android:background=
"@color/color_E6E6E6"
/>
</RelativeLayout>
\ No newline at end of file
gradle.properties
View file @
7c6571af
...
...
@@ -16,8 +16,8 @@ org.gradle.jvmargs=-Xmx1536m
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
DEBUG_URL
=
"http://39.97.65.143:9082/api
-gs
/"
RELEASE_URL="http
://api.mints-id.com/gs
-api/"
DEBUG_URL
=
"http://39.97.65.143:9082/api/"
RELEASE_URL="http
s://api.mints-id.com/gsnew
-api/"
RELEASE_KEY_PASSWORD
=
gold.space
RELEASE_KEY_ALIAS
=
gold_space
...
...
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