|
|
@@ -0,0 +1,51 @@
|
|
|
+package org.jeecg.modules.rooms.controller;
|
|
|
+
|
|
|
+
|
|
|
+import io.swagger.annotations.Api;
|
|
|
+import io.swagger.annotations.ApiOperation;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.apache.commons.lang3.StringUtils;
|
|
|
+import org.jeecg.common.Enum.ResultCode;
|
|
|
+import org.jeecg.common.api.vo.Result;
|
|
|
+import org.jeecg.modules.rooms.entity.CesMealCoupon;
|
|
|
+import org.jeecg.modules.rooms.service.CesMealCouponServiceImpl;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+
|
|
|
+import org.springframework.stereotype.Controller;
|
|
|
+import org.springframework.web.bind.annotation.RequestParam;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+import javax.annotation.Resource;
|
|
|
+
|
|
|
+/**
|
|
|
+ * <p>
|
|
|
+ * 餐卷设置 前端控制器
|
|
|
+ * </p>
|
|
|
+ *
|
|
|
+ * @author fendo
|
|
|
+ * @since 2023-03-14
|
|
|
+ */
|
|
|
+@RestController
|
|
|
+@RequestMapping("/rooms/cesMealCoupon")
|
|
|
+@Api(tags = "ces_all_day_price_rule")
|
|
|
+@Slf4j
|
|
|
+public class CesMealCouponController {
|
|
|
+
|
|
|
+ @Resource
|
|
|
+ private CesMealCouponServiceImpl mealCouponService;
|
|
|
+
|
|
|
+ @ApiOperation(value="餐券查询", notes="餐券查询")
|
|
|
+ @GetMapping("/fetch")
|
|
|
+ public Result fetch(@RequestParam String hotelId){
|
|
|
+ if(StringUtils.isBlank(hotelId)){
|
|
|
+ return Result.error(ResultCode.PARAM_MISS);
|
|
|
+ }
|
|
|
+ try{
|
|
|
+ return mealCouponService.fetch(hotelId);
|
|
|
+ }catch (Exception e){
|
|
|
+ return Result.error(e.getMessage());
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|