Эх сурвалжийг харах

培训登记簿样式修改

jingyuanchao 1 жил өмнө
parent
commit
8265cc6d64

+ 3 - 2
soc-modules/soc-modules-core/src/main/java/com/xunmei/core/edu/service/impl/CoreEduTrainingTaskServiceImpl.java

@@ -870,7 +870,8 @@ public class CoreEduTrainingTaskServiceImpl extends ServiceImpl<CoreEduTrainingT
 
     private Map<String, Object> getFtlEdu(CoreEduTrainingTaskDetailVo task) {
         Map<String, Object> data = new HashMap<>();
-        String time = DateUtil.format(task.getTrainingStartDateTime(), "yyyy年MM月dd日HH时mm分");
+        String startTime = DateUtil.format(task.getTrainingStartDateTime(), "yyyy年MM月dd日HH时mm分");
+        String endTime = DateUtil.format(task.getTrainingEndDateTime(), "yyyy年MM月dd日HH时mm分");
         String address = task.getOrgName();
         String hostName = task.getHostName() == null ? StringUtil.EMPTY_STRING : task.getHostName();
         String recorderName = task.getRecorderName() == null ? StringUtil.EMPTY_STRING : task.getRecorderName();
@@ -878,7 +879,7 @@ public class CoreEduTrainingTaskServiceImpl extends ServiceImpl<CoreEduTrainingT
         String note = task.getNote();
         String prefixPath = RemoteCallHandlerExecutor.executeRemoteCall(() -> fileService.getLocalPathPrefix(), ErrorMsgConstants.QUERY_FILE_PATH_ERROR).getData();
         String staticsPath = RemoteCallHandlerExecutor.executeRemoteCall(() -> fileService.getStaticPathPrefix(), ErrorMsgConstants.QUERY_FILE_PATH_ERROR).getData();
-        data.put("time", StringUtils.isNotEmpty(time) ? time : StringUtil.EMPTY_STRING);
+        data.put("time", startTime + " - " + endTime);
         data.put("address", StringUtils.isNotEmpty(address) ? address : StringUtil.EMPTY_STRING);
         data.put("hostName", StringUtils.isNotEmpty(hostName) ? hostName : StringUtil.EMPTY_STRING);
         data.put("recorderName", StringUtils.isNotEmpty(recorderName) ? recorderName : StringUtil.EMPTY_STRING);

+ 2 - 2
soc-modules/soc-modules-file/src/main/java/com/xunmei/file/utils/PdfUtil.java

@@ -184,9 +184,9 @@ public class PdfUtil {
     public static void dealEduBody(Document document, PdfPTable table, Font tableFont, Map<String, Object> data) throws Exception {
         //第一行
         createPDFCell(tableFont, table, "时间", Element.ALIGN_MIDDLE, 1, 1);
-        createPDFCell(tableFont, table, data.get("time").toString(), Element.ALIGN_MIDDLE, 2, 1);
+        createPDFCell(tableFont, table, data.get("time").toString(), Element.ALIGN_LEFT, 5, 1);
         createPDFCell(tableFont, table, "地点", Element.ALIGN_MIDDLE, 1, 1);
-        createPDFCell(tableFont, table, data.get("address").toString(), Element.ALIGN_MIDDLE, 2, 1);
+        createPDFCell(tableFont, table, data.get("address").toString(), Element.ALIGN_MIDDLE, 5, 1);
         //第二行
         createPDFCell(tableFont, table, "主持人", Element.ALIGN_MIDDLE, 1, 1);
         createPDFCell(tableFont, table, data.get("hostName").toString(), Element.ALIGN_MIDDLE, 2, 1);