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
aa3203dd
Commit
aa3203dd
authored
Feb 21, 2022
by
刘鹏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat : 系统消息界面UI完成
parent
da541843
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
333 additions
and
2 deletions
+333
-2
config.gradle
config.gradle
+2
-2
AndroidManifest.xml
m-im/src/main/AndroidManifest.xml
+6
-0
SystemMessageListActivity.kt
m-im/src/main/java/com/yidianling/medical/im/SystemMessageListActivity.kt
+93
-0
MedicalSystemListAdapter.kt
m-im/src/main/java/com/yidianling/medical/im/adapter/MedicalSystemListAdapter.kt
+18
-0
medical_item_system_list.xml
m-im/src/main/res/layout/medical_item_system_list.xml
+101
-0
medical_system_list_activity.xml
m-im/src/main/res/layout/medical_system_list_activity.xml
+65
-0
medical_system_icon.png
m-im/src/main/res/mipmap-xhdpi/medical_system_icon.png
+0
-0
platform_list_empty_icon.png
ydl-platform/src/main/res/drawable-xhdpi/platform_list_empty_icon.png
+0
-0
platform_medical_login_bg.png
ydl-platform/src/main/res/drawable-xhdpi/platform_medical_login_bg.png
+0
-0
platform_list_empty_view.xml
ydl-platform/src/main/res/layout/platform_list_empty_view.xml
+48
-0
No files found.
config.gradle
View file @
aa3203dd
...
...
@@ -35,7 +35,7 @@ ext {
//-------------- 功能组件 --------------
//第一步
"ydl-platform"
:
"0.0.40.
69
"
,
"ydl-platform"
:
"0.0.40.
73
"
,
//第二步 若干
"ydl-webview"
:
"0.0.38.56"
,
...
...
@@ -120,7 +120,7 @@ ext {
//-------------- 功能组件 --------------
//第一步
"ydl-platform"
:
"0.0.40.
69
"
,
"ydl-platform"
:
"0.0.40.
73
"
,
//第二步 若干
"ydl-webview"
:
"0.0.38.56"
,
...
...
m-im/src/main/AndroidManifest.xml
View file @
aa3203dd
...
...
@@ -296,5 +296,11 @@
android:name=
"com.yidianling.medical.archives.MedicalEditArchivesActivity"
android:screenOrientation=
"portrait"
android:theme=
"@style/platform_NoTitleTheme"
/>
<!--医疗系统消息-->
<activity
android:name=
"com.yidianling.medical.im.SystemMessageListActivity"
android:screenOrientation=
"portrait"
android:theme=
"@style/platform_NoTitleTheme"
/>
</application>
</manifest>
m-im/src/main/java/com/yidianling/medical/im/SystemMessageListActivity.kt
0 → 100644
View file @
aa3203dd
package
com.yidianling.medical.im
import
android.content.Context
import
android.content.Intent
import
android.view.LayoutInflater
import
android.view.View
import
androidx.core.content.ContextCompat
import
androidx.recyclerview.widget.LinearLayoutManager
import
androidx.swiperefreshlayout.widget.SwipeRefreshLayout
import
com.chad.library.adapter.base.BaseQuickAdapter
import
com.ydl.ydlcommon.base.BaseActivity
import
com.ydl.ydlcommon.utils.StatusBarUtils
import
com.ydl.ydlcommon.utils.Utils
import
com.yidianling.im.R
import
com.yidianling.medical.im.adapter.MedicalSystemListAdapter
import
com.yidianling.medical.widgets.LoadMoreView
import
kotlinx.android.synthetic.main.medical_system_list_activity.*
import
kotlinx.coroutines.*
import
java.util.*
/**
* 系统消息列表
* @author liupeng
* */
class
SystemMessageListActivity
:
BaseActivity
(),
SwipeRefreshLayout
.
OnRefreshListener
,
BaseQuickAdapter
.
RequestLoadMoreListener
{
private
lateinit
var
mEmptyView
:
View
private
lateinit
var
mAdapter
:
MedicalSystemListAdapter
companion
object
{
private
lateinit
var
mDoctorId
:
String
private
lateinit
var
mDoctorUid
:
String
@JvmStatic
fun
start
(
context
:
Context
,
doctorId
:
String
,
doctorUid
:
String
)
{
val
starter
=
Intent
(
context
,
SystemMessageListActivity
::
class
.
java
)
.
putExtra
(
"doctorId"
,
doctorId
)
.
putExtra
(
"doctorUid"
,
doctorUid
)
context
.
startActivity
(
starter
)
}
}
override
fun
layoutResId
():
Int
{
return
R
.
layout
.
medical_system_list_activity
}
override
fun
initDataAndEvent
()
{
initStatus
()
mEmptyView
=
LayoutInflater
.
from
(
this
@SystemMessageListActivity
)
.
inflate
(
R
.
layout
.
platform_list_empty_view
,
null
,
false
)
mAdapter
=
MedicalSystemListAdapter
()
system_list
.
layoutManager
=
LinearLayoutManager
(
this
@SystemMessageListActivity
,
LinearLayoutManager
.
VERTICAL
,
false
)
system_list
.
adapter
=
mAdapter
mAdapter
.
setOnItemClickListener
{
adapter
,
view
,
position
->
if
(
Utils
.
isFastClick
())
{
//防止连击
return
@setOnItemClickListener
}
}
mAdapter
.
setLoadMoreView
(
LoadMoreView
())
mAdapter
.
setOnLoadMoreListener
(
this
@SystemMessageListActivity
,
system_list
)
system_swipe_refresh_layout
?.
setOnRefreshListener
(
this
)
system_swipe_refresh_layout
?.
setColorSchemeColors
(
ContextCompat
.
getColor
(
this
@SystemMessageListActivity
,
R
.
color
.
platform_main_theme
)
)
system_swipe_refresh_layout
?.
setProgressViewOffset
(
false
,
0
,
200
)
}
override
fun
onRefresh
()
{
}
override
fun
onLoadMoreRequested
()
{
}
private
fun
initStatus
()
{
StatusBarUtils
.
setTransparentForImageView
(
this
@SystemMessageListActivity
,
null
)
StatusBarUtils
.
statusBarLightMode
(
this
@SystemMessageListActivity
)
}
}
\ No newline at end of file
m-im/src/main/java/com/yidianling/medical/im/adapter/MedicalSystemListAdapter.kt
0 → 100644
View file @
aa3203dd
package
com.yidianling.medical.im.adapter
import
com.chad.library.adapter.base.BaseQuickAdapter
import
com.chad.library.adapter.base.BaseViewHolder
import
com.yidianling.im.R
import
com.yidianling.im.bean.SystemMsgBean
/**
* 医生系统消息item adapter
*/
class
MedicalSystemListAdapter
:
BaseQuickAdapter
<
SystemMsgBean
.
SystemMBean
?,
BaseViewHolder
>(
R
.
layout
.
medical_item_system_list
)
{
override
fun
convert
(
helper
:
BaseViewHolder
,
item
:
SystemMsgBean
.
SystemMBean
?)
{
}
}
\ No newline at end of file
m-im/src/main/res/layout/medical_item_system_list.xml
0 → 100644
View file @
aa3203dd
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:paddingLeft=
"16dp"
android:paddingRight=
"16dp"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"24dp"
android:textColor=
"#ff8595a9"
android:textSize=
"14sp"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
tools:text=
"2022-02-18"
/>
<androidx.cardview.widget.CardView
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:background=
"@drawable/medical_bg_ffffff_8dp"
android:elevation=
"0dp"
app:cardElevation=
"0dp"
>
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:paddingStart=
"12dp"
android:paddingTop=
"16dp"
android:paddingEnd=
"12dp"
android:paddingBottom=
"16dp"
>
<ImageView
android:id=
"@+id/system_icon"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:src=
"@mipmap/medical_system_icon"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
<TextView
android:id=
"@+id/system_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"8dp"
android:text=
"处方消息提醒"
android:textColor=
"#ff0c1d31"
android:textSize=
"16sp"
android:textStyle=
"bold"
app:layout_constraintBottom_toBottomOf=
"@id/system_icon"
app:layout_constraintLeft_toRightOf=
"@id/system_icon"
app:layout_constraintTop_toTopOf=
"@id/system_icon"
/>
<TextView
android:id=
"@+id/system_dec"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:text=
"您的处方已审核通过"
android:textColor=
"#ff495c72"
android:textSize=
"14sp"
app:layout_constraintLeft_toLeftOf=
"@id/system_icon"
app:layout_constraintTop_toBottomOf=
"@id/system_icon"
/>
<View
android:id=
"@+id/center_line"
android:layout_width=
"match_parent"
android:layout_height=
"0.5dp"
android:layout_marginTop=
"16dp"
android:background=
"@color/medical_color_e7ecf0"
app:layout_constraintTop_toBottomOf=
"@id/system_dec"
/>
<TextView
android:id=
"@+id/look_dec"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"12dp"
android:text=
"查看详情"
android:textColor=
"#ff0c1d31"
android:textSize=
"14sp"
app:layout_constraintLeft_toLeftOf=
"@id/system_icon"
app:layout_constraintTop_toBottomOf=
"@id/center_line"
/>
<ImageView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:src=
"@mipmap/medical_icon_arrow_right"
app:layout_constraintBottom_toBottomOf=
"@id/look_dec"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toTopOf=
"@id/look_dec"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.cardview.widget.CardView>
</LinearLayout>
\ No newline at end of file
m-im/src/main/res/layout/medical_system_list_activity.xml
0 → 100644
View file @
aa3203dd
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
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=
"match_parent"
android:background=
"@color/white"
>
<androidx.appcompat.widget.Toolbar
android:id=
"@+id/toolbar"
android:layout_width=
"match_parent"
android:layout_height=
"56dp"
android:background=
"@color/white"
android:elevation=
"0dp"
android:gravity=
"bottom"
app:contentInsetStart=
"0dp"
app:layout_collapseMode=
"pin"
app:layout_constraintTop_toTopOf=
"parent"
>
<RelativeLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
>
<TextView
android:id=
"@+id/tv_title"
android:layout_width=
"match_parent"
android:layout_height=
"56dp"
android:ellipsize=
"end"
android:gravity=
"center"
android:maxEms=
"10"
android:maxLines=
"1"
android:text=
"系统消息"
android:textColor=
"@color/medical_color_10233a"
android:textSize=
"18sp"
android:textStyle=
"bold"
/>
<ImageView
android:id=
"@+id/iv_back"
android:layout_width=
"wrap_content"
android:layout_height=
"56dp"
android:paddingStart=
"16dp"
android:paddingEnd=
"20dp"
android:src=
"@mipmap/medical_icon_title_back"
/>
</RelativeLayout>
</androidx.appcompat.widget.Toolbar>
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id=
"@+id/system_swipe_refresh_layout"
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:background=
"#f6f7f9"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/toolbar"
app:layout_constraintVertical_weight=
"1"
>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/system_list"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
/>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file
m-im/src/main/res/mipmap-xhdpi/medical_system_icon.png
0 → 100644
View file @
aa3203dd
1.32 KB
ydl-platform/src/main/res/drawable-xhdpi/platform_list_empty_icon.png
0 → 100644
View file @
aa3203dd
13 KB
ydl-platform/src/main/res/drawable-xhdpi/platform_medical_login_bg.png
0 → 100644
View file @
aa3203dd
7.43 KB
ydl-platform/src/main/res/layout/platform_list_empty_view.xml
0 → 100644
View file @
aa3203dd
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
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=
"match_parent"
>
<ImageView
android:id=
"@+id/empty_img"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:src=
"@drawable/platform_list_empty_icon"
app:layout_constraintBottom_toTopOf=
"@id/net_error"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
app:layout_constraintVertical_chainStyle=
"packed"
/>
<TextView
android:layout_marginTop=
"20dp"
android:id=
"@+id/net_error"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"网络异常,请稍后再试"
android:textColor=
"#8595a9"
android:textSize=
"14sp"
app:layout_constraintBottom_toTopOf=
"@id/reLoad"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/empty_img"
/>
<TextView
android:id=
"@+id/reLoad"
android:layout_width=
"120dp"
android:layout_height=
"62dp"
android:background=
"@drawable/platform_medical_login_bg"
android:gravity=
"center"
android:text=
"重新加载"
android:visibility=
"gone"
android:textColor=
"@color/white"
android:textSize=
"14sp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/net_error"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file
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