Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
36a49fa2
提交
36a49fa2
编写于
5月 06, 2019
作者:
tao.wu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
no message
上级
00d2bd98
变更
3
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
79 行增加
和
25 行删除
+79
-25
hypeDataSourceMedicationUse.js
...manage/models/hypertension/hypeDataSourceMedicationUse.js
+4
-4
hypeDataSourceReferral.js
...cord-manage/models/hypertension/hypeDataSourceReferral.js
+30
-5
hypertension.vue
...ews/followup/record-manage/patient-scale/hypertension.vue
+45
-16
未找到文件。
src/views/followup/record-manage/models/hypertension/hypeDataSourceMedicationUse.js
浏览文件 @
36a49fa2
...
...
@@ -31,7 +31,7 @@ export default ($this) => {
clickFunc
:
()
=>
{
$this
.
addComponents
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
name
==
'hypeDataSourceMedicationUse'
){
if
(
$this
.
addComponents
[
index
].
formObject
.
arrList
.
length
>=
3
)
{
if
(
$this
.
addComponents
[
index
].
formObject
.
arrList
&&
$this
.
addComponents
[
index
].
formObject
.
arrList
.
length
>=
3
)
{
$this
.
$message
.
warning
(
'最多只可添加3种药物!'
)
}
else
{
$this
.
dialogFormVisible
=
true
;
...
...
@@ -63,7 +63,7 @@ export default ($this) => {
$this
.
addComponents
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
name
==
'hypeDataSourceMedicationUse'
){
$this
.
addComponents
[
index
].
dataSource
.
forEach
((
item
,
index2
)
=>
{
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
){
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
&&
$this
.
addComponents
[
index
].
dataSource
[
index2
].
prop
!=
'arrList'
){
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
[
0
].
required
=
flag
;
}
})
...
...
@@ -89,7 +89,7 @@ export default ($this) => {
$this
.
addComponents
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
name
==
'hypeDataSourceMedicationUse'
){
$this
.
addComponents
[
index
].
dataSource
.
forEach
((
item
,
index2
)
=>
{
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
){
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
&&
$this
.
addComponents
[
index
].
dataSource
[
index2
].
prop
!=
'arrList'
){
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
[
0
].
required
=
flag
;
}
})
...
...
@@ -115,7 +115,7 @@ export default ($this) => {
$this
.
addComponents
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
name
==
'hypeDataSourceMedicationUse'
){
$this
.
addComponents
[
index
].
dataSource
.
forEach
((
item
,
index2
)
=>
{
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
){
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
&&
$this
.
addComponents
[
index
].
dataSource
[
index2
].
prop
!=
'arrList'
){
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
[
0
].
required
=
flag
;
}
})
...
...
src/views/followup/record-manage/models/hypertension/hypeDataSourceReferral.js
浏览文件 @
36a49fa2
...
...
@@ -30,15 +30,40 @@ export default ($this) => {
{
formType
:
'input'
,
className
:
'float-none'
,
prop
:
'mechanism
Department
'
,
model
:
'mechanism
Department
'
,
label
:
'机构
及科别
:'
,
prop
:
'mechanism'
,
model
:
'mechanism'
,
label
:
'机构:'
,
disabled
:
false
,
placeholder
:
'请输入机构
及科别
'
,
placeholder
:
'请输入机构'
,
spanNum
:
12
,
maxlength
:
30
,
type
:
'text'
,
rules
:
[{
required
:
false
,
message
:
'请输入机构及科别'
,
trigger
:
[
'submit'
,
'change'
,
'blur'
]}],
rules
:
[{
required
:
false
,
message
:
'请输入机构'
,
trigger
:
[
'submit'
,
'change'
,
'blur'
]}],
changeFun
:
(
val
)
=>
{
let
flag
=
val
?
true
:
false
;
$this
.
addComponents
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
name
==
'hypeDataSourceReferral'
){
$this
.
addComponents
[
index
].
dataSource
.
forEach
((
item
,
index2
)
=>
{
if
(
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
){
$this
.
addComponents
[
index
].
dataSource
[
index2
].
rules
[
0
].
required
=
flag
;
}
})
}
})
},
},
{
formType
:
'input'
,
className
:
'float-none'
,
prop
:
'department'
,
model
:
'department'
,
label
:
'科室:'
,
disabled
:
false
,
placeholder
:
'请输入科室'
,
spanNum
:
12
,
maxlength
:
30
,
type
:
'text'
,
rules
:
[{
required
:
false
,
message
:
'请输入科室'
,
trigger
:
[
'submit'
,
'change'
,
'blur'
]}],
changeFun
:
(
val
)
=>
{
let
flag
=
val
?
true
:
false
;
$this
.
addComponents
.
forEach
((
item
,
index
)
=>
{
...
...
src/views/followup/record-manage/patient-scale/hypertension.vue
浏览文件 @
36a49fa2
...
...
@@ -165,7 +165,7 @@
{
name
:
'hypeDataSourceLifeMode'
,
formObject
:
{},
showModule
:
true
,
formName
:
'hypertension_003'
,
className
:
'obj-form-title'
,
dataSource
:
hypeDataSourceLifeMode
(
this
),
hideTitle
:
false
,
title
:
'生活方式指导'
},
{
name
:
'hypeDataSourceHelpChecking'
,
formObject
:
{},
showModule
:
true
,
formName
:
'hypertension_004'
,
className
:
'obj-form-title'
,
dataSource
:
hypeDataSourceHelpChecking
(
this
),
hideTitle
:
false
,
title
:
'辅助检查'
},
{
name
:
'hypeDataSourceMedicationUse'
,
formObject
:
{
arrList
:
this
.
medication
},
showModule
:
true
,
formName
:
'h_s_002'
,
className
:
'obj-form-title'
,
dataSource
:
hypeDataSourceMedicationUse
(
this
),
hideTitle
:
false
,
title
:
'用药情况'
},
{
name
:
'hypeDataSourceReferral'
,
formObject
:
{
reason
:
''
,
mechanism
Department
:
''
},
showModule
:
true
,
formName
:
'h_s_003'
,
className
:
'obj-form-title'
,
dataSource
:
hypeDataSourceReferral
(
this
),
hideTitle
:
false
,
title
:
'转诊'
},
{
name
:
'hypeDataSourceReferral'
,
formObject
:
{
reason
:
''
,
mechanism
:
''
},
showModule
:
true
,
formName
:
'h_s_003'
,
className
:
'obj-form-title'
,
dataSource
:
hypeDataSourceReferral
(
this
),
hideTitle
:
false
,
title
:
'转诊'
},
{
name
:
'hypeDataSourceNextFollowDay'
,
formObject
:
{
nextFollowDay
:
''
},
showModule
:
true
,
formName
:
'h_s_004'
,
className
:
'obj-form-title'
,
dataSource
:
hypeDataSourceNextFollowDay
(
this
),
hideTitle
:
true
,
title
:
'下次随访日期'
},
]
},
...
...
@@ -233,10 +233,16 @@
this
.
formData
=
res
.
data
let
keysList
=
Object
.
keys
(
this
.
formData
);
if
(
keysList
.
length
>
0
){
this
.
medication
=
[];
// this.medication = [{
// medicinesName: '',
// dosageDay: '',
// dosageNum: '',
// medicineType: 'nullData'
// }];
for
(
let
i
=
0
;
i
<
this
.
addComponents
.
length
;
i
++
){
let
formName
=
this
.
addComponents
[
i
].
formName
;
if
(
this
.
formData
[
formName
]
&&
formName
==
'h_s_002'
){
this
.
medication
=
[];
if
(
this
.
formData
[
formName
]
&&
formName
==
'h_s_002'
&&
this
.
formData
.
h_s_002
.
length
>
1
){
let
type3Obj
=
{};
this
.
formData
.
h_s_002
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
medicineType
==
'1'
){
...
...
@@ -282,6 +288,19 @@
// 处理用药情况数据
handleModuleMedicalUse
(){
let
otherMed
=
[];
// this.medication = [{
// medicinesName: '',
// dosageDay: '',
// dosageNum: '',
// medicineType: 'nullData'
// }];
this
.
medication
.
push
({
medicinesName
:
''
,
dosageDay
:
''
,
dosageNum
:
''
,
medicineType
:
'nullData'
});
console
.
log
(
'medication111'
,
this
.
medication
)
for
(
let
i
=
0
;
i
<
this
.
addComponents
.
length
;
i
++
){
if
(
this
.
addComponents
[
i
].
name
==
'hypeDataSourceMedicationUse'
){
const
formObject
=
this
.
addComponents
[
i
].
formObject
;
...
...
@@ -295,24 +314,28 @@
})
}
if
(
this
.
medication
.
length
>
0
){
this
.
medication
=
[...
this
.
medication
,...
otherMed
];
this
.
formData
.
h_s_002
=
this
.
medication
;
this
.
valid
=
true
;
}
else
{
this
.
$message
.
warning
(
'最少需要添加1种用药情况!'
);
this
.
valid
=
false
;
this
.
$nextTick
(()
=>
{
// 如果表单未完善,跳转到该表单模块
document
.
querySelector
(
`#form
${
i
}
`
).
scrollIntoView
(
true
);
return
;
})
}
// if(this.medication.length>0){
// this.medication = [...this.medication,...otherMed];
// this.formData.h_s_002 = this.medication;
// this.valid = true;
// }else{
// this.$message.warning('最少需要添加1种用药情况!');
// this.valid = false;
// this.$nextTick(() => {
// // 如果表单未完善,跳转到该表单模块
// document.querySelector(`#form${i}`).scrollIntoView(true);
// return;
// })
// }
this
.
medication
=
[...
this
.
medication
,...
otherMed
];
this
.
formData
.
h_s_002
=
this
.
medication
;
this
.
valid
=
true
;
}
}
let
flag
=
this
.
valid
;
this
.
$emit
(
'checkEnd'
,
false
);
console
.
log
(
'medication222'
,
this
.
medication
)
return
flag
;
},
// 提交量表
...
...
@@ -357,6 +380,12 @@
this
.
dialogFormVisible
=
val
;
},
setMedication
(
val
){
// this.medication.push( {
// medicinesName: '',
// dosageDay: '',
// dosageNum: '',
// medicineType: 'nullData'
// })
this
.
medication
.
push
({...
val
,
medicineType
:
'1'
});
console
.
log
(
'medication=>'
,
this
.
medication
)
}
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录