| | |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springblade.modules.FTP.FtpUtil; |
| | | import org.springblade.modules.FTP.OutJson; |
| | | import org.springblade.modules.FTP.monitor; |
| | | import org.springblade.modules.apply.entity.Apply; |
| | | import org.springblade.modules.apply.excel.ApplyExcel; |
| | | import org.springblade.modules.apply.excel.ApplyImporter; |
| | |
| | | "'" + "," + "'" + apply.getApplyStatus() + "'" + "," +"'" + apply.getIsExam() + "'" + ");" + |
| | | "update blade_user set is_apply = " + user1.getIsApply() + " " +"where id = " + "'" + user1.getId() + "'"; |
| | | String json = JSON.toJSONString(s); |
| | | OutJson.createJsonFile(json, "d:/", "wsql"); |
| | | String response = String.valueOf((new Date()).getTime()); |
| | | OutJson.createJsonFile(json, "d:/", "w"+response); |
| | | FileInputStream in = null; |
| | | try { |
| | | in = new FileInputStream(new File("D:\\" + fileName)); |
| | | in = new FileInputStream(new File("D:\\" + "w"+response+".json")); |
| | | } catch (FileNotFoundException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | FtpUtil.uploadFile(ftpHost, ftpPort, ftpUserName, ftpPassword, "anbao/", "/", fileName, in); |
| | | FtpUtil.uploadFile(ftpHost, ftpPort, ftpUserName, ftpPassword, "anbao/", "/", "w"+response+".json", in); |
| | | } |
| | | |
| | | |