Code遇见的错误
遇见的错误,费时间的,又离谱
QingHuaiBuShuai
这个作者很懒,什么都没留下…
展开
-
【Java 】|获取当前日期,若月份和天不足两位时前面补0
import java.util.Date;import java.util.Calendar;import java.text.SimpleDateFormat;import org.apache.commons.lang3.StringUtils;public class Test{ public static void main(String[] args) throws Exception { SimpleDateFormat simpleDateFormat =.原创 2021-12-29 10:04:25 · 2382 阅读 · 1 评论 -
null转换为想要的格式
/** * 将null转换为0.0 * * @param obj * @return */public static Double nvd(Object obj) { return (obj == null || "null".equals(obj)) ? 0.0 : Double.valueOf(obj.toString().trim());}/** * 将null转换为"" * * @param obj * @return .原创 2021-12-16 10:35:56 · 851 阅读 · 0 评论 -
BigDecimal , double 转换
BigDecimal offsetAmount = (BigDecimal) cj.get(i).get("xxxx");double offsetAmount = offsetAmount.doubleValue();BigDecimal直接返回给前台还不行,得转成double不清楚为什么。原创 2021-12-16 10:38:23 · 333 阅读 · 0 评论 -
layui计算行总和
项目layui版本太低(2.2.5),一些东西是真滴麻烦。 var tableIns = table .render({ elem: '#overallCostTable', url: ctx + '/*****', where: { "applyDate": $("#applyDate").val()原创 2021-12-16 11:09:30 · 1445 阅读 · 0 评论 -
安装父模块时,自动跳过聚合的子模块,不安装子模块
安装父模块时,死活不扫描子模块,也成功聚合了,最后发现是Idea设置的错误。默认是选上的,我的不知道为啥没选上,淦!原创 2021-07-31 19:12:17 · 96 阅读 · 0 评论 -
Maven使用tomcat插件debug报错
tomcat插件 Run 正常 Debug启动就报No valid Maven installation found. Either set the home directory in the configuration dialog or set the M2_HOME environment variable on your system.网上说的仓库位置没配对,我的是对的。最后发现是这里设置错误了,改成下图设置就可以了,离谱。...原创 2021-07-31 19:08:21 · 145 阅读 · 0 评论