refactor(shop): 优化商城信息获取和缓存逻辑

- 移除 ShopMainController 中的 debug 日志
- 修改 ShopWebsiteServiceImpl 中的缓存键前缀为 PascalCase
- 删除 ShopWebsiteServiceImpl 中的冗余打印语句
- 删除整个 debug_navigation_data.sql 文件
This commit is contained in:
2025-08-22 15:52:55 +08:00
parent 210efaf470
commit b46341bd32
3 changed files with 2 additions and 112 deletions

View File

@@ -42,6 +42,7 @@ public class ShopMainController extends BaseController {
try {
// 使用专门的商城信息获取方法
ShopVo shopVo = shopWebsiteService.getShopInfo(tenantId);
// log.debug("获取商城信息成功: {}", shopVo);
return success(shopVo);
} catch (IllegalArgumentException e) {
return fail(e.getMessage(), null);

View File

@@ -32,7 +32,7 @@ public class ShopWebsiteServiceImpl implements ShopWebsiteService {
/**
* 商城信息缓存键前缀
*/
private static final String SHOP_INFO_KEY_PREFIX = "shop_info:";
private static final String SHOP_INFO_KEY_PREFIX = "ShopInfo:";
@Override
public ShopVo getShopInfo(Integer tenantId) {
@@ -55,7 +55,6 @@ public class ShopWebsiteServiceImpl implements ShopWebsiteService {
// 直接调用 CMS 服务获取站点信息,然后使用商城专用缓存
ShopVo shopVO = cmsWebsiteService.getSiteInfo(tenantId);
System.out.println("shopVO = " + shopVO);
if (shopVO == null) {
throw new RuntimeException("请先创建商城");
}