Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
创建新议题
提交
议题看板
打开侧边栏
jingqi.liu
pica.cloud.web-education-admin
提交
5426d36d
提交
5426d36d
编写于
5月 15, 2019
作者:
yi.li
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
详情接口及健康记录页面
上级
af68b014
变更
4
展开全部
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
551 行增加
和
38 行删除
+551
-38
element-reset.css
src/style/patients-style/element-reset.css
+2
-1
patientsapi.js
src/utils/patients/patientsapi.js
+36
-0
edit-information.vue
...atients/mypatients-manage/components/edit-information.vue
+264
-0
patient-detail.vue
src/views/patients/mypatients-manage/patient-detail.vue
+249
-37
未找到文件。
src/style/patients-style/element-reset.css
浏览文件 @
5426d36d
...
@@ -15,7 +15,8 @@
...
@@ -15,7 +15,8 @@
}
}
/*恢复messageBox默认样式*/
/*恢复messageBox默认样式*/
.el-message-box
{
.el-message-box
{
width
:
360px
;
height
:
220px
;
}
}
.el-message-box__status
+
.el-message-box__message
{
.el-message-box__status
+
.el-message-box__message
{
padding-left
:
20px
;
padding-left
:
20px
;
...
...
src/utils/patients/patientsapi.js
浏览文件 @
5426d36d
...
@@ -76,3 +76,39 @@ export const getPatientDetail = (patientId) => {
...
@@ -76,3 +76,39 @@ export const getPatientDetail = (patientId) => {
description
:
'获取居民详情'
,
description
:
'获取居民详情'
,
})
})
};
};
export
const
deletePatient
=
(
data
)
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
`healths/patients/batch`
),
method
:
'delete'
,
data
:
data
,
description
:
'删除居民'
,
})
};
export
const
getRemindPatient
=
(
data
)
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
`healths/patients/remind`
),
method
:
'post'
,
data
:
data
,
description
:
'提醒居民绑定微信'
,
})
};
export
const
savePatientInfo
=
(
data
)
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
`healths/patients/update`
),
method
:
'post'
,
data
:
data
,
description
:
'保存居民信息'
,
})
};
export
const
getLabelsList
=
(
params
)
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
`healths/labels/`
),
method
:
'get'
,
params
:
params
,
description
:
'获取分组列表'
,
})
};
src/views/patients/mypatients-manage/components/edit-information.vue
0 → 100644
浏览文件 @
5426d36d
<
template
>
<div
class=
"form-warp"
>
<el-form
:model=
"patientInfoForm"
:rules=
"rules"
ref=
"patientInfoForm"
label-width=
"150px"
label-suffix=
":"
size=
"small"
:inline=
"true"
>
<el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"居民姓名"
prop=
"nickname"
>
<el-input
v-model=
"patientInfoForm.nickname"
placeholder=
"请输入居民姓名"
></el-input>
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"手机号"
prop=
"mobilePhone"
>
<el-input
v-model=
"patientInfoForm.mobilePhone"
maxlength=
"11"
placeholder=
"请输入手机号"
></el-input>
</el-form-item>
</el-col>
</el-row>
<div
class=
"has-header"
>
数据记录
</div>
<el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"诊断"
prop=
"diseaseIdList"
>
<el-select
v-model=
"patientInfoForm.diseaseIdList"
multiple
placeholder=
"请选择居民疾病诊断"
>
<el-option
v-for=
"item in diseasesList"
:key=
"item.diseaseId"
:label=
"item.diseaseName"
:value=
"item.diseaseId"
>
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"分组"
prop=
"labelIdList"
>
<el-select
v-model=
"patientInfoForm.labelIdList"
multiple
placeholder=
"请选择居民分组"
>
<el-option
v-for=
"item in labelsList"
:key=
"item.labelId"
:label=
"item.labelName"
:value=
"item.labelId"
>
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<div
class=
"has-header"
>
基本信息
</div>
<el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"身份证"
prop=
"idNo"
>
<el-input
v-model=
"patientInfoForm.idNo"
placeholder=
"请输入身份证"
></el-input>
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"出生年月"
prop=
"birthTime"
>
<el-date-picker
type=
"date"
v-model=
"patientInfoForm.birthTime"
placeholder=
"请选择出生年月"
value-format=
"yyyy-MM-dd"
value=
"yyyy-MM-dd"
style=
"width:250px"
>
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"12"
>
<el-form-item
label=
"年龄"
prop=
"age"
>
<span>
{{
patientInfoForm
.
age
}}
</span>
<!--
<el-input
v-model=
"patientInfoForm.age"
placeholder=
"请输入身份证"
></el-input>
-->
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"性别"
prop=
"sex"
>
<el-radio-group
v-model=
"patientInfoForm.sex"
>
<el-radio
:label=
"1"
>
男
</el-radio>
<el-radio
:label=
"2"
>
女
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
</
template
>
<
script
>
import
{
mapGetters
}
from
'vuex'
import
{
getDiseasesList
,
getLabelsList
,
getPatientDetail
,
getRemindPatient
,
deletePatient
,
savePatientInfo
}
from
'@/utils/patients/patientsapi'
export
default
{
name
:
"basicInfo"
,
components
:
{},
data
()
{
return
{
diseasesList
:
[],
labelsList
:
[],
patientInfoForm
:
{
nickname
:
''
,
mobilePhone
:
''
,
diseaseIdList
:
[],
labelIdList
:
[],
idNo
:
''
,
birthTime
:
''
,
age
:
''
,
},
rules
:
{
nickname
:
[{
required
:
true
,
message
:
'请输入居民姓名'
,
trigger
:
[
'change'
,
'blur'
]
}],
mobilePhone
:
[{
required
:
true
,
message
:
'请输入手机号'
,
trigger
:
[
'change'
,
'blur'
]
}],
},
patientId
:
'99997786'
,
//暂时写死一个居民的patientId
patientInfo
:
{
isWechatBind
:
1
,
remark
:
''
,
},
showLabelName
:
''
,
showDiseaseName
:
''
,
birthTimeDisplay
:
''
,
recordList
:
[{}],
}
},
created
()
{
this
.
init
();
this
.
initConstant
();
},
computed
:
{
// ...mapState('planManage',{
// remarkOption: state => state.remarkOption,
// templateOptions: state => state.templateOptions,
// })
...
mapGetters
([
'_token'
,
])
},
methods
:
{
// ...mapActions('planManage', ['getTimeNodeList','getRemarkOption','getFollowupTemplate']),
initConstant
(){
getDiseasesList
().
then
((
data
)
=>
{
if
(
data
.
code
==
'000000'
)
{
this
.
diseasesList
=
data
.
data
;
}
});
getLabelsList
({
type
:
1
,
token
:
'AB2BEE40C5AD452E93688D31A14E8C12'
}).
then
((
data
)
=>
{
if
(
data
.
code
==
'000000'
)
{
this
.
labelsList
=
data
.
data
.
labelNameList
;
}
})
},
init
()
{
getPatientDetail
(
this
.
patientId
).
then
((
data
)
=>
{
if
(
data
.
code
==
'000000'
)
{
this
.
patientInfo
=
data
.
data
;
if
(
this
.
patientInfo
){
let
customLabels
=
this
.
patientInfo
.
customLabels
;
let
diseases
=
this
.
patientInfo
.
diseases
;
let
groupLabelNames
=
[];
let
groupDiseaseNames
=
[];
//对出生日期的处理
if
(
this
.
patientInfo
.
birthTime
){
let
timeArr
=
this
.
patientInfo
.
birthTime
.
split
(
'-'
);
let
mm
=
parseInt
(
timeArr
[
1
])
<
10
?
`0
${
parseInt
(
timeArr
[
1
])}
`
:
parseInt
(
timeArr
[
1
]);
let
dd
=
parseInt
(
timeArr
[
2
])
<
10
?
`0
${
parseInt
(
timeArr
[
2
])}
`
:
parseInt
(
timeArr
[
2
]);
this
.
birthTimeDisplay
=
`
${
timeArr
[
0
]}
-
${
mm
}
-
${
dd
}
`
;
}
else
{
this
.
birthTimeDisplay
=
''
;
}
// 对分组的处理
if
(
customLabels
)
{
customLabels
.
forEach
(
item
=>
{
groupLabelNames
.
push
(
item
.
label
)
});
this
.
showLabelName
=
groupLabelNames
.
join
(
';'
);
}
else
{
this
.
showLabelName
=
''
;
}
// 对诊断疾病的处理
if
(
diseases
)
{
diseases
.
forEach
(
item
=>
{
groupDiseaseNames
.
push
(
item
.
diseaseName
)
});
this
.
showDiseaseName
=
groupDiseaseNames
.
join
(
';'
);
}
else
{
this
.
showDiseaseName
=
''
;
}
}
}
})
},
//提醒绑定
remindBind
()
{
let
remindMobileWechatPara
=
{
qrcodeType
:
1
,
patientId
:
this
.
patientId
,
// deviceInfo: window.getDeviceInfo()
}
getRemindPatient
({
...
remindMobileWechatPara
}).
then
(
data
=>
{
if
(
data
.
code
==
'000000'
)
{
this
.
$message
.
success
(
data
.
data
.
respMsg
);
}
else
{
this
.
$message
.
error
(
data
.
message
);
}
})
},
//保存备注
saveRemark
()
{
savePatientInfo
(
this
.
patientInfo
).
then
(
data
=>
{
if
(
data
.
code
==
'000000'
){
this
.
$message
.
success
(
'保存备注成功'
)
}
else
{
this
.
$message
.
error
(
data
.
message
);
}
})
},
},
filters
:
{
emptyFilter
:
function
(
value
)
{
if
(
!
value
)
{
return
'-'
;
}
else
{
return
value
;
}
},
sexFileter
:
function
(
value
)
{
if
(
!
value
&&
value
!=
0
)
{
return
'-'
;
}
else
{
let
hash
=
{
1
:
'男'
,
2
:
'女'
};
return
hash
[
value
];
}
},
},
}
</
script
>
<
style
lang=
"scss"
>
.el-input
{
width
:
250px
;
}
.form-warp
{
margin-top
:
30px
;
.has-header
{
padding
:
15px
0
;
margin-bottom
:
20px
;
border-bottom
:
1px
dashed
#888
;
}
}
</
style
>
src/views/patients/mypatients-manage/patient-detail.vue
浏览文件 @
5426d36d
此差异已折叠。
点击以展开。
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录