From a144dec759ca53e72a6421596fda2e92b468084f Mon Sep 17 00:00:00 2001
From: Administrator <admin>
Date: Mon, 02 Aug 2021 11:57:51 +0800
Subject: [PATCH] 数据操作同步监管后台

---
 src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java |   24 ++++++++++++++++++++++++
 1 files changed, 24 insertions(+), 0 deletions(-)

diff --git a/src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java b/src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java
index a25ca85..4ec1800 100644
--- a/src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java
+++ b/src/main/java/org/springblade/modules/apply/service/impl/ApplyServiceImpl.java
@@ -9,10 +9,12 @@
 import net.sourceforge.pinyin4j.format.HanyuPinyinOutputFormat;
 import net.sourceforge.pinyin4j.format.HanyuPinyinToneType;
 import net.sourceforge.pinyin4j.format.exception.BadHanyuPinyinOutputFormatCombination;
+import org.springblade.common.utils.arg;
 import org.springblade.modules.apply.entity.Apply;
 import org.springblade.modules.apply.excel.ApplyExcel;
 import org.springblade.modules.apply.mapper.ApplyMapper;
 import org.springblade.modules.apply.service.ApplyService;
+import org.springblade.modules.apply.vo.ApplyPaPerVO;
 import org.springblade.modules.apply.vo.ApplyVO;
 import org.springblade.modules.exam.entity.ExamPaper;
 import org.springblade.modules.exam.service.ExamPaperService;
@@ -93,6 +95,12 @@
 			apply.setApplyCode(getApplyCode(apply));
 			//插入数据
 			this.save(apply);
+			//内网新增
+			try {
+				arg.test01(arg.url+"/apply/save",apply);
+			} catch (Exception e) {
+				e.printStackTrace();
+			}
 		});
 	}
 
@@ -230,4 +238,20 @@
 		}
 		return pinyinStr;
 	}
+
+	/**
+	 * 获取准考证信息
+	 * @param apply
+	 * @return
+	 */
+	@Override
+	public ApplyPaPerVO getApplyInfo(Apply apply) {
+		ApplyPaPerVO applyPaPerVO = baseMapper.getApplyInfo(apply);
+
+		String time = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(applyPaPerVO.getStartTime()).split(" ")[0];
+		String startTime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(applyPaPerVO.getStartTime()).split(" ")[1];
+		String endTime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(applyPaPerVO.getEndTime()).split(" ")[1];
+		applyPaPerVO.setStringTime(time+" "+startTime.substring(0,startTime.length()-3) +"-"+ endTime.substring(0,endTime.length()-3));
+		return applyPaPerVO;
+	}
 }

--
Gitblit v1.9.3