提交 d3283886 编写于 作者: Yuanzhao.dai's avatar Yuanzhao.dai

变更计划&结束随访&修改计划

上级 15918325
......@@ -30,6 +30,15 @@ const followRouters = {
name: 'planManage',
redirect: 'plan-manage/plan-list',
children: [
{
path: 'plan-modify',
component: planModify,
name: 'planModify',
meta: {
title: '修改计划',
keepAlive: false //页面不需要缓存
},
},
{
path: 'plan-detail',
component: planDetail,
......
......@@ -14,6 +14,7 @@ export default {
nodeTimeList: [], //随访时间节点列表,
nodeContent: {}, //时间节点详情
planOption: [], //随访计划select
timeNodeList: []
},
mutations: {
......@@ -25,6 +26,7 @@ export default {
},
GET_RESIDENT_DETAIL(state, payload) {
state.residentDetail = payload
state.timeNodeList = payload.fPlanPatientDatilDtoList.timeNodeList
},
GET_PLAN_DETAIL(state, payload) {
state.planDetail = payload
......@@ -36,7 +38,7 @@ export default {
state.nodeContent = payload
},
GET_PLAN_OPTION(state, payload) {
state.planOption = payload
state.planOption = payload.fPlanDtoList
}
},
actions: {
......@@ -82,6 +84,20 @@ export default {
}).then(({data}) => {
context.commit('GET_NODE_CONTENT', data);
});
}
},
getPlanOptions(context, payload) {
followApi.getPlanList({
pageNum: -1
}).then(({data}) => {
context.commit('GET_PLAN_OPTION', data);
});
},
changePlan(context, payload) {
followApi.changePlan({
}).then(({data}) => {
// context.commit('GET_PLAN_OPTION', data);
});
},
},
}
......@@ -11,7 +11,7 @@
<el-form-item label="分组:">
<el-select v-model="planChangeData.group" >
<el-option
v-for="item in groupOption"
v-for="item in groupList"
:key="item.labelId"
:label="item.labelName"
:value="item.labelId">
......@@ -19,35 +19,36 @@
</el-select>
</el-form-item>
<el-form-item label="随访计划:">
<el-select v-model="planChangeData.plan" >
<el-select v-model="planChangeData.planId" >
<el-option
v-for="item in planOption"
:key="item.value"
:label="item.label"
:value="item.value">
:key="item.id"
:label="item.name"
:value="item.id">
</el-option>
</el-select>
</el-form-item>
<el-form-item label="随访开始时间:">
<el-select v-model="planChangeData.startTime">
<el-option
v-for="item in groupOption"
:key="item.value"
:label="item.label"
:value="item.value">
v-for="item in nodeTimeList"
:key="item.id"
:label="item.timeStr"
:value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button class="button-green" @click="clickClose" type="primary">取 消</el-button>
<el-button class="button-white" @click="clickClose" plain>确 定</el-button>
<el-button class="button-white" @click="changePlan" plain>确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { mapState, mapActions} from 'vuex'
export default {
name: "change-plan",
props: {
......@@ -63,27 +64,51 @@
return {};
}
},
groupOption: {
/*groupOption: {
type: Array,
default: function () {
return [];
}
},
planOption: {
},*/
/*planOption: {
type: Array,
default: function () {
return [];
}
},
},*/
},
data() {
return {
showChangePlan: true
}
},
mounted() {
this.getPlanOptions();
this.getNodeTimeList();
// 获取随访时间列表
},
computed: {
...mapState('planManage', {
planOption: state => state.planOption,
groupList: state => state.groupList,
nodeTimeList: state => state.nodeTimeList,
})
},
methods: {
...mapActions('planManage', ['getPlanOptions', 'getNodeTimeList', 'changePlan']),
clickClose() {
this.$emit('closeChangePlan',false)
this.$emit('closeChangePlan',false);
},
changePlan() {
this.clickClose()
/* this.changePlan(this.planChangeData).then(({data}) => {
this.clickClose()
});*/
}
},
watch: {
planChangeData(val) {
this.getNodeTimeList(val.planId);
}
}
}
......
......@@ -71,7 +71,7 @@
<div class="content-div">
<div class="c-title">随访登记表:</div>
<div class="c-content more-content">
<p v-for="item in nodeContent.followupList">{{item.sendContent}}</p>
<p class="click-text" v-for="item in nodeContent.followupList" >{{item.sendContent}}</p>
</div>
</div>
</div>
......@@ -111,7 +111,7 @@
},
mounted() {
this.getPlanDetail(this.$route.query.planId); //获取居民详情
this.getNodeTimeList(this.planId); // 获取随访时间列表
this.getNodeTimeList(this.$route.query.planId); // 获取随访时间列表
},
computed: {
...mapState('planManage', {
......
......@@ -118,11 +118,7 @@
this.$router.push({path: '/followup/plan-manage/resident-list', query: {planId:'1'}})
},
changeRow(row){
// this.statusForm = row;
// this.dialogFormVisible = true;
// if (this.$refs['statusForm']) {
// this.$refs['statusForm'].resetFields();
// }
this.$router.push({path: '/followup/plan-manage/plan-modify', query: {planId:'1'}})
},
deleteRow(row){},
......
<template>
<div class="plan-modify">
修改计划
<bread-crumb
:curmbFirst="curmbFirst"
:curmbSecond="curmbSecond"
:curmbThird="curmbThird"
:jumPathThird="jumPathThird">
</bread-crumb>
<div class="new-plan-content f-main-content screenSet">
<div class="header">
<div class="title">
<span>修改计划</span>
</div>
<div class="plan-btns-group">
<el-button class="button-white" plain @click="cancelEdit" >取 消</el-button>
<el-button class="button-green" type="primary" @click="cancelEdit" >保 存</el-button>
</div>
</div>
<el-form ref="baseInfo" :model="modifyInfo" :rules="rules" label-suffix=":" label-width="140px">
<el-form-item label="随访计划名称" prop="name">
<el-input v-model="modifyInfo.name" maxlength="20" style="width: 30%" clearable></el-input>
</el-form-item>
<el-form-item label="随访居民" required>
<div class="select-patients">
<el-button plain icon="el-icon-plus" @click="selectPatientHandler">{{modifyInfo.hasSelectedNum ? '继续添加' : '选择居民'}}</el-button><br>
<el-button type="text" class="mt10" @click="seeSelectedHandler" v-if="modifyInfo.hasSelectedNum">已选{{modifyInfo.hasSelectedNum}}<i class="el-icon-arrow-right"></i></el-button>
</div>
</el-form-item>
<el-form-item label="随访模板" prop="followupTemplate">
<el-select
v-model="modifyInfo.followupTemplate"
placeholder="请选择随访模板"
clearable>
<el-option
v-for="item in templateOptions"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
<p class="tips">随访计划创建成功后,模板不可更换,请谨慎选择。</p>
</el-form-item>
<el-form-item label="随访开始时间" prop="startTime">
<el-date-picker
v-model="modifyInfo.startTime"
type="date"
placeholder="请选择随访开始时间"
clearable
style="width:380px;">
</el-date-picker>
</el-form-item>
<el-form-item label="备注">
<el-select
v-model="modifyInfo.followupKind"
placeholder="请选择随访种类"
clearable>
<el-option
v-for="item in kindOptions"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-form>
</div>
<select-patient
:isShowSelectPatient="isShowSelectPatient"
@closeSelectPatient="closeSelectPatient"
@sureSelectPatient="sureSelectPatient(arguments)">
</select-patient>
</div>
</template>
<script>
import BreadCrumb from '@/components/breadcrumb'
import SelectPatient from '@/views/followup/plan-manage/dialog/select-patient';
import HasSelectedPatient from '@/views/followup/plan-manage/dialog/has-selected-patient';
export default {
name: "plan-modify"
name: "plan-modify",
components: {
BreadCrumb,
SelectPatient,
HasSelectedPatient,
},
data() {
return {
/*面包屑配置*/
curmbFirst: '随访管理',
curmbSecond: '计划管理',
curmbThird: '修改随访计划',
jumPathThird: '/followUp/plan-manage',
modifyInfo: {},
rules: {
name: [{ required: true, message: '请输入随访计划名称', trigger: 'blur' }],
followupTemplate: [{ required: true, message: '请选择随访模板', trigger: 'change' }],
startTime: [{ required: true, message: '请选择随访开始时间', trigger: 'change' }],
},
templateOptions: [
{
value: '0',
label: '随访模板一'
}, {
value: '1',
label: '随访模板二'
}, {
value: '2',
label: '随访模板三'
}
],
kindOptions: [
{
value: '0',
label: '上门随访'
}, {
value: '1',
label: '术后随访'
}
],
isShowSelectPatient: false, //显示居民选择框
hasSelectedList: [], //已选居民
}
},
methods: {
selectPatientHandler() {
this.isShowSelectPatient = true;
},
closeSelectPatient(val) {
this.isShowSelectPatient = val;
},
sureSelectPatient() {
let getArguments = arguments[0];
this.isShowSelectPatient = getArguments[0];
this.hasSelectedList = getArguments[1];
this.modifyInfo.hasSelectedNum = getArguments[1].length;
},
},
}
</script>
<style scoped>
<style lang="scss" scoped>
@import '../../../style/followup/followup-common';
@import '../../../style/followup/element-reset.css';
.header{
display: flex;
align-items: center;
justify-content: space-between;
padding-bottom: 20px;
border-bottom: $borderBottomStyle;
margin-bottom: 30px;
}
</style>
......@@ -62,10 +62,10 @@
</div>
</div>
</div>
<!--<div class="time-nodes">
<div class="time-nodes">
<p class="title">随访时间节点</p>
<el-radio-group v-model="timeNodes">
<el-radio-button :key="item.id" v-for="item in residentDetail.fPlanTimeDtoList" :label="item.nodeId">{{item.timeStr}}</el-radio-button>
<el-radio-button :key="item.nodeId" v-for="item in timeNodeList" :label="item.nodeId">{{item.timeNodeContent}}</el-radio-button>
</el-radio-group>
<div class="followup-contents">
<div class="content-div">
......@@ -80,7 +80,7 @@
</div>
<div class="content-div">
<div class="c-title">推送患教:</div>
<div class="c-content more-content">
<div class="c-content more-content" v-for="item in nodeContent.pushContentList">
<p>{{item.startDaysStr}} <span class="click-text" >{{item.sendContent}}</span></p>
<p class="reminding">推送规则:优先微信推送,如果居民没关注云鹊医公众号,将短信推送,短信推送会消耗您的额度。推送详情请前往云鹊医app患教中心查询</p>
</div>
......@@ -88,14 +88,14 @@
<div class="content-div">
<div class="c-title">随访登记表:</div>
<div class="c-content more-content">
<p v-for="item in nodeContent.followupList">{{item.sendContent}}</p>
<p class="click-text" v-for="item in nodeContent.followupList">{{item.sendContent}}</p>
</div>
</div>
</div>
</div>-->
</div>
</div>
<change-plan :showThisPage="showChangePlan" @closeChangePlan="closeChangePlan"></change-plan>
<finish-followup :showThisPage="showFinishFollowup" @closeFinishFollowup="closeFinishFollowup"></finish-followup>
<change-plan :showThisPage="showChangePlan" :planChangeData="planChangeData" @closeChangePlan="closeChangePlan"></change-plan>
<finish-followup :showThisPage="showFinishFollowup" :finishData="finishData" @closeFinishFollowup="closeFinishFollowup"></finish-followup>
</div>
</template>
......@@ -124,33 +124,48 @@
/*面包屑配置*/
timeNodes: 0,//时间节点
showChangePlan: false,//是否展示变更计划
showFinishFollowup: false, //是否展示结束随访
showFinishFollowup: false, //是否展示结束随访,
planChangeData: {}, //变更信息
finishData: {}, //结束信息
}
},
created() {
},
computed: {
...mapState('planManage', {
residentDetail: state => state.residentDetail,
nodeContent: state => state.nodeContent,
timeNodeList: state => state.timeNodeList,
nodeContent: state => state.nodeContent,
groupList: state => state.groupList
})
},
mounted() {
this.getResidentDetail({
patientId: this.$route.query.patientId,
planId: this.$route.query.planId
}); //获取居民详情
this.getGroupList(); //获取分组列表
},
computed: {
...mapState('planManage', {
residentDetail: state => state.residentDetail,
nodeContent: state => state.nodeContent
})
},
methods: {
...mapActions('planManage', ['getResidentDetail']),
...mapActions('planManage', ['getResidentDetail', 'getNodeTimeContent', 'getGroupList']),
changePlan() {
this.planChangeData = {
group: this.residentDetail.fPlanPatientDatilDtoList.labelIds,
planId: this.residentDetail.fPlanPatientDatilDtoList.planId,
startTime: this.residentDetail.fPlanPatientDatilDtoList.time
}
this.showChangePlan = true;
},
closeChangePlan(isShow) {
this.showChangePlan = isShow
},
finishFollowup() {
this.finishData = {
patientName: this.residentDetail.fPlanPatientDatilDtoList.nickName,
}
this.showFinishFollowup = true;
},
closeFinishFollowup(isShow) {
......@@ -158,8 +173,9 @@
},
},
watch: {
planDetail(val) {
this.timeNodes = val.fPlanTimeDtoList[0].id
timeNodeList(val) {
console.log('val1',val)
this.timeNodes = val[0].nodeId
},
timeNodes(val) {
this.getNodeTimeContent(val)
......
......@@ -90,8 +90,8 @@
label="操作"
align="center">
<template slot-scope="scope">
<el-button class="btn-right-class" type="text" @click="changePlan" >变更计划</el-button>|
<el-button class="btn-right-class" type="text" @click="finishFollowup" >结束随访</el-button>
<el-button class="btn-right-class" type="text" @click="changePlan(scope.row)" >变更计划</el-button>|
<el-button class="btn-right-class" type="text" @click="finishFollowup(scope.row)" >结束随访</el-button>
</template>
</el-table-column>
</el-table>
......@@ -110,8 +110,8 @@
</div>
</div>
</div>
<change-plan :showThisPage="showChangePlan" :groupOption="groupList" @closeChangePlan="closeChangePlan"></change-plan>
<finish-followup :showThisPage="showFinishFollowup" @closeFinishFollowup="closeFinishFollowup"></finish-followup>
<change-plan :showThisPage="showChangePlan" :planChangeData="planChangeData" @closeChangePlan="closeChangePlan"></change-plan>
<finish-followup :showThisPage="showFinishFollowup" :finishData="finishData" @closeFinishFollowup="closeFinishFollowup"></finish-followup>
</div>
</template>
......@@ -138,7 +138,7 @@
curmbThird: '查看居民',
jumPathThird: '/followUp/plan-manage',
/*面包屑配置*/
labelWidth: '96px', //标题长度
labelWidth: '110px', //标题长度
searchData: {}, //查询数据
groupOption: [{ // 分组选项
value: '全部',
......@@ -146,7 +146,9 @@
}],
status: 0, //列表筛选条件
showChangePlan: false,//是否展示变更计划
planChangeData: {}, //变更计划数据
showFinishFollowup: false, //是否展示结束随访
finishData: {}, //结束数据
}
},
created() {
......@@ -196,13 +198,21 @@
resetSearchData(formName) {
this.$refs[formName].resetFields();
},
changePlan() {
changePlan(row) {
this.planChangeData = {
group: row.labelIds,
planId: 1,
startTime: row.time
}
this.showChangePlan = true;
},
closeChangePlan(isShow) {
this.showChangePlan = isShow
},
finishFollowup() {
finishFollowup(row) {
this.finishData = {
patientName: row.patientName,
};
this.showFinishFollowup = true;
},
closeFinishFollowup(isShow) {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册