From 927bef9602e99506f5d889ba96f731426532aa70 Mon Sep 17 00:00:00 2001 From: Tankaikai Date: Tue, 19 Nov 2024 10:11:37 +0800 Subject: [PATCH 01/10] =?UTF-8?q?=E6=B6=88=E8=B4=B9=E9=80=81=E7=A7=AF?= =?UTF-8?q?=E5=88=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../chaozhanggui/system/cashierservice/service/PayService.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/service/PayService.java b/src/main/java/com/chaozhanggui/system/cashierservice/service/PayService.java index a79c260..d81d89d 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/service/PayService.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/service/PayService.java @@ -1291,6 +1291,9 @@ public class PayService { orderInfo.setPaidTime(System.currentTimeMillis()); tbOrderInfoMapper.updateByPrimaryKeySelective(orderInfo); + // 消费送积分 + tbMemberPointsService.consumeAwardPoints(Long.valueOf(orderInfo.getMemberId()), Long.valueOf(orderInfo.getId())); + JSONObject jsonObject = new JSONObject(); jsonObject.put("token", 0); jsonObject.put("type", "wxcreate"); From 5eb1403647c328e8deef064daef6b3de4aa806fc Mon Sep 17 00:00:00 2001 From: wangw <1594593906@qq.com> Date: Tue, 19 Nov 2024 10:24:43 +0800 Subject: [PATCH 02/10] =?UTF-8?q?=E5=95=86=E5=93=81=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/cashierservice/entity/TbProduct.java | 6 +----- src/main/resources/mapper/TbProductMapper.xml | 4 +--- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbProduct.java b/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbProduct.java index 6e2d092..14a982d 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbProduct.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/entity/TbProduct.java @@ -42,7 +42,7 @@ public class TbProduct implements Serializable { */ private String shortTitle; /** - * 商品类型(属性):REAL- 实物商品 VIR---虚拟商品 + * 商品类型(属性):普通商品 normal 套餐商品 package 称重商品 weigh 团购券商品 coupon */ private String type; /** @@ -104,10 +104,6 @@ public class TbProduct implements Serializable { * 是否暂停销售 */ private Integer isPauseSale; - /** - * 是否删除0不删1删除 - */ - private Integer isDelete; private Long createdAt; diff --git a/src/main/resources/mapper/TbProductMapper.xml b/src/main/resources/mapper/TbProductMapper.xml index 57f74ee..84e9c14 100644 --- a/src/main/resources/mapper/TbProductMapper.xml +++ b/src/main/resources/mapper/TbProductMapper.xml @@ -25,7 +25,6 @@ - @@ -40,7 +39,7 @@ id , category_id, spec_id, merchant_id, shop_id, name, short_title, type, pack_fee, low_price, low_member_price, - unit_id, cover_img, images, sort, status, fail_msg, is_hot, type_enum, is_del, is_stock, is_pause_sale, is_delete, + unit_id, cover_img, images, sort, status, fail_msg, is_hot, type_enum, is_del, is_stock, is_pause_sale, created_at, updated_at, group_snap, spec_info, select_spec, spec_table_headers, group_category_id, real_sales_number, stock_number, is_grounding, is_refund_stock, warn_line select @@ -49,23 +62,14 @@ where id = #{id,jdbcType=INTEGER} - @@ -76,9 +80,8 @@ LEFT JOIN tb_product_sku sku ON tb.id = sku.product_id JOIN (SELECT product_id ,SUM(real_sales_number) as realSalesNumber FROM tb_product_sku - WHERE shop_id = #{shopId} - and is_del = 0 - AND product_id IN + WHERE + shop_id = #{shopId} and is_del = 0 AND product_id IN #{item} @@ -86,7 +89,8 @@ ORDER BY realSalesNumber DESC LIMIT 3) AS top_products ON tb.id = top_products.product_id where tb.status = 1 - and tb.type_enum != 'group' + and tb.type != 'coupon' and tb.is_del = 0 + and tb.days LIKE concat('%',DAYNAME(CURRENT_DATE),'%') and tb.start_time <= CURRENT_TIMESTAMP and tb.end_time >= CURRENT_TIMESTAMP and tb.is_grounding = 1 group by tb.id order by stockNumber desc @@ -101,17 +105,12 @@ and tb.shop_id = #{shopId} and tb.status = 1 and tb.is_grounding = 1 - and tb.type_enum != 'group' + and tb.type != 'coupon' and tb.is_del = 0 + and tb.days LIKE concat('%',DAYNAME(CURRENT_DATE),'%') and tb.start_time <= CURRENT_TIMESTAMP and tb.end_time >= CURRENT_TIMESTAMP group by tb.id order by tb.sort asc - - - - - -