Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
frontend-h5
Project
Project
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
songrui
frontend-h5
Commits
d3ea72cf
Commit
d3ea72cf
authored
Dec 05, 2024
by
gengchunlei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
居民端小程序 v1.2 删除无效文件
parent
9de9fa56
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
0 additions
and
1808 deletions
+0
-1808
List.vue
src/doctor/followUp/List.vue
+0
-258
ListCopy.vue
src/doctor/followUp/ListCopy.vue
+0
-274
Search.vue
src/doctor/followUp/search/Search.vue
+0
-257
Base.vue
src/doctor/resident/Base.vue
+0
-122
Index.vue
src/doctor/resident/Index.vue
+0
-104
Visit.vue
src/doctor/resident/Visit.vue
+0
-290
BaseInfo.vue
src/doctor/resident/form/BaseInfo.vue
+0
-470
index.js
src/router/index.js
+0
-33
No files found.
src/doctor/followUp/List.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div
class=
'all-back'
>
<van-nav-bar
title=
'慢病管理'
left-text=
''
left-arrow
@
click-right=
"toSearch"
@
click-left=
'toBack'
>
<template
#
right
>
<doc-icon
type=
"doc-search"
style=
"color: #262626"
/>
</
template
>
</van-nav-bar>
<van-pull-refresh
v-model=
"loading"
@
refresh=
"onRefresh"
:disabled=
'isRefreshDisable'
>
<div
class=
'top-title'
>
我的待随访({{ total }})
</div>
<van-tabs
v-model:active=
'active'
>
<van-tab
:name=
'item.name'
v-for=
'item in tabList'
:key=
"item.name"
>
<
template
#
title
>
<span>
{{
item
.
title
}}
(
{{
item
.
num
}}
)
</span>
</
template
>
</van-tab>
</van-tabs>
<div
class=
'list-data'
ref=
'list'
>
<div
class=
'mt-10 white-back p-16'
v-for=
'item in activeData'
:key=
"item.id"
>
<div
class=
'flex items-center'
>
<div
class=
'base-title'
>
{{ item.residentName }}
</div>
<div
class=
'second-title plr-8'
>
{{ getInfoByIdCard(item.idCard).age }}岁
</div>
<div
class=
'second-title plr-6'
>
{{ item.genderName }}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
身份证号
</div>
<div
class=
'detail-right'
>
{{ $idCardHide(item.idCard) }}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
是否逾期
</div>
<div
class=
'detail-right'
>
{{ item.isOverdueName }}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
逾期天数
</div>
<div
class=
'detail-right'
>
{{ item.overdueDay }} 天
</div>
</div>
<div
class=
'flex mt-3'
style=
'align-items: baseline'
>
<div
class=
'detail-left'
>
慢病标签
</div>
<div
class=
'detail-right'
style=
'flex: 1'
>
<ChronicTag
:list=
"item.chronicTagsArray"
/>
</div>
</div>
<van-divider
class=
'mt-3'
/>
<div
class=
'mt-3 flex word-right'
>
<div></div>
<div>
<van-button
round
size=
'small'
class=
'btn'
@
click=
'toGeneralDetail(item)'
>
详情
</van-button>
<van-button
round
size=
'small'
class=
'btn'
style=
'margin-left: 16px'
@
click=
'toAddGeneral(item)'
>
通用随访
</van-button>
</div>
</div>
</div>
<div
class=
"text-center empty"
v-if=
"!activeData.length"
>
<img
src=
"@/assets/image/doctor/empty.png"
alt=
""
style=
"width: 1.2rem;"
>
<p>
暂无数据
</p>
</div>
</div>
</van-pull-refresh>
</div>
</template>
<
script
>
import
dayjs
from
'dayjs'
import
{
getVisitAll
}
from
'@/api/doctor/generalFU.js'
import
ChronicTag
from
'@/doctor/components/chronicTag/ChronicTag.vue'
import
{
backHome
,
getInfoByIdCard
}
from
'@/utils/common'
export
default
{
name
:
'List'
,
components
:
{
ChronicTag
},
data
()
{
return
{
active
:
1
,
tabList
:
[
{
title
:
'高血压'
,
name
:
1
,
num
:
0
},
{
title
:
'糖尿病'
,
name
:
2
,
num
:
0
},
{
title
:
'冠心病'
,
name
:
3
,
num
:
0
},
{
title
:
'脑卒中'
,
name
:
4
,
num
:
0
},
{
title
:
'慢阻肺'
,
name
:
5
,
num
:
0
},
{
title
:
'慢性肾病'
,
name
:
6
,
num
:
0
},
{
title
:
'血脂异常'
,
name
:
7
,
num
:
0
}
],
detailInfo
:
[],
total
:
0
,
// 下拉刷新
loading
:
false
,
isRefreshDisable
:
false
}
},
computed
:
{
activeData
()
{
return
this
.
detailInfo
.
filter
(
e
=>
e
.
diseaseType
===
this
.
active
)
}
},
created
()
{
this
.
init
()
},
mounted
()
{
const
list
=
this
.
$refs
.
list
list
.
addEventListener
(
'scroll'
,
()
=>
{
if
(
list
.
scrollTop
>
0
)
{
this
.
isRefreshDisable
=
true
}
else
{
this
.
isRefreshDisable
=
false
}
})
},
methods
:
{
getInfoByIdCard
,
init
()
{
this
.
load
()
},
load
(
loading
=
true
)
{
// const nextVisitDateStart = dayjs().format('YYYY-MM-DD')
// const nextVisitDateEnd = dayjs().add(6, 'day').format('YYYY-MM-DD')
const
query
=
{
// nextVisitDateStart,
// nextVisitDateEnd
}
getVisitAll
(
query
,
loading
).
then
(
res
=>
{
console
.
log
(
'getVisitAll'
,
res
)
this
.
detailInfo
=
res
.
data
||
[]
this
.
total
=
this
.
detailInfo
.
length
this
.
tabList
.
forEach
(
e
=>
{
e
.
num
=
this
.
detailInfo
.
filter
(
i
=>
i
.
diseaseType
===
e
.
name
).
length
})
}).
finally
(()
=>
{
this
.
loading
=
false
})
},
scrollHandle
(
dom
)
{
if
(
!
dom
)
return
if
(
dom
.
scrollTop
>
0
)
{
this
.
isRefreshDisable
=
true
}
else
{
this
.
isRefreshDisable
=
false
}
},
onRefresh
()
{
this
.
load
(
false
)
},
toGeneralDetail
(
item
)
{
this
.
$router
.
push
({
path
:
`/doctor/resident/base`
,
query
:
{
residentId
:
item
.
residentInfoId
}
})
},
toAddGeneral
(
val
)
{
const
{
id
,
...
others
}
=
val
this
.
$router
.
push
({
path
:
`/doctor/followUp/generalFU/add`
,
query
:
{...
others
}
})
},
toSearch
()
{
this
.
$router
.
push
({
path
:
`/doctor/followUp/search`
})
},
toBack
()
{
backHome
()
}
}
}
</
script
>
<
style
scoped
lang=
'less'
>
.all-back {
background: #F5F5F5;
.top-title {
padding: 10px 12px;
}
.white-back {
background: #FFFFFF;
}
.mt-10 {
margin-top: 10px;
}
.p-16 {
padding: 16px;
}
.plr-8 {
padding: 0px 8px;
}
.plr-6 {
padding: 0px 6px;
}
.base-title {
font-weight: bold;
font-size: 16px;
}
.second-title {
background: #F0F3FF;
line-height: 24px;
margin-left: 10px;
}
.detail-left {
width: 104px;
font-size: 14px;
color: #8C8C8C;
}
.detail-right {
font-size: 14px;
}
.word-right {
justify-content: space-between;
align-items: center;
}
.btn {
background: #F0F3FF;
color: #607FF0;
border: 0px;
line-height: 26px;
height: 26px;
//padding: 4px 8px 4px 8px;
padding: 0px 8px;
}
.list-data {
height: calc(100vh - 140px);
overflow-y: auto;
}
}
</
style
>
\ No newline at end of file
src/doctor/followUp/ListCopy.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div
class=
'all-back'
>
<van-nav-bar
title=
'慢病管理'
left-text=
''
left-arrow
@
click-right=
'toSearch'
@
click-left=
'toBack'
>
<template
#
right
>
<doc-icon
type=
'doc-search'
style=
'color: #262626'
/>
</
template
>
</van-nav-bar>
<div
class=
'top-title'
>
我的待随访({{ total }})
</div>
<van-tabs
v-model:active=
'active'
@
change=
'changeTab'
>
<van-tab
:name=
'item.name'
v-for=
'item in tabList'
:key=
'item.name'
>
<
template
#
title
>
<span>
{{
item
.
title
}}
(
{{
item
.
num
}}
)
</span>
</
template
>
</van-tab>
</van-tabs>
<van-pull-refresh
v-model=
'loading'
@
refresh=
'onRefresh'
:disabled=
'isRefreshDisable'
>
<div
class=
'list-data'
ref=
'list'
>
<van-list
v-model:loading=
'loadingTable'
:finished=
'finished'
:finished-text=
"detailInfo.length ? '没有更多了' : ''"
@
load=
'onMore'
>
<div
class=
'mt-10 white-back p-16'
v-for=
'item in detailInfo'
:key=
'item.id'
>
<div
class=
'flex items-center'
>
<div
class=
'base-title'
>
{{ item.residentName }}
</div>
<div
class=
'second-title plr-8'
>
{{ getInfoByIdCard(item.idCard).age }}岁
</div>
<div
class=
'second-title plr-6'
>
{{ item.genderName }}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
身份证号
</div>
<div
class=
'detail-right'
>
{{ $idCardHide(item.idCard) }}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
是否逾期
</div>
<div
class=
'detail-right'
>
{{ item.isOverdueName }}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
逾期天数
</div>
<div
class=
'detail-right'
>
{{ item.overdueDay }} 天
</div>
</div>
<div
class=
'flex mt-3'
style=
'align-items: baseline'
>
<div
class=
'detail-left'
>
慢病标签
</div>
<div
class=
'detail-right'
style=
'flex: 1'
>
<ChronicTag
:list=
'item.chronicTagsArray'
/>
</div>
</div>
<van-divider
class=
'mt-3'
/>
<div
class=
'mt-3 flex word-right'
>
<div></div>
<div>
<van-button
round
size=
'small'
class=
'btn'
@
click=
'toGeneralDetail(item)'
>
详情
</van-button>
<van-button
round
size=
'small'
class=
'btn'
style=
'margin-left: 16px'
@
click=
'toAddGeneral(item)'
>
通用随访
</van-button>
</div>
</div>
</div>
</van-list>
<div
class=
'text-center empty'
v-if=
'!detailInfo.length'
>
<img
src=
'@/assets/image/doctor/empty.png'
alt=
''
style=
'width: 1.2rem;'
>
<p>
暂无数据
</p>
</div>
</div>
</van-pull-refresh>
</div>
</template>
<
script
>
import
dayjs
from
'dayjs'
import
{
getVisitAll
,
queryVisitByPage
}
from
'@/api/doctor/generalFU.js'
import
ChronicTag
from
'@/doctor/components/chronicTag/ChronicTag.vue'
import
{
backHome
,
getInfoByIdCard
}
from
'@/utils/common'
export
default
{
name
:
'List'
,
components
:
{
ChronicTag
},
data
()
{
return
{
active
:
1
,
tabList
:
[
{
title
:
'高血压'
,
name
:
1
,
num
:
0
},
{
title
:
'糖尿病'
,
name
:
2
,
num
:
0
},
{
title
:
'冠心病'
,
name
:
3
,
num
:
0
},
{
title
:
'脑卒中'
,
name
:
4
,
num
:
0
},
{
title
:
'慢阻肺'
,
name
:
5
,
num
:
0
},
{
title
:
'慢性肾病'
,
name
:
6
,
num
:
0
},
{
title
:
'血脂异常'
,
name
:
7
,
num
:
0
}
],
detailInfo
:
[],
total
:
0
,
// 下拉刷新
loading
:
false
,
isRefreshDisable
:
false
,
//列表刷新
loadingTable
:
false
,
pagination
:
{
total
:
0
,
pageIndex
:
1
,
pageSize
:
5
},
finished
:
false
}
},
mounted
()
{
const
list
=
this
.
$refs
.
list
list
.
addEventListener
(
'scroll'
,
()
=>
{
if
(
list
.
scrollTop
>
0
)
{
this
.
isRefreshDisable
=
true
}
else
{
this
.
isRefreshDisable
=
false
}
})
},
methods
:
{
getInfoByIdCard
,
changeTab
()
{
this
.
detailInfo
=
[]
this
.
pagination
.
pageIndex
=
1
this
.
load
()
},
onMore
()
{
this
.
pagination
.
pageIndex
++
this
.
load
()
},
load
(
loading
=
true
)
{
const
query
=
{
diseaseType
:
this
.
active
,
pageIndex
:
this
.
pagination
.
pageIndex
,
pageSize
:
this
.
pagination
.
pageSize
}
getVisitAll
(
query
,
loading
).
then
(
res
=>
{
console
.
log
(
'getVisitAll'
,
res
)
this
.
detailInfo
=
this
.
detailInfo
.
concat
(
res
.
data
||
[])
this
.
total
=
this
.
detailInfo
.
length
this
.
finished
=
this
.
detailInfo
.
length
>=
this
.
pagination
.
total
}).
finally
(()
=>
{
this
.
loading
=
false
this
.
loadingTable
=
false
})
},
scrollHandle
(
dom
)
{
if
(
!
dom
)
return
if
(
dom
.
scrollTop
>
0
)
{
this
.
isRefreshDisable
=
true
}
else
{
this
.
isRefreshDisable
=
false
}
},
onRefresh
()
{
this
.
detailInfo
=
[]
this
.
pagination
.
pageIndex
=
1
this
.
load
(
false
)
},
toGeneralDetail
(
item
)
{
this
.
$router
.
push
({
path
:
`/doctor/resident/base`
,
query
:
{
residentId
:
item
.
residentInfoId
}
})
},
toAddGeneral
(
val
)
{
const
{
id
,
...
others
}
=
val
this
.
$router
.
push
({
path
:
`/doctor/followUp/generalFU/add`
,
query
:
{
...
others
}
})
},
toSearch
()
{
this
.
$router
.
push
({
path
:
`/doctor/followUp/search`
})
},
toBack
()
{
backHome
()
}
}
}
</
script
>
<
style
scoped
lang=
'less'
>
.all-back {
background: #F5F5F5;
.top-title {
padding: 10px 12px;
}
.white-back {
background: #FFFFFF;
}
.mt-10 {
margin-top: 10px;
}
.p-16 {
padding: 16px;
}
.plr-8 {
padding: 0px 8px;
}
.plr-6 {
padding: 0px 6px;
}
.base-title {
font-weight: bold;
font-size: 16px;
}
.second-title {
background: #F0F3FF;
line-height: 24px;
margin-left: 10px;
}
.detail-left {
width: 104px;
font-size: 14px;
color: #8C8C8C;
}
.detail-right {
font-size: 14px;
}
.word-right {
justify-content: space-between;
align-items: center;
}
.btn {
background: #F0F3FF;
color: #607FF0;
border: 0px;
line-height: 26px;
height: 26px;
//padding: 4px 8px 4px 8px;
padding: 0px 8px;
}
.list-data {
height: calc(100vh - 140px);
overflow-y: auto;
}
}
</
style
>
\ No newline at end of file
src/doctor/followUp/search/Search.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div
class=
"flex flex-col pt-2 search"
>
<div
class=
"flex items-center px-4 pb-1 shrink-0 top-bar"
>
<span
class=
"shrink-0 pr-2 back-bt"
@
click=
"toBack"
>
<doc-icon
type=
"doc-left-1"
style=
"color: #262626"
/>
</span>
<div
class=
"grow flex items-center px-2 mr-2 input-box"
>
<doc-icon
type=
"doc-search"
class=
"shrink-0"
style=
"color: #595959"
/>
<van-field
v-model=
"idCard"
placeholder=
"请输入身份证号查询"
autocomplete=
"off"
clearable
:formatter=
"formatter"
@
clear=
"idCardClear"
ref=
"idCardField"
/>
<!--
<van-uploader
:max-size=
"5 * 1024 * 1024"
:after-read=
"afterRead"
max-count=
"1"
>
<doc-icon
type=
"doc-camera"
class=
"shrink-0 mr-3"
style=
"color: #575B66"
/>
</van-uploader>
-->
</div>
<span
class=
"text-16 shrink-0 text-primary"
@
click=
"search"
>
搜索
</span>
</div>
<div
class=
"grow px-4 overflow-y-auto"
>
<div
class=
"pt-3"
v-if=
"state === 1"
>
<div
class=
"flex justify-between items-end pt-2 pb-1"
>
<span
class=
"text-16 font-semibold"
>
搜索历史
</span>
<span
class=
"flex items-center"
@
click=
"clearHistory"
>
<doc-icon
type=
"doc-delete"
style=
"color: #8c8c8c"
/>
<span
class=
"ml-1"
style=
"color: #595959"
>
清除历史
</span>
</span>
</div>
<div
class=
"flex flex-wrap mt-4 history-list"
>
<span
v-for=
"item in history"
:key=
"item"
@
click=
"toSearch(item)"
>
{{
$idCardHide
(
item
)
}}
</span>
</div>
</div>
<div
class=
"pt-2"
v-if=
"state === 2"
>
<div
class=
"text-12"
style=
"color: #8c8c8c"
>
查找结果:
</div>
<div
class=
"card"
v-if=
"result.chronicTagsArrayName || result.firstScreenResult || result.highTagsArray"
>
<div
class=
"py-3"
>
<span
class=
"text-16 font-semibold mr-3"
>
{{
result
.
residentName
}}
</span>
<span
class=
"text-12 mr-3"
>
{{
result
.
currentAge
||
'-'
}}
岁
</span>
<span
class=
"text-12 mr-3"
>
{{
result
.
genderName
}}
</span>
<span
class=
"text-12"
v-if=
"result.chronicStatus == 9"
>
死亡
</span>
</div>
<div
class=
"mb-2"
>
<span
class=
"label"
>
身份证号
</span>
<span>
{{
$idCardHide
(
result
.
idCard
)
}}
</span>
</div>
<div
class=
"mb-2"
>
<span
class=
"label"
>
高危评估
</span>
<span>
{{
result
.
firstScreenResultName
||
'-'
}}
</span>
</div>
<div
class=
"flex mb-2"
>
<span
class=
"shrink-0 label"
>
专病高危评估
</span>
<span>
{{
result
.
highTagsArrayName
||
'-'
}}
</span>
</div>
<div
class=
"flex mb-2"
>
<span
class=
"shrink-0 label"
>
慢病标签
</span>
<ChronicTag
:list=
"result.chronicTagsArray"
/>
<!--
<span>
{{
result
.
chronicTagsArrayName
}}
</span>
-->
</div>
<div
class=
"text-12 tip"
>
<div
style=
"color: #A5AEBE;"
>
提示:
</div>
<div
style=
"color: #768092;"
>
如需为居民进行 慢病诊断筛查 ,请在医生PC端进行操作
</div>
</div>
<div
class=
"text-center mt-5"
>
<van-button
round
type=
"primary"
class=
"detail-bt"
@
click=
"toDetail"
>
详情
</van-button>
</div>
</div>
<div
class=
"card"
v-else-if=
"!!result.id"
>
<div
class=
"py-3"
>
<span
class=
"text-16 font-semibold mr-3"
>
{{
result
.
residentName
}}
</span>
<span
class=
"text-12 mr-3"
>
{{
result
.
currentAge
||
'-'
}}
岁
</span>
<span
class=
"text-12"
>
{{
result
.
genderName
}}
</span>
</div>
<div
class=
"mb-2"
>
<span
class=
"label"
>
身份证号
</span>
<span>
{{
$idCardHide
(
result
.
idCard
)
}}
</span>
</div>
<div
class=
"text-12 tip"
>
<div
style=
"color: #A5AEBE;"
>
提示:
</div>
<div
style=
"color: #768092;"
>
如需为居民进行 慢病诊断筛查 ,请在医生PC端进行操作
</div>
</div>
</div>
<div
class=
"text-center empty"
v-else
>
<img
src=
"@/assets/image/doctor/empty.png"
alt=
""
style=
"width: 1.2rem;"
>
<p>
暂无数据
</p>
</div>
</div>
</div>
</div>
</
template
>
<
script
>
import
{
getResidentByPage
}
from
'@/api/doctor/generalFU.js'
import
{
validateIdCard
}
from
'@/utils/commonReg.js'
import
{
setLocalStorage
,
getLocalStorage
}
from
'@/utils/common.js'
import
{
showFailToast
}
from
'vant'
import
ChronicTag
from
'@/doctor/components/chronicTag/ChronicTag.vue'
export
default
{
components
:
{
ChronicTag
},
data
()
{
return
{
// 查询使用
idCard
:
undefined
,
// 历史记录
history
:
[],
result
:
{},
state
:
1
,
show
:
false
,
value1
:
undefined
,
value2
:
undefined
}
},
computed
:
{
historyKey
()
{
return
'search-history'
},
},
created
()
{
this
.
history
=
getLocalStorage
(
this
.
historyKey
)
||
[]
},
methods
:
{
formatter
(
value
)
{
return
value
.
replace
(
/
[\u
4e00-
\u
9fa5
/\s
+
/]
|
[^
a-zA-Z0-9
\u
4E00-
\u
9FA5
]
/g
,
''
);
},
search
()
{
if
(
!
this
.
idCard
)
return
if
(
!
validateIdCard
(
this
.
idCard
))
{
showFailToast
(
'请输入正确的身份证号'
)
return
}
const
query
=
{
idCard
:
this
.
idCard
,
pageIndex
:
1
,
pageSize
:
10
}
getResidentByPage
(
query
).
then
(
res
=>
{
const
result
=
res
?.
data
?.
dataList
||
[]
this
.
result
=
result
[
0
]
||
{}
this
.
setHistory
()
}).
finally
(()
=>
{
this
.
state
=
2
})
},
toSearch
(
idCard
)
{
this
.
idCard
=
idCard
this
.
search
()
},
toDetail
()
{
this
.
$router
.
push
({
path
:
`/doctor/resident/base`
,
query
:
{
residentId
:
this
.
result
.
residentInfoId
}
})
},
toBack
()
{
this
.
$router
.
back
()
},
idCardClear
()
{
this
.
state
=
1
},
setHistory
()
{
const
history
=
getLocalStorage
(
this
.
historyKey
)
||
[]
const
index
=
history
.
findIndex
(
e
=>
e
===
this
.
idCard
)
if
(
index
>
-
1
)
{
history
.
splice
(
index
,
1
)
}
history
.
unshift
(
this
.
idCard
)
if
(
history
.
length
>
8
)
{
history
.
pop
()
}
this
.
history
=
history
setLocalStorage
(
this
.
historyKey
,
history
)
},
clearHistory
()
{
setLocalStorage
(
this
.
historyKey
,
[])
this
.
history
=
[]
},
// 证件上传后
afterRead
(
file
)
{
console
.
log
(
file
)
showNotify
({
type
:
'primary'
,
message
:
'文件上传'
})
}
}
}
</
script
>
<
style
lang=
"less"
scoped
>
.search {
height: 100vh;
}
.top-bar {
border-bottom: 1px solid #e5e5e5;
.back-bt {
flex-basis: 24px;
text-align: center;
}
.input-box {
background-color: #FAFAFA;
border: 1px solid #F5F5F5;
border-radius: 4px;
.svg-icon {
font-size: 16px;
}
.van-cell {
font-size: 14px;
padding: 4px 10px;
background: transparent;
&::after {
display: none;
}
}
}
}
.history-list {
gap: 10px;
>span {
border-radius: 34px;
background-color: #EFF2F7;
padding: 2px 12px;
}
}
.card {
line-height: 1.2;
.label {
display: inline-block;
color: #8C8C8C;
min-width: 8em;
}
.tip {
background-color: #F8FAFC;
padding: 8px 10px;
line-height: 1.5;
}
.detail-bt {
color: #607FF0;
background-color: #F0F3FF;
border: 0;
width: 50%;
height: 32px;
}
}
</
style
>
src/doctor/resident/Base.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div
class=
"h-full base"
>
<div
class=
'mt-3 p-4 card'
v-if=
"info.id"
>
<div
class=
'flex items-center'
>
<div
class=
'text-16 font-semibold base-title'
>
{{
info
.
residentName
}}
</div>
<div
class=
'second-title px-2'
>
{{
info
.
currentAge
}}
岁
</div>
<div
class=
'second-title px-2'
>
{{
info
.
genderName
}}
</div>
<div
class=
"second-title px-2"
v-if=
"info.chronicStatus === 9"
>
死亡
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
身份证号
</div>
<div
class=
'detail-right'
>
{{
$idCardHide
(
info
.
idCard
)
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
建档状态
</div>
<div
class=
'detail-right'
>
<span
v-if=
"!!info.residentsBaseDTO"
>
已建档
</span>
<span
v-else
>
未建档
</span>
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
签约状态
</div>
<div
class=
'detail-right'
>
<span
v-if=
"!!info.signedInfoDTO"
>
已签约
</span>
<span
v-else
>
未签约
</span>
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
高危评估
</div>
<div
class=
'detail-right'
>
<span>
{{
info
.
firstScreenResultName
||
'-'
}}
</span>
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
专病高危评估
</div>
<div
class=
'detail-right'
>
<span>
{{
info
.
highTagsArrayName
||
'-'
}}
</span>
</div>
</div>
<div
class=
'flex mt-3'
>
<div
class=
'detail-left'
>
慢病标签
</div>
<div
class=
'detail-right'
style=
'flex: 1'
>
<ChronicTag
:list=
"info.chronicTagsArray"
/>
</div>
</div>
<div
class=
"text-center mt-5"
>
<van-button
round
type=
"primary"
class=
"detail-bt"
@
click=
"toEdit"
>
修改基本信息
</van-button>
</div>
</div>
<div
class=
"text-center empty"
v-else
>
<img
src=
"@/assets/image/doctor/empty.png"
alt=
""
style=
"width: 1.2rem;"
>
<p>
暂无数据
</p>
</div>
</div>
</
template
>
<
script
>
import
ChronicTag
from
'@/doctor/components/chronicTag/ChronicTag.vue'
export
default
{
components
:
{
ChronicTag
},
inject
:
[
'getBaseInfo'
],
data
()
{
return
{}
},
computed
:
{
info
()
{
return
this
.
getBaseInfo
()
||
{}
}
},
methods
:
{
toEdit
()
{
let
par
=
{
residentInfoId
:
this
.
info
.
residentInfoId
}
this
.
$router
.
push
({
path
:
`/doctor/resident/base/update`
,
query
:
par
})
}
}
}
</
script
>
<
style
lang=
"less"
scoped
>
.card {
background-color: #fff;
.second-title {
background: #F0F3FF;
line-height: 24px;
margin-left: 10px;
}
.detail-left {
width: 8em;
color: #8C8C8C;
flex-shrink: 0;
}
.detail-bt {
color: #607FF0;
background-color: #F0F3FF;
border: 0;
width: 80%;
height: 40px;
}
}
</
style
>
src/doctor/resident/Index.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div
class=
"h-full flex flex-col"
>
<van-nav-bar
title=
'居民详情'
left-text=
''
left-arrow
class=
"shrink-0"
@
click-left=
"toBack"
></van-nav-bar>
<div
class=
"flex shrink-0 justify-center pb-1"
>
<van-tabs
v-model:active=
'activeTab'
class=
"w-1/2 top-tabs"
@
change=
"tabChange"
>
<van-tab
v-for=
'item in tabList'
:key=
"item.name"
:title=
'item.title'
:name=
'item.name'
></van-tab>
</van-tabs>
</div>
<div
class=
"grow"
style=
"background-color: #f5f5f5;min-height: 0;"
>
<router-view
v-slot=
'
{ Component }'>
<Transition
name=
'route'
mode=
'out-in'
>
<component
:is=
'Component'
/>
</Transition>
</router-view>
</div>
</div>
</
template
>
<
script
>
import
{
showNotify
}
from
'vant'
import
{
queryResidentInfo
}
from
'@/api/doctor/resident'
export
default
{
data
()
{
return
{
tabList
:
[
{
title
:
'基本信息'
,
name
:
'base'
,
path
:
'/doctor/resident/base'
},
{
title
:
'随访记录'
,
name
:
'visit'
,
path
:
'/doctor/resident/visit'
}
],
activeTab
:
'base'
,
residentId
:
null
,
// 基础信息
baseInfo
:
null
}
},
computed
:
{
routeQuery
()
{
return
this
.
$route
.
query
}
},
provide
()
{
return
{
getBaseInfo
:
()
=>
this
.
baseInfo
}
},
created
()
{
this
.
residentId
=
this
.
routeQuery
.
residentId
this
.
init
()
if
(
!
this
.
residentId
)
{
showNotify
({
type
:
'warning'
,
message
:
'未获取到医生信息'
,
duration
:
0
})
return
}
this
.
load
()
},
methods
:
{
init
()
{
if
(
this
.
$route
.
name
===
'doctor-resident-visit'
)
{
this
.
activeTab
=
'visit'
}
else
if
(
this
.
$route
.
name
===
'doctor-resident-base'
)
{
this
.
activeTab
=
'base'
}
},
tabChange
()
{
console
.
log
(
this
.
activeTab
)
const
item
=
this
.
tabList
.
find
(
e
=>
e
.
name
===
this
.
activeTab
)
if
(
!
item
)
return
this
.
$router
.
replace
({
path
:
item
.
path
,
query
:
{
residentId
:
this
.
residentId
}
})
},
load
()
{
const
query
=
{
residentInfoId
:
this
.
residentId
}
queryResidentInfo
(
query
).
then
(
res
=>
{
this
.
baseInfo
=
res
.
data
||
{}
})
},
toBack
()
{
this
.
$router
.
go
(
-
1
)
}
}
}
</
script
>
<
style
lang=
"less"
scoped
>
.top-tabs {
:deep(.van-tab) {
color: #262626;
}
:deep(.van-tab--active) {
color: var(--van-tab-active-text-color);
}
:deep(.van-tabs__line) {
height: 2px;
width: 28px;
bottom: 20px;
}
}
</
style
>
src/doctor/resident/Visit.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div
class=
'h-full flex flex-col visit'
>
<van-tabs
v-model:active=
'activeTab'
class=
'shrink-0'
v-if=
'tabList.length'
@
change=
'tabChange'
shrink
>
<van-tab
v-for=
'item in tabList'
:key=
'item.name'
:title=
'item.title'
:name=
'item.name'
></van-tab>
</van-tabs>
<div
class=
'grow overflow-y-auto card-list'
ref=
'list'
>
<van-pull-refresh
v-model=
'loadingRefresh'
@
refresh=
'onRefresh'
:disabled=
'isRefreshDisable'
>
<van-list
v-model:loading=
'loading'
:finished=
'finished'
:finished-text=
"list.length ? '没有更多了' : ''"
:immediate-check=
'false'
@
load=
'onMore'
>
<div
v-for=
'item in list'
:key=
'item.id'
class=
'p-4 mt-3 card'
@
click
.
stop=
'toDetail(item)'
>
<div
class=
'flex items-center'
>
<div
class=
'detail-left'
>
随访情况
</div>
<div
class=
'detail-right'
>
{{
item
.
visitSituationName
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
随访日期
</div>
<div
class=
'detail-right'
>
{{
item
.
serveDate
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
随访医生
</div>
<div
class=
'detail-right'
>
{{
item
.
serveDoctorName
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
服务类型
</div>
<div
class=
'detail-right'
>
{{
item
.
serveTypeName
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
随访机构
</div>
<div
class=
'detail-right'
>
{{
item
.
serveUnitName
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
下次随访日期
</div>
<div
class=
'detail-right'
>
{{
item
.
nextVisitDate
||
'-'
}}
</div>
</div>
<div
class=
'mt-3 flex items-center'
>
<div
class=
'detail-left'
>
数据来源
</div>
<div
class=
'detail-right'
>
{{
item
.
sourceName
||
'-'
}}
</div>
</div>
<van-divider
class=
'mt-3'
/>
<div
class=
'flex justify-end'
>
<van-button
round
type=
'primary'
class=
'card-bt'
style=
'margin-right: .12rem'
@
click
.
stop=
'editBtn(item)'
v-show=
'item.allowUpdate ==1'
>
修改
</van-button>
<van-button
round
type=
'primary'
class=
'card-bt'
@
click
.
stop=
'delBtn(item)'
v-show=
'item.allowUpdate ==1'
>
删除
</van-button>
</div>
<span
class=
'px-3 float-bt'
>
通用随访
</span>
</div>
</van-list>
<div
class=
'text-center shrink-0 empty'
v-if=
'!list.length'
>
<img
src=
'@/assets/image/doctor/empty.png'
alt=
''
style=
'width: 1.2rem;'
>
<p>
暂无数据
</p>
</div>
</van-pull-refresh>
</div>
<div
class=
'p-3 floor'
v-if=
'activeTab'
>
<van-button
round
block
type=
'primary'
class=
'card-bt'
@
click=
'addBtn'
>
新增通用随访
</van-button>
</div>
</div>
</
template
>
<
script
>
import
{
queryVisitByPage
,
deleteVisit
}
from
'@/api/doctor/generalFU.js'
import
{
showConfirmDialog
,
showToast
}
from
'vant'
export
default
{
data
()
{
return
{
activeTab
:
undefined
,
list
:
[],
pagination
:
{
total
:
0
,
pageIndex
:
1
,
pageSize
:
4
},
loading
:
false
,
finished
:
false
,
loadingRefresh
:
false
,
isRefreshDisable
:
false
}
},
inject
:
[
'getBaseInfo'
],
computed
:
{
baseInfo
()
{
return
this
.
getBaseInfo
()
||
{}
},
chronicTagsArray
()
{
let
chronicTagsArray
=
this
.
baseInfo
.
chronicTagsArray
||
''
return
chronicTagsArray
.
split
(
','
)
},
tabList
()
{
const
list
=
[
{
title
:
'高血压'
,
name
:
1
,
code
:
'1'
},
{
title
:
'糖尿病'
,
name
:
2
,
code
:
'2'
},
{
title
:
'冠心病'
,
name
:
3
,
code
:
'4'
},
{
title
:
'脑卒中'
,
name
:
4
,
code
:
'8'
},
{
title
:
'慢性阻塞性疾病'
,
name
:
5
,
code
:
'16'
},
{
title
:
'慢性肾病'
,
name
:
6
,
code
:
'32'
},
{
title
:
'血脂异常'
,
name
:
7
,
code
:
'64'
}
]
return
list
.
filter
(
e
=>
this
.
chronicTagsArray
.
includes
(
e
.
code
))
}
},
mounted
()
{
const
list
=
this
.
$refs
.
list
list
.
addEventListener
(
'scroll'
,
()
=>
{
if
(
list
.
scrollTop
>
0
)
{
this
.
isRefreshDisable
=
true
}
else
{
this
.
isRefreshDisable
=
false
}
})
},
methods
:
{
load
(
loading
=
true
)
{
const
query
=
{
residentInfoId
:
this
.
baseInfo
.
residentInfoId
,
serveTypeList
:
[
5
,
6
,
7
,
8
,
9
,
10
,
11
,
12
,
14
],
diseaseType
:
this
.
activeTab
,
pageIndex
:
this
.
pagination
.
pageIndex
,
pageSize
:
this
.
pagination
.
pageSize
}
queryVisitByPage
(
query
,
loading
).
then
(
res
=>
{
this
.
list
=
this
.
list
.
concat
(
res
.
data
.
dataList
||
[])
this
.
pagination
.
total
=
res
.
data
.
total
||
0
this
.
finished
=
this
.
list
.
length
>=
this
.
pagination
.
total
}).
finally
(()
=>
{
this
.
loading
=
false
this
.
loadingRefresh
=
false
})
},
onMore
()
{
this
.
pagination
.
pageIndex
++
this
.
load
()
},
init
()
{
if
(
this
.
chronicTagsArray
.
length
)
{
const
item
=
this
.
tabList
.
find
(
e
=>
e
.
code
===
this
.
chronicTagsArray
[
0
])
||
{}
this
.
activeTab
=
item
.
name
}
},
tabChange
()
{
this
.
list
=
[]
this
.
pagination
.
pageIndex
=
1
this
.
load
()
},
onRefresh
()
{
this
.
list
=
[]
this
.
pagination
.
pageIndex
=
1
this
.
load
(
false
)
},
addBtn
()
{
if
(
this
.
baseInfo
.
chronicStatus
===
9
)
{
showToast
(
'该居民已标记为死亡,无法新增随访'
)
return
}
let
par
=
{
residentInfoId
:
this
.
baseInfo
.
residentInfoId
,
diseaseType
:
this
.
activeTab
}
this
.
$router
.
push
({
path
:
`/doctor/followUp/generalFU/add`
,
query
:
par
})
},
toDetail
(
item
)
{
let
par
=
{
relationId
:
item
.
relationId
}
this
.
$router
.
push
({
path
:
`/doctor/followUp/generalFU/detail`
,
query
:
par
})
},
editBtn
(
item
)
{
let
par
=
{
id
:
item
.
relationId
,
residentInfoId
:
this
.
baseInfo
.
residentInfoId
}
this
.
$router
.
push
({
path
:
`/doctor/followUp/generalFU/add`
,
query
:
par
})
},
delBtn
(
item
)
{
showConfirmDialog
({
title
:
'提示'
,
message
:
'确认删除该随访记录吗?
\
n确认后将无法查看该随访信息'
}).
then
(()
=>
{
// on confirm
// console.log(item.id)
deleteVisit
({
id
:
item
.
id
}).
then
(
res
=>
{
this
.
load
()
})
})
.
catch
(()
=>
{
// on cancel
})
}
}
}
</
script
>
<
style
lang=
'less'
scoped
>
.card-list {
padding-bottom: 76px;
}
.card {
position: relative;
background-color: #fff;
.detail-left {
width: 8em;
color: #8C8C8C;
flex-shrink: 0;
}
.card-bt {
font-size: 14px;
color: #607FF0;
background-color: #F0F3FF;
border: 0;
height: 26px;
}
.float-bt {
position: absolute;
top: 10px;
right: 0;
background-color: var(--van-primary-color);
color: #fff;
border-top-left-radius: 40px;
border-bottom-left-radius: 40px;
height: 26px;
line-height: 26px;
}
}
.floor {
position: fixed;
bottom: 0;
left: 0;
right: 0;
}
</
style
>
src/doctor/resident/form/BaseInfo.vue
deleted
100644 → 0
View file @
9de9fa56
<
template
>
<div>
<van-nav-bar
title=
'修改居民信息'
left-text=
''
left-arrow
@
click-left=
'toBack'
></van-nav-bar>
<div
class=
'p-4 h-overflow'
>
<van-form
ref=
'form'
>
<div
class=
'title'
>
居民信息
</div>
<!--
<div
class=
'label-title'
>
证件类型
</div>
<van-field
v-model=
'form.certificateTypeName'
is-link
readonly
placeholder=
'证件类型'
class=
'input-back mt-2 form-input'
:rules=
'rules.certificateTypeName'
/>
-->
<!--
<div
class=
'label-title mt-5'
>
证件号码
</div>
<van-field
v-model=
'form.idCard'
readonly
placeholder=
'证件号码'
class=
'input-back mt-2 form-input'
:rules=
'rules.idCard'
/>
-->
<div
class=
'label-title mt-5'
>
姓名
</div>
<van-field
v-model=
'form.residentName'
clearable
placeholder=
'姓名'
class=
'input-back mt-2 form-input'
:rules=
'rules.residentName'
/>
<!--
<div
class=
'label-title mt-5'
>
性别
</div>
<van-field
v-model=
'form.genderName'
is-link
readonly
placeholder=
'性别'
class=
'input-back mt-2 form-input'
:rules=
'rules.genderName'
/>
-->
<!--
<div
class=
'label-title mt-5'
>
出生日期
</div>
<van-field
v-model=
'form.dataBirth'
is-link
readonly
placeholder=
'出生日期'
class=
'input-back mt-2 form-input'
:rules=
'rules.dataBirth'
/>
-->
<div
class=
'label-title mt-5'
>
本人电话
</div>
<van-field
v-model=
'form.telephone'
clearable
placeholder=
'本人电话'
class=
'input-back mt-2 form-input'
:rules=
'rules.telephone'
/>
<div
class=
'label-title mt-5'
>
民族
</div>
<van-field
v-model=
'form.nationalName'
is-link
readonly
name=
'national'
placeholder=
'请选择'
class=
'input-back mt-2 form-input'
:rules=
'rules.nationalName'
@
click=
'showNational = true'
/>
<van-popup
v-model:show=
'showNational'
position=
'bottom'
>
<van-picker
:columns-field-names=
"
{ text: 'name', value: 'value' }"
:columns="store.getDict('DC00006')"
@confirm='nationalConfirm'
@cancel='showNational = false'
/>
</van-popup>
<!--
<div
class=
'label-title mt-5'
>
年龄
</div>
<van-field
v-model=
'form.currentAge'
readonly
placeholder=
'年龄'
class=
'input-back mt-2 form-input'
:rules=
'rules.currentAge'
/>
-->
<div
class=
'label-title mt-5'
>
现住址
</div>
<van-field
v-model=
'form.presentCodeName'
is-link
readonly
placeholder=
'请选择所在地区'
class=
'input-back mt-2 form-input'
:rules=
'rules.presentCodeName'
@
click=
'showPresent = true'
>
<template
#
input
>
<span
class=
'text-end'
>
{{
form
.
presentCodeName
}}
</span>
</
template
>
</van-field>
<van-popup
v-model:show=
'showPresent'
:close-on-click-overlay=
'false'
position=
'bottom'
>
<DocAddress
v-model:value=
'form.presentCode'
@
close=
'showPresent = false'
:viewData=
'addressRecord.presentCode'
@
change=
'presentChange'
/>
</van-popup>
<div
class=
'no-req-label mt-5'
>
详细地址
</div>
<van-field
v-model=
'form.nowAddress'
clearable
class=
'input-back mt-2 form-input'
placeholder=
'请填写详细地址'
maxlength=
'50'
/>
<div
class=
'flex items-center justify-between mt-5'
>
<div
class=
'label-title '
>
户口地址
</div>
<van-button
size=
'mini'
plain
type=
'primary'
@
click=
'setRegisteredAddress'
>
同步现住址
</van-button>
</div>
<van-field
v-model=
'form.registeredCodeName'
is-link
readonly
placeholder=
'请选择所在地区'
class=
'input-back mt-2 form-input'
:rules=
'rules.registeredCode'
@
click=
'showRegistered = true'
>
<
template
#
input
>
<span
class=
'text-end'
>
{{
form
.
registeredCodeName
}}
</span>
</
template
>
</van-field>
<van-popup
v-model:show=
'showRegistered'
:close-on-click-overlay=
'false'
position=
'bottom'
>
<DocAddress
v-model:value=
'form.registeredCode'
@
close=
'showRegistered = false'
:viewData=
'addressRecord.registeredCode'
@
change=
'registeredChange'
/>
</van-popup>
<div
class=
'no-req-label mt-5'
>
详细地址
</div>
<van-field
v-model=
'form.permanentAddress'
clearable
class=
'input-back mt-2 form-input'
placeholder=
'请填写详细地址'
maxlength=
'50'
/>
<div
class=
'title mt-5'
>
联系人信息
</div>
<div
class=
'no-req-label mt-5'
>
联系人姓名
</div>
<van-field
v-model=
'form.contactName'
clearable
placeholder=
'联系人姓名'
class=
'input-back mt-2 form-input'
:rules=
'rules.contactName'
/>
<div
class=
'no-req-label mt-5'
>
与居民关系
</div>
<van-field
v-model=
'form.relationName'
readonly
is-link
placeholder=
'与居民关系'
class=
'input-back mt-2 form-input'
@
click=
'showRelation= true'
/>
<van-popup
v-model:show=
'showRelation'
position=
'bottom'
>
<van-picker
:columns-field-names=
"{ text: 'name', value: 'value' }"
:columns=
"store.getDict('DC00023')"
@
confirm=
'relationlConfirm'
@
cancel=
'showRelation = false'
/>
</van-popup>
<van-field
v-if=
'form.relation == 99'
v-model=
'form.relationOther'
clearable
placeholder=
'其他关系'
class=
'input-back mt-2 form-input'
/>
<div
class=
'no-req-label mt-5'
>
联系电话
</div>
<van-field
v-model=
'form.contactPhone'
clearable
placeholder=
'联系电话'
class=
'input-back mt-2 form-input'
:rules=
'rules.contactPhone'
/>
</van-form>
</div>
<div
class=
'px-5 grow flex flex-col justify-end pt-2 pb-2'
>
<van-button
type=
'primary'
block
round
@
click=
'onSubmit'
>
提交
</van-button>
</div>
</div>
</template>
<
script
>
import
{
addToArr
,
fetchDataHandle
}
from
'@/utils/common'
import
{
useStore
}
from
'@/doctor/store'
import
DocAddress
from
'@/components/docAddress/DocAddress'
import
dayjs
from
'dayjs'
import
{
getChronicResidentsId
}
from
'@/api/doctor/generalFU'
import
{
updateResident
}
from
'@/api/doctor/resident'
const
defaultForm
=
(
info
=
{})
=>
{
const
form
=
{
id
:
undefined
,
residentInfoId
:
undefined
,
// 年龄
currentAge
:
undefined
,
// 出生地详细地址
birthAddress
:
undefined
,
// 出生地编码
birthCode
:
undefined
,
// 证件类型,[DC00004]
certificateType
:
1
,
certificateTypeName
:
'身份证'
,
// 联系人姓名
contactName
:
undefined
,
contactName2
:
undefined
,
// 联系人电话
contactPhone
:
undefined
,
// 与居民关系,[DC00023]
contactRelation
:
undefined
,
contactRelationName
:
undefined
,
// 出生日期
dataBirth
:
undefined
,
// 职业,[DC00010]
duty
:
undefined
,
dutyName
:
undefined
,
// 文化程度(学历),[DC00007]
education
:
undefined
,
educationName
:
undefined
,
// 性别,[DC00005]
gender
:
undefined
,
genderName
:
undefined
,
// 身份证号
idCard
:
undefined
,
// innerMarital: undefined,
// 民族,[DC00006]
national
:
undefined
,
nationalName
:
undefined
,
// 现住址
nowAddress
:
undefined
,
// 户籍地址
permanentAddress
:
undefined
,
// 现住址编码
presentCode
:
undefined
,
presentCodeName
:
undefined
,
// 户籍地编码
registeredCode
:
undefined
,
registeredCodeName
:
undefined
,
// 居民档案id
residentId
:
undefined
,
// 姓名
residentName
:
undefined
,
// 本人电话
telephone
:
undefined
,
// 工作单位
workUnit
:
undefined
,
// 与居民关系
relation
:
undefined
,
relationName
:
undefined
,
relationOther
:
undefined
// 人群
}
Reflect
.
ownKeys
(
form
).
forEach
(
key
=>
{
if
(
info
[
key
]
!=
undefined
)
{
form
[
key
]
=
info
[
key
]
}
})
return
form
}
export
default
{
name
:
'BaseInfo'
,
components
:
{
DocAddress
},
props
:
{
info
:
{
default
:
()
=>
{
return
{}
}
}
},
data
()
{
return
{
store
:
useStore
(),
// 民族
showNational
:
false
,
showRelation
:
false
,
// 现住址
showPresent
:
false
,
// 户籍地址
showRegistered
:
false
,
// 地址回显使用
addressRecord
:
{},
form
:
{},
rules
:
{
certificateTypeName
:
[{
required
:
true
,
message
:
'请选择证件类型'
}],
idCard
:
[{
required
:
true
,
message
:
'请填写证件号码'
}],
residentName
:
[{
required
:
true
,
message
:
'请填写姓名'
}],
genderName
:
[{
required
:
true
,
message
:
'请选择性别'
}],
dataBirth
:
[{
required
:
true
,
message
:
'请选择出生日期'
}],
nationalName
:
[{
required
:
true
,
message
:
'请选择名族'
}],
currentAge
:
[{
required
:
true
,
message
:
'请填写年龄'
}],
telephone
:
[{
required
:
true
,
message
:
'请填写本人电话'
}],
contactName
:
[{
required
:
false
,
message
:
'请填写联系人姓名'
}],
contactPhone
:
[{
required
:
false
,
message
:
'请填写联系电话'
}],
presentCodeName
:
[{
required
:
true
,
message
:
'请选择所在地区'
}],
registeredCode
:
[{
required
:
true
,
message
:
'请选择所在地区'
}]
}
}
},
computed
:
{
authInfo
()
{
return
this
.
store
.
$state
.
authInfo
},
routerDetail
()
{
return
this
.
$route
.
query
}
},
created
()
{
this
.
load
()
},
methods
:
{
async
load
()
{
const
res
=
await
getChronicResidentsId
(
this
.
routerDetail
.
residentInfoId
)
this
.
form
=
defaultForm
(
res
.
data
)
if
(
this
.
form
.
presentCode
)
{
this
.
addressRecord
.
presentCode
=
addToArr
(
this
.
form
.
presentCode
)
}
if
(
this
.
form
.
registeredCode
)
{
this
.
addressRecord
.
registeredCode
=
addToArr
(
this
.
form
.
registeredCode
)
}
},
// 民族
nationalConfirm
({
selectedValues
,
selectedOptions
})
{
this
.
form
.
national
=
selectedValues
[
0
]
this
.
form
.
nationalName
=
selectedOptions
[
0
].
name
this
.
showNational
=
false
},
//与居民关系
relationlConfirm
({
selectedValues
,
selectedOptions
})
{
this
.
form
.
relation
=
selectedValues
[
0
]
this
.
form
.
relationName
=
selectedOptions
[
0
].
name
this
.
showRelation
=
false
},
// 现住址
presentChange
(
val
)
{
const
selectedOptions
=
val
.
selectedOptions
this
.
form
.
presentCodeName
=
selectedOptions
.
map
(
e
=>
e
.
text
).
join
(
'/'
)
},
// 户口地址
registeredChange
(
val
)
{
const
selectedOptions
=
val
.
selectedOptions
this
.
form
.
registeredCodeName
=
selectedOptions
.
map
(
e
=>
e
.
text
).
join
(
'/'
)
if
(
!
this
.
form
.
presentCode
&&
selectedOptions
.
length
>=
5
)
{
this
.
form
.
presentCode
=
val
.
value
this
.
form
.
presentCodeName
=
this
.
form
.
registeredCodeName
}
},
// 同步现住址
setRegisteredAddress
()
{
this
.
$refs
.
form
.
validate
([
'presentCode'
]).
then
(
res
=>
{
this
.
form
.
registeredCode
=
this
.
form
.
presentCode
this
.
form
.
registeredCodeName
=
this
.
form
.
presentCodeName
this
.
form
.
permanentAddress
=
this
.
form
.
nowAddress
this
.
addressRecord
.
registeredCode
=
addToArr
(
this
.
form
.
presentCode
)
}).
catch
(
err
=>
console
.
warn
(
err
))
},
onSubmit
()
{
this
.
$refs
.
form
.
validate
().
then
(()
=>
{
let
par
=
{
...
this
.
form
}
updateResident
(
par
).
then
(()
=>
{
this
.
toBack
()
})
}).
catch
((
e
)
=>
{
console
.
warn
(
'ArchiveCommon error'
,
e
)
})
},
toBack
()
{
this
.
$router
.
back
()
}
}
}
</
script
>
<
style
scoped
lang=
'less'
>
.h-overflow {
height: calc(100vh - 110px);
overflow-y: auto;
}
.title {
font-weight: bold;
margin-bottom: 20px;
}
.label-title {
font-size: 13px;
color: #595959;
font-weight: 500;
&::after {
content: "*";
color: red;
font-weight: bold;
margin-left: 4px;
}
}
.no-req-label {
font-size: 13px;
color: #595959;
font-weight: 500;
}
.form-input {
padding: 8px 12px;
border-radius: 8px;
}
.input-back {
background: #FAFAFA;
}
.tel-back {
background: #F5F5F5;
padding: 8px;
border-radius: 0px 0px 8px 8px;
}
.tel {
background: #FFFFFF;
padding: 8px;
border-radius: 8px;
}
.tel-label {
color: #607FF0;
font-weight: bold;
}
.p-12-0 {
padding: 12px 0px;
}
:deep(.van-nav-bar .van-icon) {
color: #000000;
}
:deep(.van-cell-group--inset) {
overflow: visible;
}
:deep(.van-cell) {
overflow: visible;
}
:deep(.van-field__error-message) {
position: absolute;
}
:deep(.van-cell:after) {
border-bottom: 0px;
}
</
style
>
\ No newline at end of file
src/router/index.js
View file @
d3ea72cf
...
...
@@ -60,13 +60,6 @@ const routes = [
name
:
'doctor-archives-form'
,
component
:
()
=>
import
(
/* webpackChunkName: "doctor" */
'@/doctor/archives/form/BaseInfo.vue'
)
},
{
path
:
'followUp/list'
,
name
:
'followUp-list'
,
component
:
()
=>
import
(
/* webpackChunkName: "doctor" */
'@/doctor/followUp/List'
)
},
{
path
:
'followUp/generalFU/detail'
,
name
:
'followUp-generalFU-detail'
,
...
...
@@ -77,32 +70,6 @@ const routes = [
name
:
'followUp-generalFU-add'
,
component
:
()
=>
import
(
/* webpackChunkName: "doctor" */
'@/doctor/followUp/generalFU/form/Index'
)
},
{
path
:
'resident'
,
name
:
'doctor-resident'
,
redirect
:
'/doctor/resident/base'
,
component
:
()
=>
import
(
/* webpackChunkName: "doctor" */
'@/doctor/resident/Index.vue'
),
children
:
[
// 基本信息
{
path
:
'base'
,
name
:
'doctor-resident-base'
,
component
:
()
=>
import
(
/* webpackChunkName: "doctor" */
'@/doctor/resident/Base.vue'
)
},
// 随访记录
{
path
:
'visit'
,
name
:
'doctor-resident-visit'
,
component
:
()
=>
import
(
/* webpackChunkName: "doctor" */
'@/doctor/resident/Visit.vue'
)
}
]
},
//修改基本信息
{
path
:
'resident/base/update'
,
name
:
'doctor-resident-base-update'
,
component
:
()
=>
import
(
/* webpackChunkName: "page-doctor" */
'@/doctor/resident/form/BaseInfo.vue'
)
}
]
},
{
...
...
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