试试
sql:xml判断问题
<if test="obj.userType != null and obj.userType != ''">
and spi.user_type = #{ obj.userType}
</if>
当userType的类型是integer类型时,参数为0时会 ==' '条件会成立
解决办法:
删除:1:obj.userType != '' 2:<if test= "userType!= null and userType!='' or userType== 0">
1:object转换成java对象
JSONObject object = JSONObject.parseObject(req);
JSONObject chat_info = (JSONObject)object.get("chat_info");
GroupChatDTO groupChatDTO = chat_info.toJavaObject(GroupChatDTO.class);
注:使用的jar包是fastjson
前后端时间传输问题:
@DateFormat 起作用, 后端传前端@JsonFormat起作用
企业微信启动是添加so包,并且使用新的启动命令:
nohup java -Djava.library.path=/home/solib/ -jar renren-admin.jar &
2:字符串匹配问题
String address1 = address.replace("|","");
String address2 =address1.replaceAll(" ","");
String address3 =address2.replaceAll(" ","");
String address4 =address3.replaceAll("\"","");
3.文件路径问题
4.引入的第三方jar包idea可以运行,jar包无法运行
修改pom文件:
<build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <configuration> <includeSystemScope>true</includeSystemScope> </configuration> </plugin> </plugins> </build>