| 
															
																@ -1,5 +1,6 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																package com.yihu.wlyy.service.app.record; 
															 | 
															
															 | 
															
																package com.yihu.wlyy.service.app.record; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import com.fasterxml.jackson.databind.ObjectMapper; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import com.yihu.wlyy.service.BaseService; 
															 | 
															
															 | 
															
																import com.yihu.wlyy.service.BaseService; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import com.yihu.wlyy.util.HttpClientUtil; 
															 | 
															
															 | 
															
																import com.yihu.wlyy.util.HttpClientUtil; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import com.yihu.wlyy.util.SystemConf; 
															 | 
															
															 | 
															
																import com.yihu.wlyy.util.SystemConf; 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -8,10 +9,13 @@ import org.apache.commons.lang3.StringUtils; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.apache.http.NameValuePair; 
															 | 
															
															 | 
															
																import org.apache.http.NameValuePair; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.apache.http.message.BasicNameValuePair; 
															 | 
															
															 | 
															
																import org.apache.http.message.BasicNameValuePair; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.json.JSONObject; 
															 | 
															
															 | 
															
																import org.json.JSONObject; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import org.springframework.beans.factory.annotation.Autowired; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.stereotype.Service; 
															 | 
															
															 | 
															
																import org.springframework.stereotype.Service; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import java.util.ArrayList; 
															 | 
															
															 | 
															
																import java.util.ArrayList; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import java.util.HashMap; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import java.util.List; 
															 | 
															
															 | 
															
																import java.util.List; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import java.util.Map; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																/** 
															 | 
															
															 | 
															
																/** 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 * Created by zhenglingfeng on 2016/10/17. 
															 | 
															
															 | 
															
																 * Created by zhenglingfeng on 2016/10/17. 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -19,10 +23,13 @@ import java.util.List; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																@Service 
															 | 
															
															 | 
															
																@Service 
															 | 
														
													
												
													
														
															| 
															 | 
															
																public class HealthDataService extends BaseService { 
															 | 
															
															 | 
															
																public class HealthDataService extends BaseService { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    @Autowired 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    private ObjectMapper objectMapper; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    /** 
															 | 
															
															 | 
															
																    /** 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     * 获取健康档案信息 
															 | 
															
															 | 
															
																     * 获取健康档案信息 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     */ 
															 | 
															
															 | 
															
																     */ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    public JSONObject getHealthData(String strSSID, String strEvent, String strCatalog, String strSerial) throws Exception { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    public Map getHealthData(String strSSID, String strEvent, String strCatalog, String strSerial) throws Exception { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        String url = SystemConf.getInstance().getSystemProperties().getProperty("sign_check_upload"); 
															 | 
															
															 | 
															
																        String url = SystemConf.getInstance().getSystemProperties().getProperty("sign_check_upload"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        url = url + "/third/smjk/HealthData"; 
															 | 
															
															 | 
															
																        url = url + "/third/smjk/HealthData"; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -33,8 +40,7 @@ public class HealthDataService extends BaseService { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        params.add(new BasicNameValuePair("strSerial", strSerial)); 
															 | 
															
															 | 
															
																        params.add(new BasicNameValuePair("strSerial", strSerial)); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        String response = HttpClientUtil.post(url, params, "UTF-8"); 
															 | 
															
															 | 
															
																        String response = HttpClientUtil.post(url, params, "UTF-8"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        JSONObject result = new JSONObject(); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																        Map result = new HashMap<>(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        if (!StringUtils.isEmpty(response)){ 
															 | 
															
															 | 
															
																        if (!StringUtils.isEmpty(response)){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            JSONObject jsonObject = new JSONObject(response); 
															 | 
															
															 | 
															
																            JSONObject jsonObject = new JSONObject(response); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            int status = jsonObject.getInt("status"); 
															 | 
															
															 | 
															
																            int status = jsonObject.getInt("status"); 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -42,7 +48,7 @@ public class HealthDataService extends BaseService { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                String xmlData = jsonObject.getString("data"); 
															 | 
															
															 | 
															
																                String xmlData = jsonObject.getString("data"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                if (!StringUtils.isEmpty(xmlData)){ 
															 | 
															
															 | 
															
																                if (!StringUtils.isEmpty(xmlData)){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    String xmlJson = XMLUtil.xml2json(xmlData); 
															 | 
															
															 | 
															
																                    String xmlJson = XMLUtil.xml2json(xmlData); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    result = new JSONObject(xmlJson); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                    result = objectMapper.readValue(xmlJson, Map.class); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                } 
															 | 
															
															 | 
															
																                } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            } 
															 | 
															
															 | 
															
																            } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        } 
															 | 
															
															 | 
															
																        } 
															 |