yht2016 5 years ago
parent
commit
d35ecfee55

+ 3 - 3
api/followup_api.js

@ -7,15 +7,15 @@
         * @desc 获取居民各详细信息
         */
        getPatientInfo(data) {
            return httpRequest.post('/doctor/patient_label_info/patient',{data:data})
            return httpRequest.post('doctor/patient_label_info/patient',{data:data})
        },
        //获得随访医生的列表
        sign_doctors(data){
            return httpRequest.get('/doctor/patient_group/sign_doctors',{data:data})
            return httpRequest.get('doctor/patient_group/sign_doctors',{data:data})
        },
        //保存随访
        addFollowupPlan(data){
            return httpRequest.post('/doctor/followup/addFollowupPlan',{data:data})
            return httpRequest.post('doctor/followup/addFollowupPlan',{data:data})
        }, 
	}
    exports.followUpAPI = followUpAPI;

+ 37 - 4
app/rehabilitation/html/addRecoveryDown.html

@ -94,6 +94,7 @@
        <script src="../../../js/util.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../../api/http-request.js" type="text/javascript"></script>
		<script type="text/javascript" src="../../../api/rehabilitation-api.js"></script>
		<script type="text/javascript" src="../../../api/sign_api.js"></script>
		<script type="text/javascript">
			var doctorType = (JSON.parse(window.localStorage.getItem('wlyyAgent'))||{}).doctorType
			var httpData=GetRequest()
@ -123,7 +124,9 @@
					icon: 6
				})
			}
			
			function signSpecialist(flag, signSpecialist){
				console.log('signSpecialist', flag, signSpecialist)
			}
			top.addRecoveryDownVue = new Vue({
                el: "#app",
                data: {
@ -158,11 +161,11 @@
					}
				},
                methods: {
					isSignSpecialist: function(is_sign, idcard){
					signSpecialist: function(is_sign, patientCode){
						if(is_sign){ // 已家签
							if(idcard){ // 已签约专科
							if(patientCode){ // 已签约专科
								this.is_sign_specialist = true
								this.getRehabilitationPatientList(idcard)
								this.getPatient(patientCode)
							}
						} else {
							this.patientInfo = undefined
@ -198,6 +201,7 @@
						}
						this.getRehabilitationPatientList(this.searchKey)
					},
					// 根据身份证号码获取家签居民
					getRehabilitationPatientList: function(value){
						var vm = this,
							loading = layer.load(0, {shade: false})
@ -221,6 +225,35 @@
							}
						})
					},
					// 根据居民code 查找居民
					getPatient: function(patient){
						var vm = this
						var params = {
							patient: patient
						}
						signAPI.getPatient(params).then(function(res){
							if(res.status==200){
								if(res.data){
									var result = res.data
									vm.patientInfo = {}
									vm.patientInfo['patient'] = result.code
									vm.patientInfo['patientName'] = result.name
									vm.patientInfo['sex'] = result.sex
									vm.patientInfo['age'] = result.age
									vm.patientInfo['hospitalName'] = result.jtHospitalName
									vm.patientInfo['doctorName'] = result.jtDoctorName
									vm.patientInfo['doctorHealthName'] = result.jtDoctorHealthName
									vm.$forceUpdate()
									vm.getPatientLabelInfo()
									// 获取签约专科信息
									vm.findPatientTeamList()
								}
								console.log('res', res)
							} else {
								showErrorMessage('获取居民信息失败!')
							}
						})
					},
					getSpecialistTeamList: function(){
						var vm = this,
							loading = layer.load(0, {shade: false})

+ 5 - 4
app/rehabilitation/html/signZkTeam.html

@ -160,12 +160,13 @@
							if(res.status == 200) {
								var num=0;
								$.each(res.data, function(index,item){
									if(item.teamCode==vm.teamInfo.id){  //签约团队与二维码团队一致
									if(item.teamCode==vm.id){  //签约团队与二维码团队一致
										num++
									}
								})
								if(num>0){//签约团队与二维码团队一致
									top.addRecoveryDownVue.isSignSpecialist(true, data.idcard)
									console.log('data', data)
									top.addRecoveryDownVue.signSpecialist(true, data.patient_code)
								} else {
									vm.createPatientInSpeciaRelation(data)
								}
@ -186,9 +187,9 @@
						}
						rehaAPI.createPatientInSpeciaRelation(params).then(function(res){
							if(res.data&&res.data.status == 200) {
								top.addRecoveryDownVue.isSignSpecialist(true, data.idcard)
								top.addRecoveryDownVue.signSpecialist(true, data.patient_code)
							} else {
								top.addRecoveryDownVue.isSignSpecialist(false)
								top.addRecoveryDownVue.signSpecialist(false)
								showErrorMessage(res.msg);
							}
						})