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} + + + + +