prader6

随笔分类 -  工具类

java springBoot +vue 项目配置https 访问
摘要:背景:公司做了一个公众号的网页项目,这个项目主要是用户扫码,填写信息。分为用户端和管理端。后端用的java,前端用的vue,刚开始的时候,是http访问项目。可是,用户反应http 在url 上提示不安全,体验不好,所以吧http 访问改成https。 操作概要: 首先说明一下,公司的服务器(win 阅读全文

posted @ 2020-04-03 13:53 prader6 阅读(6163) 评论(1) 推荐(4) 编辑

日期工具类
摘要:package net.yunxinyong.accesscard.utils; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Calendar; import java.ut 阅读全文

posted @ 2020-02-17 13:55 prader6 阅读(149) 评论(0) 推荐(0) 编辑

求某个时间,距离该天凌晨的毫秒数
摘要:/** * 求某个时间距离这天凌晨的毫秒数 * @param date * @return * @throws ParseException */ public static long getMillonTimes(String date) throws ParseException { long 阅读全文

posted @ 2019-12-31 06:02 prader6 阅读(167) 评论(0) 推荐(0) 编辑

把pdf的内容转化为txt文件
摘要:import org.apache.pdfbox.pdmodel.PDDocument; import org.apache.pdfbox.util.PDFTextStripper; import java.io.File; import java.io.FileOutputStream; impo 阅读全文

posted @ 2019-12-03 16:00 prader6 阅读(603) 评论(0) 推荐(0) 编辑

读取本地word 浏览器下载(设置编码格式)
摘要:String filePath = "C:\\word\\报告.doc"; BufferedWriter bos = null; BufferedReader bis = null; String fileName = year + "年" + month + "报告.doc"; try { cha 阅读全文

posted @ 2019-11-22 18:07 prader6 阅读(398) 评论(0) 推荐(0) 编辑

返回两个时间段内的季度
摘要:参考文章:https://www.cnblogs.com/caoyingjielxq/p/9426972.html public static Date parse(String string, String patern){ SimpleDateFormat simpleDateFormat = 阅读全文

posted @ 2019-11-16 18:13 prader6 阅读(253) 评论(0) 推荐(0) 编辑

springboot项目获取resource下的文件
摘要:代码中的那个excel就在项目的resource(资源文件夹下放着)。 阅读全文

posted @ 2019-08-06 11:20 prader6 阅读(876) 评论(0) 推荐(0) 编辑

postman上传excel,java后台读取excel生成到指定位置进行备份,并且把excel中的数据添加到数据库
摘要:最近要做个前端网页上传excel,数据直接添加到数据库的功能。。在此写个读取excel的demo。 首先新建springboot的web项目 导包,读取excel可以用poi也可以用jxl,这里本文用的是poi poi的 pom依赖如下: service层的实现类为: 上面这个实现类包含两个方法,上 阅读全文

posted @ 2019-07-03 18:28 prader6 阅读(326) 评论(0) 推荐(0) 编辑

postman上传excel,java后台读取excel生成到指定位置进行备份,并且把excel中的数据添加到数据库
摘要:最近要做个前端网页上传excel,数据直接添加到数据库的功能。。在此写个读取excel的demo。 首先新建springboot的web项目 导包,读取excel可以用poi也可以用jxl,这里本文用的是poi poi的 pom依赖如下: service层的实现类为: 上面这个实现类包含两个方法,上 阅读全文

posted @ 2019-07-03 18:28 prader6 阅读(985) 评论(0) 推荐(0) 编辑

导航

点击右上角即可分享
微信分享提示