Selaa lähdekoodia

店铺问答讨论优化

dujian 3 kuukautta sitten
vanhempi
commit
2b449e71bb

+ 3 - 2
alien-store-platform/src/main/java/shop/alien/storeplatform/service/impl/StorePlatformDiscussionServiceImpl.java

@@ -57,8 +57,9 @@ public class StorePlatformDiscussionServiceImpl extends ServiceImpl<StorePlatfor
         IPage<StorePlatformDiscussion> replyPage = this.page(page, new LambdaQueryWrapper<StorePlatformDiscussion>()
                 .eq(StorePlatformDiscussion::getRootId, rootId)
                 .ne(StorePlatformDiscussion::getId, rootId) // 排除主贴本身
-                .orderByAsc(StorePlatformDiscussion::getCreatedTime));
-        
+                .orderByDesc(StorePlatformDiscussion::getCreatedTime));
+//                .orderByAsc(StorePlatformDiscussion::getCreatedTime));
+
         // 3. 转换为VO并补充用户信息
         IPage<StorePlatformDiscussionUserVo> voPage = replyPage.convert(this::convertToVo);
         fillUserInfoBatch(voPage.getRecords());