Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YDL-Component-Medical
Overview
Overview
Details
Activity
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
杨凯
YDL-Component-Medical
Commits
5ce59e7f
Commit
5ce59e7f
authored
Aug 01, 2022
by
万齐军
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码合并
parent
d8365292
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
33 additions
and
140 deletions
+33
-140
IConfideService.kt
api/confide/src/main/java/com/ydl/confide/api/IConfideService.kt
+0
-5
.gitignore
api/media/.gitignore
+0
-2
build.gradle
api/media/build.gradle
+0
-35
proguard-rules.pro
api/media/proguard-rules.pro
+0
-22
AndroidManifest.xml
api/media/src/main/AndroidManifest.xml
+0
-5
IMediaService.kt
api/media/src/main/java/com/ydl/media/api/IMediaService.kt
+0
-9
build.gradle
app/build.gradle
+2
-0
ConfdieServiceImpl.kt
m-confide/src/main/java/com/ydl/confide/home/modular/service/ConfdieServiceImpl.kt
+0
-9
build.gradle
m-js/build.gradle
+2
-3
JsMethod.kt
m-js/src/main/java/com/ydl/js/JsMethod.kt
+3
-2
JsModularService.kt
m-js/src/main/java/com/ydl/js/JsModularService.kt
+0
-5
NewH5_WVClickAbstractListener.java
m-js/src/main/java/com/ydl/js/NewH5_WVClickAbstractListener.java
+12
-7
WebServiceImpl.kt
m-js/src/main/java/com/ydl/js/WebServiceImpl.kt
+4
-4
settings.gradle
settings.gradle
+1
-1
build.gradle
ydl-media/build.gradle
+0
-1
MediaImpl.kt
ydl-media/src/main/java/com/ydl/media/moduler/service/MediaImpl.kt
+0
-30
ModularServiceManager.kt
ydl-platform/src/main/java/com/ydl/ydlcommon/modular/ModularServiceManager.kt
+9
-0
No files found.
api/confide/src/main/java/com/ydl/confide/api/IConfideService.kt
View file @
5ce59e7f
...
...
@@ -38,9 +38,5 @@ interface IConfideService : IProvider {
uid
:
String
)
fun
isOnlineRtm
():
Boolean
fun
requestConfidePermission
(
activity
:
FragmentActivity
,
call
:
((
Boolean
)
->
Unit
)?)
fun
login
(
userId
:
String
?,
event
:
(
isSuccess
:
Boolean
,
msg
:
String
?)
->
Unit
)
}
\ No newline at end of file
api/media/.gitignore
deleted
100644 → 0
View file @
d8365292
/build
\ No newline at end of file
api/media/build.gradle
deleted
100644 → 0
View file @
d8365292
apply
plugin:
'com.android.library'
apply
plugin:
'kotlin-android'
apply
from:
"../../publish.gradle"
android
{
compileSdkVersion
rootProject
.
ext
.
android
[
"compileSdkVersion"
]
buildToolsVersion
rootProject
.
ext
.
android
[
"buildToolsVersion"
]
defaultConfig
{
minSdkVersion
rootProject
.
ext
.
android
[
"minSdkVersion"
]
targetSdkVersion
rootProject
.
ext
.
android
[
"targetSdkVersion"
]
}
buildTypes
{
release
{
minifyEnabled
false
proguardFiles
getDefaultProguardFile
(
'proguard-android-optimize.txt'
),
'proguard-rules.pro'
}
}
compileOptions
{
sourceCompatibility
JavaVersion
.
VERSION_1_8
targetCompatibility
JavaVersion
.
VERSION_1_8
}
kotlinOptions
{
jvmTarget
=
'1.8'
}
}
dependencies
{
implementation
"com.google.code.gson:gson:2.8.5"
implementation
"com.alibaba:arouter-api:$arouter_api"
implementation
"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
\ No newline at end of file
api/media/proguard-rules.pro
deleted
100644 → 0
View file @
d8365292
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}
# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable
# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile
\ No newline at end of file
api/media/src/main/AndroidManifest.xml
deleted
100644 → 0
View file @
d8365292
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android=
"http://schemas.android.com/apk/res/android"
package=
"com.ydl.media.api"
>
</manifest>
\ No newline at end of file
api/media/src/main/java/com/ydl/media/api/IMediaService.kt
deleted
100644 → 0
View file @
d8365292
package
com.ydl.media.api
import
android.app.Activity
import
com.alibaba.android.arouter.facade.template.IProvider
interface
IMediaService
:
IProvider
{
fun
closeFloatView
(
activity
:
Activity
);
}
\ No newline at end of file
app/build.gradle
View file @
5ce59e7f
...
...
@@ -220,6 +220,8 @@ dependencies {
implementation
project
(
':m-fm'
)
implementation
project
(
":api:fm"
)
implementation
project
(
':ydl-tuicore'
)
implementation
project
(
':m-js'
)
implementation
project
(
':api:js'
)
implementation
rootProject
.
ext
.
dependencies
[
"retrofit-url-manager"
]
...
...
m-confide/src/main/java/com/ydl/confide/home/modular/service/ConfdieServiceImpl.kt
View file @
5ce59e7f
...
...
@@ -111,10 +111,6 @@ class ConfdieServiceImpl : IConfideService {
findRouteService
(
IAudioImService
::
class
.
java
).
yDLAvManagerInit
(
app
,
avManagerKey
)
}
override
fun
isOnlineRtm
():
Boolean
{
return
findRouteService
(
IAudioImService
::
class
.
java
).
getIsOnlineRtm
()
}
override
fun
showAxbConfirmDialog
(
activity
:
Activity
?,
type
:
Int
,
phoneNumber
:
String
?)
{
findRouteService
(
IAudioImService
::
class
.
java
).
openAxbDialog
(
activity
,
type
,
phoneNumber
)
}
...
...
@@ -131,8 +127,4 @@ class ConfdieServiceImpl : IConfideService {
ConfidePermissionDialog
().
apply
{
callback
=
call
}.
show
(
activity
.
supportFragmentManager
,
"ConfidePermissionDialog"
)
}
override
fun
login
(
userId
:
String
?,
event
:
(
isSuccess
:
Boolean
,
msg
:
String
?)
->
Unit
)
{
YDLavManager
.
instances
.
login
(
userId
,
event
)
}
}
\ No newline at end of file
m-js/build.gradle
View file @
5ce59e7f
...
...
@@ -46,9 +46,7 @@ android {
}
dependencies
{
api
fileTree
(
dir:
'libs'
,
include:
[
'*.aar'
,
'*.jar'
])
implementation
'androidx.appcompat:appcompat:1.0.0'
implementation
"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation
"com.alibaba:arouter-api:$arouter_api"
kapt
"com.alibaba:arouter-compiler:$arouter_compiler"
...
...
@@ -69,9 +67,9 @@ dependencies {
implementation
project
(
":api:tests"
)
implementation
project
(
":api:fm"
)
implementation
project
(
":api:course"
)
implementation
project
(
':api:media'
)
implementation
project
(
':api:muse'
)
implementation
project
(
':api:js'
)
implementation
project
(
':api:audioim'
)
}
\ No newline at end of file
m-js/src/main/java/com/ydl/js/JsMethod.kt
View file @
5ce59e7f
...
...
@@ -5,6 +5,7 @@ import com.blankj.utilcode.util.PermissionUtils
import
com.google.gson.JsonObject
import
com.google.gson.JsonParser
import
com.tencent.smtt.sdk.WebView
import
com.ydl.audioim.api.IAudioImService
import
com.ydl.confide.api.IConfideService
import
com.ydl.confide.event.ConfideDialogEvent
import
com.ydl.webview.H5Params
...
...
@@ -90,9 +91,9 @@ class JsMethod(private val webView: WebView?) {
val
data
=
param
.
getAsJsonObject
(
"data"
).
toString
()
val
topActivity
=
BaseActivityMgr
.
INST
.
topActivity
if
(!
JsModularService
.
getIConfideService
().
i
sOnlineRtm
())
{
if
(!
findRouteService
(
IAudioImService
::
class
.
java
).
getI
sOnlineRtm
())
{
//异常退出或者账号被顶掉,重新登录并拨打
JsModularService
.
getIConfideService
().
login
(
JsModularService
.
getIUserService
().
getUserInfo
()
?.
uid
)
{
isSuccess
:
Boolean
,
_
->
findRouteService
(
IAudioImService
::
class
.
java
).
loginRtm
(
JsModularService
.
getIUserService
().
getUserInfo
()
?.
uid
)
{
isSuccess
:
Boolean
,
_
->
if
(
isSuccess
)
{
findRouteService
(
IConfideService
::
class
.
java
).
confideDial
(
id
,
data
,
...
...
m-js/src/main/java/com/ydl/js/JsModularService.kt
View file @
5ce59e7f
...
...
@@ -2,7 +2,6 @@ package com.ydl.js
import
com.ydl.confide.api.IConfideService
import
com.ydl.course.api.ICourseService
import
com.ydl.media.api.IMediaService
import
com.ydl.muse.api.IMuseService
import
com.ydl.ydlcommon.modular.ModularServiceManager
import
com.yidianling.dynamic.api.IDynamicService
...
...
@@ -44,10 +43,6 @@ class JsModularService {
return
ModularServiceManager
.
provide
(
ICourseService
::
class
.
java
)
}
fun
getIMediaService
():
IMediaService
{
return
ModularServiceManager
.
provide
(
IMediaService
::
class
.
java
)
}
fun
getIMuseService
():
IMuseService
{
return
ModularServiceManager
.
provide
(
IMuseService
::
class
.
java
)
}
...
...
m-js/src/main/java/com/ydl/js/NewH5_WVClickAbstractListener.java
View file @
5ce59e7f
...
...
@@ -21,6 +21,8 @@ import com.ydl.confide.event.ChangeAnotherExpertEvent;
import
com.ydl.js.bean.TimeDataBean
;
import
com.ydl.js.http.JsHttpImpl
;
import
com.ydl.js.moduler.service.JsImpl
;
import
com.ydl.media.audio.AudioPlayer
;
import
com.ydl.media.view.PlayerFloatHelper
;
import
com.ydl.webview.H5JsBean
;
import
com.ydl.webview.H5Params
;
import
com.ydl.webview.NewH5Activity
;
...
...
@@ -59,8 +61,6 @@ import de.greenrobot.event.EventBus;
import
io.reactivex.android.schedulers.AndroidSchedulers
;
import
io.reactivex.schedulers.Schedulers
;
import
static
com
.
ydl
.
ydlcommon
.
router
.
IYDLRouterConstant
.
ROUTER_MUSE_PLAY
;
/**
* webview 点击事件监听 抽象类
* Created by harvie on 2017/7/4 0004.
...
...
@@ -645,11 +645,16 @@ public class NewH5_WVClickAbstractListener implements NewH5_WebViewClientClickLi
@Override
public
void
closeFloatView
()
{
try
{
JsModularService
.
Companion
.
getIMediaService
().
closeFloatView
(
mActivity
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
mActivity
.
runOnUiThread
(()
->
{
try
{
if
(
PlayerFloatHelper
.
Companion
.
isShow
(
mActivity
))
{
PlayerFloatHelper
.
Companion
.
removeView
(
mActivity
);
AudioPlayer
.
Companion
.
get
().
stopPlayer
();
}
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
});
}
@Override
...
...
m-js/src/main/java/com/ydl/js/WebServiceImpl.kt
View file @
5ce59e7f
...
...
@@ -7,9 +7,9 @@ import android.text.TextUtils
import
com.alibaba.android.arouter.facade.annotation.Route
import
com.google.gson.Gson
import
com.tencent.smtt.sdk.WebView
import
com.ydl.
confide.api.IConfide
Service
import
com.ydl.
audioim.api.IAudioIm
Service
import
com.ydl.webview.*
import
com.ydl.ydlcommon.modular.
ModularServiceManager
import
com.ydl.ydlcommon.modular.
findRouteService
import
com.ydl.ydlcommon.utils.Utils
import
com.yidianling.common.tools.ToastUtil
import
com.yidianling.ydl_pay.pay.payDialog.CallBack
...
...
@@ -39,9 +39,9 @@ class WebServiceImpl : IWebService {
//防止连击
return
}
if
(!
JsModularService
.
getIConfideService
().
i
sOnlineRtm
())
{
if
(!
findRouteService
(
IAudioImService
::
class
.
java
).
getI
sOnlineRtm
())
{
//异常退出或者账号被顶掉,重新登录并拨打
JsModularService
.
getIConfideService
().
login
(
JsModularService
.
getIUserService
().
getUserInfo
()
?.
uid
)
{
isSuccess
:
Boolean
,
_
->
findRouteService
(
IAudioImService
::
class
.
java
).
loginRtm
(
JsModularService
.
getIUserService
().
getUserInfo
()
?.
uid
)
{
isSuccess
:
Boolean
,
_
->
if
(
isSuccess
)
{
connectionJava
(
jsData
?.
id
?:
0
,
jsData
?.
confideType
?:
1
,
activity
,
tellData
,
jsData
?.
callType
)
}
else
{
...
...
settings.gradle
View file @
5ce59e7f
...
...
@@ -5,5 +5,5 @@ include ':app',
':m-consultant'
,
':m-muse'
,
':m-fm'
,
':m-tests'
,
":m-course"
,
":m-im"
,
":m-dynamic"
,
":m-article"
,
":m-audioim"
,
":m-user"
,
":m-confide"
include
':ydl-tuicore'
,
':api:confide'
,
':api:dynamic'
,
':api:fm'
,
':api:consultant'
,
':api:course'
,
':api:user'
,
':api:tests'
,
':api:im'
,
':api:home'
,
':api:m
edia'
,
':api:muse'
,
':api:js
'
':api:course'
,
':api:user'
,
':api:tests'
,
':api:im'
,
':api:home'
,
':api:m
use'
,
':api:js'
,
':api:audioim
'
include
':m-js'
ydl-media/build.gradle
View file @
5ce59e7f
...
...
@@ -52,7 +52,6 @@ dependencies {
kapt
"com.alibaba:arouter-compiler:$arouter_compiler"
api
project
(
':ydl-platform'
)
implementation
project
(
':api:media'
)
}
ydl-media/src/main/java/com/ydl/media/moduler/service/MediaImpl.kt
deleted
100644 → 0
View file @
d8365292
package
com.ydl.media.moduler.service
import
android.app.Activity
import
android.content.Context
import
com.alibaba.android.arouter.facade.annotation.Route
import
com.ydl.media.api.IMediaService
import
com.ydl.media.audio.AudioPlayer
import
com.ydl.media.view.PlayerFloatHelper
@Route
(
path
=
"/media/MediaService"
)
class
MediaImpl
:
IMediaService
{
override
fun
init
(
context
:
Context
?)
{
}
override
fun
closeFloatView
(
activity
:
Activity
)
{
activity
.
runOnUiThread
(
Runnable
{
try
{
if
(
PlayerFloatHelper
.
isShow
(
activity
))
{
PlayerFloatHelper
.
removeView
(
activity
)
AudioPlayer
.
get
().
stopPlayer
()
}
}
catch
(
e
:
Exception
)
{
e
.
printStackTrace
()
}
})
}
}
\ No newline at end of file
ydl-platform/src/main/java/com/ydl/ydlcommon/modular/ModularServiceManager.kt
View file @
5ce59e7f
...
...
@@ -76,10 +76,16 @@ object ModularServiceManager {
private
val
routerMap
:
HashMap
<
String
,
IProvider
>
=
HashMap
()
@Deprecated
(
"使用findRouteService代替"
,
ReplaceWith
(
"findRouteService(IPlatformUserModuleService::class.java)"
,
"import com.ydl.ydlcommon.modular.findRouteService"
)
)
fun
getPlatformUserService
():
IPlatformUserModuleService
?
{
return
provide
(
IPlatformUserModuleService
::
class
.
java
)
}
@Deprecated
(
"使用findRouteService代替"
,
ReplaceWith
(
"findRouteService(clz)"
,
"import com.ydl.ydlcommon.modular.findRouteService"
)
)
fun
<
T
:
IProvider
>
provide
(
clz
:
Class
<
T
>,
path
:
String
):
T
{
var
provider
:
IProvider
?
=
null
...
...
@@ -106,6 +112,9 @@ object ModularServiceManager {
return
provider
as
T
}
@Deprecated
(
"使用findRouteService代替"
,
ReplaceWith
(
"findRouteService(clz)"
,
"import com.ydl.ydlcommon.modular.findRouteService"
)
)
fun
<
T
:
IProvider
>
provide
(
clz
:
Class
<
T
>):
T
{
var
provider
:
IProvider
?
=
null
...
...
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