Просмотр исходного кода

Merge branch 'dev' of trick9191/patient-co-management into dev

trick9191 7 лет назад
Родитель
Сommit
106ceb2ec1

Разница между файлами не показана из-за своего большого размера
+ 20 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/account/PatientInfoService.java


+ 20 - 2
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/task/PushMsgTask.java

@ -11,6 +11,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.stereotype.Component;
import javax.annotation.PostConstruct;
@ -55,6 +56,15 @@ public class PushMsgTask {
    private String template_doctor_audit;//审核结果通知
    @Value("${wechat.message.template_doctor_service}")
    private String template_doctor_service;//服务结果通知
    @Value("${pushMes.method}")
    private String putMesMethod;
    @Value("${pushMes.redis_prescription_title}")
    private String redisQueue;
    @Value("${putMesType.wechat}")
    private String putMesType;
    @Autowired
    private StringRedisTemplate redisTemplate;
    /**
     * 添加一条推送消息
@ -95,8 +105,16 @@ public class PushMsgTask {
            json.put("openid", openid);
            json.put("name", name);
            json.put("data", data);
            queue.put(json);
            String str = "";
            //如果是内网推送到redis,如果是外网推送到内存队列
            if(putMesMethod.equals("1")){
                JSONObject mes = new JSONObject();
                mes.put("title",putMesType);
                mes.put("value",json.toString());
                redisTemplate.opsForList().leftPush(redisQueue,mes.toString());
            }else{
                queue.put(json);
            }
        } catch (Exception e) {
            logger.error("添加到微信消息列队列失败!", e);
            e.printStackTrace();

+ 14 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/patient/PatientInfoController.java

@ -61,4 +61,18 @@ public class PatientInfoController extends BaseController {
            return invalidUserException(e, -1, "获取患者信息失败!");
        }
    }
    @RequestMapping(value = "initPatientNation")
    @ResponseBody
    @ApiOperation("初始化民族字典")
    public String initPatientNation(){
        try {
            // 获取医生下的患者
            int rs = patientInfoService.initPatientNation();
            return write(200, "初始化成功!", "data", rs);
        } catch (Exception e) {
            error(e);
            return invalidUserException(e, -1, "获取患者信息失败!");
        }
    }
}

+ 219 - 1
patient-co/patient-co-wlyy/src/main/resources/application.yml

@ -91,7 +91,9 @@ interceptor:
  accesstoken:
    status: 1 ###  1开启 0 关闭
    time: 2 ##对外接的accesstoken生命周期 2小时
putMesType:
  #推送到redis消息类型
  wechat: wechat
---
##测试的配置
spring:
@ -183,6 +185,11 @@ express:
#  sf_url: https://bsp-ois.sit.sf-express.com:9443/bsp-ois/sfexpressServic
  sf_code: SDDF
  sf_check_word: ttzlgGyOQu4L
pushMes:
# 1为推送redis,0为推送消息队列
  method: 0
  # redis队列名称
  redis_prescription_title: redisPrescription
es:
  index:
@ -290,6 +297,11 @@ express:
#  sf_url: https://bsp-ois.sit.sf-express.com:9443/bsp-ois/sfexpressServic
  sf_code: sddf
  sf_check_word: PqFN0ADkTwnvXArMhqGxVduag44vyDQ7
pushMes:
# 1为推送redis,0为推送消息队列
  method: 0
  # redis队列名称
  redis_prescription_title: redisPrescription
es:
@ -399,6 +411,11 @@ express:
#  sf_url: https://bsp-ois.sit.sf-express.com:9443/bsp-ois/sfexpressServic
  sf_code: SDDF
  sf_check_word: ttzlgGyOQu4L
pushMes:
  # 1为推送redis,0为推送消息队列
  method: 0
  # redis队列名称
  redis_prescription_title: redisPrescription
es:
  index:
@ -499,6 +516,207 @@ express:
#  sf_url: https://bsp-ois.sit.sf-express.com:9443/bsp-ois/sfexpressServic
  sf_code: SDDF
  sf_check_word: ttzlgGyOQu4L
pushMes:
# 1为推送redis,0为推送消息队列
  method: 0
  # redis队列名称
  redis_prescription_title: redisPrescription
es:
  index:
    HealthEduArticlePatient: health_edu_article_patient_test
  type:
    HealthEduArticlePatient: health_edu_article_patient_test
  host: 172.19.103.68
  port: 9200
  tPort: 9300
  clusterName: jkzl
---
##内网环境连测试环境
spring:
  profiles: local_test
  datasource:
    wlyy:
      url: jdbc:mysql://172.19.103.85/wlyy?useUnicode:true&characterEncoding=utf-8&autoReconnect=true
      username: linzhou
      password: linzhou
    health:
      url: jdbc:mysql://172.19.103.85/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: linzhou
      password: linzhou
  redis:
    host: 172.19.103.88 # Redis server host.
    port: 6379 # Redis server port.
#    password: jkzl_ehr
server:
  server_url: http://ehr.yihu.com/wlyy/
im:
  im_list_get: http://172.19.103.88:3000/
  data_base_name: im_new
wechat:
  appId: wx1f129f7b51701428
  appSecret: 988f005d8309ed1795939e0f042431fb
  wechat_token: 27eb3bb24f149a7760cf1bb154b08040
  wechat_base_url: http%3a%2f%2fehr.yihu.com%2fwlyy
  accId: gh_ffd64560fb21
  message:
    ##医生追加建议提醒 --签约邀请
    doctor_invitel_template:  uXdBJVbrhKG-WLaCG4s8C4SXSr2kknQ94vKFt-3rIiA
    #咨询回复
    template_consult_notice: dr4QNyFoRvVsf8uWxXMC1dRyjwnbUuJwJ21vBLhf18
    #签约成功
    template_sign_success: VYGj8OUKj6FH4i4_nZS2UAHurJxQHx-7_OBPILIdB8s
    #签约失败
    template_sign_failed: m221Jrkm0UUY00ExTCpQNTB8t_1U_V4LR9Bg8BgH9-o
    #健康指导提醒
    template_health_notice: 5Nts8lA_at9Cd1JuTK-qDxx95lchpcmUfPTEwYDgXYQ
    #解约提醒
    template_termination:  qZm1NwSueAsbHaOf9DrnLoSj0X5gZuh9W7aDYzLWNds
    #预约成功
    template_appoint_success:  vU5x2tGyk1zUngBrEqMfnFqqMa6M8J98w8k5MCSUYM
    #预约取消
    template_appoint_failed:  r-bVEKgXVyl8O96saoJXlLd7DX1zW7fXA4a0PZHxiQM
    #缴费提醒
    template_expenses_remind:  pZby4Mz3H5angmjGTuvXzo9lwlaVfEiqORwI8soI-5E
    #健康教育
    template_healthy_article: aO_qqk5nAXaGXhsikPVLNelqzwlrp1LTPfIQ1qRMpxo
    #医生变更
    template_doctor_change:  V5h0F84t972kUzQvWy8qYrgdaYGJVj10pFeFVl19Nb8
    #问卷调查
    template_doctor_survey:  OqQXrb-e43_TJpq_70_K_y6vYJgY5mpjFYY4c5RWFP4
    #审核结果通知
    template_doctor_audit:  lCtOgJgL1tBJbAytqN7cn-FgCH_Usg99FENEy2TrC08
    #服务结果通知
    template_doctor_service: i34rq3xFLnpf_VN2Jor9n2YlQqJMM7oXyYvuctriISw
yihu:
  yihu_OpenPlatform_url: http://ssotest.yihu.cn/OpenPlatform/cgiBin/1.0/
  yihu_OpenPlatform_appId: 9000276
  yihu_OpenPlatform_secret: OKC8BS1KGXTDE9GPP1EO4VYLUXF8DJ7QUP72H613ZXA
fastDFS:
  fastdfs_file_url: http://172.19.103.54:80/
images:
  path: /var/local/upload/images
  renew_path: /usr/local/apache-tomcat-8.0.36/webapps/wlyy/images/renew.png
  sign_path: /usr/local/apache-tomcat-8.0.36/webapps/wlyy/images/familycontract.png
sign:
  check_upload: http://172.19.103.88:8011/wlyy_service
express:
  sf_url: http://218.17.248.244:11080/bsp-oisp/sfexpressService
#  sf_url: https://bsp-ois.sit.sf-express.com:9443/bsp-ois/sfexpressServic
  sf_code: SDDF
  sf_check_word: ttzlgGyOQu4L
pushMes:
# 1为推送redis,0为推送消息队列
  method: 1
  # redis队列名称
  redis_prescription_title: redisPrescription
---
##内网环境
spring:
  profiles: local
  datasource:
    wlyy:
      url: jdbc:mysql://172.19.103.85/wlyy?useUnicode:true&characterEncoding=utf-8&autoReconnect=true
      username: linzhou
      password: linzhou
    health:
      url: jdbc:mysql://172.19.103.85/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: linzhou
      password: linzhou
  redis:
    host: 172.19.103.88 # Redis server host.
    port: 6379 # Redis server port.
#    password: jkzl_ehr
server:
  server_url: http://ehr.yihu.com/wlyy/
im:
  im_list_get: http://172.19.103.88:3000/
  data_base_name: im_new
wechat:
  appId: wx1f129f7b51701428
  appSecret: 988f005d8309ed1795939e0f042431fb
  wechat_token: 27eb3bb24f149a7760cf1bb154b08040
  wechat_base_url: http%3a%2f%2fehr.yihu.com%2fwlyy
  accId: gh_ffd64560fb21
  message:
    ##医生追加建议提醒 --签约邀请
    doctor_invitel_template:  uXdBJVbrhKG-WLaCG4s8C4SXSr2kknQ94vKFt-3rIiA
    #咨询回复
    template_consult_notice: dr4QNyFoRvVsf8uWxXMC1dRyjwnbUuJwJ21vBLhf18
    #签约成功
    template_sign_success: VYGj8OUKj6FH4i4_nZS2UAHurJxQHx-7_OBPILIdB8s
    #签约失败
    template_sign_failed: m221Jrkm0UUY00ExTCpQNTB8t_1U_V4LR9Bg8BgH9-o
    #健康指导提醒
    template_health_notice: 5Nts8lA_at9Cd1JuTK-qDxx95lchpcmUfPTEwYDgXYQ
    #解约提醒
    template_termination:  qZm1NwSueAsbHaOf9DrnLoSj0X5gZuh9W7aDYzLWNds
    #预约成功
    template_appoint_success:  vU5x2tGyk1zUngBrEqMfnFqqMa6M8J98w8k5MCSUYM
    #预约取消
    template_appoint_failed:  r-bVEKgXVyl8O96saoJXlLd7DX1zW7fXA4a0PZHxiQM
    #缴费提醒
    template_expenses_remind:  pZby4Mz3H5angmjGTuvXzo9lwlaVfEiqORwI8soI-5E
    #健康教育
    template_healthy_article: aO_qqk5nAXaGXhsikPVLNelqzwlrp1LTPfIQ1qRMpxo
    #医生变更
    template_doctor_change:  V5h0F84t972kUzQvWy8qYrgdaYGJVj10pFeFVl19Nb8
    #问卷调查
    template_doctor_survey:  OqQXrb-e43_TJpq_70_K_y6vYJgY5mpjFYY4c5RWFP4
    #审核结果通知
    template_doctor_audit:  lCtOgJgL1tBJbAytqN7cn-FgCH_Usg99FENEy2TrC08
    #服务结果通知
    template_doctor_service: i34rq3xFLnpf_VN2Jor9n2YlQqJMM7oXyYvuctriISw
yihu:
  yihu_OpenPlatform_url: http://ssotest.yihu.cn/OpenPlatform/cgiBin/1.0/
  yihu_OpenPlatform_appId: 9000276
  yihu_OpenPlatform_secret: OKC8BS1KGXTDE9GPP1EO4VYLUXF8DJ7QUP72H613ZXA
fastDFS:
  fastdfs_file_url: http://172.19.103.54:80/
images:
  path: /var/local/upload/images
  renew_path: /usr/local/apache-tomcat-8.0.36/webapps/wlyy/images/renew.png
  sign_path: /usr/local/apache-tomcat-8.0.36/webapps/wlyy/images/familycontract.png
sign:
  check_upload: http://172.19.103.88:8011/wlyy_service
express:
  sf_url: http://218.17.248.244:11080/bsp-oisp/sfexpressService
#  sf_url: https://bsp-ois.sit.sf-express.com:9443/bsp-ois/sfexpressServic
  sf_code: SDDF
  sf_check_word: ttzlgGyOQu4L
pushMes:
  # 1为推送redis,0为推送消息队列
  method: 1
  # redis队列名称
  redis_prescription_title: redisPrescription
es: