From 039eed185a44d95f6bd8acf67c357b9d1e12a0f9 Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Fri, 22 Nov 2024 19:38:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/xml/KcEvaluationsStatMapper.xml | 2 +- .../kc/wjxDjxx/entity/WjxDjxxTmlbPage.java | 2 + .../kc/wjxDjxx/entity/WjxDjxxTmxx.java | 2 + .../kc/wjxDjxx/mapper/xml/WjxDjxxMapper.xml | 8 +- .../service/impl/WjxDjxxServiceImpl.java | 23 ++++ .../service/impl/WjxWjxxServiceImpl.java | 5 + .../controller/WjxWjxxTmlbController.java | 7 +- .../kc/zyCcjg/service/IZyCcjgService.java | 2 + .../service/impl/ZyCcjgServiceImpl.java | 5 + .../zyInfo/controller/ZyInfoController.java | 21 ++++ .../modules/kc/zyInfo/entity/ZyInfo.java | 2 + .../kc/zyInfo/mapper/ZyInfoMapper.java | 2 + .../kc/zyInfo/mapper/xml/ZyInfoMapper.xml | 9 ++ .../kc/zyInfo/service/IZyInfoService.java | 2 + .../service/impl/ZyInfoServiceImpl.java | 5 + .../controller/ZyInfoStudentController.java | 105 ++++++++++++++++++ .../service/IZyInfoStudentService.java | 4 + .../impl/ZyInfoStudentServiceImpl.java | 74 ++++++++++++ 18 files changed, 274 insertions(+), 6 deletions(-) diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/kcEvaluationsStat/mapper/xml/KcEvaluationsStatMapper.xml b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/kcEvaluationsStat/mapper/xml/KcEvaluationsStatMapper.xml index caacd997..aac1f444 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/kcEvaluationsStat/mapper/xml/KcEvaluationsStatMapper.xml +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/kcEvaluationsStat/mapper/xml/KcEvaluationsStatMapper.xml @@ -1255,7 +1255,7 @@ select max(id) as id,gh,xqxn from KC_EXPORT_CONFIG_TPKWCQKJZGLX where xqxn = #{x AND EVS.ANSID = ANS.ID AND EV.evaluationver = '5' AND EVS.EVALUATIONID = #{col00} - AND EVS.QUEID = '31') AS COL14, + AND EVS.QUEID = '75') AS COL14, CASE EV.EVALUATIONVER WHEN '2' THEN '线上听课表' diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmlbPage.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmlbPage.java index ee00a7da..baa486b7 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmlbPage.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmlbPage.java @@ -54,6 +54,8 @@ public class WjxDjxxTmlbPage { private Double wjScore; private String sfxysdpy; private String picPath; + private java.lang.Integer wjSubtype; + private String id; } diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmxx.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmxx.java index 54d115fe..35d5c4ce 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmxx.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/entity/WjxDjxxTmxx.java @@ -79,4 +79,6 @@ public class WjxDjxxTmxx implements Serializable { private String djid; @TableField(exist = false) private String djtmid; + @TableField(exist = false) + private String wjSubtype; } diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/mapper/xml/WjxDjxxMapper.xml b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/mapper/xml/WjxDjxxMapper.xml index 3713dd1e..bb3583f4 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/mapper/xml/WjxDjxxMapper.xml +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/wjxDjxx/mapper/xml/WjxDjxxMapper.xml @@ -116,9 +116,9 @@ + + \ No newline at end of file diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/IZyInfoService.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/IZyInfoService.java index 8239be64..59b02c5d 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/IZyInfoService.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/IZyInfoService.java @@ -42,4 +42,6 @@ public interface IZyInfoService extends IService { IPage sysStaticCyList(Page page, CyInfoSys cyInfoSys); List getStaticCyExportUrl(CyInfoSys cyInfoSys); + + IPage listKhcl(Page page, QueryWrapper queryWrapper); } diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/impl/ZyInfoServiceImpl.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/impl/ZyInfoServiceImpl.java index 944aef5a..a19aa645 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/impl/ZyInfoServiceImpl.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfo/service/impl/ZyInfoServiceImpl.java @@ -239,6 +239,11 @@ public class ZyInfoServiceImpl extends ServiceImpl impleme return baseMapper.getStaticCyExportUrl(cyInfoSys); } + @Override + public IPage listKhcl(Page page, QueryWrapper queryWrapper) { + return baseMapper.listKhcl(page,queryWrapper); + } + // appId private static final String appId = "wx031697a8ca09a5ce";//东师 diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/controller/ZyInfoStudentController.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/controller/ZyInfoStudentController.java index 3c3b39fc..51048760 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/controller/ZyInfoStudentController.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/controller/ZyInfoStudentController.java @@ -593,6 +593,42 @@ public class ZyInfoStudentController extends JeecgController uploadSckhcl(@RequestBody ZyInfoStudent zyInfoStudent) { + try { + System.out.println("ids:"+zyInfoStudent.getId()); + zyInfoStudentService.batchZyinfoKhcl(zyInfoStudent.getId()); + }catch (Exception e) { + e.printStackTrace(); + } + + return Result.OK("上传成功!"); + } + + @PostMapping(value = "/uploadSckhcl2") + public Result uploadSckhcl2(@RequestParam(name="ids",required=true) String ids) { + try { + zyInfoStudentService.batchZyinfoKhcl(ids); + }catch (Exception e) { + e.printStackTrace(); + } + + return Result.OK("上传成功!"); + } + + @AutoLog(value = "学生提交作业-批量删除") @ApiOperation(value="学生提交作业-批量删除", notes="学生提交作业-批量删除") @RequiresPermissions("zyInfoStudent:zy_info_student:deleteBatch") @@ -1104,4 +1140,73 @@ public class ZyInfoStudentController extends JeecgController> Scccjg(ZyInfoStudent zyInfoStudent, HttpServletRequest req, HttpServletResponse response) { + ZyInfoStudent zyInfoStudent1 = zyInfoStudentService.scccjg(zyInfoStudent,req,response); + return null; + } + + + @AutoLog(value = "学生提交作业-批量发布考核材料") + @ApiOperation(value="学生提交作业-批量发布考核材料", notes="学生提交作业-批量发布考核材料") + @PostMapping(value = "/batchKhclZyid") + public Result batchKhclZyid(@RequestParam(name="ids",required=true) String ids) { + try { + String idsList[] = ids.split(","); + if(idsList.length>0){ + ZyInfoStudent zyInfoStudentPar = zyInfoStudentService.getById(idsList[0]); + ZyInfo zyInfo = zyInfoService.getById(zyInfoStudentPar.getMainId()); + QueryWrapper kcKechengbiaoQueryWrapper = new QueryWrapper<>(); + kcKechengbiaoQueryWrapper.eq("rwbh",zyInfo.getRwbh()); + kcKechengbiaoQueryWrapper.eq("jgh",zyInfo.getCreateBy()); + kcKechengbiaoQueryWrapper.eq("xqxn",zyInfo.getXnxq()); + kcKechengbiaoQueryWrapper.last("limit 1"); + KcKechengbiao kcKechengbiao = kcKechengbiaoService.getOne(kcKechengbiaoQueryWrapper); + + zyInfo.setSfsckhcl("1"); + zyInfo.setSfsckhclTime(new Date()); + zyInfoService.updateById(zyInfo); + + + + for(int i=0;i< idsList.length;i++){ + + ZyInfoStudent zyInfoStudentPar2 = zyInfoStudentService.getById(idsList[i]); + + if(StringUtils.isNotEmpty(zyInfoStudentPar2.getFilePath())){ + //上传文件 + Map uploadMap = SFTPUtil.upload(sftpConfig,upLoadPath+"/"+zyInfoStudentPar2.getFilePath(),zyInfoStudentPar2.getFilePath()); + zyInfoStudentPar2.setSfsckhcl("1"); + zyInfoStudentPar2.setFwqPath(uploadMap.get("data")); + zyInfoStudentPar2.setKhclTime(new Date()); + zyInfoStudentService.updateById(zyInfoStudentPar2); + + ZyInfoScjl zyInfoScjl = new ZyInfoScjl(); + zyInfoScjl.setZyId(zyInfo.getId()); + zyInfoScjl.setZyName(zyInfo.getTitle()); + zyInfoScjl.setZyLeixing(zyInfo.getZyLeixing()); + zyInfoScjl.setZyZb(zyInfo.getScore()); + zyInfoScjl.setJgh(kcKechengbiao.getJgh()); + zyInfoScjl.setSkjs(kcKechengbiao.getSkjs()); + zyInfoScjl.setSkdd(kcKechengbiao.getSkdd()); + zyInfoScjl.setKkdw(kcKechengbiao.getKkdw()); + zyInfoScjl.setKkdwid(kcKechengbiao.getKkdwid()); + zyInfoScjl.setKcxz(kcKechengbiao.getKcxz()); + zyInfoScjl.setXnxq(zyInfo.getXnxq()); + zyInfoScjl.setFilePath(zyInfoStudentPar2.getFwqPath()); + zyInfoScjl.setStudentNo(zyInfoStudentPar2.getCreateBy()); + zyInfoScjl.setStudentName(zyInfoStudentPar2.getStudentName()); + zyInfoScjlService.save(zyInfoScjl); + } + } + } + }catch (Exception e) { + e.printStackTrace(); + } + + return Result.OK("上传成功!"); + } + + } diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/IZyInfoStudentService.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/IZyInfoStudentService.java index 16c3369e..783cd5ed 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/IZyInfoStudentService.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/IZyInfoStudentService.java @@ -50,4 +50,8 @@ public interface IZyInfoStudentService extends IService { List xnccBatchWeipu(ZyInfoStudent zyInfoStudent, HttpServletResponse response); List cxccByZyId(ZyInfoStudent zyInfoStudent2); + + ZyInfoStudent scccjg(ZyInfoStudent zyInfoStudent, HttpServletRequest req, HttpServletResponse response); + + void batchZyinfoKhcl(String ids); } diff --git a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/impl/ZyInfoStudentServiceImpl.java b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/impl/ZyInfoStudentServiceImpl.java index 3a4235e2..d139d497 100644 --- a/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/impl/ZyInfoStudentServiceImpl.java +++ b/jeecg-module-main/src/main/java/org/jeecg/modules/kc/zyInfoStudent/service/impl/ZyInfoStudentServiceImpl.java @@ -19,6 +19,8 @@ import org.jeecg.modules.kc.zyCcjg.entity.ZyCcjg; import org.jeecg.modules.kc.zyCcjg.mapper.ZyCcjgMapper; import org.jeecg.modules.kc.zyInfo.entity.ZyInfo; import org.jeecg.modules.kc.zyInfo.service.IZyInfoService; +import org.jeecg.modules.kc.zyInfoScjl.entity.ZyInfoScjl; +import org.jeecg.modules.kc.zyInfoScjl.service.IZyInfoScjlService; import org.jeecg.modules.kc.zyInfoStudent.entity.ZyInfoStudent; import org.jeecg.modules.kc.zyInfoStudent.entity.ZyInfoStudentSys; import org.jeecg.modules.kc.zyInfoStudent.mapper.ZyInfoStudentMapper; @@ -28,10 +30,12 @@ import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Service; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.test.annotation.Rollback; import javax.activation.MimetypesFileTypeMap; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import javax.transaction.Transactional; import java.io.*; import java.net.HttpURLConnection; import java.net.URL; @@ -88,6 +92,14 @@ public class ZyInfoStudentServiceImpl extends ServiceImpl0){ + for(String zyId:idsList){ + ZyInfo zyInfo = zyInfoService.getById(zyId); + QueryWrapper kcKechengbiaoQueryWrapper = new QueryWrapper<>(); + kcKechengbiaoQueryWrapper.eq("rwbh",zyInfo.getRwbh()); + kcKechengbiaoQueryWrapper.eq("jgh",zyInfo.getCreateBy()); + kcKechengbiaoQueryWrapper.eq("xqxn",zyInfo.getXnxq()); + kcKechengbiaoQueryWrapper.last("limit 1"); + KcKechengbiao kcKechengbiao = kcKechengbiaoService.getOne(kcKechengbiaoQueryWrapper); + zyInfo.setSfsckhcl("1"); + zyInfo.setSfsckhclTime(new Date()); + zyInfoService.updateById(zyInfo); + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.eq("main_id",zyId); + queryWrapper.isNotNull("file_path"); + List list = baseMapper.selectList(queryWrapper); + for(ZyInfoStudent zyInfoStudentPar2:list){ + if(StringUtils.isNotEmpty(zyInfoStudentPar2.getFilePath())){ + //上传文件 + Map uploadMap = SFTPUtil.upload(sftpConfig,upLoadPath+"/"+zyInfoStudentPar2.getFilePath(),zyInfoStudentPar2.getFilePath()); + zyInfoStudentPar2.setSfsckhcl("1"); + zyInfoStudentPar2.setFwqPath(uploadMap.get("data")); + zyInfoStudentPar2.setKhclTime(new Date()); + baseMapper.updateById(zyInfoStudentPar2); + + ZyInfoScjl zyInfoScjl = new ZyInfoScjl(); + zyInfoScjl.setZyId(zyInfo.getId()); + zyInfoScjl.setZyName(zyInfo.getTitle()); + zyInfoScjl.setZyLeixing(zyInfo.getZyLeixing()); + zyInfoScjl.setZyZb(zyInfo.getScore()); + zyInfoScjl.setJgh(kcKechengbiao.getJgh()); + zyInfoScjl.setSkjs(kcKechengbiao.getSkjs()); + zyInfoScjl.setSkdd(kcKechengbiao.getSkdd()); + zyInfoScjl.setKkdw(kcKechengbiao.getKkdw()); + zyInfoScjl.setKkdwid(kcKechengbiao.getKkdwid()); + zyInfoScjl.setKcxz(kcKechengbiao.getKcxz()); + zyInfoScjl.setXnxq(zyInfo.getXnxq()); + zyInfoScjl.setFilePath(zyInfoStudentPar2.getFwqPath()); + zyInfoScjl.setStudentNo(zyInfoStudentPar2.getCreateBy()); + zyInfoScjl.setStudentName(zyInfoStudentPar2.getStudentName()); + zyInfoScjlService.save(zyInfoScjl); + } + } + } + } + }catch (Exception e) { + e.printStackTrace(); + } + } + private void delweipulunwen(ZyInfoStudent zyInfoStudent, HttpServletResponse response) { zyInfoStudent.setQueryType("0");//外网查重数据 String paperids = baseMapper.getWpFile(zyInfoStudent);