|  | @ -17,9 +17,11 @@ import com.yihu.jw.entity.base.area.BaseProvinceDO;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.base.area.BaseTownDO;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.base.doctor.BaseDoctorDO;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.base.im.ConsultDo;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.hospital.consult.WlyyHospitalSysDictDO;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.hospital.message.SystemMessageDO;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.hospital.prescription.*;
 | 
	
		
			
				|  |  | import com.yihu.jw.entity.order.BusinessOrderDO;
 | 
	
		
			
				|  |  | import com.yihu.jw.hospital.dict.WlyyHospitalSysDictDao;
 | 
	
		
			
				|  |  | import com.yihu.jw.hospital.httplog.service.BaseOperateLogService;
 | 
	
		
			
				|  |  | import com.yihu.jw.hospital.mapping.service.PatientMappingService;
 | 
	
		
			
				|  |  | import com.yihu.jw.hospital.prescription.dao.OutpatientDao;
 | 
	
	
		
			
				|  | @ -136,6 +138,8 @@ public class PrescriptionEndpoint extends EnvelopRestEndpoint {
 | 
	
		
			
				|  |  |     private BaseOperateLogService baseOperateLogService;
 | 
	
		
			
				|  |  |     @Autowired
 | 
	
		
			
				|  |  |     private TasyNatService tasyNatService;
 | 
	
		
			
				|  |  |     @Autowired
 | 
	
		
			
				|  |  |     private WlyyHospitalSysDictDao wlyyHospitalSysDictDao;
 | 
	
		
			
				|  |  |     @Value("${qywx.id}")
 | 
	
		
			
				|  |  |     private String qywxId;
 | 
	
		
			
				|  |  | 
 | 
	
	
		
			
				|  | @ -2888,17 +2892,27 @@ public class PrescriptionEndpoint extends EnvelopRestEndpoint {
 | 
	
		
			
				|  |  |         }else if ("xm_tasy_wx".equalsIgnoreCase(wxId)){
 | 
	
		
			
				|  |  |             String res=tasyNatService.departMent(deptCode);
 | 
	
		
			
				|  |  |             String dept="";
 | 
	
		
			
				|  |  |             WlyyHospitalSysDictDO wlyyHospitalSysDictDO = wlyyHospitalSysDictDao.findById("tasyNatDept");
 | 
	
		
			
				|  |  |             if (wlyyHospitalSysDictDO!=null){
 | 
	
		
			
				|  |  |                 dept=wlyyHospitalSysDictDO.getDictValue();
 | 
	
		
			
				|  |  |             }
 | 
	
		
			
				|  |  |             JSONObject deptres = JSON.parseObject(res);
 | 
	
		
			
				|  |  |             if (deptres!=null){
 | 
	
		
			
				|  |  |                 if (deptres.getString("success").equalsIgnoreCase("true")){
 | 
	
		
			
				|  |  |                     JSONObject data = JSON.parseObject(deptres.getString("data"));
 | 
	
		
			
				|  |  |                     dept=data.getString("Dept");
 | 
	
		
			
				|  |  |                     JSONArray jsonArray1 = JSON.parseArray(dept);
 | 
	
		
			
				|  |  |                     /*JSONObject data = JSON.parseObject(deptres.getString("data"));
 | 
	
		
			
				|  |  |                     String depts=data.getString("Dept");
 | 
	
		
			
				|  |  |                     JSONArray jsonArray1 = JSON.parseArray(depts);
 | 
	
		
			
				|  |  |                     if (jsonArray1!=null&&jsonArray1.size()>0){
 | 
	
		
			
				|  |  |                         JSONObject jsonObject = jsonArray1.getJSONObject(0);
 | 
	
		
			
				|  |  |                         dept=jsonObject.getString("Id");
 | 
	
		
			
				|  |  |                         System.out.println(dept);
 | 
	
		
			
				|  |  |                     }
 | 
	
		
			
				|  |  |                         for (int i=0;i<jsonArray1.size();i++){
 | 
	
		
			
				|  |  |                             JSONObject jsonObject = jsonArray1.getJSONObject(i);
 | 
	
		
			
				|  |  |                             if (dept.equalsIgnoreCase(jsonObject.getString("Id"))){
 | 
	
		
			
				|  |  |                                 dept=jsonObject.getString("Id");
 | 
	
		
			
				|  |  |                                 System.out.println(dept);
 | 
	
		
			
				|  |  |                                 break;
 | 
	
		
			
				|  |  |                             }
 | 
	
		
			
				|  |  |                         }
 | 
	
		
			
				|  |  | 
 | 
	
		
			
				|  |  |                     }*/
 | 
	
		
			
				|  |  |                     String json=tasyNatService.GetDoctorWorkDate("3",dept);
 | 
	
		
			
				|  |  |                     JSONObject jsonObject = JSON.parseObject(json);
 | 
	
		
			
				|  |  |                     jsonObject.put("dept",dept);
 |