diff --git a/src/main/java/com/zhgd/xmgl/modules/baotou/controller/ReturnTrainingDetailController.java b/src/main/java/com/zhgd/xmgl/modules/baotou/controller/ReturnTrainingDetailController.java index 7395b2b47..5b46f2bdb 100644 --- a/src/main/java/com/zhgd/xmgl/modules/baotou/controller/ReturnTrainingDetailController.java +++ b/src/main/java/com/zhgd/xmgl/modules/baotou/controller/ReturnTrainingDetailController.java @@ -70,9 +70,10 @@ public class ReturnTrainingDetailController { @OperLog(operModul = "复工培训申请(专项培训申请)明细管理", operType = "分页查询", operDesc = "分页列表查询复工培训申请(专项培训申请)明细信息") @ApiOperation(value = "分页列表查询复工培训申请(专项培训申请)明细信息", notes = "分页列表查询复工培训申请(专项培训申请)明细信息", httpMethod = "GET") @ApiImplicitParams({ - @ApiImplicitParam(name = "pageNo", value = "第几页", paramType = "query", required = true, dataType = "Integer"), - @ApiImplicitParam(name = "pageSize", value = "每页显示条数", paramType = "query", required = true, dataType = "Integer"), - }) + @ApiImplicitParam(name = "pageNo", value = "第几页", paramType = "query", required = true, dataType = "Integer"), + @ApiImplicitParam(name = "pageSize", value = "每页显示条数", paramType = "query", required = true, dataType = "Integer"), + @ApiImplicitParam(name = "queryExamStatus", value = "1未考试2通过3未通过", paramType = "query", required = false, dataType = "String"), + }) @GetMapping(value = "/page") public Result> queryPageList(@ApiIgnore @RequestParam HashMap param) { return Result.success(returnTrainingDetailService.queryPageList(param)); diff --git a/src/main/java/com/zhgd/xmgl/modules/baotou/controller/WorkerAdmissionDetailController.java b/src/main/java/com/zhgd/xmgl/modules/baotou/controller/WorkerAdmissionDetailController.java index 5eff56c9e..e7e05fe5c 100644 --- a/src/main/java/com/zhgd/xmgl/modules/baotou/controller/WorkerAdmissionDetailController.java +++ b/src/main/java/com/zhgd/xmgl/modules/baotou/controller/WorkerAdmissionDetailController.java @@ -77,6 +77,7 @@ public class WorkerAdmissionDetailController { @ApiImplicitParam(name = "pageNo", value = "第几页", paramType = "query", required = true, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "每页显示条数", paramType = "query", required = true, dataType = "Integer"), @ApiImplicitParam(name = "idCards", value = "身份证号s(多个逗号分割)", paramType = "query", required = false, dataType = "String"), + @ApiImplicitParam(name = "queryExamStatus", value = "1未考试2通过3未通过", paramType = "query", required = false, dataType = "String"), }) @GetMapping(value = "/page") public Result> queryPageList(@ApiIgnore @RequestParam HashMap param) { @@ -200,7 +201,7 @@ public class WorkerAdmissionDetailController { List entity = new ArrayList(); entity.add(new ExcelExportEntity("编号", "num")); entity.add(new ExcelExportEntity("姓名", "name")); - entity.add(new ExcelExportEntity("岗位", "post")); + entity.add(new ExcelExportEntity("岗位/工种", "post")); entity.add(new ExcelExportEntity("单位", "enterprise")); entity.add(new ExcelExportEntity("发证日期", "date")); List> excelList = new ArrayList>(); @@ -220,14 +221,14 @@ public class WorkerAdmissionDetailController { map.put("date", DateUtil.today()); excelList.add(map); try { - String url = detail.getFieldAcquisitionUrl(); + String url = JSON.parseArray(detail.getFieldAcquisitionUrl()).getJSONObject(0).getString("url"); MinioUtils.downloadFile(url); - ImgUtil.convert(FileUtil.file(PathUtil.getBasePath(), JSON.parseArray(url).getJSONObject(0).getString("id")), FileUtil.file(head, workerName + ".jpg")); + FileUtil.move(FileUtil.file(PathUtil.getBasePath(), url), FileUtil.file(head, workerName + "." + StrUtil.subAfter(url, ".", true)), true); } catch (Exception e) { log.error("批量制卡", e); } // 生成指定url对应的二维码到文件,宽和高都是300像素 - QrCodeUtil.generate(idCardMap.get(detail.getIdCard()).getId() + "", 300, 300, FileUtil.file(qrCode, num + ".jpg")); + QrCodeUtil.generate("/pages/projectEnd/laborManage/searchTeam/personDetail?id=" + idCardMap.get(detail.getIdCard()).getId(), 300, 300, FileUtil.file(qrCode, num + ".jpg")); } Workbook workbook = ExcelExportUtil.exportExcel(new ExportParams(), entity, excelList); FileOutputStream fos = null; diff --git a/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/DeviceUnitMapper.java b/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/DeviceUnitMapper.java index af3c56ff1..c583aa087 100644 --- a/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/DeviceUnitMapper.java +++ b/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/DeviceUnitMapper.java @@ -22,7 +22,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; * @version: V1.0 */ @Mapper -@DataScope +//@DataScope public interface DeviceUnitMapper extends BaseMapper { List queryList(@Param(Constants.WRAPPER) QueryWrapper queryWrapper,@Param("param") HashMap param); diff --git a/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/ReturnTrainingDetailMapper.xml b/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/ReturnTrainingDetailMapper.xml index 66e3d815b..9ccc214e0 100644 --- a/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/ReturnTrainingDetailMapper.xml +++ b/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/ReturnTrainingDetailMapper.xml @@ -17,6 +17,16 @@ LEFT JOIN team_info b ON a.team_id = b.id LEFT JOIN department_info c ON a.department_id = c.id LEFT JOIN worker_type wt ON b.worker_type_id = wt.id + where 1=1 + + and etr.id is null + + + and etr.is_pass = 1 + + + and etr.is_pass = 0 + )t ${ew.customSqlSegment} diff --git a/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/WorkerAdmissionDetailMapper.xml b/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/WorkerAdmissionDetailMapper.xml index 6ffeb381e..cb9044d32 100644 --- a/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/WorkerAdmissionDetailMapper.xml +++ b/src/main/java/com/zhgd/xmgl/modules/baotou/mapper/xml/WorkerAdmissionDetailMapper.xml @@ -25,6 +25,7 @@ tr.score, if(wi.id is null,0,1) as is_import ,tr.id as record_id + ,tr.is_new_batch from worker_admission_detail t left join worker_admission wa on wa.id=t.worker_admission_id left join enterprise_info ei1 on ei1.id=t.epc_cbs @@ -42,7 +43,7 @@ left join exam_train_record tr on tr.application_id=wa.id and t.id_card=tr.worker_card and tr.application_type=1 - and tr.is_new_batch=1 and tr.submit = 1 + and tr.submit = 1 left join ( @@ -53,13 +54,22 @@ #{item} - - - and t.worker_name = #{param.eqWorkerName} - - )t - ${ew.customSqlSegment} - + + + and t.worker_name = #{param.eqWorkerName} + + + and tr.id is null + + + and tr.is_pass = 1 + + + and tr.is_pass = 0 + + )t + ${ew.customSqlSegment} + select t.id - ,count(distinct etr.worker_card) qualifierNum + ,count(distinct etr.worker_card) examQualifierNum from worker_admission t join exam_train_record etr on etr.application_id=t.id where t.id in diff --git a/src/main/java/com/zhgd/xmgl/modules/baotou/service/impl/WorkerAdmissionDetailServiceImpl.java b/src/main/java/com/zhgd/xmgl/modules/baotou/service/impl/WorkerAdmissionDetailServiceImpl.java index eec0027bf..a5ec41831 100644 --- a/src/main/java/com/zhgd/xmgl/modules/baotou/service/impl/WorkerAdmissionDetailServiceImpl.java +++ b/src/main/java/com/zhgd/xmgl/modules/baotou/service/impl/WorkerAdmissionDetailServiceImpl.java @@ -22,6 +22,7 @@ import com.zhgd.xmgl.modules.exam.service.IExamTrainRecordService; import com.zhgd.xmgl.modules.worker.entity.*; import com.zhgd.xmgl.modules.worker.mapper.UfaceDevMapper; import com.zhgd.xmgl.modules.worker.service.*; +import com.zhgd.xmgl.util.FlowUtil; import com.zhgd.xmgl.util.MapBuilder; import com.zhgd.xmgl.util.PageUtil; import com.zhgd.xmgl.util.RefUtil; @@ -33,6 +34,7 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.util.*; +import java.util.function.Function; import java.util.stream.Collectors; /** @@ -70,6 +72,15 @@ public class WorkerAdmissionDetailServiceImpl extends ServiceImpl queryPageList(HashMap param) { @@ -286,6 +297,7 @@ public class WorkerAdmissionDetailServiceImpl extends ServiceImpl idCardMap = detailList.stream().collect(Collectors.toMap(WorkerAdmissionDetail::getIdCard, Function.identity(), (o1, o2) -> o1)); existDepartmentInfos.addAll(addDepartments); for (WorkerInfo addWorker : addWorkers) { try { @@ -300,6 +312,21 @@ public class WorkerAdmissionDetailServiceImpl extends ServiceImpl queryPageList(HashMap param) { @@ -155,6 +161,7 @@ public class WorkerAdmissionServiceImpl extends ServiceImpl map) { String instanceId = FlowUtil.getString(map, "instanceId"); + String startUser = FlowUtil.getString(map, "startUser"); // HistoricProcessInstance historicProcessInstance = historyService.createHistoricProcessInstanceQuery().processInstanceId(instanceId).singleResult(); // Date approvalTime = historicProcessInstance.getEndTime(); Long certificateIssuingUnit = FlowUtil.getPullDownLong(map, "certificateIssuingUnit"); @@ -174,6 +181,10 @@ public class WorkerAdmissionServiceImpl extends ServiceImpl workerTypeList = dictionaryItemService.getDictList("bt_worker_type", projectSn); if (map.get("details") != null) { if (map.get("details") instanceof List) { + List applyUsers = systemUserService.getProjectChildernSystemUserList(new MapBuilder() + .put("userId", startUser) + .put("projectSn", projectSn) + .build()); // List nums = workerAdmissionDetailService.list(new LambdaQueryWrapper() // .eq(WorkerAdmissionDetail::getProjectSn, projectSn) // .eq(WorkerAdmissionDetail::getIsCertificateQualified, 1) @@ -183,12 +194,18 @@ public class WorkerAdmissionServiceImpl extends ServiceImpl readNums = detailsList.stream().map(o -> MapUtils.getString(((Map) o), "field8425114066876")).collect(Collectors.toList()); List nums = workerInfoService.list(new LambdaQueryWrapper() .in(WorkerInfo::getNum, readNums).eq(WorkerInfo::getProjectSn, projectSn).last(Cts.IGNORE_DATA_SCOPE_CONDITION)).stream().map(WorkerInfo::getNum).collect(Collectors.toList()); + if (applyUsers.size() > 0) { + nums.remove(applyUsers.get(0).getNum()); + } // List existDetailIdCards = workerAdmissionDetailService.list(new LambdaQueryWrapper() // .in(WorkerAdmissionDetail::getIdCard, idCards) // .eq(WorkerAdmissionDetail::getIsCertificateQualified, 1) // .eq(WorkerAdmissionDetail::getProjectSn, projectSn)).stream().map(WorkerAdmissionDetail::getIdCard).collect(Collectors.toList()); List existWorkerIdCards = workerInfoService.list(new LambdaQueryWrapper() .in(WorkerInfo::getIdCard, idCards).eq(WorkerInfo::getProjectSn, projectSn).last(Cts.IGNORE_DATA_SCOPE_CONDITION)).stream().map(WorkerInfo::getIdCard).collect(Collectors.toList()); + if (applyUsers.size() > 0) { + existWorkerIdCards.remove(applyUsers.get(0).getIdCard()); + } // existDetailIdCards.addAll(existWorkerIdCards); existWorkerIdCards.stream().distinct(); for (Object o : detailsList) { @@ -385,6 +402,14 @@ public class WorkerAdmissionServiceImpl extends ServiceImpl> list = ExcelUtils.jxlExlToList(is, 0); + list = list.stream().filter(o -> { + for (Map.Entry entry : o.entrySet()) { + if (StrUtil.isNotBlank(entry.getValue())) { + return true; + } + } + return false; + }).collect(Collectors.toList()); if (list == null || list.size() == 0) { throw new OpenAlertException(MessageUtil.get("excelNotDataErr")); } diff --git a/src/main/java/com/zhgd/xmgl/modules/exam/controller/ExamWorkerController.java b/src/main/java/com/zhgd/xmgl/modules/exam/controller/ExamWorkerController.java index 035415f6c..2706c09d9 100644 --- a/src/main/java/com/zhgd/xmgl/modules/exam/controller/ExamWorkerController.java +++ b/src/main/java/com/zhgd/xmgl/modules/exam/controller/ExamWorkerController.java @@ -7,6 +7,7 @@ import cn.hutool.core.util.IdUtil; import cn.hutool.core.util.NumberUtil; import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.ZipUtil; +import cn.hutool.http.HttpUtil; import com.alibaba.fastjson2.JSON; import com.alibaba.fastjson2.JSONArray; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; @@ -220,17 +221,17 @@ public class ExamWorkerController { BigDecimal total = NumberUtil.mul(list.size(), score); if (key == 1) { params.put("t1", typeArr[++typeIndex] + "、单选题:(每题" + score + "分,共计" + total + "分)"); - addOption(list, content, i, imageMap); + addOption(list, content, i, imageMap, params); params.put("c1", content.toString()); } else if (key == 2) { params.put("t2", typeArr[++typeIndex] + "、多选题:(每题" + one.getScore() + "分,共计" + total + "分、漏选少选得" + NumberUtil.div(one.getScore(), 2, 2) + "分,错选不得分。)"); //遍历题目 - addOption(list, content, i, imageMap); + addOption(list, content, i, imageMap, params); params.put("c2", content.toString()); } else { params.put("t3", typeArr[++typeIndex] + "、判断题(每题" + one.getScore() + "分,共" + total + "分,正确:打√,错误:打×)"); //遍历题目 - addOption(list, content, i, imageMap); + addOption(list, content, i, imageMap, params); params.put("c3", content.toString()); } } @@ -243,8 +244,8 @@ public class ExamWorkerController { params.put("score", record.getScore()); params.put("startExamTime", DateUtil.format(record.getStartExamTime(), "yyyy年MM月dd日")); - String tempUrl = Fileutils.getExportTemplateFile("template/下载试卷模板.docx").getAbsolutePath(); -// String tempUrl = "C:\\Users\\Administrator\\Desktop\\下载试卷模板.docx"; +// String tempUrl = Fileutils.getExportTemplateFile("template/下载试卷模板.docx").getAbsolutePath(); + String tempUrl = "C:\\Users\\Administrator\\Desktop\\下载试卷模板.docx"; //生成word文档流 EasyPoiUtil.exportNewLineWord(response, params, FileUtil.file(tempUrl)); @@ -344,17 +345,17 @@ public class ExamWorkerController { BigDecimal total = NumberUtil.mul(volist.size(), score); if (key == 1) { params.put("t1", typeArr[++typeIndex] + "、单选题:(每题" + score + "分,共计" + total + "分)"); - addOption(volist, content, i, imageMap); + addOption(volist, content, i, imageMap, params); params.put("c1", content.toString()); } else if (key == 2) { params.put("t2", typeArr[++typeIndex] + "、多选题:(每题" + one.getScore() + "分,共计" + total + "分、漏选少选得" + NumberUtil.div(one.getScore(), 2, 2) + "分,错选不得分。)"); //遍历题目 - addOption(volist, content, i, imageMap); + addOption(volist, content, i, imageMap, params); params.put("c2", content.toString()); } else { params.put("t3", typeArr[++typeIndex] + "、判断题(每题" + one.getScore() + "分,共" + total + "分,正确:打√,错误:打×)"); //遍历题目 - addOption(volist, content, i, imageMap); + addOption(volist, content, i, imageMap, params); params.put("c3", content.toString()); } } @@ -401,8 +402,9 @@ public class ExamWorkerController { * @param content * @param i * @param imageMap + * @param params */ - private void addOption(List list, StringBuilder content, int[] i, HashMap imageMap) { + private void addOption(List list, StringBuilder content, int[] i, HashMap imageMap, Map params) { //遍历题目 for (ExamQuestionBankVo question : list) { content.append(" ").append(i[0]).append("、"); @@ -411,18 +413,26 @@ public class ExamWorkerController { JSONArray ja = JSON.parseArray(question.getPic()); if (CollUtil.isNotEmpty(ja)) { //保存图片占位符 - /*try { - String imageKey = "image" + i[0]; - imageMap.put(imageKey, EasyPoiUtil.imgFormatting(PathUtil.getBasePath() + "/" + ja.getJSONObject(0).getString("url"), 18, 18)); - content.append("{{" + imageKey + "}}"); - } catch (Exception e) { - log.error("导出word添加题目和选项错误", e); - }*/ +// try { +// String imageKey = "image" + i[0]; +// String url = ja.getJSONObject(0).getString("url"); +// String dest = PathUtil.getBasePath() + "/temp/" + IdUtil.randomUUID() + "." + StrUtil.subAfter(url, ".", true); +// HttpUtil.downloadFile(url, dest); +// imageMap.put(imageKey, EasyPoiUtil.imgFormatting(dest, 18, 18)); +// content.append("{{" + imageKey + "}}"); +// params.put(imageKey, imageMap.get(imageKey)); +// } catch (Exception e) { +// log.error("导出word添加题目和选项错误", e); +// } } } - - content.append(question.getQuestionName().replaceAll("[((]\\s*?[))]", "( " - + (question.getType() != 3 ? question.getSelectOption() : (Objects.equals(question.getSelectOption(), "对") ? "√" : "×")) + " )")).append("\n"); + String selectOption = question.getSelectOption(); + if (Objects.equals(question.getSelectOption(), "对")) { + selectOption = "√"; + } else if (Objects.equals(question.getSelectOption(), "错")) { + selectOption = "×"; + } + content.append(question.getQuestionName().replaceAll("[((]\\s*?[))]", "( " + selectOption + " )")).append("\n"); if (question.getType() == 3) { continue; } diff --git a/src/main/java/com/zhgd/xmgl/modules/exam/service/impl/ExamTrainRecordServiceImpl.java b/src/main/java/com/zhgd/xmgl/modules/exam/service/impl/ExamTrainRecordServiceImpl.java index 1c8f25f9f..2b9b70821 100644 --- a/src/main/java/com/zhgd/xmgl/modules/exam/service/impl/ExamTrainRecordServiceImpl.java +++ b/src/main/java/com/zhgd/xmgl/modules/exam/service/impl/ExamTrainRecordServiceImpl.java @@ -135,7 +135,8 @@ public class ExamTrainRecordServiceImpl extends ServiceImpl Objects.equals(o.getSubmit(), 0)).sorted((o1, o2) -> o2.getCreateTime().compareTo(o1.getCreateTime())).findFirst().map(o -> o).orElse(null); if (notSubmit == null) { - throw new OpenAlertException("您已提交试卷"); + //您已提交试卷 + return rs.stream().filter(o -> Objects.equals(o.getSubmit(), 1)).sorted((o1, o2) -> o2.getCreateTime().compareTo(o1.getCreateTime())).findFirst().map(o -> o).orElse(null); } ExamTrainRecord submit = rs.stream().filter(o -> Objects.equals(o.getSubmit(), 1) && Objects.equals(o.getIsNewBatch(), 1)).sorted((o1, o2) -> o2.getCreateTime().compareTo(o1.getCreateTime())).findFirst().map(o -> o).orElse(null); if (submit == null) { @@ -319,11 +320,14 @@ public class ExamTrainRecordServiceImpl extends ServiceImpl 0) { - admissionDetail = details.get(0); - typeName = admissionDetail.getPostWorkTypeName(); + admissionDetail = details.stream().filter(o -> Objects.equals(o.getIsCertificateQualified(), 1)).findFirst().map(o -> o).orElse(null); + if (admissionDetail != null) { + typeName = admissionDetail.getPostWorkTypeName(); + } else { + throw new OpenAlertException("人员资质不合格"); + } } else { throw new OpenAlertException("人员在人员入场中不存在"); } diff --git a/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerContract.java b/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerContract.java index 8e07e0473..cdf2d058c 100644 --- a/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerContract.java +++ b/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerContract.java @@ -22,8 +22,8 @@ import io.swagger.annotations.ApiModelProperty; @ApiModel(value="WorkerContract实体类",description="WorkerContract") public class WorkerContract implements Serializable { private static final long serialVersionUID = 1L; - - /**合同表*/ + + /**合同表*/ @TableId(type = IdType.ASSIGN_ID) @ApiModelProperty(value="合同表") private java.lang.Long id ; @@ -58,7 +58,6 @@ public class WorkerContract implements Serializable { /**人员ID*/ @Excel(name = "人员ID", width = 15) @ApiModelProperty(value="人员ID") - private java.lang.Long workerId ; /**签订状态(0.未签订 1.已签订)*/ @Excel(name = "签订状态(0.未签订 1.已签订)", width = 15) diff --git a/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerPhysicals.java b/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerPhysicals.java index a7cc7d1a1..d4cab2af5 100644 --- a/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerPhysicals.java +++ b/src/main/java/com/zhgd/xmgl/modules/worker/entity/WorkerPhysicals.java @@ -22,7 +22,7 @@ import io.swagger.annotations.ApiModelProperty; @ApiModel(value="WorkerPhysicals实体类",description="WorkerPhysicals") public class WorkerPhysicals implements Serializable { private static final long serialVersionUID = 1L; - + /**id*/ @TableId(type = IdType.ASSIGN_ID) @ApiModelProperty(value="id") @@ -30,7 +30,6 @@ public class WorkerPhysicals implements Serializable { /**人员Id*/ @Excel(name = "人员Id", width = 15) @ApiModelProperty(value="人员Id") - private java.lang.Long workerId ; /**项目唯一标识*/ @Excel(name = "项目唯一标识", width = 15) @@ -50,14 +49,24 @@ public class WorkerPhysicals implements Serializable { private java.lang.String personWeight ; /**体检时间*/ @Excel(name = "体检时间", width = 15) - @ApiModelProperty(value="体检时间") - private java.lang.String physicalsTime ; - /**状态,1未体检,2体检合格,3体检不合格*/ - @Excel(name = "状态,1未体检,2体检合格,3体检不合格", width = 15) - @ApiModelProperty(value="状态,1未体检,2体检合格,3体检不合格") - private java.lang.Integer state ; - /**结论*/ - @Excel(name = "结论", width = 15) - @ApiModelProperty(value="结论") - private java.lang.String conclusion ; + @ApiModelProperty(value = "体检时间") + private java.lang.String physicalsTime; + /** + * 状态,1未体检,2体检合格,3体检不合格 + */ + @Excel(name = "状态,1未体检,2体检合格,3体检不合格", width = 15) + @ApiModelProperty(value = "状态,1未体检,2体检合格,3体检不合格") + private java.lang.Integer state; + /** + * 结论 + */ + @Excel(name = "结论", width = 15) + @ApiModelProperty(value = "结论") + private java.lang.String conclusion; + /** + * 附件 + */ + @Excel(name = "附件", width = 15) + @ApiModelProperty(value = "附件") + private java.lang.String attachment; } diff --git a/src/main/java/com/zhgd/xmgl/modules/worker/mapper/xml/WorkerInfoMapper.xml b/src/main/java/com/zhgd/xmgl/modules/worker/mapper/xml/WorkerInfoMapper.xml index f69523ddf..706ac2e40 100644 --- a/src/main/java/com/zhgd/xmgl/modules/worker/mapper/xml/WorkerInfoMapper.xml +++ b/src/main/java/com/zhgd/xmgl/modules/worker/mapper/xml/WorkerInfoMapper.xml @@ -53,6 +53,9 @@ LEFT JOIN device_unit du on du.id=a.work_area WHERE 1 = 1 + + and a.num like concat('%', #{param.num},'%') + and ( wt.type_name = '电工' or wt.type_name = '电焊工' or @@ -1216,7 +1219,7 @@ ru.rule_name ,if(a.person_type=1,wt.type_name,c.department_name) as post_work_type_name ,du.device_unit_name as work_area_name - ,ei1.enterprise_name as epc_cbs + ,ei1.enterprise_name as epc_cbs_name from worker_info a INNER JOIN project p ON a.project_sn = p.project_sn LEFT JOIN team_info b ON a.team_id = b.id diff --git a/src/main/java/com/zhgd/xmgl/util/FlowUtil.java b/src/main/java/com/zhgd/xmgl/util/FlowUtil.java index 99ba9f8d3..e88c8709e 100644 --- a/src/main/java/com/zhgd/xmgl/util/FlowUtil.java +++ b/src/main/java/com/zhgd/xmgl/util/FlowUtil.java @@ -4,6 +4,7 @@ import cn.hutool.core.convert.Convert; import cn.hutool.core.date.DateUtil; import cn.hutool.core.util.StrUtil; import com.alibaba.fastjson.JSON; +import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONObject; import org.apache.commons.collections.MapUtils; import org.apache.commons.lang3.StringUtils; @@ -191,4 +192,24 @@ public class FlowUtil { formData.putAll(formData1); } + /** + * 拼接星号前端url,文件名称*文件路径,如image 1499@2x.png*67adc25d35f0f51e0803cc80.png,多个,分割 + * + * @param json + * @return + */ + public static String buildXingUrl(String json) { + StringBuilder url = new StringBuilder(); + JSONArray ja = JSON.parseArray(json); + for (int i = 0; i < ja.size(); i++) { + JSONObject jo = ja.getJSONObject(i); + if (i != 0) { + url.append(","); + } + url.append(jo.getString("name")); + url.append("*"); + url.append(jo.getString("url")); + } + return url.toString(); + } } diff --git a/src/main/resources/application-gsx-t-dev.properties b/src/main/resources/application-gsx-t-dev.properties index a891ac4f6..0d617cf7c 100644 --- a/src/main/resources/application-gsx-t-dev.properties +++ b/src/main/resources/application-gsx-t-dev.properties @@ -81,4 +81,4 @@ magic-api.resource.location=D:/jxj/prod/backEnd/itbgpImage/data/magic-api #上传的图片的url前缀 upload.image.url.prefix=${spring.file-storage.minio[0].domain} wordExcelUrl=http://192.168.34.133:5173/#/canvasEditor -defaultProjectSn=BD3137498CB84BF0969979E0342CDBCA +defaultProjectSn=5B8B3DB047214AE188F2C7916DD08203 diff --git a/src/main/resources/template/下载试卷模板.docx b/src/main/resources/template/下载试卷模板.docx index 2c9903d21..f424f309e 100644 --- a/src/main/resources/template/下载试卷模板.docx +++ b/src/main/resources/template/下载试卷模板.docx @@ -4,4 +4,164 @@ {{c2}} {{t3}} {{c3}} + +{{c4}} +{{c4}} +5555555 +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}} +{{c4}}