yeshijie 7 rokov pred
rodič
commit
a0551ff021

+ 5 - 3
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/consult/ConsultTeamService.java

@ -31,6 +31,7 @@ import com.yihu.wlyy.repository.prescription.PrescriptionInfoDao;
import com.yihu.wlyy.repository.prescription.PrescriptionReviewedDao;
import com.yihu.wlyy.service.app.health.HealthEduArticleService;
import com.yihu.wlyy.service.app.health.PatientHealthGuidanceService;
import com.yihu.wlyy.service.app.prescription.PrescriptionInfoService;
import com.yihu.wlyy.service.app.prescription.PrescriptionLogService;
import com.yihu.wlyy.service.app.talk.TalkGroupService;
import com.yihu.wlyy.service.third.jw.JwPrescriptionService;
@ -130,6 +131,8 @@ public class ConsultTeamService extends ConsultService {
    private WeiXinAccessTokenUtils accessTokenUtils;
    @Autowired
    private JwPrescriptionService jwPrescriptionService;
    @Autowired
    private PrescriptionInfoService prescriptionInfoService;
    Map<Integer, String> relations = new HashMap<>();
@ -877,9 +880,8 @@ public class ConsultTeamService extends ConsultService {
    public Integer addPrescriptionConsult(String jwCode,String patient,String agent,String doctorCode,ConsultTeam ct,String reason,Integer type) throws Exception {
        synchronized (jwCode.intern()){
//            PrescriptionReviewed p = prescriptionReviewedDao.findByPrescriptionCodeAndStatus()
            List<Prescription> prescriptionList = prescriptionDao.fingdByJwCodeAndStatus(jwCode,0,patient);
            if(prescriptionList!=null&&prescriptionList.size()>0){//存在未审核的续方
            String check = prescriptionInfoService.presCheckState(jwCode);
            if("0".equals(check)){//存在未审核的续方
                return -1;
            }
            Doctor doctor = doctorDao.findByCode(doctorCode);