new Vue({
  el: '#app',
  data: {
   	symptoms:[
   		{key:"NO_SYMPTOM",name:'无症状',value:''},
   		{key:"HEADACHE",name:'头痛头晕',value:''},
   		{key:"NAUSEA",name:'恶心呕吐',value:''},
   		{key:"VERTIGO_TINNITUS",name:'眼花耳鸣',value:''},
   		{key:"DIFFICULTY_BREATHING",name:'呼吸困难',value:''},
   		{key:"PALPITATIONS",name:'心悸胸闷',value:''},
   		{key:"EPISTAXIS_BLEEDING",name:'鼻衄出血不止',value:''},
   		{key:"LIMBS_NUMB",name:'四肢发麻',value:''},
   		{key:"EXTREMITY_EDEMA",name:'下肢水肿',value:''},
   		{key:"POLYDIPSIA",name:'多饮',value:''},
   		{key:"MORE_FOOD",name:'多食',value:''},
   		{key:"MORE_URINE",name:'多尿',value:''},
   		{key:"BLURRED_VISION",name:'视力模糊',value:''},
   		{key:"INFECTION",name:'感染',value:''},
			{key:"NUMB_HANDS",name:'四肢麻痹',value:''},
			{key:"WEIGHT_LOSS",name:'体重下降',value:''}
   	],//症状
    hypoglycemia:"",//低血糖反应
    remark: "",//其他
    readonly:true
  },
  mounted: function() {
  	var vm = this
  	var Request = GetRequest();
  	recordAPI.getFollowupProjectData({id:Request["id"],followupProject:1}).then(function(res){
			if(res.status==200){
				var data = res.data;
				delete data["create_time"];delete data["followup_id"];delete data["followup_project"];delete data["id"];
				var allData = vm.symptoms;
				for(var key in data){
					if(key == "HYPOG_REACT_CODE"){
						vm.hypoglycemia = data[key]
					}else if(key == "SYMPTOM_OTHER"){
						vm.remark = data[key]
					}else{
						for(var j=0;j<allData.length;j++){
							if(allData[j].key == key){
								allData[j].value = data[key]
								break;
							}
						}
					}
				}
			}
		})
  }
})