智慧保安后台管理-外网
Administrator
2021-09-22 e50a89ac0eaaa7daaf9f69554b7df11002b8eb95
缴费上传接口修改,考试开始接口修改
3 files modified
28 ■■■■ changed files
src/main/java/org/springblade/modules/apply/controller/ApplyController.java 14 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java 12 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/resource/endpoint/OssEndpoint.java 2 ●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/apply/controller/ApplyController.java
@@ -704,13 +704,13 @@
        //内网同步
        Long sid = examScore.getId();
        String format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(examScore.getExamTime());
//        String s = "insert into exam_score(id,exam_time,user_id,exam_id,apply_id) " +
//            "values(" + "'" + sid + "'" + "," + "'" +
//            format + "'" + "," + "'" +
//            examScore.getUserId() +"'" + ","  +"'" +
//            examScore.getExamId() +"'" + ","  +"'" +
//            examScore.getApplyId() + "'" + ")";
//        FtpUtil.sqlFileUpload(s);
        String s = "insert into exam_score(id,exam_time,user_id,exam_id,apply_id) " +
            "values(" + "'" + sid + "'" + "," + "'" +
            format + "'" + "," + "'" +
            examScore.getUserId() +"'" + ","  +"'" +
            examScore.getExamId() +"'" + ","  +"'" +
            examScore.getApplyId() + "'" + ")";
        FtpUtil.sqlFileUpload(s);
        return examScore;
    }
src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java
@@ -463,9 +463,9 @@
            apply1.setIsExam(3);
            baseMapper.updateById(apply1);
//            String s1 =
//                "update sys_apply set is_exam = " + apply1.getIsExam() + " " +"where id = " + "'" + apply1.getId() + "'";
//            FtpUtil.sqlFileUpload(s1);
            String s1 =
                "update sys_apply set is_exam = " + apply1.getIsExam() + " " +"where id = " + "'" + apply1.getId() + "'";
            FtpUtil.sqlFileUpload(s1);
        }
        //模拟考
        if (apply.getExamType()==2){
@@ -475,9 +475,9 @@
            trainingRegistration.setIsExam(3);
            trainingRegistrationService.updateById(trainingRegistration);
//            String s1 =
//                "update sys_training_registration set is_exam = " + trainingRegistration.getIsExam() + " " +"where id = " + "'" + trainingRegistration.getId() + "'";
//            FtpUtil.sqlFileUpload(s1);
            String s1 =
                "update sys_training_registration set is_exam = " + trainingRegistration.getIsExam() + " " +"where id = " + "'" + trainingRegistration.getId() + "'";
            FtpUtil.sqlFileUpload(s1);
        }
    }
src/main/java/org/springblade/modules/resource/endpoint/OssEndpoint.java
@@ -458,7 +458,7 @@
                if (null!=user){
                    ExamPayment examPayment = new ExamPayment();
                    examPayment.setWorkerId(user.getId().toString());
                    examPayment.setPaymentStatus(1);
                    examPayment.setPaymentStatus(3);
                    examPayment.setCertificateUrl(urls);
                    examPayment.setType(1);
                    examPayment.setPaymentTime(new Date());