|  | @ -1360,7 +1360,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |         if (businessOrderDO==null){
 |  |         if (businessOrderDO==null){
 | 
												
													
														
															|  |             throw new Exception("查不到订单!");
 |  |             throw new Exception("查不到订单!");
 | 
												
													
														
															|  |         }
 |  |         }
 | 
												
													
														
															|  |         if (businessOrderDO.getOrderCategory().equalsIgnoreCase("1")){
 |  | 
 | 
												
													
														
															|  | 
 |  |         if (businessOrderDO.getOrderCategory().equalsIgnoreCase("1")&&businessOrderDO.getStatus()==0){
 | 
												
													
														
															|  |             if ("0".equalsIgnoreCase(changeflag)){
 |  |             if ("0".equalsIgnoreCase(changeflag)){
 | 
												
													
														
															|  |                 ConsultDo consultDo = consultOrderDao.findOne(businessOrderDO.getRelationCode());
 |  |                 ConsultDo consultDo = consultOrderDao.findOne(businessOrderDO.getRelationCode());
 | 
												
													
														
															|  |                 consultDo.setPayStatus(1);
 |  |                 consultDo.setPayStatus(1);
 | 
												
											
												
													
														
															|  | @ -1396,7 +1396,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |                     }
 |  |                     }
 | 
												
													
														
															|  |                 }
 |  |                 }
 | 
												
													
														
															|  |                 if (wechatId.equalsIgnoreCase("xm_zsyy_wx")){
 |  |                 if (wechatId.equalsIgnoreCase("xm_zsyy_wx")){
 | 
												
													
														
															|  |                     String url="https://hlwyy.xmzsh.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  | 
 | 
												
													
														
															|  | 
 |  |                     String url=baseUrl+"/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
													
														
															|  |                     enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 |  |                     enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 | 
												
													
														
															|  |                 }else if(wechatId.equalsIgnoreCase("xm_ykyy_wx")){
 |  |                 }else if(wechatId.equalsIgnoreCase("xm_ykyy_wx")){
 | 
												
													
														
															|  |                     String url=baseUrl+"/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  |                     String url=baseUrl+"/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
											
												
													
														
															|  | @ -1405,7 +1405,6 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |                     String url="https://ih.xmheart.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  |                     String url="https://ih.xmheart.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
													
														
															|  |                     enterpriseService.sendTWMesByDoctor("xm_xzzx_wx",outpatientDO.getDoctor(),title,msg,url);
 |  |                     enterpriseService.sendTWMesByDoctor("xm_xzzx_wx",outpatientDO.getDoctor(),title,msg,url);
 | 
												
													
														
															|  |                 }
 |  |                 }
 | 
												
													
														
															|  | 
 |  | 
 | 
												
													
														
															|  |                 System.out.println("发送企业模板消息成功");
 |  |                 System.out.println("发送企业模板消息成功");
 | 
												
													
														
															|  |                 try {
 |  |                 try {
 | 
												
													
														
															|  |                     if ("xm_zsyy_wx".equalsIgnoreCase(wechatId)){
 |  |                     if ("xm_zsyy_wx".equalsIgnoreCase(wechatId)){
 | 
												
											
												
													
														
															|  | @ -1428,7 +1427,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |            }catch (Exception e){
 |  |            }catch (Exception e){
 | 
												
													
														
															|  |                e.printStackTrace();
 |  |                e.printStackTrace();
 | 
												
													
														
															|  |            }
 |  |            }
 | 
												
													
														
															|  |            if (businessOrderDO.getStatus()!=null&&businessOrderDO.getStatus()!=1){
 |  | 
 | 
												
													
														
															|  | 
 |  |            if (businessOrderDO.getStatus()!=null&&businessOrderDO.getStatus()==0){
 | 
												
													
														
															|  |                //发送企业模板消息给医生
 |  |                //发送企业模板消息给医生
 | 
												
													
														
															|  |                BasePatientDO patientDO = new BasePatientDO();
 |  |                BasePatientDO patientDO = new BasePatientDO();
 | 
												
													
														
															|  |                patientDO = patientDao.findById(outpatientDO.getPatient());
 |  |                patientDO = patientDao.findById(outpatientDO.getPatient());
 | 
												
											
												
													
														
															|  | @ -1456,7 +1455,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |                    }
 |  |                    }
 | 
												
													
														
															|  |                }
 |  |                }
 | 
												
													
														
															|  |                if (wechatId.equalsIgnoreCase("xm_zsyy_wx")){
 |  |                if (wechatId.equalsIgnoreCase("xm_zsyy_wx")){
 | 
												
													
														
															|  |                        String url="https://hlwyy.xmzsh.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  | 
 | 
												
													
														
															|  | 
 |  |                    String url=baseUrl+"/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
													
														
															|  |                    enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 |  |                    enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 | 
												
													
														
															|  |                }else if (wechatId.equalsIgnoreCase("xm_ykyy_wx")){
 |  |                }else if (wechatId.equalsIgnoreCase("xm_ykyy_wx")){
 | 
												
													
														
															|  |                    String url=baseUrl+"/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  |                    String url=baseUrl+"/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
											
												
													
														
															|  | @ -1516,7 +1515,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |                 WlyyOutpatientDO wlyyOutpatientDO = outpatientDao.findById(businessOrderDO.getRelationCode());
 |  |                 WlyyOutpatientDO wlyyOutpatientDO = outpatientDao.findById(businessOrderDO.getRelationCode());
 | 
												
													
														
															|  |                 wlyyOutpatientDO.setPayStatus(1);
 |  |                 wlyyOutpatientDO.setPayStatus(1);
 | 
												
													
														
															|  |                 WlyyOutpatientDO outpatientDO = outpatientDao.save(wlyyOutpatientDO);
 |  |                 WlyyOutpatientDO outpatientDO = outpatientDao.save(wlyyOutpatientDO);
 | 
												
													
														
															|  |                 if (businessOrderDO.getStatus()!=null&&businessOrderDO.getStatus()!=1){
 |  | 
 | 
												
													
														
															|  | 
 |  |                 if (businessOrderDO.getStatus()!=null&&businessOrderDO.getStatus()==0){
 | 
												
													
														
															|  |                     //发送企业模板消息给医生
 |  |                     //发送企业模板消息给医生
 | 
												
													
														
															|  |                     BasePatientDO patientDO = new BasePatientDO();
 |  |                     BasePatientDO patientDO = new BasePatientDO();
 | 
												
													
														
															|  |                     patientDO = patientDao.findById(outpatientDO.getPatient());
 |  |                     patientDO = patientDao.findById(outpatientDO.getPatient());
 | 
												
											
												
													
														
															|  | @ -1541,7 +1540,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |                         }
 |  |                         }
 | 
												
													
														
															|  |                     }
 |  |                     }
 | 
												
													
														
															|  |                     if (wxId.equalsIgnoreCase("xm_zsyy_wx")){
 |  |                     if (wxId.equalsIgnoreCase("xm_zsyy_wx")){
 | 
												
													
														
															|  |                         String url="https://hlwyy.xmzsh.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  | 
 | 
												
													
														
															|  | 
 |  |                         String url=baseUrl+"/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
													
														
															|  |                         enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 |  |                         enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 | 
												
													
														
															|  |                     }else if (wxId.equalsIgnoreCase("xm_xzzx_wx")){
 |  |                     }else if (wxId.equalsIgnoreCase("xm_xzzx_wx")){
 | 
												
													
														
															|  |                         String url="https://ih.xmheart.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  |                         String url="https://ih.xmheart.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
											
												
													
														
															|  | @ -1561,7 +1560,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |             WlyyOutpatientDO wlyyOutpatientDO = outpatientDao.findById(businessOrderDO.getRelationCode());
 |  |             WlyyOutpatientDO wlyyOutpatientDO = outpatientDao.findById(businessOrderDO.getRelationCode());
 | 
												
													
														
															|  |             wlyyOutpatientDO.setPayStatus(1);
 |  |             wlyyOutpatientDO.setPayStatus(1);
 | 
												
													
														
															|  |             WlyyOutpatientDO outpatientDO = outpatientDao.save(wlyyOutpatientDO);
 |  |             WlyyOutpatientDO outpatientDO = outpatientDao.save(wlyyOutpatientDO);
 | 
												
													
														
															|  |             if (businessOrderDO.getStatus()!=null&&businessOrderDO.getStatus()!=1){
 |  | 
 | 
												
													
														
															|  | 
 |  |             if (businessOrderDO.getStatus()!=null&&businessOrderDO.getStatus()==0){
 | 
												
													
														
															|  |                 //发送企业模板消息给医生
 |  |                 //发送企业模板消息给医生
 | 
												
													
														
															|  |                 BasePatientDO patientDO = new BasePatientDO();
 |  |                 BasePatientDO patientDO = new BasePatientDO();
 | 
												
													
														
															|  |                 patientDO = patientDao.findById(outpatientDO.getPatient());
 |  |                 patientDO = patientDao.findById(outpatientDO.getPatient());
 | 
												
											
												
													
														
															|  | @ -1587,7 +1586,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
 | 
												
													
														
															|  |                     }
 |  |                     }
 | 
												
													
														
															|  |                 }
 |  |                 }
 | 
												
													
														
															|  |                 if (wxId.equalsIgnoreCase("xm_zsyy_wx")){
 |  |                 if (wxId.equalsIgnoreCase("xm_zsyy_wx")){
 | 
												
													
														
															|  |                     String url="https://hlwyy.xmzsh.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  | 
 | 
												
													
														
															|  | 
 |  |                     String url=baseUrl+"/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 | 
												
													
														
															|  |                     enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 |  |                     enterpriseService.sendTWMesByDoctor("zsyy",outpatientDO.getDoctor(),title,msg,url);
 | 
												
													
														
															|  |                 }else if (wxId.equalsIgnoreCase("xm_xzzx_wx")){
 |  |                 }else if (wxId.equalsIgnoreCase("xm_xzzx_wx")){
 | 
												
													
														
															|  |                     String url="https://ih.xmheart.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |  |                     String url="https://ih.xmheart.com/hlwyy/ims-app-web/#/onlineChat/detail?_rs_title="+outpatientDO.getDescription()+"&type=3&id="+outpatientDO.getId();
 |