From 85b73336f6219260a5145815785aa9b88aba340b Mon Sep 17 00:00:00 2001 From: wangpengfei <1928057482@qq.com> Date: Mon, 12 May 2025 14:08:58 +0800 Subject: [PATCH] xiug --- .../biz/lpkgiftbag/LpkGiftBagService.java | 3 ++ .../biz/lpkgiftcard/LpkGiftCardRest.java | 52 +++++++++++-------- .../biz/lpkgiftcard/LpkGiftCardService.java | 11 ++-- .../yythmall/biz/scheduled/scheduledRest.java | 12 ++--- 4 files changed, 45 insertions(+), 33 deletions(-) diff --git a/src/main/java/com/yxt/yythmall/biz/lpkgiftbag/LpkGiftBagService.java b/src/main/java/com/yxt/yythmall/biz/lpkgiftbag/LpkGiftBagService.java index c2afb3a..d6716c8 100644 --- a/src/main/java/com/yxt/yythmall/biz/lpkgiftbag/LpkGiftBagService.java +++ b/src/main/java/com/yxt/yythmall/biz/lpkgiftbag/LpkGiftBagService.java @@ -101,6 +101,9 @@ public class LpkGiftBagService extends MybatisBaseService goodsList = dto.getGoods(); diff --git a/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardRest.java b/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardRest.java index f893f94..aa28379 100644 --- a/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardRest.java +++ b/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardRest.java @@ -36,21 +36,25 @@ public class LpkGiftCardRest { public ResultBean wxBindMobile(@RequestBody BindCardDto bindCardDto) { return lpkGiftCardService.bindCard(bindCardDto); } + @PostMapping("/bindAllCard") @ApiOperation(value = "客户绑定礼包卡") public ResultBean bindAllCard(@RequestBody BindCardDto bindCardDto) { return lpkGiftCardService.bindAllCard(bindCardDto); } + @PostMapping("/gifCardByCustomerSid") @ApiOperation(value = "获取客户绑定的礼包卡") public ResultBean gifCardByCustomerSid(@RequestBody PagerQuery query) { return lpkGiftCardService.getGifCardByCustomerSid(query); } + @PostMapping("/gifCardsByCustomerSid") @ApiOperation(value = "获取客户绑定的礼包卡") public ResultBean gifCardsByCustomerSid(@RequestBody PagerQuery query) { return lpkGiftCardService.getGifCardsByCustomerSid(query); } + @GetMapping("/isSaturAndSun/{cardSid}") @ApiOperation(value = "获取时间段的周六日") public ResultBean isSaturAndSun(@PathVariable("cardSid") String cardSid) { @@ -74,15 +78,16 @@ public class LpkGiftCardRest { public ResultBean generateCard(@RequestBody LpkGiftCardDto dto) { return lpkGiftCardService.generateCard(dto); } + @GetMapping("/getCardByBank") @ApiOperation(value = "生成礼包卡信息") - public JSONObject getCardByBank(@RequestParam(value = "pageNo",defaultValue = "1")Integer pageNo, - @RequestParam(value = "pageSize",defaultValue = "8")Integer pageSize, - @RequestParam(value = "printAll",required = false) String printAll, - @RequestParam(value = "end",defaultValue = "") String end, - @RequestParam(value = "start",defaultValue = "") String start) { - PagerQuery pq=new PagerQuery<>(); - LpkGiftCardListQuery q=new LpkGiftCardListQuery(); + public JSONObject getCardByBank(@RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "8") Integer pageSize, + @RequestParam(value = "printAll", required = false) String printAll, + @RequestParam(value = "end", defaultValue = "") String end, + @RequestParam(value = "start", defaultValue = "") String start) { + PagerQuery pq = new PagerQuery<>(); + LpkGiftCardListQuery q = new LpkGiftCardListQuery(); pq.setCurrent(pageNo); pq.setSize(pageSize); @@ -90,11 +95,11 @@ public class LpkGiftCardRest { q.setNoStart(start); pq.setParams(q); - PagerVo p=lpkGiftCardService.getCardByBank(pq).getData(); - JSONObject jsonObject=new JSONObject(); - jsonObject.put("date",p.getRecords()); - jsonObject.put("total",p.getPages()); - jsonObject.put("count",p.getTotal()); + PagerVo p = lpkGiftCardService.getCardByBank(pq).getData(); + JSONObject jsonObject = new JSONObject(); + jsonObject.put("date", p.getRecords()); + jsonObject.put("total", p.getPages()); + jsonObject.put("count", p.getTotal()); return jsonObject; } @@ -129,9 +134,9 @@ public class LpkGiftCardRest { @RequestParam(value = "startDate") String startDate, @RequestParam(value = "endDate") String endDate, @RequestParam(value = "file") MultipartFile file, - HttpServletRequest request, - HttpServletResponse response) throws IOException, ParseException { - return lpkGiftCardService.getExcelInfo(startDate,endDate,file,request,response); + HttpServletRequest request, + HttpServletResponse response) throws IOException, ParseException { + return lpkGiftCardService.getExcelInfo(startDate, endDate, file, request, response); } @@ -143,40 +148,43 @@ public class LpkGiftCardRest { @RequestParam(value = "file") MultipartFile file, HttpServletRequest request, HttpServletResponse response) throws IOException { - return lpkGiftCardService.getExcelInfo3(startDate,endDate,file,request,response); + return lpkGiftCardService.getExcelInfo3(startDate, endDate, file, request, response); } + @ApiOperation("订单门店汇总导出") @PostMapping("/cardStatisticsListExport") - public void cardStatisticsListExport(@RequestBody LpkGiftCardListQuery pq) { + public void cardStatisticsListExport(@RequestBody LpkGiftCardListQuery pq) { lpkGiftCardService.cardStatisticsListExport(pq); } + @ApiOperation("订单门店汇总列表") @PostMapping("/cardStatisticsList") - public ResultBean cardStatisticsList(@RequestBody PagerQuery pq) { + public ResultBean cardStatisticsList(@RequestBody PagerQuery pq) { return lpkGiftCardService.cardStatisticsList(pq); } @ApiOperation("设置是否作废") @GetMapping("/cancelCard/{sid}") - public ResultBean cancelCard(@PathVariable("sid")String sid) { + public ResultBean cancelCard(@PathVariable("sid") String sid) { return lpkGiftCardService.isEnable(sid); } @ApiOperation("提货卡转赠福礼卡") @PostMapping("/cardTransfer") - public ResultBean cardTransfer(String sid) { + public ResultBean cardTransfer(String sid) { return lpkGiftCardService.cardTransfer(sid); } @ApiOperation("共享家庭卡详情") @GetMapping("/cardShareDetail/{sid}") - public ResultBean cardShareDetail(@PathVariable("sid") String sid) { + public ResultBean cardShareDetail(@PathVariable("sid") String sid) { return lpkGiftCardService.cardShareDetail(sid); } + @ApiOperation("共享家庭卡蔬菜详情") @GetMapping("/cardShareGoodsDetail/{sid}") - public ResultBean cardShareGoodsDetail(@PathVariable("sid") String sid) { + public ResultBean cardShareGoodsDetail(@PathVariable("sid") String sid) { return lpkGiftCardService.cardShareGoodsDetail(sid); } diff --git a/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardService.java b/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardService.java index 511038f..daec28c 100644 --- a/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardService.java +++ b/src/main/java/com/yxt/yythmall/biz/lpkgiftcard/LpkGiftCardService.java @@ -161,11 +161,11 @@ public class LpkGiftCardService extends MybatisBaseService reserveDictionaries=new ArrayList<>(); // String nextYear = DateUtil.offsetMonth(new Date(), 12).toString(); // int y = DateUtil.year(DateUtil.parse(nextYear)); @@ -285,7 +285,7 @@ public class scheduledRest { String a ="https://timor.tech/api/holiday/year/"; // RestTemplate restTemplate=new RestTemplate(); // ResponseEntity forEntity = restTemplate.getForEntity(a, String.class); - String s = HttpUtils.sendGet(a, ""); - System.out.println(s); +// String s = HttpUtils.sendGet(a, ""); +// System.out.println(s); } }