diff --git a/cash-api/account-server/src/main/java/com/czg/controller/user/UShopInfoController.java b/cash-api/account-server/src/main/java/com/czg/controller/user/UShopInfoController.java index f7496a624..b413caab7 100644 --- a/cash-api/account-server/src/main/java/com/czg/controller/user/UShopInfoController.java +++ b/cash-api/account-server/src/main/java/com/czg/controller/user/UShopInfoController.java @@ -3,10 +3,13 @@ package com.czg.controller.user; import com.czg.account.dto.shopinfo.ShopInfoByCodeDTO; import com.czg.account.dto.shopinfo.ShopInfoDetailDTO; import com.czg.account.dto.shopinfo.ShopInfoSubVO; +import com.czg.account.entity.ShopTable; import com.czg.account.service.ShopInfoService; +import com.czg.account.service.ShopTableService; import com.czg.resp.CzgResult; import com.czg.sa.StpKit; import com.mybatisflex.core.paginate.Page; +import com.mybatisflex.core.query.QueryWrapper; import jakarta.annotation.Resource; import jakarta.validation.constraints.NotEmpty; import org.springframework.web.bind.annotation.GetMapping; @@ -23,6 +26,8 @@ import org.springframework.web.bind.annotation.RestController; public class UShopInfoController { @Resource private ShopInfoService shopInfoService; + @Resource + private ShopTableService shopTableService; /** * 桌码换取详细店铺信息 @@ -33,6 +38,15 @@ public class UShopInfoController { return CzgResult.success(shopInfoService.getByCode(tableCode, lat, lng, true)); } + /** + * 桌码获取详细台桌信息 + * @return 台桌信息 + */ + @GetMapping("/tableInfo") + public CzgResult getTableInfo(@RequestParam String tableCode) { + return CzgResult.success(shopTableService.getOne(new QueryWrapper().eq(ShopTable::getTableCode, tableCode))); + } + /** * 获取店铺详细信息 * @return 店铺信息