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
0e1cad6c
Commit
0e1cad6c
authored
Nov 13, 2019
by
严久程
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
课程、支付
parent
3a36d2aa
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
31 additions
and
17 deletions
+31
-17
config.gradle
config.gradle
+1
-1
CoursePlayActivity.kt
m-course/src/main/java/com/yidianling/course/coursePlay/CoursePlayActivity.kt
+6
-2
CoursePlugin.kt
m-course/src/main/java/com/yidianling/course/flutterPlugin/CoursePlugin.kt
+10
-5
CourseIn.kt
m-course/src/main/java/com/yidianling/course/router/CourseIn.kt
+4
-2
attrs.xml
ydl-platform/src/main/res/values/attrs.xml
+10
-7
No files found.
config.gradle
View file @
0e1cad6c
ext
{
kotlin_version
=
'1.3.21'
dev_mode
=
fals
e
dev_mode
=
tru
e
ydl_app
=
[
appName
:
"心理咨询壹点灵"
,
...
...
m-course/src/main/java/com/yidianling/course/coursePlay/CoursePlayActivity.kt
View file @
0e1cad6c
...
...
@@ -30,6 +30,7 @@ import com.ydl.ydlcommon.adapter.CommonRecyclerAdapter
import
com.ydl.ydlcommon.base.BaseActivity
import
com.ydl.ydlcommon.bean.ShareData
import
com.ydl.ydlcommon.data.PlatformDataManager
import
com.ydl.ydlcommon.modular.ModularServiceManager
import
com.ydl.ydlcommon.router.IYDLRouterConstant
import
com.ydl.ydlcommon.router.YdlCommonRouterManager
import
com.ydl.ydlcommon.utils.ScreenUtil
...
...
@@ -46,6 +47,7 @@ import com.yidianling.course.R
import
com.yidianling.course.bean.CourseMediaBean
import
com.yidianling.course.bean.CourseMediaDetailBean
import
com.yidianling.course.coursePlay.presenter.CoursePlayPresenter
import
com.yidianling.course.router.CourseIn
import
kotlinx.android.synthetic.main.activity_course_play.*
import
org.json.JSONException
import
org.json.JSONObject
...
...
@@ -527,8 +529,10 @@ class CoursePlayActivity : BaseActivity() {
dialog
.
setCallBack
(
object
:
YDLShareDialog
.
ICallBack
{
override
fun
callBack
(
type
:
Int
)
{
if
(
1
==
type
)
{
if
(
YdlCommonRouterManager
.
getYdlCommonRoute
().
getUid
()<=
0
)
{
YdlCommonRouterManager
.
getYdlCommonRoute
().
startChooseLoginWay
(
this
@CoursePlayActivity
)
ModularServiceManager
.
getPlatformUserService
()
if
(
CourseIn
.
isLogin
())
{
CourseIn
.
loginWayIntent
(
this
@CoursePlayActivity
)
}
else
{
//分享到心事动态
toTrend
(
share
)
...
...
m-course/src/main/java/com/yidianling/course/flutterPlugin/CoursePlugin.kt
View file @
0e1cad6c
...
...
@@ -11,7 +11,7 @@ import com.ydl.webview.NewH5Activity
import
com.ydl.ydl_router.manager.YDLRouterManager
import
com.ydl.ydlcommon.base.BaseApp
import
com.ydl.ydlcommon.base.flutter.base.BaseFlutterFragment
import
com.ydl.ydlcommon.
router.YdlCommonRouter
Manager
import
com.ydl.ydlcommon.
modular.ModularService
Manager
import
com.yidianling.common.tools.LogUtil
import
com.yidianling.common.tools.RxDeviceTool
import
com.yidianling.course.BuildConfig
...
...
@@ -53,11 +53,12 @@ class CoursePlugin : MethodChannel.MethodCallHandler {
override
fun
onMethodCall
(
methodCall
:
MethodCall
,
result
:
MethodChannel
.
Result
)
{
when
(
methodCall
.
method
)
{
GETPUBLICPARAMAS
->
{
val
loginBean
=
ModularServiceManager
.
getPlatformUserService
()
?.
getUser
()
val
mMap
=
mutableMapOf
<
String
,
Any
>()
mMap
[
"isDevelopment"
]
=
BuildConfig
.
DEBUG
mMap
[
"uid"
]
=
YdlCommonRouterManager
.
getYdlCommonRoute
().
getUid
().
toString
()
mMap
[
"accessToken"
]
=
YdlCommonRouterManager
.
getYdlCommonRoute
().
getAccessToken
()
?:
""
mMap
[
"uid"
]
=
loginBean
?.
userId
?:
0
mMap
[
"accessToken"
]
=
loginBean
?.
token
?:
""
?:
""
mMap
[
"isFromApp"
]
=
"1"
mMap
[
"version"
]
=
RxDeviceTool
.
getAppVersionName
(
BaseApp
.
getApp
())
mMap
[
"osBuild"
]
=
...
...
@@ -70,7 +71,11 @@ class CoursePlugin : MethodChannel.MethodCallHandler {
var
jumpUrl
:
String
?
=
methodCall
.
arguments
.
toString
()
if
(!
TextUtils
.
isEmpty
(
jumpUrl
))
{
when
{
jumpUrl
!!
.
contains
(
"user/login"
)
->
mFragment
!!
.
startActivity
(
CourseIn
.
loginWayIntent
(
mFragment
!!
.
activity
!!
))
jumpUrl
!!
.
contains
(
"user/login"
)
->
mFragment
!!
.
startActivity
(
CourseIn
.
loginWayIntent
(
mFragment
!!
.
activity
!!
)
)
jumpUrl
.
contains
(
"course/myCourse"
)
->
MyCourseActivity
.
start
(
mFragment
!!
.
activity
)
jumpUrl
.
contains
(
"course/specialList"
)
->
//跳转专题列表页
mFragment
!!
.
activity
!!
.
startActivity
(
...
...
m-course/src/main/java/com/yidianling/course/router/CourseIn.kt
View file @
0e1cad6c
...
...
@@ -2,8 +2,10 @@ package com.yidianling.course.router
import
android.app.Activity
import
android.content.Intent
import
com.ydl.ydlcommon.modular.ModularServiceManager
import
com.yidianling.router.RouterManager
import
com.yidianling.router.user.UserResponse
import
com.yidianling.user.api.service.IUserService
/**
* author : Zhangwenchao
...
...
@@ -13,7 +15,7 @@ import com.yidianling.router.user.UserResponse
object
CourseIn
{
fun
isLogin
():
Boolean
{
return
RouterManager
.
getUserRouter
()
?.
isLogin
()
?:
false
return
ModularServiceManager
.
provide
(
IUserService
::
class
.
java
).
isLogin
()
}
fun
getUserInfo
():
UserResponse
.
UserInfo
?
{
...
...
@@ -21,7 +23,7 @@ object CourseIn {
}
fun
loginWayIntent
(
activity
:
Activity
):
Intent
?
{
return
RouterManager
.
getUserRouter
()
?
.
loginWayIntent
(
activity
)
return
ModularServiceManager
.
provide
(
IUserService
::
class
.
java
)
.
loginWayIntent
(
activity
)
}
fun
mainIntent
(
activity
:
Activity
):
Intent
?
{
...
...
ydl-platform/src/main/res/values/attrs.xml
View file @
0e1cad6c
...
...
@@ -96,15 +96,18 @@
<!--弧度设置圆角Imageview-->
<attr
name=
"pa_borderRadius"
format=
"dimension"
/
>
<attr
name=
"pa_type"
>
<enum
name=
"pa_circle"
value=
"0"
/
>
<enum
name=
"pa_round"
value=
"1"
/
>
</attr
>
<!-- <attr name="pa_borderRadius" format="dimension" />--
>
<!-- <attr name="pa_type">--
>
<!-- <enum name="pa_circle" value="0" />--
>
<!-- <enum name="pa_round" value="1" />--
>
<!-- </attr>--
>
<declare-styleable
name=
"Platform_RoundImageView"
>
<attr
name=
"pa_borderRadius"
/>
<attr
name=
"pa_type"
/>
<attr
name=
"pa_borderRadius"
format=
"dimension"
/>
<attr
name=
"pa_type"
>
<enum
name=
"pa_circle"
value=
"0"
/>
<enum
name=
"pa_round"
value=
"1"
/>
</attr>
</declare-styleable>
<!--九宫格解锁-->
...
...
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