Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
91d25214
提交
91d25214
编写于
5月 06, 2019
作者:
yi.li
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
量表详情接口返回数据处理
上级
36cb0634
变更
1
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
36 行增加
和
26 行删除
+36
-26
diabetes.vue
src/views/followup/record-manage/patient-scale/diabetes.vue
+36
-26
未找到文件。
src/views/followup/record-manage/patient-scale/diabetes.vue
浏览文件 @
91d25214
...
@@ -243,33 +243,41 @@
...
@@ -243,33 +243,41 @@
if
(
keysList
.
length
>
0
){
if
(
keysList
.
length
>
0
){
for
(
let
i
=
0
;
i
<
this
.
addComponents
.
length
;
i
++
){
for
(
let
i
=
0
;
i
<
this
.
addComponents
.
length
;
i
++
){
let
formName
=
this
.
addComponents
[
i
].
formName
;
let
formName
=
this
.
addComponents
[
i
].
formName
;
if
(
this
.
formData
[
formName
]){
if
(
this
.
formData
[
formName
]
&&
formName
==
'h_s_002'
){
let
investigationState
=
this
.
formData
[
formName
].
investigationState
;
this
.
medication
=
[];
let
inTurn
=
this
.
formData
[
formName
].
inTurn
;
let
type3Obj
=
{};
if
(
(
investigationState
===
'失访'
||
investigationState
===
'死亡'
)
){
this
.
formData
[
'h_s_002'
].
forEach
((
item
,
index
)
=>
{
this
.
showModule
=
false
;
if
(
item
.
medicineType
==
'1'
){
}
this
.
medication
.
push
({
// if(inTurn == '12个月'){
dosageDay
:
item
.
dosageDay
,
// this.needRule = false;
dosageNum
:
item
.
dosageNum
,
// }
medicinesName
:
item
.
medicinesName
,
medicineType
:
item
.
medicineType
if
(
formName
==
'h_s_002'
){
})
this
.
formData
[
formName
].
forEach
((
item
)
=>
{
}
else
if
(
item
.
medicineType
==
'2'
){
this
.
formData
[
formName
]
=
{};
type3Obj
=
{
if
(
item
.
medicineType
==
'1'
){
dosageDay
:
item
.
dosageDay
,
this
.
medication
.
push
(
item
);
dosageNum
:
item
.
dosageNum
,
}
else
if
(
item
.
medicineType
==
'2'
){
medicinesName
:
item
.
medicinesName
,
this
.
formData
[
formName
].
medicineType
=
item
.
medicineType
;
medicineType
:
item
.
medicineType
this
.
formData
[
formName
].
medicinesName
=
item
.
medicinesName
;
this
.
formData
[
formName
].
dosageDay
=
item
.
dosageDay
;
this
.
formData
[
formName
].
dosageNum
=
item
.
dosageNum
;
}
}
this
.
formData
[
formName
].
arrList
=
this
.
medication
;
})
}
}
})
this
.
addComponents
[
i
].
formObject
=
{
arrList
:
this
.
medication
,
dosageDay
:
type3Obj
.
dosageDay
,
dosageNum
:
type3Obj
.
dosageNum
,
medicinesName
:
type3Obj
.
medicinesName
}
}
else
if
(
this
.
formData
[
formName
]
&&
formName
==
'diabetes_001'
){
this
.
addComponents
[
i
].
formObject
=
this
.
formData
[
formName
];
let
symptom
=
this
.
formData
[
formName
].
symptom
;
this
.
addComponents
[
i
].
formObject
.
symptom
=
JSON
.
parse
(
symptom
);
}
else
{
this
.
addComponents
[
i
].
formObject
=
this
.
formData
[
formName
];
this
.
addComponents
[
i
].
formObject
=
this
.
formData
[
formName
];
}
}
// 量表字段回显,会触发change校验,所以这里拿到数据渲染页面后,重置验证
// 量表字段回显,会触发change校验,所以这里拿到数据渲染页面后,重置验证
if
(
this
.
$refs
[
'form'
+
i
].
length
>
0
){
if
(
this
.
$refs
[
'form'
+
i
].
length
>
0
){
this
.
$refs
[
'form'
+
i
][
0
].
resetFields
();
this
.
$refs
[
'form'
+
i
][
0
].
resetFields
();
...
@@ -289,12 +297,14 @@
...
@@ -289,12 +297,14 @@
this
.
formData
.
planPatientsTimesId
=
parseFloat
(
this
.
planPatientsTimesId
);
this
.
formData
.
planPatientsTimesId
=
parseFloat
(
this
.
planPatientsTimesId
);
this
.
formData
.
scaleNo
=
this
.
scaleNo
;
this
.
formData
.
scaleNo
=
this
.
scaleNo
;
this
.
formData
.
isLine
=
2
;
this
.
formData
.
isLine
=
2
;
// this.formData.h_s_002 = this.medication.push({type: '2',medicinesName:this.formData.h_s_002.medicinesName,dosageDay: this.formData.h_s_002.dosageDay,dosageNum:this.formData.h_s_002.dosageNum}
);
this
.
formData
.
diabetes_001
.
symptom
=
JSON
.
stringify
(
this
.
formData
.
diabetes_001
.
symptom
);
let
arrNew
=
[];
let
arrNew
=
[];
arrNew
.
push
({
medicineType
:
'2'
,
medicinesName
:
this
.
formData
.
h_s_002
.
medicinesName
,
dosageDay
:
this
.
formData
.
h_s_002
.
dosageDay
,
dosageNum
:
this
.
formData
.
h_s_002
.
dosageNum
});
arrNew
.
push
({
medicineType
:
'2'
,
medicinesName
:
this
.
formData
.
h_s_002
.
medicinesName
,
dosageDay
:
this
.
formData
.
h_s_002
.
dosageDay
,
dosageNum
:
this
.
formData
.
h_s_002
.
dosageNum
});
this
.
formData
.
h_s_002
=
this
.
medication
.
concat
(
arrNew
);
this
.
formData
.
h_s_002
=
this
.
medication
.
concat
(
arrNew
);
console
.
log
(
'用药情况'
,
this
.
formData
.
h_s_002
)
// if(this.formData.h_s_002.length
<=
1
){
// console.log(JSON.stringify(this.formData))
// this.formData.h_s_002.push()
// }
// console.log('用药情况',this.formData.h_s_002)
postScale
(
this
.
domain
,
this
.
formData
).
then
(
res
=>
{
postScale
(
this
.
domain
,
this
.
formData
).
then
(
res
=>
{
if
(
res
.
code
==
'000000'
){
if
(
res
.
code
==
'000000'
){
let
doMsg
=
(
this
.
saveWay
==
1
)
?
'提交成功'
:
'保存成功'
;
let
doMsg
=
(
this
.
saveWay
==
1
)
?
'提交成功'
:
'保存成功'
;
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录