|  | @ -1,39 +1,26 @@
 | 
	
		
			
				|  |  | package com.yihu.wlyy.service.app.prescription;
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  | import com.fasterxml.jackson.databind.ObjectMapper;
 | 
	
		
			
				|  |  | import com.fasterxml.jackson.databind.node.ObjectNode;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.entity.patient.prescription.Prescription;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.entity.patient.prescription.PrescriptionDispensaryCode;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.entity.patient.prescription.PrescriptionInfo;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.entity.patient.prescription.PrescriptionLog;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.repository.message.MessageDao;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.repository.prescription.PrescriptionDao;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.repository.prescription.PrescriptionDispensaryCodeDao;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.repository.prescription.PrescriptionInfoDao;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.service.BaseService;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.service.common.QrcodeService;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.util.HttpUtil;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.util.QrcodeUtil;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.util.SystemConf;
 | 
	
		
			
				|  |  | import com.yihu.wlyy.util.fastdfs.FastDFSUtil;
 | 
	
		
			
				|  |  | import org.apache.axis.encoding.*;
 | 
	
		
			
				|  |  | import org.apache.axis.encoding.Base64;
 | 
	
		
			
				|  |  | import org.apache.commons.lang3.StringUtils;
 | 
	
		
			
				|  |  | import org.json.JSONArray;
 | 
	
		
			
				|  |  | import org.json.JSONObject;
 | 
	
		
			
				|  |  | import org.springframework.beans.factory.annotation.Autowired;
 | 
	
		
			
				|  |  | import org.springframework.beans.factory.annotation.Value;
 | 
	
		
			
				|  |  | import org.springframework.data.domain.Page;
 | 
	
		
			
				|  |  | import org.springframework.data.domain.PageRequest;
 | 
	
		
			
				|  |  | import org.springframework.data.domain.Sort;
 | 
	
		
			
				|  |  | import org.springframework.jdbc.core.JdbcTemplate;
 | 
	
		
			
				|  |  | import org.springframework.stereotype.Service;
 | 
	
		
			
				|  |  | import org.springframework.transaction.annotation.Transactional;
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  | import java.io.*;
 | 
	
		
			
				|  |  | import java.net.HttpURLConnection;
 | 
	
		
			
				|  |  | import java.net.MalformedURLException;
 | 
	
		
			
				|  |  | import java.net.URL;
 | 
	
		
			
				|  |  | import java.net.URLEncoder;
 | 
	
		
			
				|  |  | import java.io.InputStream;
 | 
	
		
			
				|  |  | import java.util.*;
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  | /**
 | 
	
	
		
			
				|  | @ -55,6 +42,8 @@ public class PrescriptionDispensaryCodeService extends BaseService {
 | 
	
		
			
				|  |  |     private HttpUtil httpUtil;
 | 
	
		
			
				|  |  |     @Autowired
 | 
	
		
			
				|  |  |     private PrescriptionDao prescriptionDao;
 | 
	
		
			
				|  |  |     @Autowired
 | 
	
		
			
				|  |  |     private MessageDao messageDao;
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  |     private static Object obj = new Object();
 | 
	
		
			
				|  |  |     private static Object obj2 = new Object();
 | 
	
	
		
			
				|  | @ -251,6 +240,13 @@ public class PrescriptionDispensaryCodeService extends BaseService {
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  |             prescriptionDispensaryCode.setIsUse(1);
 | 
	
		
			
				|  |  |             prescriptionDispensaryCodeDao.save(prescriptionDispensaryCode);
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  |             Prescription prescription = prescriptionDao.findByCode(prescriptionDispensaryCode.getPrescriptionCode());
 | 
	
		
			
				|  |  |             if(prescription.getDispensaryType()==3){
 | 
	
		
			
				|  |  |                 //健管师配送
 | 
	
		
			
				|  |  |                 //修改系统的续方消息的审核状态
 | 
	
		
			
				|  |  |                 messageDao.updatePreScriptionMessage(prescription.getCode(), "1", 7);
 | 
	
		
			
				|  |  |             }
 | 
	
		
			
				|  |  |         }else{
 | 
	
		
			
				|  |  |             throw new Exception("二维码输入错误或者已过期!");
 | 
	
		
			
				|  |  |         }
 |