|
@@ -45,12 +45,6 @@ public class HotelServiceImpl extends ServiceImpl<HotelMapper, HotelEntity> impl
|
|
|
@Override
|
|
|
public Result search(HotelPageDto param) {
|
|
|
|
|
|
- Long roleId = iBaseService.getRoleId();
|
|
|
- log.info("角色id: {}", roleId);
|
|
|
- BaseRuntimeException.isNull(roleId, null,"请联系系统管理员授权");
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
BaseUtil.startPage(param);
|
|
|
IPage<HotelEntity> page = new Page<>(param.getPageNum() , param.getPageSize());
|
|
|
|
|
@@ -73,6 +67,10 @@ public class HotelServiceImpl extends ServiceImpl<HotelMapper, HotelEntity> impl
|
|
|
Integer isAdmin = iBaseService.getIsAdmin();
|
|
|
if (isAdmin != 1){
|
|
|
log.info("非管理员查询");
|
|
|
+ Long roleId = iBaseService.getRoleId();
|
|
|
+ log.info("角色id: {}", roleId);
|
|
|
+ BaseRuntimeException.isNull(roleId, null,"请联系系统管理员授权");
|
|
|
+
|
|
|
List<String> hotelIds = roleService.getScopeById(roleId);
|
|
|
log.info("酒店id: {}", hotelIds);
|
|
|
wrapper.in(HotelEntity::getId, hotelIds);
|