!1108 【代码优化】排序:字段驼峰改为下划线

Merge pull request !1108 from jinmh/master
This commit is contained in:
芋道源码 2024-10-27 07:11:27 +00:00 committed by Gitee
commit a57396aa4c
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ public class MyBatisUtils {
// 排序字段
if (!CollectionUtil.isEmpty(sortingFields)) {
page.addOrder(sortingFields.stream().map(sortingField -> SortingField.ORDER_ASC.equals(sortingField.getOrder()) ?
OrderItem.asc(sortingField.getField()) : OrderItem.desc(sortingField.getField()))
OrderItem.asc(StrUtil.toUnderlineCase(sortingField.getField())) : OrderItem.desc(StrUtil.toUnderlineCase(sortingField.getField())))
.collect(Collectors.toList()));
}
return page;