From 12c8894436b0e78907962cd3420b6ea5bcf21610 Mon Sep 17 00:00:00 2001 From: wangw <1594593906@qq.com> Date: Fri, 13 Sep 2024 16:01:42 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E5=B9=B6=E8=A1=8C=E8=BF=90=E8=A1=8C?= =?UTF-8?q?=E7=9A=84Bug=20=E5=BA=97=E9=93=BA=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/cashierservice/entity/TbShopInfo.java | 10 ++++++++++ .../system/cashierservice/service/ProductService.java | 2 +- src/main/resources/mapper/TbShopInfoMapper.xml | 8 +++++++- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbShopInfo.java b/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbShopInfo.java index 4e94053..708a336 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbShopInfo.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbShopInfo.java @@ -112,6 +112,16 @@ public class TbShopInfo implements Serializable { private String districts; private String isCustom; + //是否开启桌位费 0否1是 + private Integer isTableFee; + //桌位费 + private BigDecimal tableFee; + //就餐模式 堂食 dine-in 外带 take-out + private String eatModel; + //程序码(零点八零首页) + private String smallQrcode; + //店铺收款码 + private String paymentQrcode; private static final long serialVersionUID = 1L; diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java b/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java index 9e2c781..e1df7ef 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java @@ -389,7 +389,7 @@ public class ProductService { */ public List handleDate(List products,boolean check,Integer isSale,boolean isVip){ if (!CollectionUtils.isEmpty(products)) { - products.parallelStream().forEach(it -> { + products.forEach(it -> { if(check){ List tbProductGroups = tbProductGroupMapper.selectByProductId(it.getShopId(), it.getId().toString()); for (TbProductGroup g : tbProductGroups) { diff --git a/src/main/resources/mapper/TbShopInfoMapper.xml b/src/main/resources/mapper/TbShopInfoMapper.xml index 9844f1a..78d2a24 100644 --- a/src/main/resources/mapper/TbShopInfoMapper.xml +++ b/src/main/resources/mapper/TbShopInfoMapper.xml @@ -54,6 +54,11 @@ + + + + + @@ -66,7 +71,8 @@ detail, lat, lng, mch_id, register_type, is_wx_ma_independent, address, city, type, industry, industry_name, business_start_day,business_end_day,business_time, post_time, post_amount_line, on_sale, settle_type, settle_time, enter_at, expire_at, status, average, order_wait_pay_minute, support_device_number, - distribute_level, created_at, updated_at, proxy_id, shop_qrcode, tag,is_open_yhq,is_use_vip,provinces,cities,districts,is_custom + distribute_level, created_at, updated_at, proxy_id, shop_qrcode, tag,is_open_yhq,is_use_vip,provinces,cities,districts,is_custom, + is_table_fee,table_fee,eat_model,small_qrcode,payment_qrcode view From a0ddc67f8f71dbb6ab720f72dfe501e574a5e1b1 Mon Sep 17 00:00:00 2001 From: wangw <1594593906@qq.com> Date: Fri, 13 Sep 2024 16:20:31 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E5=8D=95=E4=BD=8D=E4=B8=BA=E7=A9=BA?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/cashierservice/service/ProductService.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java b/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java index e1df7ef..f96fb6c 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java @@ -389,7 +389,12 @@ public class ProductService { */ public List handleDate(List products,boolean check,Integer isSale,boolean isVip){ if (!CollectionUtils.isEmpty(products)) { - products.forEach(it -> { + products.parallelStream().forEach(it -> { + TbShopUnit tbShopUnit = unitMapper.selectByPrimaryKey(Integer.valueOf(it.getUnitId())); + if (it.getName().equals("烤牛肉")) { + System.out.println("单位:"+tbShopUnit.getName()); + } + it.setUnitSnap(tbShopUnit != null ? tbShopUnit.getName() : ""); if(check){ List tbProductGroups = tbProductGroupMapper.selectByProductId(it.getShopId(), it.getId().toString()); for (TbProductGroup g : tbProductGroups) { @@ -403,8 +408,6 @@ public class ProductService { }else { it.setIsSale(isSale); } - TbShopUnit tbShopUnit = unitMapper.selectByPrimaryKey(Integer.valueOf(it.getUnitId())); - it.setUnitSnap(tbShopUnit != null ? tbShopUnit.getName() : ""); //购物车数量 it.setCartNumber("0"); List tbProductSkus = tbProductSkuMapper.selectGroundingByProId(it.getId());