新增桌码绑定接口

This commit is contained in:
2024-10-24 16:29:08 +08:00
parent 4ec0f04cc5
commit 537b9b408b
9 changed files with 75 additions and 7 deletions

View File

@@ -28,4 +28,12 @@ public interface MpShopTableService extends IService<TbShopTable> {
* @return 台桌信息
*/
TbShopTable selectByTableId(String tableId, Integer shopId);
/**
* 根据主键查询台桌
* @param id 主键
* @param shopId 店铺id
* @return 台桌信息
*/
TbShopTable selectById(Integer id, Integer shopId);
}

View File

@@ -37,4 +37,11 @@ public class MpShopTableServiceImpl extends ServiceImpl<MpShopTableMapper, TbSho
.eq(TbShopTable::getShopId, shopId)
.eq(TbShopTable::getQrcode, tableId));
}
@Override
public TbShopTable selectById(Integer id, Integer shopId) {
return getOne(new LambdaQueryWrapper<TbShopTable>()
.eq(TbShopTable::getId, id)
.eq(TbShopTable::getShopId, shopId));
}
}