Kaynağa Gözat

免疫接种,提交测试环境接口代码

huangwenjie 7 yıl önce
ebeveyn
işleme
2205557f37

+ 55 - 6
patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/service/manager/sign/SignFamilyService.java

@ -277,7 +277,7 @@ public class SignFamilyService extends BaseJpaService<SignFamily,Long> {
            if(!StringUtils.isEmpty(doctor)){
                //1.4.2更新重点关注列表,取消关注
                updateTrackPatient(signFamily.getPatient(),signFamily.getDoctor());
                updateTrackPatient(signFamily.getPatient(),signFamily.getDoctor(),signFamily.getDoctorHealth(),doctor,doctorHealth);
                signFamily.setDoctor(doctor);
                signFamily.setDoctorName(doctorName);
@ -285,7 +285,7 @@ public class SignFamilyService extends BaseJpaService<SignFamily,Long> {
            if(!StringUtils.isEmpty(doctorHealth)){
                //1.4.2更新重点关注列表,取消关注
                updateTrackPatient(signFamily.getPatient(),signFamily.getDoctorHealth());
                updateTrackPatient(signFamily.getPatient(),signFamily.getDoctorHealth(),signFamily.getDoctor(),doctor,doctorHealth);
                signFamily.setDoctorHealth(doctorHealth);
                signFamily.setDoctorHealthName(doctorHealthName);
@ -447,9 +447,58 @@ public class SignFamilyService extends BaseJpaService<SignFamily,Long> {
        return list ;
    }
    public void updateTrackPatient(String patient,String oldDoctor){
        TrackPatient trackPatient = trackPatientDao.findByDoctorCodeAndPatientCode(oldDoctor,patient);
        trackPatient.setDel("0");
        trackPatientDao.save(trackPatient);
    /**
     * 设置取消关注
     * @param patient
     * @param oldDoctor 患者签约旧的要取消关注的医生
     * @param oldDoctor2 患者旧的签约的另一个医生
     * @param newDoctor 患者新签约的全科医生
     * @param newHDoctor 患者新签约的健康管理师
     */
    public void updateTrackPatient(String patient,String oldDoctor,String oldDoctor2,String newDoctor,String newHDoctor){
        //是否需要修改
        boolean flag = false;
        if(StringUtils.isBlank(oldDoctor)){
            return ;
        }
        //1.两个都修改
        if(StringUtils.isNotBlank(newDoctor)&&StringUtils.isNotBlank(newHDoctor)){
            if((!oldDoctor.equals(newDoctor))&&(!oldDoctor.equals(newHDoctor))){
                flag = true;
            }
            //只改全科
        }else if(StringUtils.isNotBlank(newDoctor)&&StringUtils.isBlank(newHDoctor)){
            if(!oldDoctor.equals(newDoctor)){
                if(StringUtils.isBlank(oldDoctor2)){
                    flag = true;
                }else{
                    if(!oldDoctor.equals(oldDoctor2)){
                        flag = true;
                    }
                }
            }
            //只改健管
        }else if(StringUtils.isBlank(newDoctor)&&StringUtils.isNotBlank(newHDoctor)){
            if(!oldDoctor.equals(newHDoctor)){
                if(StringUtils.isBlank(oldDoctor2)){
                    flag = true;
                }else{
                    if(!oldDoctor.equals(oldDoctor2)){
                        flag = true;
                    }
                }
            }
        }else{
            return ;
        }
        if(flag){
            TrackPatient trackPatient = trackPatientDao.findByDoctorCodeAndPatientCode(oldDoctor,patient);
            if(trackPatient!=null){
                trackPatient.setDel("0");
                trackPatientDao.save(trackPatient);
            }
        }
    }
}

+ 1 - 1
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/common/SystemConfig.java

@ -71,7 +71,7 @@ public class SystemConfig {
    public String getPublicKey() { return  getSystemProperties().getProperty("gateway_public_key"); }
    
    public String getImmPublicKey() { return  getSystemProperties().getProperty("ImmPublicTest.key"); }
    public String getImmPublicKey() { return  getSystemProperties().getProperty("imm_public_key"); }
    public String getJwHospital()
    {

+ 3 - 3
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ZysoftApi.java

@ -23,15 +23,15 @@ public class ZysoftApi extends AbstractApiExecuter {
    private static byte[]  publicKey;
    private static byte[]  zkzlPublicKey;
    private static byte[]  zkzlPrivateKey;
    private static byte[]  immPublicKey;
    private static String  immPublicKey;
    
    /**
     * 获取计免预约加密公钥
     */
    public static byte[] getImmPublicKey() throws Exception {
    public static String getImmPublicKey() throws Exception {
        if(immPublicKey == null)
        {
            immPublicKey =  sehrCrypto.sehrCrypto.ReadFileBytes(ZysoftApi.class.getClassLoader().getResource(SystemConfig.getInstance().getImmPublicKey()).toURI().getPath());
            immPublicKey =  ZysoftApi.class.getClassLoader().getResource(SystemConfig.getInstance().getImmPublicKey()).toURI().getPath();
        }
        return immPublicKey;
    }

+ 46 - 12
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/guahao/GuahaoService.java

@ -52,6 +52,16 @@ public class GuahaoService {
    private String ORDER_INFO = "GetReservationRecord";//预约信息
    private String REG_LIST = "GetRegList";//获取市民预约挂号信息
    /** *//**
     * RSA最大加密明文大小
     */
    private static final int MAX_ENCRYPT_BLOCK = 117;
    /** *//**
     * RSA最大解密密文大小
     */
    private static final int MAX_DECRYPT_BLOCK = 128;
    @Autowired
    private PatientDao patientDao;
@ -1286,28 +1296,52 @@ public class GuahaoService {
        
        return result;
    }
    
    /**
     * 获取免疫接种机构列表
     * @param condition
     * @return
     */
    public String GetOrgImmuneList()throws Exception  {
        String result = "";
        Map<String,String> params = new HashMap<>();
        String condition = "<root><zone>350203</zone><zone>350206</zone><zone>350205</zone><zone>350211</zone><zone>350212</zone><zone>350213</zone></root>";
    
        ZysoftApi api = ZysoftApi.getSingleton();
    
        condition = api.getConditionRSA(condition);
        
        //加密后的东西
        System.out.println("Condition: " + condition);
    
        PublicKey publicKey=immPublicKeyget(api.getImmPublicKey());
        byte[] encryptedBytes = this.encrypt(condition.getBytes(),publicKey);
        condition = new String(encryptedBytes,"utf-8");
        System.out.println(condition);
        params.put("Condition", condition);
        return immPostSecond("GetOrgImmuneList","计免预约-获取免疫接种机构列表",params);
    }
    
    public static byte[] encrypt(byte[] data, PublicKey publicKey) throws Exception{
        Cipher cipher=Cipher.getInstance("RSA");//java默认"RSA"="RSA/ECB/PKCS1Padding"
        cipher.init(Cipher.ENCRYPT_MODE, publicKey);
        int inputLen = data.length;
        ByteArrayOutputStream out = new ByteArrayOutputStream();
        int offSet = 0;
        byte[] cache;
        int i = 0;
        // 对数据分段加密
        while (inputLen - offSet > 0) {
            if (inputLen - offSet > MAX_ENCRYPT_BLOCK) {
                cache = cipher.doFinal(data, offSet, MAX_ENCRYPT_BLOCK);
            } else {
                cache = cipher.doFinal(data, offSet, inputLen - offSet);
            }
            out.write(cache, 0, cache.length);
            i++;
            offSet = i * MAX_ENCRYPT_BLOCK;
        }
        byte[] encryptedData = out.toByteArray();
        out.close();
        return encryptedData;
    }
    public PublicKey immPublicKeyget(String filename) throws Exception {
        File f = new File(filename);
        FileInputStream fis = new FileInputStream(f);
@ -1404,7 +1438,7 @@ public class GuahaoService {
        params.put("BarCode", barCode);
        params.put("OrgCode", orgCode);
        params.put("SectionType", sectionType);
        params.put("strStart", strStart);
        params.put("StartTime", strStart);
        params.put("SSID", ssid);
        params.put("PatientName", patientName);
        params.put("PatientID", patientID);
@ -1446,7 +1480,7 @@ public class GuahaoService {
        params.put("BarCode", barCode);
        params.put("OrgCode", orgCode);
        params.put("SectionType", sectionType);
        params.put("strStart", strStart);
        params.put("StartTime", strStart);
        params.put("SSID", ssid);
        params.put("PatientName", patientName);
        params.put("PatientID", patientID);

+ 1 - 1
patient-co/patient-co-wlyy/pom.xml

@ -565,7 +565,7 @@
                    <target>1.8</target>
                    <compilerArguments>
                        <verbose/>
                        <bootclasspath>${java.home}/lib/rt.jar;${java.home}/lib/jce.jar</bootclasspath>
                        <bootclasspath>${java.home}/lib/rt.jar:${java.home}/lib/jce.jar</bootclasspath>
                    </compilerArguments>
                </configuration>
                <version>3.1</version>

+ 41 - 43
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/account/DoctorInfoService.java

@ -42,6 +42,8 @@ import org.apache.http.NameValuePair;
import org.apache.http.message.BasicNameValuePair;
import org.json.JSONArray;
import org.json.JSONObject;
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.domain.Page;
@ -71,6 +73,7 @@ import java.util.*;
@Component
public class DoctorInfoService extends BaseService {
    private static Logger logger = LoggerFactory.getLogger(DoctorInfoService.class);
    @Autowired
    private DoctorDao doctorDao;
    @Autowired
@ -856,7 +859,7 @@ public class DoctorInfoService extends BaseService {
        String oldDoctorHealthName = signFamily.getDoctorHealthName();
        //1.4.2更新重点关注列表,取消关注
        familyContractService.updateTrackPatient(patient,signFamily.getDoctorHealth());
        familyContractService.updateTrackPatient(patient,signFamily.getDoctorHealth(),signFamily.getDoctor(),null,newDoctorCode);
        //修改签约中的健康管理师
        signFamily.setDoctorHealth(newD.getCode());
@ -1013,7 +1016,7 @@ public class DoctorInfoService extends BaseService {
        Doctor newD = doctorDao.findByCode(newDoctorCode);
        //1.4.2更新重点关注列表,取消关注
        familyContractService.updateTrackPatient(patient,signFamily.getDoctorHealth());
        familyContractService.updateTrackPatient(patient,signFamily.getDoctorHealth(),signFamily.getDoctor(),null,newDoctorCode);
        //修改签约中的健康管理师
        signFamily.setDoctorHealth(newD.getCode());
@ -1239,7 +1242,7 @@ public class DoctorInfoService extends BaseService {
        String oldDoctorName = signFamily.getDoctorName();
        //1.4.2更新重点关注列表,取消关注
        familyContractService.updateTrackPatient(patient,signFamily.getDoctor());
        familyContractService.updateTrackPatient(patient,signFamily.getDoctor(),signFamily.getDoctorHealth(),newDoctorCode,null);
        //修改签约中的全科医生
        signFamily.setDoctor(newD.getCode());
@ -1257,50 +1260,45 @@ public class DoctorInfoService extends BaseService {
        newDoctorTeamMember.setCode(UUID.randomUUID().toString().replace("-", ""));
        doctorTeamDoctor.save(newDoctorTeamMember);
        Patient p = patientDao.findByCode(patient);
        JSONObject data = new JSONObject();
        data.put("toUser", patient);
        data.put("represented",patient);//被代理人
        data.put("doctor", newD.getCode());
        data.put("doctorName", newD.getName());
        data.put("keyword3", "家庭医生-全科医生");
        data.put("keyword2", DateUtil.dateToStrNoSecond(new Date()));
        data.put("keyword1", newD.getName());
        if (StringUtils.isEmpty(signFamily.getDoctorHealth()) || signFamily.getDoctor().equals(signFamily.getDoctorHealth())) {
            data.put("remark", newD.getName() + "医生将继续为您提供优质健康服务");
        } else {
            data.put("remark", newD.getName() + "医生将继续为您提供优质健康服务");
        }
        try{
            Patient p = patientDao.findByCode(patient);
            JSONObject data = new JSONObject();
            data.put("toUser", patient);
            data.put("represented",patient);//被代理人
            data.put("doctor", newD.getCode());
            data.put("doctorName", newD.getName());
            data.put("keyword3", "家庭医生-全科医生");
            data.put("keyword2", DateUtil.dateToStrNoSecond(new Date()));
            data.put("keyword1", newD.getName());
            if (StringUtils.isEmpty(signFamily.getDoctorHealth()) || signFamily.getDoctor().equals(signFamily.getDoctorHealth())) {
                data.put("remark", newD.getName() + "医生将继续为您提供优质健康服务");
            } else {
                data.put("remark", newD.getName() + "医生将继续为您提供优质健康服务");
            }
        if (StringUtils.isNotBlank(p.getOpenid())) {
            data.put("first", p.getName() + ",您签约团队的全科医生已变更,您的新全科医生信息如下:");
            pushMsgTask.putWxMsg(accessTokenUtils.getAccessToken(), 10, p.getOpenid(), p.getName(), data);
        }
//        else {
//            //如果自己没有绑定,则发给家人
//            JSONObject json = weiXinOpenIdUtils.getFamilyOpenId(p.getCode());
//            Patient member = (Patient) json.get("member");
//            if (StringUtils.isNotBlank(member.getOpenid())) {
//                data.put("first", weiXinOpenIdUtils.getTitleMes(p, (int) json.get("relation"), member.getName()) + p.getName() + ",您好!因签约团队内分工调整,您的责任医生有变动," + oldDoctorName +
//                        "医生无法继续为您服务,具体变动如下:");
//                pushMsgTask.putWxMsg(accessTokenUtils.getAccessToken(), 10, member.getOpenid(), member.getName(), data);
//            }
//        }
            if (StringUtils.isNotBlank(p.getOpenid())) {
                data.put("first", p.getName() + ",您签约团队的全科医生已变更,您的新全科医生信息如下:");
                pushMsgTask.putWxMsg(accessTokenUtils.getAccessToken(), 10, p.getOpenid(), p.getName(), data);
            }
        //发送代理人
        JSONArray jsonArray = weiXinOpenIdUtils.getAgentOpenId(p.getCode(),p.getOpenid());
        if(jsonArray!=null&&jsonArray.length()>0){
            for (int i = 0;i<jsonArray.length();i++){
                JSONObject j  = jsonArray.getJSONObject(i);
                Patient member = (Patient) j.get("member");
                JSONObject json = data;
                json.remove("toUser");
                json.put("toUser",member.getCode());
                json.remove("first");
                json.put("first", weiXinOpenIdUtils.getTitleMes(p, (int) json.get("relation"), p.getName()) + p.getName() + ",您好!您签约团队的全科医生已变更,您的新全科医生信息如下:");
                pushMsgTask.putWxMsg(accessTokenUtils.getAccessToken(), 10, member.getOpenid(), p.getName(), json);
            //发送代理人
            JSONArray jsonArray = weiXinOpenIdUtils.getAgentOpenId(p.getCode(),p.getOpenid());
            if(jsonArray!=null&&jsonArray.length()>0){
                for (int i = 0;i<jsonArray.length();i++){
                    JSONObject j  = jsonArray.getJSONObject(i);
                    Patient member = (Patient) j.get("member");
                    JSONObject json = data;
                    json.remove("toUser");
                    json.put("toUser",member.getCode());
                    json.remove("first");
                    json.put("first", weiXinOpenIdUtils.getTitleMes(p, (int) json.get("relation"), p.getName()) + p.getName() + ",您好!您签约团队的全科医生已变更,您的新全科医生信息如下:");
                    pushMsgTask.putWxMsg(accessTokenUtils.getAccessToken(), 10, member.getOpenid(), p.getName(), json);
                }
            }
        }catch (Exception e){
            logger.info(e.getMessage());
        }
    }
//    /**

+ 58 - 6
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/sign/FamilyContractService.java

@ -2279,6 +2279,9 @@ public class FamilyContractService extends BaseService {
        SignFamily signFamily = signFamilyDao.findByjiatingPatientYes(patient);
        String oldDoctor = signFamily.getDoctor();
        String oldHdoctor = signFamily.getDoctorHealth();
        if (signFamily == null) {
            result.put("status", -1);
            result.put("msg", "居民不存在家庭签约");
@ -2377,7 +2380,7 @@ public class FamilyContractService extends BaseService {
            }
            //1.4.2更新重点关注列表,取消关注
            updateTrackPatient(patient,signFamily.getDoctorHealth());
            updateTrackPatient(patient,oldHdoctor,oldDoctor,doctor,healthDoctor);
            signFamily.setDoctorHealth(docHealth.getCode());
            signFamily.setDoctorHealthName(docHealth.getName());
@ -2431,7 +2434,7 @@ public class FamilyContractService extends BaseService {
            }
            //1.4.2更新重点关注列表,取消关注
            updateTrackPatient(patient,signFamily.getDoctor());
            updateTrackPatient(patient,oldDoctor,oldHdoctor,doctor,healthDoctor);
            signFamily.setDoctor(docQk.getCode());
            signFamily.setDoctorName(docQk.getName());
@ -4325,9 +4328,58 @@ public class FamilyContractService extends BaseService {
        return rs;
    }
    public void updateTrackPatient(String patient,String oldDoctor){
        TrackPatient trackPatient = trackPatientDao.findByDoctorCodeAndPatientCode(oldDoctor,patient);
        trackPatient.setDel("0");
        trackPatientDao.save(trackPatient);
    /**
     * 设置取消关注
     * @param patient
     * @param oldDoctor 患者签约旧的要取消关注的医生
     * @param oldDoctor2 患者旧的签约的另一个医生
     * @param newDoctor 患者新签约的全科医生
     * @param newHDoctor 患者新签约的健康管理师
     */
    public void updateTrackPatient(String patient,String oldDoctor,String oldDoctor2,String newDoctor,String newHDoctor){
        //是否需要修改
        boolean flag = false;
        if(StringUtils.isBlank(oldDoctor)){
            return ;
        }
        //1.两个都修改
        if(StringUtils.isNotBlank(newDoctor)&&StringUtils.isNotBlank(newHDoctor)){
            if((!oldDoctor.equals(newDoctor))&&(!oldDoctor.equals(newHDoctor))){
                flag = true;
            }
        //只改全科
        }else if(StringUtils.isNotBlank(newDoctor)&&StringUtils.isBlank(newHDoctor)){
            if(!oldDoctor.equals(newDoctor)){
                if(StringUtils.isBlank(oldDoctor2)){
                    flag = true;
                }else{
                    if(!oldDoctor.equals(oldDoctor2)){
                        flag = true;
                    }
                }
            }
        //只改健管
        }else if(StringUtils.isBlank(newDoctor)&&StringUtils.isNotBlank(newHDoctor)){
            if(!oldDoctor.equals(newHDoctor)){
                if(StringUtils.isBlank(oldDoctor2)){
                    flag = true;
                }else{
                    if(!oldDoctor.equals(oldDoctor2)){
                        flag = true;
                    }
                }
            }
        }else{
            return ;
        }
       if(flag){
            TrackPatient trackPatient = trackPatientDao.findByDoctorCodeAndPatientCode(oldDoctor,patient);
            if(trackPatient!=null){
                trackPatient.setDel("0");
                trackPatientDao.save(trackPatient);
            }
        }
    }
}

+ 3 - 3
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/statistics/ServiceStatisticsService.java

@ -175,9 +175,9 @@ public class ServiceStatisticsService extends BaseService {
        }*/
        //数据转移至Es
        String sqlHistory="select count(*) AS h from " + esType + " where patients.code='" + patient + "' and adminTeamCode = '"+teamCode+"'";
        String sqlYear = "select count(*) AS y from "+esType+" where patients.code='" + patient + "' and adminTeamCode = '"+teamCode+"' and czrq >= "+changeDate(yearBegin)+" and czrq <= "+changeDate(yearEnd);
        String sqlMonth = "select count(*) AS m from "+esType+" where patients.code='" + patient + "' and adminTeamCode = '"+teamCode+"' and czrq >= "+changeDate(monthBegin);
        String sqlHistory="select count(*) AS h from " + esType + " where patientCode='" + patient + "' and adminTeamCode = '"+teamCode+"'";
        String sqlYear = "select count(*) AS y from "+esType+" where patientCode='" + patient + "' and adminTeamCode = '"+teamCode+"' and czrq >= "+changeDate(yearBegin)+" and czrq <= "+changeDate(yearEnd);
        String sqlMonth = "select count(*) AS m from "+esType+" where patientCode='" + patient + "' and adminTeamCode = '"+teamCode+"' and czrq >= "+changeDate(monthBegin);
        result.put("history", elasticsearchUtil.excuteForLong(sqlHistory,esType,esIndex));
        result.put("year", elasticsearchUtil.excuteForLong(sqlYear,esType,esIndex));

+ 1 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/sign/DoctorFamilyContractController.java

@ -1163,6 +1163,7 @@ public class DoctorFamilyContractController extends WeixinBaseController {
            }
            return write(200, "更新成功");
        } catch (Exception e) {
            error(e);
            return error(-1, "更新失败");
        }
    }

+ 19 - 15
patient-co/patient-co-wlyy/src/main/resources/logback.xml

@ -11,9 +11,9 @@
    </appender>
    <appender name="rollingFile" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/tmp/logs/wlyy.log</file>
        <file>/Users/Mewtwo/ideaSpace/log/tmp/logs/wlyy.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>/tmp/logs/wlyy.%d{yyyy-MM-dd}.log</fileNamePattern>
            <fileNamePattern>/Users/Mewtwo/ideaSpace/log/tmp/logs/wlyy.%d{yyyy-MM-dd}.log</fileNamePattern>
            <maxHistory>15</maxHistory>
        </rollingPolicy>
        <encoder>
@ -23,9 +23,9 @@
    </appender>
    <appender name="business_m" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/datadisk/wlyy_logs/business_m.log</file>
        <file>/Users/Mewtwo/ideaSpace/log/wlyy_logs/business_m.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>/datadisk/wlyy_logs/rolling/business_m.%d{yyyy-MM-dd_HH-mm}.log</fileNamePattern>
            <fileNamePattern>/Users/Mewtwo/ideaSpace/log/wlyy_logs/rolling/business_m.%d{yyyy-MM-dd_HH-mm}.log</fileNamePattern>
            <maxHistory>15</maxHistory>
        </rollingPolicy>
        <encoder>
@ -34,9 +34,9 @@
        </encoder>
    </appender>
    <appender name="business_d" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/datadisk/wlyy_logs/business.log</file>
        <file>/Users/Mewtwo/ideaSpace/log/wlyy_logs/business.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>/datadisk/wlyy_logs/dayLogs/business.%d{yyyy-MM-dd}.log</fileNamePattern>
            <fileNamePattern>/Users/Mewtwo/ideaSpace/log/wlyy_logs/dayLogs/business.%d{yyyy-MM-dd}.log</fileNamePattern>
            <maxHistory>15</maxHistory>
        </rollingPolicy>
        <encoder>
@ -45,9 +45,9 @@
        </encoder>
    </appender>
    <appender name="interface_call_m" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/datadisk/wlyy_logs/interface_call_m.log</file>
        <file>/Users/Mewtwo/ideaSpace/log/wlyy_logs/interface_call_m.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>/datadisk/wlyy_logs/rolling/interface_call_m.%d{yyyy-MM-dd_HH-mm}.log</fileNamePattern>
            <fileNamePattern>/Users/Mewtwo/ideaSpace/log/wlyy_logs/rolling/interface_call_m.%d{yyyy-MM-dd_HH-mm}.log</fileNamePattern>
            <maxHistory>15</maxHistory>
        </rollingPolicy>
        <encoder>
@ -56,9 +56,9 @@
        </encoder>
    </appender>
    <appender name="interface_call_d" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/datadisk/wlyy_logs/interface_call.log</file>
        <file>/Users/Mewtwo/ideaSpace/log/wlyy_logs/interface_call.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>/datadisk/wlyy_logs/dayLogs/interface_call.%d{yyyy-MM-dd}.log</fileNamePattern>
            <fileNamePattern>/Users/Mewtwo/ideaSpace/log/wlyy_logs/dayLogs/interface_call.%d{yyyy-MM-dd}.log</fileNamePattern>
            <maxHistory>15</maxHistory>
        </rollingPolicy>
        <encoder>
@ -90,10 +90,10 @@
    <!--处方支付日志 start-->
    <!-- 演示按时间滚动的策略 -->
    <appender name="dailyRollingFileAppender" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <File>/tmp/logs/wlyy_prescription_pay.log</File>
        <File>/Users/Mewtwo/ideaSpace/log/tmp/logs/wlyy_prescription_pay.log</File>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <!-- daily rollover -->
            <FileNamePattern>/tmp/logs/wlyy_prescription_pay.%d{yyyy-MM-dd}.log</FileNamePattern>
            <FileNamePattern>/Users/Mewtwo/ideaSpace/log/tmp/logs/wlyy_prescription_pay.%d{yyyy-MM-dd}.log</FileNamePattern>
            <!-- 保留 15天数据,默认无限
            <maxHistory>15</maxHistory>-->
        </rollingPolicy>
@ -106,10 +106,12 @@
    </logger>
    <!--处方支付日志 end-->
    <appender name="error_rollingFile" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/datadisk/wlyy_logs/error/error.log</file>
        <file>/Users/Mewtwo/ideaSpace/log/wlyy_logs/error/error.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>/datadisk/wlyy_logs/error/error.%d{yyyy-MM-dd}.log</fileNamePattern>
            <fileNamePattern>/Users/Mewtwo/ideaSpace/log/wlyy_logs/error/error.%d{yyyy-MM-dd}.log</fileNamePattern>
            <maxHistory>30</maxHistory>
        </rollingPolicy>
        <encoder>
@ -126,4 +128,6 @@
        <!--<appender-ref ref="console" />-->
        <appender-ref ref="rollingFile" />
    </root>
</configuration>
</configuration>

+ 1 - 1
pom.xml

@ -617,7 +617,7 @@
                        <target>1.8</target>
                        <compilerArguments>
                            <verbose/>
                            <bootclasspath>${java.home}/lib/rt.jar;${java.home}/lib/jce.jar</bootclasspath>
                            <bootclasspath>${java.home}/lib/rt.jar:${java.home}/lib/jce.jar</bootclasspath>
                        </compilerArguments>
                    </configuration>
                    <version>3.1</version>