提交 6d25fae7 编写于 作者: tao.wu's avatar tao.wu

Merge branch 'dev-followUp-20190312' of...

Merge branch 'dev-followUp-20190312' of 192.168.110.53:com.pica.cloud.education.frontend/pica.cloud.web-education-admin into dev-followUp-20190312
......@@ -152,16 +152,17 @@
},
watch: {
planChangeData(val) {
const _this = this
let labelList = val.yLabelList
labelList.forEach(function (item, index) {
let nodeItem = this.groupList.filter(function(item1){
let nodeItem = _this.groupList.filter(function(item1){
return item1.labelId == item;
});
let pushItem = {
labelId: nodeItem[0].labelId,
label: nodeItem[0].labelName,
}
this.selectedGroup.push(pushItem)
_this.selectedGroup.push(pushItem)
})
}
}
......
<template>
<div class="finish-followup" v-if="showThisPage">
<el-dialog
title="结束随访"
:title="finishData.title"
:visible.sync="showFinishFollowup"
v-if="showThisPage"
:before-close="clickClose"
......@@ -15,7 +15,7 @@
<el-form-item label="居民:">
{{finishData.patientName}}
</el-form-item>
<el-form-item label="结束原因:" prop="finishReason">
<el-form-item :label="finishData.reasonName" prop="finishReason">
<el-input
type="textarea"
v-model="finishData.finishReason"
......@@ -60,7 +60,7 @@
{ required: true, message: '请输入结束原因', trigger: 'blur' },
{ min: 1, max: 30, message: '长度在30个字符内', trigger: 'blur' }
],
}
},
}
},
methods: {
......
......@@ -11,8 +11,8 @@
<div class="title"><p>基本信息</p></div>
<div class="h-btn">
<el-button class="button-white" plain size="small" @click="changePlan">计划变更</el-button>
<el-button v-if="status==1" class="button-white" plain size="small" @click="finishFollowup">结束随访</el-button>
<el-button v-if="status==2" class="button-white" plain size="small" @click="finishFollowup">恢复随访</el-button>
<el-button v-if="status==3" class="button-white" plain size="small" @click="finishFollowup">恢复随访</el-button>
<el-button v-else class="button-white" plain size="small" @click="finishFollowup">结束随访</el-button>
</div>
</div>
<div class="base-info">
......@@ -177,6 +177,8 @@
planId: this.residentDetail.fPlanDto.id,
patientName: this.residentDetail.patientName,
patientIdList: patientIdList,
title: this.status==3?'恢复随访':'结束随访',
reasonName: this.status==3?'恢复原因:':'结束原因:'
}
this.showFinishFollowup = true;
},
......
......@@ -51,7 +51,7 @@
<el-radio-button label="3">已结束({{residentList.yesCount}})</el-radio-button>
</el-radio-group>
<div class="btn-left">
<el-button class="button-green" type="primary" size="small" v-if="status==2" @click="recoverFollowup('all')">恢复随访</el-button>
<el-button class="button-green" type="primary" size="small" v-if="status==3" @click="finishFollowup('all')">恢复随访</el-button>
<el-button class="button-green" type="primary" size="small" v-else @click="finishFollowup('all')">结束随访</el-button>
<el-button class="button-white" plain size="small" @click="selectPatientHandler">添加居民</el-button>
</div>
......@@ -101,7 +101,7 @@
align="center">
<template slot-scope="scope">
<el-button class="btn-right-class" type="text" @click="changePlan(scope.row)" >变更计划</el-button>|
<el-button class="btn-right-class" type="text" v-if="status==2" @click="recoverFollowup(scope.row)" >恢复随访</el-button>
<el-button class="btn-right-class" type="text" v-if="status==3" @click="finishFollowup(scope.row)" >恢复随访</el-button>
<el-button class="btn-right-class" type="text" v-else @click="finishFollowup(scope.row)" >结束随访</el-button>
</template>
</el-table-column>
......@@ -123,7 +123,6 @@
</div>
<change-plan :showThisPage="showChangePlan" :planChangeData="planChangeData" @closeChangePlan="closeChangePlan"></change-plan>
<finish-followup :showThisPage="showFinishFollowup" :finishData="finishData" @closeFinishFollowup="closeFinishFollowup"></finish-followup>
<recover-followup :showThisPage="showRecoverFollowup" :finishData="recoverData" @closeFinishFollowup="closeRecoverFollowup"></recover-followup>
<select-patient
:isShowSelectPatient="isShowSelectPatient"
:patientIdList="initialPatientIdList"
......@@ -143,8 +142,6 @@
import ChangePlan from '@/views/followup/plan-manage/dialog/change-plan';
//结束随访dialog
import FinishFollowup from '@/views/followup/plan-manage/dialog/finish-followup';
//恢复随访dialog
import RecoverFollowup from '@/views/followup/plan-manage/dialog/finish-followup';
//添加居民
import SelectPatient from '@/views/followup/plan-manage/dialog/select-patient';
//添加居民选择随访时间
......@@ -158,7 +155,6 @@
ChangePlan,
FinishFollowup,
SelectPatient,
RecoverFollowup,
addPatientTime
},
data() {
......@@ -180,8 +176,6 @@
planChangeData: {}, //变更计划数据
showFinishFollowup: false, //是否展示结束随访
finishData: {}, //结束数据
showRecoverFollowup: false, //是否展示恢复随访
recoverData: {}, //恢复数据
isShowSelectPatient: false, //显示居民选择框
hasSelectedList: [], //已选居民
finishPatientList: [], //结束随访居民(多选)
......@@ -242,9 +236,11 @@
},
changePlan(row) {
this.planChangeData = {
group: row.labelIds,
planId: 1,
startTime: row.time
planPatientsId: row.fuPlanPatientId,
planId: this.$route.query.planId,
patientId: row.patientId,
yLabelList: row.labelIdList||[],
startDate: row.time
}
this.showChangePlan = true;
},
......@@ -260,48 +256,38 @@
});
return;
}
let patientIds = [];
let patientNames = [];
this.finishPatientList.forEach(function (item, index) {
patientIds.push(item.patientId)
patientNames.push(item.patientName)
});
console.log(patientIds)
this.finishData = {
patientName: row.patientName,
changeCode: this.status,
planId: this.$route.query.planId,
patientName: patientNames.join('、'),
patientIdList: patientIds,
title: this.status==3?'恢复随访':'结束随访',
reasonName: this.status==3?'恢复原因:':'结束原因:'
};
} else {
let patientIdList = [];
patientIdList.push(row.patientId)
let patientIds = [];
patientIds.push(row.patientId)
this.finishData = {
changeCode: this.status,
planId: this.$route.query.planId,
patientName: row.patientName,
changeCode: row.status,
patientIdList: patientIdList,
patientName: row.patientName,
patientIdList: patientIds,
title: this.status==3?'恢复随访':'结束随访',
reasonName: this.status==3?'恢复原因:':'结束原因:'
};
}
this.showFinishFollowup = true;
},
closeFinishFollowup(isShow) {
this.showFinishFollowup = isShow
},
recoverFollowup(row) {
if(row=='all') {
if(this.finishPatientList.length<=0) {
this.$message({
message: '请选择居民!',
type: 'warning'
});
return;
}
this.finishData = {
patientName: row.patientName,
};
} else {
this.finishData = {
patientName: row.patientName,
};
}
this.showFinishFollowup = true;
},
closeRecoverFollowup(isShow) {
this.showRecoverFollowup = isShow
},
selectPatientHandler() {
this.isShowSelectPatient = true;
},
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册