Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
eec10add
提交
eec10add
编写于
4月 08, 2019
作者:
tao.wu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
no message
上级
b6597e58
变更
4
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
107 行增加
和
41 行删除
+107
-41
select-patient.vue
src/views/followup/plan-manage/dialog/select-patient.vue
+10
-10
set-time-form.vue
src/views/followup/plan-manage/dialog/set-time-form.vue
+11
-3
set-time-node.vue
src/views/followup/plan-manage/dialog/set-time-node.vue
+31
-4
new-plan.vue
src/views/followup/plan-manage/new-plan.vue
+55
-24
未找到文件。
src/views/followup/plan-manage/dialog/select-patient.vue
浏览文件 @
eec10add
...
@@ -212,16 +212,16 @@
...
@@ -212,16 +212,16 @@
this
.
patientsData
=
res
.
data
.
patientList
//接口获取的当页居民
this
.
patientsData
=
res
.
data
.
patientList
//接口获取的当页居民
this
.
getSex
()
this
.
getSex
()
this
.
paginationSet
.
total
=
res
.
data
.
totalRows
this
.
paginationSet
.
total
=
res
.
data
.
totalRows
//
// 设置所请求的当页人员是否成为选中状态
// 设置所请求的当页人员是否成为选中状态
//
if(this.patientIdList.length > 0){
if
(
this
.
patientIdList
.
length
>
0
){
//
this.patientsData.forEach((item)=>{
this
.
patientsData
.
forEach
((
item
)
=>
{
//
if(this.patientIdList.includes(item.patientId)){// 如果已经选过居民
if
(
this
.
patientIdList
.
includes
(
item
.
patientId
)){
// 如果已经选过居民
//
this.$nextTick(()=>{
this
.
$nextTick
(()
=>
{
//
this.$refs.multipleTable.toggleRowSelection(item,true);
this
.
$refs
.
multipleTable
.
toggleRowSelection
(
item
,
true
);
//
})
})
//
}
}
//
})
})
//
}
}
}
}
})
})
},
},
...
...
src/views/followup/plan-manage/dialog/set-time-form.vue
浏览文件 @
eec10add
...
@@ -130,7 +130,8 @@
...
@@ -130,7 +130,8 @@
},
},
props
:
{
props
:
{
timeForm
:
Object
,
timeForm
:
Object
,
valBegin
:
Boolean
,
valBegin
:
Boolean
,
// 设置新时间节点的校验开关
saveValiedBegin
:
Boolean
,
// 点击保存提交整个表单的校验开关
markOptions
:
Array
,
markOptions
:
Array
,
followTypeList
:
Array
,
followTypeList
:
Array
,
remindOptions
:
Array
,
remindOptions
:
Array
,
...
@@ -142,10 +143,17 @@
...
@@ -142,10 +143,17 @@
valBegin
(
val
){
valBegin
(
val
){
if
(
val
){
if
(
val
){
this
.
$refs
[
this
.
timeForm
.
formRef
].
validate
((
valid
)
=>
{
this
.
$refs
[
this
.
timeForm
.
formRef
].
validate
((
valid
)
=>
{
this
.
$emit
(
'checkValid'
,
valid
)
this
.
$emit
(
'checkValid'
,
{
valid
:
valid
,
type
:
'normal'
}
)
});
});
}
}
}
},
saveValiedBegin
(
val
){
if
(
val
){
this
.
$refs
[
this
.
timeForm
.
formRef
].
validate
((
valid
)
=>
{
this
.
$emit
(
'checkValid'
,{
valid
:
valid
,
type
:
'save'
})
});
}
}
},
},
methods
:
{
methods
:
{
changeRemindDay
(
val
){
changeRemindDay
(
val
){
...
...
src/views/followup/plan-manage/dialog/set-time-node.vue
浏览文件 @
eec10add
...
@@ -41,6 +41,7 @@
...
@@ -41,6 +41,7 @@
<set-time-form
<set-time-form
:timeForm=
"timeForm"
:timeForm=
"timeForm"
:valBegin=
"valBegin"
:valBegin=
"valBegin"
:saveValiedBegin=
"saveValiedBegin"
:markOptions=
"markOptions"
:markOptions=
"markOptions"
:remindOptions=
"remindOptions"
:remindOptions=
"remindOptions"
:pushTimeOptions=
"pushTimeOptions"
:pushTimeOptions=
"pushTimeOptions"
...
@@ -90,6 +91,7 @@
...
@@ -90,6 +91,7 @@
data
()
{
data
()
{
return
{
return
{
valBegin
:
false
,
valBegin
:
false
,
saveValiedBegin
:
false
,
isSelectCartoon
:
false
,
isSelectCartoon
:
false
,
activeTab
:
null
,
activeTab
:
null
,
currentFormRef
:
1
,
currentFormRef
:
1
,
...
@@ -104,7 +106,8 @@
...
@@ -104,7 +106,8 @@
},
},
props
:
{
props
:
{
setTimeNodeList
:
Array
,
setTimeNodeList
:
Array
,
patientIdList
:
Array
patientIdList
:
Array
,
checkForm
:
Boolean
,
},
},
computed
:
{
computed
:
{
...
mapState
(
'planManage'
,{
...
mapState
(
'planManage'
,{
...
@@ -137,6 +140,15 @@
...
@@ -137,6 +140,15 @@
}
}
},
},
watch
:
{
watch
:
{
checkForm
(
val
){
// console.log(val)
if
(
val
){
// 触发 保存 校验
this
.
saveValiedBegin
=
true
}
else
{
this
.
saveValiedBegin
=
false
}
},
valBegin
(
val
){
valBegin
(
val
){
this
.
valBegin
=
val
this
.
valBegin
=
val
},
},
...
@@ -181,9 +193,10 @@
...
@@ -181,9 +193,10 @@
this
.
getFormOptions
()
this
.
getFormOptions
()
},
},
checkValid
(
val
){
checkValid
(
obj
){
this
.
valBegin
=
false
this
.
valBegin
=
false
if
(
val
)
{
console
.
log
(
'校验结果'
,
obj
.
valid
)
if
(
obj
.
valid
)
{
if
(
this
.
timeForm
.
remindDay
.
length
>
0
){
if
(
this
.
timeForm
.
remindDay
.
length
>
0
){
this
.
timeForm
.
remindDay
.
forEach
((
item
)
=>
{
this
.
timeForm
.
remindDay
.
forEach
((
item
)
=>
{
this
.
timeForm
.
remindList
.
push
({
this
.
timeForm
.
remindList
.
push
({
...
@@ -206,12 +219,26 @@
...
@@ -206,12 +219,26 @@
}
}
this
.
setTimeNodeList
.
push
(
this
.
timeForm
);
this
.
setTimeNodeList
.
push
(
this
.
timeForm
);
this
.
$emit
(
'setTimeNodeListOnCom'
,
this
.
setTimeNodeList
)
if
(
obj
.
type
==
'save'
){
console
.
log
(
'是点击保存时候的校验,因此告诉最外层的 new-plan 组件,校验结果'
)
this
.
$emit
(
'addListenSave'
,
true
)
}
// this.timeForm = _.cloneDeep(timeFormInit);
// this.timeForm = _.cloneDeep(timeFormInit);
this
.
timeForm
=
timeFormInit
this
.
timeForm
=
timeFormInit
this
.
timeForm
.
formRef
=
this
.
getNowTime
();
this
.
timeForm
.
formRef
=
this
.
getNowTime
();
this
.
timeForm
.
isDisabled
=
true
;
this
.
timeForm
.
isDisabled
=
true
;
this
.
$emit
(
'setTimeNodeListOnCom'
,
this
.
setTimeNodeList
)
}
else
{
}
else
{
// 告诉 保存 按钮, 校验没通过
if
(
obj
.
type
==
'save'
){
console
.
log
(
'是点击保存时候的校验,因此告诉最外层的 new-plan 组件,校验结果'
)
this
.
$emit
(
'addListenSave'
,
false
)
}
return
return
}
}
},
},
...
...
src/views/followup/plan-manage/new-plan.vue
浏览文件 @
eec10add
...
@@ -82,17 +82,24 @@
...
@@ -82,17 +82,24 @@
:setTimeNodeList=
"setTimeNodeList"
:setTimeNodeList=
"setTimeNodeList"
@
setTimeNodeListOnCom=
"setTimeNodeListOnCom"
@
setTimeNodeListOnCom=
"setTimeNodeListOnCom"
:patientIdList=
"baseInfo.patientIdList"
:patientIdList=
"baseInfo.patientIdList"
:checkForm=
"checkForm"
@
addListenSave=
"addListenSave"
/>
/>
</div>
</div>
</div>
</div>
<select-patient
<select-patient
:isShowSelectPatient=
"isShowSelectPatient"
:isShowSelectPatient=
"isShowSelectPatient"
:patientIdList=
"
hasSelecte
dList"
:patientIdList=
"
baseInfo.patientI
dList"
@
closeSelectPatient=
"closeSelectPatient"
@
closeSelectPatient=
"closeSelectPatient"
@
sureSelectPatient=
"sureSelectPatient(arguments)"
@
sureSelectPatient=
"sureSelectPatient(arguments)"
/>
/>
<has-selected-patient
:isShowSelectedDialog=
"isShowSelectedDialog"
:hasSelectedList=
"hasSelectedList"
@
closeSelectedDialog=
"closeSelectedDialog"
@
continueAdd=
"continueAdd"
></has-selected-patient>
<has-selected-patient
:isShowSelectedDialog=
"isShowSelectedDialog"
:hasSelectedList=
"hasSelectedList"
@
closeSelectedDialog=
"closeSelectedDialog"
@
continueAdd=
"continueAdd"
/>
</div>
</div>
</
template
>
</
template
>
...
@@ -114,6 +121,7 @@
...
@@ -114,6 +121,7 @@
},
},
data
()
{
data
()
{
return
{
return
{
checkForm
:
false
,
/*面包屑配置*/
/*面包屑配置*/
curmbFirst
:
'随访管理'
,
curmbFirst
:
'随访管理'
,
curmbSecond
:
'计划管理'
,
curmbSecond
:
'计划管理'
,
...
@@ -152,6 +160,11 @@
...
@@ -152,6 +160,11 @@
//清理store中存的数据setTimeNodeList
//清理store中存的数据setTimeNodeList
},
},
// watch: {
// checkForm(val){
// this.checkForm = val
// }
// },
computed
:
{
computed
:
{
...
mapState
(
'planManage'
,{
...
mapState
(
'planManage'
,{
setTimeNodeList
:
state
=>
state
.
setTimeNodeList
,
setTimeNodeList
:
state
=>
state
.
setTimeNodeList
,
...
@@ -161,6 +174,46 @@
...
@@ -161,6 +174,46 @@
},
},
methods
:
{
methods
:
{
...
mapActions
(
'planManage'
,
[
'getTimeNodeList'
,
'getRemarkOption'
,
'getFollowupTemplate'
]),
...
mapActions
(
'planManage'
,
[
'getTimeNodeList'
,
'getRemarkOption'
,
'getFollowupTemplate'
]),
// 点击保存
saveEdit
()
{
console
.
log
(
this
.
checkForm
)
// 点击保存,先进行校验,表单字段是否通过验证
this
.
checkForm
=
true
},
// 监听保存校验结果
addListenSave
(
val
){
console
.
log
(
'监听保存校验结果'
,
val
)
this
.
checkForm
=
false
if
(
val
){
this
.
baseInfo
.
fPlanTimeReqList
=
this
.
setTimeNodeList
// 提交
createFollowPlan
(
this
.
baseInfo
).
then
(
res
=>
{
if
(
res
.
code
==
'000000'
){
this
.
getTimeNodeList
([]);
// 各种校验通过后,提交编辑内容,toast提示
this
.
$notify
.
success
({
title
:
''
,
message
:
'创建成功'
,
showClose
:
false
});
setTimeout
(()
=>
{
this
.
$router
.
push
({
path
:
'/followup/plan-manage/plan-list'
})
},
2000
)
}
else
{
this
.
$notify
.
success
({
title
:
'提交失败'
,
message
:
res
.
message
,
showClose
:
false
});
}
})
// console.log('保存setTimeNodeList1',this.$refs.getTimeNodeList.setTimeNodeList1)
// console.log('store中的setTimeNodeList数据为=>',JSON.stringify(this.setTimeNodeList))
}
},
setTimeNodeListOnCom
(
val
){
setTimeNodeListOnCom
(
val
){
this
.
getTimeNodeList
(
val
)
this
.
getTimeNodeList
(
val
)
},
},
...
@@ -227,29 +280,7 @@
...
@@ -227,29 +280,7 @@
preClick
()
{
preClick
()
{
this
.
activeTab
=
'first'
;
this
.
activeTab
=
'first'
;
},
},
saveEdit
()
{
this
.
baseInfo
.
fPlanTimeReqList
=
this
.
setTimeNodeList
// 提交
createFollowPlan
(
this
.
baseInfo
).
then
(
res
=>
{
if
(
res
.
code
==
'000000'
){
this
.
getTimeNodeList
([]);
// 各种校验通过后,提交编辑内容,toast提示
this
.
$notify
.
success
({
title
:
''
,
message
:
'创建成功'
,
showClose
:
false
});
this
.
$router
.
push
({
path
:
'/followup/plan-manage/plan-list'
})
}
})
// console.log('保存setTimeNodeList1',this.$refs.getTimeNodeList.setTimeNodeList1)
// console.log('store中的setTimeNodeList数据为=>',JSON.stringify(this.setTimeNodeList))
},
},
},
watch
:
{
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录