Commit 9636ee6d by 严久程
parents 84f47db1 772879aa
ext { ext {
kotlin_version = "1.3.21" kotlin_version = "1.3.21"
dev_mode = true dev_mode = false
ydl_app = [ ydl_app = [
appName : "心理咨询壹点灵", appName : "心理咨询壹点灵",
...@@ -43,11 +43,11 @@ ext { ...@@ -43,11 +43,11 @@ ext {
// -------------- 业务模块 -------------- // -------------- 业务模块 --------------
//第三步 若干 //第三步 若干
"m-confide" : "0.0.18", "m-confide" : "0.0.18",
"m-consultant" : "0.0.27", "m-consultant" : "0.0.29",
"m-course" : "0.0.21", "m-course" : "0.0.17",
"m-fm" : "0.0.15", "m-fm" : "0.0.15",
"m-muse" : "0.0.11", "m-muse" : "0.0.11",
"m-tests" : "0.0.9", "m-tests" : "0.0.10",
"m-user" : "0.0.30", "m-user" : "0.0.30",
//-------------- 业务模块 API 层 -------------- //-------------- 业务模块 API 层 --------------
...@@ -69,10 +69,9 @@ ext { ...@@ -69,10 +69,9 @@ ext {
"ydl-pay" : "0.0.9", "ydl-pay" : "0.0.9",
"m-audioim" : "0.0.15", "m-audioim" : "0.0.15",
//以下 几乎不会动 //以下 几乎不会动
"router" : "0.0.1", "router" : "0.0.1",
"ydl-net" : "0.0.2", "ydl-net" : "0.0.2",
"ydl-utils" : "0.0.2", "ydl-utils" : "0.0.3",
"ydl-flutter-base": "0.0.3", "ydl-flutter-base": "0.0.3",
] ]
...@@ -81,7 +80,7 @@ ext { ...@@ -81,7 +80,7 @@ ext {
//第三步 若干 //第三步 若干
"m-confide" : "0.0.15", "m-confide" : "0.0.15",
"m-consultant" : "0.0.26", "m-consultant" : "0.0.26",
"m-course" : "0.0.17", "m-course" : "0.0.22",
"m-fm" : "0.0.15", "m-fm" : "0.0.15",
"m-muse" : "0.0.7", "m-muse" : "0.0.7",
"m-tests" : "0.0.4", "m-tests" : "0.0.4",
...@@ -108,7 +107,7 @@ ext { ...@@ -108,7 +107,7 @@ ext {
"router" : "0.0.1", "router" : "0.0.1",
"ydl-net" : "0.0.2", "ydl-net" : "0.0.2",
"ydl-utils" : "0.0.2", "ydl-utils" : "0.0.3",
"ydl-flutter-base": "0.0.3", "ydl-flutter-base": "0.0.3",
] ]
......
...@@ -267,7 +267,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres ...@@ -267,7 +267,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
if (isVisibleToUser && isResumed) { if (isVisibleToUser && isResumed) {
onResume() onResume()
} }
} }
private fun showConsultAssistantDialog() { private fun showConsultAssistantDialog() {
......
...@@ -36,5 +36,12 @@ public class CourseHomeBodyBean { ...@@ -36,5 +36,12 @@ public class CourseHomeBodyBean {
public String originalApplyFee; public String originalApplyFee;
public boolean isBuy; public boolean isBuy;
public String demoFile; public String demoFile;
/**
* 活动图标
*/
public String activityImg;
/**
* 是否参加活动
*/
public String joinActivity;
} }
...@@ -28,4 +28,12 @@ public class CourseHostInfoBean { ...@@ -28,4 +28,12 @@ public class CourseHostInfoBean {
public String askTotalTime; public String askTotalTime;
public String helpLong; public String helpLong;
public ShareData shareData; public ShareData shareData;
/**
* 活动图标
*/
public String activityImg;
/**
* 是否参加活动
*/
public String joinActivity;
} }
...@@ -113,6 +113,7 @@ class CourseSearchActivity : BaseActivity(), CourseSearchAdapter.OnItemClick, IC ...@@ -113,6 +113,7 @@ class CourseSearchActivity : BaseActivity(), CourseSearchAdapter.OnItemClick, IC
} }
loadCourseList(true) loadCourseList(true)
} }
}) })
activity_course_search_search_bar_view.postDelayed({ activity_course_search_search_bar_view.postDelayed({
RxKeyboardTool.showSoftInput(this, activity_course_search_search_bar_view.getEditText()) RxKeyboardTool.showSoftInput(this, activity_course_search_search_bar_view.getEditText())
......
...@@ -75,7 +75,16 @@ class CourseItemNewView : ConstraintLayout { ...@@ -75,7 +75,16 @@ class CourseItemNewView : ConstraintLayout {
.load(headUrl) .load(headUrl)
.into(iv_head) .into(iv_head)
tv_title.text = course.title //活动标签
if(!TextUtils.isEmpty(course.courseHostInfo?.activityImg)){
img_activity.visibility = View.VISIBLE
GlideApp.with(context).load(course.courseHostInfo?.activityImg).into(img_activity)
tv_title.text = "\u3000\u3000\u3000\u0020"+course.title
}else{
img_activity.visibility = View.GONE
tv_title.text = course.title
}
if (!TextUtils.isEmpty(course.doctorName)) { if (!TextUtils.isEmpty(course.doctorName)) {
doctorName = course.doctorName doctorName = course.doctorName
} else { } else {
......
...@@ -82,6 +82,14 @@ ...@@ -82,6 +82,14 @@
app:layout_constraintTop_toTopOf="@+id/iv_head" app:layout_constraintTop_toTopOf="@+id/iv_head"
tools:text="走出余光恐惧,一位余光恐惧者的亲诉一位余光恐惧者的亲诉一位余光恐惧者的亲诉一位余光恐惧者的亲诉"/> tools:text="走出余光恐惧,一位余光恐惧者的亲诉一位余光恐惧者的亲诉一位余光恐惧者的亲诉一位余光恐惧者的亲诉"/>
<ImageView
android:id="@+id/img_activity"
android:layout_width="47dp"
android:layout_height="15dp"
android:layout_marginTop="3.3dp"
app:layout_constraintTop_toTopOf="@+id/tv_title"
app:layout_constraintLeft_toLeftOf="@+id/tv_title"
android:visibility="gone"/>
<TextView <TextView
android:id="@+id/tv_doctor_info" android:id="@+id/tv_doctor_info"
android:layout_width="0dp" android:layout_width="0dp"
......
...@@ -2,22 +2,22 @@ package com.yidianling.tests.router ...@@ -2,22 +2,22 @@ package com.yidianling.tests.router
import android.app.Activity import android.app.Activity
import android.content.Intent import android.content.Intent
import com.ydl.ydl_router.manager.YDLRouterManager import com.ydl.webview.H5Params
import com.ydl.ydl_router.manager.YDLRouterParams import com.ydl.webview.NewH5Activity
import com.ydl.ydlcommon.base.BaseApp
import com.ydl.ydlcommon.base.config.HttpConfig import com.ydl.ydlcommon.base.config.HttpConfig
import com.ydl.ydlcommon.router.IYDLRouterConstant
import com.yidianling.router.tests.ITestsRouter import com.yidianling.router.tests.ITestsRouter
class TestsRouterImp : ITestsRouter { class TestsRouterImp : ITestsRouter {
override fun testH5Result(testResultId: String) { override fun testH5Result(testResultId: String) {
YDLRouterManager.router(IYDLRouterConstant.ROUTER_H5_H5, val h5Params = H5Params(HttpConfig.MH5_URL+"ceshi/result/"+testResultId, null)
YDLRouterParams().putExtra(IYDLRouterConstant.EXTRA_URL, HttpConfig.MH5_URL+"ceshi/result/"+testResultId),"") NewH5Activity.start(BaseApp.getApp(),h5Params)
} }
override fun testDetailH5(testId: String) { override fun testDetailH5(testId: String) {
YDLRouterManager.router(IYDLRouterConstant.ROUTER_H5_H5, val h5Params = H5Params(HttpConfig.MH5_URL+"ceshi/"+testId, null)
YDLRouterParams().putExtra(IYDLRouterConstant.EXTRA_URL, HttpConfig.MH5_URL+"ceshi/"+testId),"") NewH5Activity.start(BaseApp.getApp(),h5Params)
} }
override fun testDetailIntent(activity: Activity, testId: Int): Intent { override fun testDetailIntent(activity: Activity, testId: Int): Intent {
......
...@@ -25,6 +25,7 @@ import com.tbruyelle.rxpermissions2.RxPermissions ...@@ -25,6 +25,7 @@ import com.tbruyelle.rxpermissions2.RxPermissions
import com.umeng.socialize.UMShareAPI import com.umeng.socialize.UMShareAPI
import com.umeng.socialize.UMShareConfig import com.umeng.socialize.UMShareConfig
import com.umeng.socialize.bean.SHARE_MEDIA import com.umeng.socialize.bean.SHARE_MEDIA
import com.ydl.ydlcommon.base.BaseApp
import com.ydl.ydlcommon.base.BaseMvpActivity import com.ydl.ydlcommon.base.BaseMvpActivity
import com.ydl.ydlcommon.utils.ActivityManager import com.ydl.ydlcommon.utils.ActivityManager
import com.ydl.ydlcommon.utils.StatusBarUtils import com.ydl.ydlcommon.utils.StatusBarUtils
...@@ -34,10 +35,9 @@ import com.ydl.ydlcommon.view.dialog.CommonDialog ...@@ -34,10 +35,9 @@ import com.ydl.ydlcommon.view.dialog.CommonDialog
import com.yidianling.common.tools.LogUtil import com.yidianling.common.tools.LogUtil
import com.yidianling.common.tools.RxKeyboardTool import com.yidianling.common.tools.RxKeyboardTool
import com.yidianling.common.tools.ToastUtil import com.yidianling.common.tools.ToastUtil
import com.yidianling.user.api.bean.UserResponseBean
import com.yidianling.user.BuildConfig
import com.yidianling.user.R import com.yidianling.user.R
import com.yidianling.user.UserHelper import com.yidianling.user.UserHelper
import com.yidianling.user.api.bean.UserResponseBean
import com.yidianling.user.bean.AliAuthBean import com.yidianling.user.bean.AliAuthBean
import com.yidianling.user.constants.UserBIConstants import com.yidianling.user.constants.UserBIConstants
import com.yidianling.user.http.request.BindPhoneJavaParam import com.yidianling.user.http.request.BindPhoneJavaParam
...@@ -225,7 +225,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont ...@@ -225,7 +225,7 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
/* /*
* 3.set debugMode when app is in debug mode, sdk will print log in debug mode * 3.set debugMode when app is in debug mode, sdk will print log in debug mode
*/ */
mAlicomAuthHelper?.setDebugMode(BuildConfig.DEBUG) mAlicomAuthHelper?.setDebugMode(BaseApp.instance.getGlobalConfig().appDebug)
requestPermission() requestPermission()
/* /*
......
...@@ -7,7 +7,9 @@ import com.lzy.imagepicker.ImagePicker ...@@ -7,7 +7,9 @@ import com.lzy.imagepicker.ImagePicker
import com.lzy.imagepicker.view.CropImageView import com.lzy.imagepicker.view.CropImageView
import com.ydl.devicesidlib.DeviceIDHelper import com.ydl.devicesidlib.DeviceIDHelper
import com.ydl.ydlcommon.actions.imagepicker.YdlImageLoader import com.ydl.ydlcommon.actions.imagepicker.YdlImageLoader
import com.ydl.ydlcommon.base.BaseApp
import com.ydl.ydlcommon.utils.BuryPointUtils import com.ydl.ydlcommon.utils.BuryPointUtils
import com.ydl.ydlcommon.utils.LogUtil
import com.ydl.ydlcommon.utils.log.LogHelper import com.ydl.ydlcommon.utils.log.LogHelper
import com.yidianling.common.tools.RxTool import com.yidianling.common.tools.RxTool
...@@ -25,6 +27,8 @@ object YdlRepository { ...@@ -25,6 +27,8 @@ object YdlRepository {
fun initApp(app: Application,isDebug:Boolean) { fun initApp(app: Application,isDebug:Boolean) {
DeviceIDHelper.getInstance().init(app.applicationContext) DeviceIDHelper.getInstance().init(app.applicationContext)
LogHelper.getInstance().deleteExpireLogSync() LogHelper.getInstance().deleteExpireLogSync()
LogUtil.debug = BaseApp.instance.getGlobalConfig().appDebug
com.yidianling.common.tools.LogUtil.debug = BaseApp.instance.getGlobalConfig().appDebug
//初始化工具类 //初始化工具类
RxTool.init(app) RxTool.init(app)
BuryPointUtils.init() BuryPointUtils.init()
......
...@@ -3,7 +3,6 @@ package com.ydl.ydlcommon.base.config ...@@ -3,7 +3,6 @@ package com.ydl.ydlcommon.base.config
import android.content.Context import android.content.Context
import android.text.TextUtils import android.text.TextUtils
import com.facebook.stetho.okhttp3.StethoInterceptor import com.facebook.stetho.okhttp3.StethoInterceptor
import com.ydl.ydlcommon.BuildConfig
import com.ydl.ydlcommon.base.BaseApp import com.ydl.ydlcommon.base.BaseApp
import com.ydl.ydlcommon.data.PlatformDataManager import com.ydl.ydlcommon.data.PlatformDataManager
import com.ydl.ydlcommon.data.http.EncryptUtils import com.ydl.ydlcommon.data.http.EncryptUtils
...@@ -72,7 +71,7 @@ class HttpConfig { ...@@ -72,7 +71,7 @@ class HttpConfig {
//获取证书 //获取证书
val cerInputStream = context.resources.openRawResource(com.ydl.ydlcommon.R.raw.ydl_trust); val cerInputStream = context.resources.openRawResource(com.ydl.ydlcommon.R.raw.ydl_trust);
val builder = OkHttpConfig.Builder(context); val builder = OkHttpConfig.Builder(context);
if (BuildConfig.DEBUG) { if (appDebug) {
builder.setNetInterceptor(StethoInterceptor()) builder.setNetInterceptor(StethoInterceptor())
}else{ }else{
//使用预埋证书,校验服务端证书 //使用预埋证书,校验服务端证书
......
...@@ -2,7 +2,6 @@ ...@@ -2,7 +2,6 @@
package com.ydl.ydlcommon.utils; package com.ydl.ydlcommon.utils;
import android.util.Log; import android.util.Log;
import com.ydl.ydlcommon.BuildConfig;
/** /**
...@@ -18,7 +17,8 @@ public class LogUtil { ...@@ -18,7 +17,8 @@ public class LogUtil {
private static String lastMethodName; private static String lastMethodName;
private static boolean debug = BuildConfig.DEBUG; public static boolean debug = false;
public static String TAG = "hzs"; public static String TAG = "hzs";
private LogUtil() { private LogUtil() {
......
...@@ -3,8 +3,6 @@ package com.yidianling.common.tools; ...@@ -3,8 +3,6 @@ package com.yidianling.common.tools;
import android.util.Log; import android.util.Log;
import com.yidianling.common.BuildConfig;
/** /**
* LogUtil * LogUtil
...@@ -19,12 +17,17 @@ public class LogUtil { ...@@ -19,12 +17,17 @@ public class LogUtil {
private static String lastMethodName; private static String lastMethodName;
private static boolean debug = BuildConfig.DEBUG; public static boolean debug = false;
public static String TAG = "hzs"; public static String TAG = "hzs";
private LogUtil() { private LogUtil() {
} }
public static void setPrint(boolean isPrint){
debug = isPrint;
}
private static String printLog(String log) { private static String printLog(String log) {
//记录本地日志系统 //记录本地日志系统
......
...@@ -21,12 +21,18 @@ import android.webkit.ValueCallback; ...@@ -21,12 +21,18 @@ import android.webkit.ValueCallback;
import android.widget.ImageView; import android.widget.ImageView;
import android.widget.LinearLayout; import android.widget.LinearLayout;
import android.widget.PopupWindow; import android.widget.PopupWindow;
import com.alibaba.android.arouter.facade.annotation.Route; import com.alibaba.android.arouter.facade.annotation.Route;
import com.alibaba.android.arouter.launcher.ARouter; import com.alibaba.android.arouter.launcher.ARouter;
import com.tencent.smtt.export.external.interfaces.JsResult; import com.tencent.smtt.export.external.interfaces.JsResult;
import com.tencent.smtt.export.external.interfaces.SslError; import com.tencent.smtt.export.external.interfaces.SslError;
import com.tencent.smtt.export.external.interfaces.SslErrorHandler; import com.tencent.smtt.export.external.interfaces.SslErrorHandler;
import com.tencent.smtt.sdk.*; import com.tencent.smtt.sdk.CookieManager;
import com.tencent.smtt.sdk.CookieSyncManager;
import com.tencent.smtt.sdk.WebChromeClient;
import com.tencent.smtt.sdk.WebSettings;
import com.tencent.smtt.sdk.WebView;
import com.tencent.smtt.sdk.WebViewClient;
import com.umeng.socialize.UMShareAPI; import com.umeng.socialize.UMShareAPI;
import com.umeng.socialize.bean.SHARE_MEDIA; import com.umeng.socialize.bean.SHARE_MEDIA;
import com.ydl.ydl_router.manager.YDLRouterManager; import com.ydl.ydl_router.manager.YDLRouterManager;
...@@ -36,7 +42,13 @@ import com.ydl.ydlcommon.base.config.YDLConstants; ...@@ -36,7 +42,13 @@ import com.ydl.ydlcommon.base.config.YDLConstants;
import com.ydl.ydlcommon.bean.StatusBarOptions; import com.ydl.ydlcommon.bean.StatusBarOptions;
import com.ydl.ydlcommon.router.YdlCommonRouterManager; import com.ydl.ydlcommon.router.YdlCommonRouterManager;
import com.ydl.ydlcommon.ui.LogoLoadingView; import com.ydl.ydlcommon.ui.LogoLoadingView;
import com.ydl.ydlcommon.utils.*; import com.ydl.ydlcommon.utils.BuryPointUtils;
import com.ydl.ydlcommon.utils.LogUtil;
import com.ydl.ydlcommon.utils.NetWorkSpeedUtils;
import com.ydl.ydlcommon.utils.PopUtils;
import com.ydl.ydlcommon.utils.StatusBarUtils;
import com.ydl.ydlcommon.utils.TemporaryUtils;
import com.ydl.ydlcommon.utils.URLUtils;
import com.ydl.ydlcommon.view.TitleBar; import com.ydl.ydlcommon.view.TitleBar;
import com.ydl.ydlcommon.view.dialog.YDLShareDialog; import com.ydl.ydlcommon.view.dialog.YDLShareDialog;
import com.yidianling.common.tools.RxDeviceTool; import com.yidianling.common.tools.RxDeviceTool;
...@@ -44,13 +56,7 @@ import com.yidianling.common.tools.RxImageTool; ...@@ -44,13 +56,7 @@ import com.yidianling.common.tools.RxImageTool;
import com.yidianling.common.tools.ToastUtil; import com.yidianling.common.tools.ToastUtil;
import com.yidianling.user.api.event.UserBindPhoneEvent; import com.yidianling.user.api.event.UserBindPhoneEvent;
import com.yidianling.user.api.event.UserLoginEvent; import com.yidianling.user.api.event.UserLoginEvent;
import de.greenrobot.event.EventBus;
import in.srain.cube.views.ptr.PtrDefaultHandler;
import in.srain.cube.views.ptr.PtrFrameLayout;
import in.srain.cube.views.ptr.PtrHandler;
import in.srain.cube.views.ptr.header.MaterialHeader;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable; import org.jetbrains.annotations.Nullable;
import org.json.JSONException; import org.json.JSONException;
...@@ -60,6 +66,14 @@ import java.net.URI; ...@@ -60,6 +66,14 @@ import java.net.URI;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
import de.greenrobot.event.EventBus;
import in.srain.cube.views.ptr.PtrDefaultHandler;
import in.srain.cube.views.ptr.PtrFrameLayout;
import in.srain.cube.views.ptr.PtrHandler;
import in.srain.cube.views.ptr.header.MaterialHeader;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import static android.view.View.GONE; import static android.view.View.GONE;
import static android.view.View.VISIBLE; import static android.view.View.VISIBLE;
...@@ -870,7 +884,7 @@ public class NewH5Activity extends BaseActivity implements PtrHandler { ...@@ -870,7 +884,7 @@ public class NewH5Activity extends BaseActivity implements PtrHandler {
} }
private void onReceivedSslErrorHandle(SslErrorHandler handler) { private void onReceivedSslErrorHandle(SslErrorHandler handler) {
if (BuildConfig.DEBUG) { if (BaseApp.instance.getGlobalConfig().getAppDebug()) {
handler.proceed(); handler.proceed();
return; return;
} }
......
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