Selaa lähdekoodia

充值手续费统计

dos 2 kuukautta sitten
vanhempi
commit
763d88436f

+ 8 - 0
game-business/src/main/java/com/game/business/domain/AppUsersCharge.java

@@ -77,6 +77,14 @@ private static final long serialVersionUID=1L;
     @TableField(value = "coin_give")
     private BigDecimal coinGive;
 
+    @ApiModelProperty(value = "平台服务费")
+    @TableField(value = "platform_service")
+    public double platformService;
+
+    @ApiModelProperty(value = "平台服务费率")
+    @TableField(value = "platform_service_rate")
+    public double platformServiceRate;
+
     /** 1是会员(星探)充值 */
     @ApiModelProperty(value = "1是会员(星探)充值")
     @Excel(name = "1是会员" , readConverterExp = "星=探")

+ 2 - 0
game-business/src/main/java/com/game/business/task/AppUserCountTask.java

@@ -88,6 +88,8 @@ public class AppUserCountTask {
                     appUserCount.setRechargeAmount(appUsersChargeList.stream().filter(e -> e.getUid().equals(appUser.getUserid())).mapToDouble(e -> e.getMoney().doubleValue()).sum());
                     //提现金额
                     appUserCount.setWithdrawalAmount(appUsersCashrecords.stream().filter(e -> e.getUid().equals(appUser.getUserid())).mapToDouble(e -> e.getMoney().doubleValue()).sum());
+                    //充值服务费/手续费
+                    appUserCount.setRechargeCommission(appUsersChargeList.stream().filter(e -> e.getUid().equals(appUser.getUserid())).mapToDouble(e -> e.getPlatformService()).sum());
                     //提现服务费/手续费
                     appUserCount.setWithdrawalCommission(appUsersCashrecords.stream().filter(e -> e.getUid().equals(appUser.getUserid())).mapToDouble(e -> e.getService().doubleValue()).sum());
                     //直播消费金额

+ 2 - 2
game-business/src/main/java/com/game/business/websocket/WebSocketConnent.java

@@ -29,7 +29,7 @@ public class WebSocketConnent {
     }
 
     public void connect() throws Exception{
-        while (true){
+        /*while (true){
             try {
                 System.out.println("正在" + (this.WS_CONNENT_NUM == 0 ? "" : ("第" + this.WS_CONNENT_NUM + "次")) + "连接WebSocket[" + this.WS_URL_NAME + "]......");
 
@@ -63,6 +63,6 @@ public class WebSocketConnent {
                 System.out.println("连接[" + this.WS_URL_NAME + "]异常," + this.WS_CONNENT_NUM + "秒后尝试重新连接:" + e.getMessage());
                 Thread.sleep(this.WS_CONNENT_NUM * 1000);
             }
-        }
+        }*/
     }
 }

+ 11 - 1
game-business/src/main/resources/mapper/business/AppUsersChargeMapper.xml

@@ -13,6 +13,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="coin"    column="coin"    />
         <result property="coinType"    column="coin_type"    />
         <result property="coinGive"    column="coin_give"    />
+        <result property="platformService"    column="platform_service"    />
+        <result property="platformServiceRate"    column="platform_service_rate"    />
         <result property="isAgent"    column="is_agent"    />
         <result property="isDelete"    column="is_delete"    />
         <result property="isWater"    column="is_water"    />
@@ -35,7 +37,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </resultMap>
 
     <sql id="selectAppUsersChargeVo">
-        select id, addtime, after_coin, agent_id, ambient, coin, coin_type, coin_give, is_agent, is_delete, is_water, money, opt_type, opt_user, orderno, pid, pid_level1, pid_level2, pid_level3, pid_level4, remarks, rule_id, status, touid, trade_no, type, uid from app_users_charge
+        select id, addtime, after_coin, agent_id, ambient, coin, coin_type, coin_give,platform_service_rate,platform_service, is_agent, is_delete, is_water, money, opt_type, opt_user, orderno, pid, pid_level1, pid_level2, pid_level3, pid_level4, remarks, rule_id, status, touid, trade_no, type, uid from app_users_charge
     </sql>
 
     <select id="selectAppUsersChargeList" parameterType="com.game.business.domain.AppUsersCharge" resultMap="AppUsersChargeResult">
@@ -48,6 +50,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="coin != null "> and coin = #{coin}</if>
             <if test="coinType != null "> and coin_type = #{coinType}</if>
             <if test="coinGive != null "> and coin_give = #{coinGive}</if>
+            <if test="platform_service_rate != null "> and platform_service = #{platformService}</if>
+            <if test="platform_service != null "> and platform_service_rate = #{platformServiceRate}</if>
             <if test="isAgent != null "> and is_agent = #{isAgent}</if>
             <if test="isDelete != null "> and is_delete = #{isDelete}</if>
             <if test="isWater != null "> and is_water = #{isWater}</if>
@@ -86,6 +90,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="coin != null">coin,</if>
             <if test="coinType != null">coin_type,</if>
             <if test="coinGive != null">coin_give,</if>
+            <if test="platformService != null">platform_ervice,</if>
+            <if test="platformServiceRate != null">platform_ervice_rate,</if>
             <if test="isAgent != null">is_agent,</if>
             <if test="isDelete != null">is_delete,</if>
             <if test="isWater != null">is_water,</if>
@@ -115,6 +121,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="coin != null">#{coin},</if>
             <if test="coinType != null">#{coinType},</if>
             <if test="coinGive != null">#{coinGive},</if>
+            <if test="platformService != null">#{platformService},</if>
+            <if test="platformServiceRate != null">#{platformServiceRate},</if>
             <if test="isAgent != null">#{isAgent},</if>
             <if test="isDelete != null">#{isDelete},</if>
             <if test="isWater != null">#{isWater},</if>
@@ -147,6 +155,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="coin != null">coin = #{coin},</if>
             <if test="coinType != null">coin_type = #{coinType},</if>
             <if test="coinGive != null">coin_give = #{coinGive},</if>
+            <if test="platformService != null">platform_service = #{platformService},</if>
+            <if test="platformServiceRate != null">platform_service_rate = #{platformServiceRate},</if>
             <if test="isAgent != null">is_agent = #{isAgent},</if>
             <if test="isDelete != null">is_delete = #{isDelete},</if>
             <if test="isWater != null">is_water = #{isWater},</if>

+ 5 - 0
game-common/src/main/java/com/game/common/constant/finance/FinTranType3.java

@@ -37,6 +37,11 @@ public enum FinTranType3 {
      */
     CHARGE_WIN_GAME(FinTranType2.GAME_REWARD, 1103, "11215",0),
 
+    /**
+     * 充值 - 扣除手续费
+     */
+    CHARGE_OUT_RATE(FinTranType2.CHARGE, 1104, MessageUtils.message("11277") + ProjConfig.getD_ticketName(),0),
+
     /**
      * 分红 - 代理分红
      */