|
|
@@ -7,11 +7,16 @@ import java.util.stream.Collectors;
|
|
|
import java.io.IOException;
|
|
|
import java.io.UnsupportedEncodingException;
|
|
|
import java.net.URLDecoder;
|
|
|
+import javax.annotation.Resource;
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
import org.jeecg.common.api.vo.Result;
|
|
|
import org.jeecg.common.system.query.QueryGenerator;
|
|
|
import org.jeecg.common.util.oConvertUtils;
|
|
|
+import org.jeecg.modules.business.entity.BusBookingRooms;
|
|
|
+import org.jeecg.modules.business.entity.BusRoomsLivingOrder;
|
|
|
+import org.jeecg.modules.business.service.IBusBookingRoomsService;
|
|
|
+import org.jeecg.modules.business.service.IBusRoomsLivingOrderService;
|
|
|
import org.jeecg.modules.fw.entity.FwLivingJx;
|
|
|
import org.jeecg.modules.fw.service.IFwLivingJxService;
|
|
|
|
|
|
@@ -20,6 +25,8 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
|
|
|
+import org.jeecg.modules.rooms.entity.CesRooms;
|
|
|
+import org.jeecg.modules.rooms.service.CesRoomsServiceImpl;
|
|
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
|
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
|
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
|
|
@@ -50,6 +57,12 @@ import org.apache.shiro.authz.annotation.RequiresPermissions;
|
|
|
public class FwLivingJxController extends JeecgController<FwLivingJx, IFwLivingJxService> {
|
|
|
@Autowired
|
|
|
private IFwLivingJxService fwLivingJxService;
|
|
|
+@Resource
|
|
|
+private IBusRoomsLivingOrderService busRoomsLivingOrderService;
|
|
|
+@Resource
|
|
|
+private IBusBookingRoomsService busBookingRoomsService;
|
|
|
+@Resource
|
|
|
+private CesRoomsServiceImpl cesRoomsService;
|
|
|
|
|
|
/**
|
|
|
* 分页列表查询
|
|
|
@@ -70,6 +83,19 @@ public class FwLivingJxController extends JeecgController<FwLivingJx, IFwLivingJ
|
|
|
QueryWrapper<FwLivingJx> queryWrapper = QueryGenerator.initQueryWrapper(fwLivingJx, req.getParameterMap());
|
|
|
Page<FwLivingJx> page = new Page<FwLivingJx>(pageNo, pageSize);
|
|
|
IPage<FwLivingJx> pageList = fwLivingJxService.page(page, queryWrapper);
|
|
|
+ pageList.getRecords().forEach(t -> {
|
|
|
+ BusRoomsLivingOrder busRoomsLivingOrder = busRoomsLivingOrderService.getById(t.getLivingOrderId());
|
|
|
+ if (busRoomsLivingOrder != null) {
|
|
|
+ BusBookingRooms busBookingRooms = busBookingRoomsService.getById(busRoomsLivingOrder.getBookingRoomId());
|
|
|
+ if (busBookingRooms != null) {
|
|
|
+ t.setRoomId(busBookingRooms.getRoomId());
|
|
|
+ CesRooms cesRooms = cesRoomsService.getById(busBookingRooms.getRoomId());
|
|
|
+ if (cesRooms != null) {
|
|
|
+ t.setRoomName(cesRooms.getName());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
return Result.OK(pageList);
|
|
|
}
|
|
|
|