From 7a200635fc307604aa2fd4fe24bb7981dda9e264 Mon Sep 17 00:00:00 2001 From: "Stormeye.Wu" Date: Wed, 26 Sep 2018 22:47:48 +0800 Subject: [PATCH] =?UTF-8?q?[=E6=88=90=E9=95=BF=E5=80=BC=E9=87=8D=E6=95=B4]?= =?UTF-8?q?[=E9=87=8D=E6=95=B4]:=20=201.=20=E6=AF=8F=E5=A4=A9=E7=99=BB?= =?UTF-8?q?=E5=BD=95=E9=A6=96=E6=AC=A1=E7=BB=99=E6=88=90=E9=95=BF=E5=80=BC?= =?UTF-8?q?=20=202.=20=E6=B6=88=E8=B4=B9=E9=87=91=E9=A2=9D=E4=B8=BA0?= =?UTF-8?q?=E6=97=B6=EF=BC=8C=E4=B8=8D=E7=BB=99=E6=88=90=E9=95=BF=E5=80=BC?= =?UTF-8?q?=E3=80=82=20=203.=20=E6=B6=88=E8=B4=B9=E9=87=91=E9=A2=9D?= =?UTF-8?q?=E9=99=A4=E4=BB=A51=E5=85=83=EF=BC=8C=E5=9B=9B=E8=88=8D?= =?UTF-8?q?=E4=BA=94=E5=85=A5=E7=BB=99=E6=88=90=E9=95=BF=E5=80=BC=20=204.?= =?UTF-8?q?=20=E7=BB=91=E8=BD=A6=E7=89=8C=E8=8E=B7=E5=BE=97=E6=88=90?= =?UTF-8?q?=E9=95=BF=E5=80=BC=20=205.=20=E5=BE=AE=E4=BF=A1=E6=98=B5?= =?UTF-8?q?=E7=A7=B0=E6=8E=88=E6=9D=83=E8=8E=B7=E5=8F=96=E6=88=90=E9=95=BF?= =?UTF-8?q?=E5=80=BC=20=206.=20=E5=BE=AE=E4=BF=A1=E6=89=8B=E6=9C=BA?= =?UTF-8?q?=E6=8E=88=E6=9D=83=E8=8E=B7=E5=8F=96=E6=88=90=E9=95=BF=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/iformall/enums/EnumScoreType.java | 39 +++++ .../resources/mapper/WxScoreHistoryMapper.xml | 154 +++++++++--------- 2 files changed, 113 insertions(+), 80 deletions(-) create mode 100644 mallinkService/src/main/java/com/iformall/enums/EnumScoreType.java diff --git a/mallinkService/src/main/java/com/iformall/enums/EnumScoreType.java b/mallinkService/src/main/java/com/iformall/enums/EnumScoreType.java new file mode 100644 index 000000000..44b4f3f8a --- /dev/null +++ b/mallinkService/src/main/java/com/iformall/enums/EnumScoreType.java @@ -0,0 +1,39 @@ +package com.iformall.enums; + +/** + * Created by Stormeye on 2018/08/09. + */ +public enum EnumScoreType { + + LOGIN(1, "每日登录"), + CONSUMPTION(2, "消费"), + BINDCAR(3, "绑车牌"), + WIFI_CONNECTION(4, "连接WIFI"), + WECHAT_PERSION(5, "微信用户昵称授权"), + WECHAT_PHONE(6, "微信用户手机授权"); + + public static EnumScoreType getEnum(Integer code) { + for (EnumScoreType value : values()) { + if (value.getCode().equals(code)) { + return value; + } + } + return null; + } + + private Integer code; + private String message; + + EnumScoreType(Integer code, String message) { + this.code = code; + this.message = message; + } + + public Integer getCode() { + return code; + } + + public String getMessage() { + return message; + } +} diff --git a/mallinkService/src/main/resources/mapper/WxScoreHistoryMapper.xml b/mallinkService/src/main/resources/mapper/WxScoreHistoryMapper.xml index a91b79ab9..b1fa3067f 100644 --- a/mallinkService/src/main/resources/mapper/WxScoreHistoryMapper.xml +++ b/mallinkService/src/main/resources/mapper/WxScoreHistoryMapper.xml @@ -1,86 +1,80 @@ - - - - - - - - - - - - - - `id`,`tenant_id`,`c_user_id`,`create_date`,`valid_date`,`order_id`,`pay_type`,`pay_amount`,`score_amount` - + + + + + + + + + + + + - - where 1 = 1 - - - and `id` = #{id} - - - - - and `tenant_id` = #{tenantId} - - - - - and `c_user_id` = #{cUserId} - - - - - and `create_date` = #{createDate} - - - - - and `valid_date` = #{validDate} - - - - - and `order_id` = #{orderId} - - - - - and `pay_type` = #{payType} - - - - - and `pay_amount` = #{payAmount} - - - - - and `score_amount` = #{scoreAmount} - - - - and id in - - #{idItem} - - - order by ${sortColumns} + + `id`,`tenant_id`,`c_user_id`,`create_date`,`score_type`,`valid_date`,`order_id`,`pay_type`,`pay_amount`,`score_amount` - - - - - - - - + + + where 1 = 1 + + + and `id` = #{id} + + + + and `tenant_id` = #{tenantId} + + + + and `c_user_id` = #{cUserId} + + + + and `create_date` = #{createDate} + + + + and `score_type` = #{scoreType} + + + + and `valid_date` = #{validDate} + + + + and `order_id` = #{orderId} + + + + and `pay_type` = #{payType} + + + + and `pay_amount` = #{payAmount} + + + + and `score_amount` = #{scoreAmount} + + + and id in + + #{idItem} + + + order by ${sortColumns} + + + + +