Ver Fonte

Merge remote-tracking branch 'origin/master'

kk há 3 semanas atrás
pai
commit
4100d6fc42

+ 14 - 2
game-business/src/main/java/com/game/business/controller/AppChargeChannelController.java

@@ -65,11 +65,11 @@ public class AppChargeChannelController extends BaseController
         if(null == list){
             list = new ArrayList<>();
         }
-        AppChargeChannel chargeChannel = new AppChargeChannel();
+        /*AppChargeChannel chargeChannel = new AppChargeChannel();
         chargeChannel.setId(-1L);
         chargeChannel.setName("其他");
         chargeChannel.setRate(0.00);
-        list.add(chargeChannel);
+        list.add(chargeChannel);*/
         return R.ok(list);
     }
 
@@ -107,6 +107,12 @@ public class AppChargeChannelController extends BaseController
     @PostMapping
     public R add(@RequestBody AppChargeChannel appChargeChannel)
     {
+        if(null != appChargeChannel.getRate()){
+            appChargeChannel.setRate(appChargeChannel.getRate()/100);
+        }
+        if(null != appChargeChannel.getWithdrawRate()){
+            appChargeChannel.setWithdrawRate(appChargeChannel.getWithdrawRate()/100);
+        }
         return R.ok(appChargeChannelService.insertAppChargeChannel(appChargeChannel));
     }
 
@@ -119,6 +125,12 @@ public class AppChargeChannelController extends BaseController
     @PutMapping
     public R edit(@RequestBody AppChargeChannel appChargeChannel)
     {
+        if(null != appChargeChannel.getRate()){
+            appChargeChannel.setRate(appChargeChannel.getRate()/100);
+        }
+        if(null != appChargeChannel.getWithdrawRate()){
+            appChargeChannel.setWithdrawRate(appChargeChannel.getWithdrawRate()/100);
+        }
         return R.ok(appChargeChannelService.updateAppChargeChannel(appChargeChannel));
     }
 

+ 115 - 0
game-business/src/main/java/com/game/business/controller/AppGameMoneyController.java

@@ -0,0 +1,115 @@
+package com.game.business.controller;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+
+import com.game.common.core.domain.R;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.game.common.annotation.Log;
+import com.game.common.core.controller.BaseController;
+import com.game.common.core.domain.AjaxResult;
+import com.game.common.enums.BusinessType;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import com.game.business.domain.AppGameMoney;
+import com.game.business.service.IAppGameMoneyService;
+import com.game.common.utils.poi.ExcelUtil;
+import com.game.common.core.page.TableDataInfo;
+
+/**
+ * 游戏投注金额Controller
+ * 
+ * @author game
+ * @date 2024-08-29
+ */
+@RestController
+@RequestMapping("/business/money")
+@Api(value = "AppGameMoneyController", description = "游戏投注金额接口", tags = {"游戏投注金额"})
+public class AppGameMoneyController extends BaseController
+{
+    @Autowired
+    private IAppGameMoneyService appGameMoneyService;
+
+    /**
+     * 查询游戏投注金额列表
+     */
+    @PreAuthorize("@ss.hasPermi('business:money:list')")
+    @GetMapping("/list")
+    @ApiOperation(value = "查询游戏投注金额列表", notes = "获取游戏投注金额列表")
+    public TableDataInfo<AppGameMoney> list(AppGameMoney appGameMoney)
+    {
+        startPage();
+        List<AppGameMoney> list = appGameMoneyService.selectAppGameMoneyList(appGameMoney);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出游戏投注金额列表
+     */
+    @PreAuthorize("@ss.hasPermi('business:money:export')")
+    @Log(title = "游戏投注金额", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    @ApiOperation(value = "导出游戏投注金额列表", notes = "导出游戏投注金额列表")
+    public void export(HttpServletResponse response, AppGameMoney appGameMoney)
+    {
+        List<AppGameMoney> list = appGameMoneyService.selectAppGameMoneyList(appGameMoney);
+        ExcelUtil<AppGameMoney> util = new ExcelUtil<AppGameMoney>(AppGameMoney.class);
+        util.exportExcel(response, list, "游戏投注金额数据");
+    }
+
+    /**
+     * 获取游戏投注金额详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('business:money:query')")
+    @GetMapping(value = "/{id}")
+    @ApiOperation(value = "获取游戏投注金额详细信息", notes = "获取游戏投注金额详细信息")
+    public R<AppGameMoney> getInfo(@PathVariable("id") Long id)
+    {
+        return R.ok(appGameMoneyService.selectAppGameMoneyById(id));
+    }
+
+    /**
+     * 新增游戏投注金额
+     */
+    @PreAuthorize("@ss.hasPermi('business:money:add')")
+    @Log(title = "游戏投注金额", businessType = BusinessType.INSERT)
+    @ApiOperation(value = "新增游戏投注金额", notes = "新增游戏投注金额")
+    @PostMapping
+    public R add(@RequestBody AppGameMoney appGameMoney)
+    {
+        return R.ok(appGameMoneyService.insertAppGameMoney(appGameMoney));
+    }
+
+    /**
+     * 修改游戏投注金额
+     */
+    @PreAuthorize("@ss.hasPermi('business:money:edit')")
+    @Log(title = "游戏投注金额", businessType = BusinessType.UPDATE)
+    @ApiOperation(value = "修改游戏投注金额", notes = "修改游戏投注金额")
+    @PutMapping
+    public R edit(@RequestBody AppGameMoney appGameMoney)
+    {
+        return R.ok(appGameMoneyService.updateAppGameMoney(appGameMoney));
+    }
+
+    /**
+     * 删除游戏投注金额
+     */
+    @PreAuthorize("@ss.hasPermi('business:money:remove')")
+    @Log(title = "游戏投注金额", businessType = BusinessType.DELETE)
+    @ApiOperation(value = "删除游戏投注金额", notes = "删除游戏投注金额")
+	@DeleteMapping("/{ids}")
+    public R remove(@PathVariable Long[] ids)
+    {
+        return R.ok(appGameMoneyService.deleteAppGameMoneyByIds(ids));
+    }
+}

+ 21 - 3
game-business/src/main/java/com/game/business/domain/AppGame.java

@@ -85,12 +85,30 @@ private static final long serialVersionUID=1L;
     @TableField(value = "game_path")
     private String gamePath;
 
-    /** 是否启用 0:未启用  1:已启用 */
-    @ApiModelProperty(value = "是否启用 0:未启用  1:已启用")
-    @Excel(name = "是否启用 0:未启用  1:已启用")
+    /** 上次中奖选项 */
+    @ApiModelProperty(value = "上次中奖选项")
+    @Excel(name = "上次中奖选项")
+    @TableField(value = "up_item")
+    private String upItem;
+
+    /** 是否启用 0:已关闭  1:未关闭 */
+    @ApiModelProperty(value = "是否启用 0:已关闭  1:未关闭")
+    @Excel(name = "是否关闭 0:已关闭  1:未关闭")
     @TableField(value = "status")
     private Long status;
 
+    /** 是否启用投注 0:启用 1:禁用 */
+    @ApiModelProperty(value = "是否启用 0:启用 1:禁用")
+    @Excel(name = "是否启用 0:启用 1:禁用")
+    @TableField(value = "enable")
+    private Long enable;
+
+    /** 每期投注次数 */
+    @ApiModelProperty(value = "每期投注次数")
+    @Excel(name = "每期投注次数")
+    @TableField(value = "betting_count")
+    private Long bettingCount;
+
     /** 排序 */
     @ApiModelProperty(value = "排序")
     @Excel(name = "排序")

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

@@ -12,6 +12,8 @@ import io.swagger.annotations.ApiModelProperty;
 import io.swagger.annotations.ApiModel;
 import lombok.Data;
 
+import java.math.BigDecimal;
+
 /**
  * 游戏选项对象 app_game_item
  *
@@ -54,6 +56,12 @@ private static final long serialVersionUID=1L;
     @TableField(value = "item_location")
     private String itemLocation;
 
+    /** 每期投注金额 */
+    @ApiModelProperty(value = "每期投注金额")
+    @Excel(name = "每期投注金额")
+    @TableField(value = "betting_money")
+    private BigDecimal bettingMoney;
+
     @ApiModelProperty(value = "开奖次数")
     @Excel(name = "开奖次数" , readConverterExp = "开奖次数")
     @TableField(value = "lottery_count")

+ 51 - 0
game-business/src/main/java/com/game/business/domain/AppGameMoney.java

@@ -0,0 +1,51 @@
+package com.game.business.domain;
+
+import java.math.BigDecimal;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import com.game.common.annotation.Excel;
+import com.game.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModelProperty;
+import io.swagger.annotations.ApiModel;
+import lombok.Data;
+
+/**
+ * 游戏投注金额对象 app_game_money
+ *
+ * @author game
+ * @date 2024-08-29
+ */
+@ApiModel(value = "app_game_money", description = "游戏投注金额")
+@TableName(value= "app_game_money")
+@Data
+public class AppGameMoney
+        {
+private static final long serialVersionUID=1L;
+
+    /** $column.columnComment */
+    @ApiModelProperty(value = "$column.columnComment")
+    @TableId(value = "id" , type = IdType.AUTO)
+    private Long id;
+
+    /** 游戏id */
+    @ApiModelProperty(value = "游戏id")
+    @Excel(name = "游戏id")
+    @TableField(value = "app_game")
+    private Long appGame;
+
+    /** 投注金额 */
+    @ApiModelProperty(value = "投注金额")
+    @Excel(name = "投注金额")
+    @TableField(value = "betting_money")
+    private BigDecimal bettingMoney;
+
+    /** 删除状态 0:未删除(默认) 1:已删除 */
+    @ApiModelProperty(value = "删除状态 0:未删除(默认) 1:已删除")
+    @TableField(value = "del_flag")
+    private Long delFlag;
+
+}

+ 61 - 0
game-business/src/main/java/com/game/business/mapper/AppGameMoneyMapper.java

@@ -0,0 +1,61 @@
+package com.game.business.mapper;
+
+import java.util.List;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.game.business.domain.AppGameMoney;
+
+/**
+ * 游戏投注金额Mapper接口
+ *
+ * @author game
+ * @date 2024-08-29
+ */
+public interface AppGameMoneyMapper extends BaseMapper<AppGameMoney> {
+    /**
+     * 查询游戏投注金额
+     *
+     * @param id 游戏投注金额主键
+     * @return 游戏投注金额
+     */
+    public AppGameMoney selectAppGameMoneyById(Long id);
+
+    /**
+     * 查询游戏投注金额列表
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 游戏投注金额集合
+     */
+    public List<AppGameMoney> selectAppGameMoneyList(AppGameMoney appGameMoney);
+
+    /**
+     * 新增游戏投注金额
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 结果
+     */
+    public int insertAppGameMoney(AppGameMoney appGameMoney);
+
+    /**
+     * 修改游戏投注金额
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 结果
+     */
+    public int updateAppGameMoney(AppGameMoney appGameMoney);
+
+    /**
+     * 删除游戏投注金额
+     *
+     * @param id 游戏投注金额主键
+     * @return 结果
+     */
+    public int deleteAppGameMoneyById(Long id);
+
+    /**
+     * 批量删除游戏投注金额
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteAppGameMoneyByIds(Long[] ids);
+}

+ 61 - 0
game-business/src/main/java/com/game/business/service/IAppGameMoneyService.java

@@ -0,0 +1,61 @@
+package com.game.business.service;
+
+import java.util.List;
+import com.game.business.domain.AppGameMoney;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+ * 游戏投注金额Service接口
+ *
+ * @author game
+ * @date 2024-08-29
+ */
+public interface IAppGameMoneyService extends IService<AppGameMoney> {
+    /**
+     * 查询游戏投注金额
+     *
+     * @param id 游戏投注金额主键
+     * @return 游戏投注金额
+     */
+    public AppGameMoney selectAppGameMoneyById(Long id);
+
+    /**
+     * 查询游戏投注金额列表
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 游戏投注金额集合
+     */
+    public List<AppGameMoney> selectAppGameMoneyList(AppGameMoney appGameMoney);
+
+    /**
+     * 新增游戏投注金额
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 结果
+     */
+    public int insertAppGameMoney(AppGameMoney appGameMoney);
+
+    /**
+     * 修改游戏投注金额
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 结果
+     */
+    public int updateAppGameMoney(AppGameMoney appGameMoney);
+
+    /**
+     * 批量删除游戏投注金额
+     *
+     * @param ids 需要删除的游戏投注金额主键集合
+     * @return 结果
+     */
+    public int deleteAppGameMoneyByIds(Long[] ids);
+
+    /**
+     * 删除游戏投注金额信息
+     *
+     * @param id 游戏投注金额主键
+     * @return 结果
+     */
+    public int deleteAppGameMoneyById(Long id);
+}

+ 95 - 0
game-business/src/main/java/com/game/business/service/impl/AppGameMoneyServiceImpl.java

@@ -0,0 +1,95 @@
+package com.game.business.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import java.util.List;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.game.business.mapper.AppGameMoneyMapper;
+import com.game.business.domain.AppGameMoney;
+import com.game.business.service.IAppGameMoneyService;
+import com.game.common.annotation.DataSource;
+import com.game.common.enums.DataSourceType;
+
+/**
+ * 游戏投注金额Service业务层处理
+ *
+ * @author game
+ * @date 2024-08-29
+ */
+@Service
+public class AppGameMoneyServiceImpl extends ServiceImpl<AppGameMoneyMapper, AppGameMoney> implements IAppGameMoneyService {
+    @Autowired
+    private AppGameMoneyMapper appGameMoneyMapper;
+
+    /**
+     * 查询游戏投注金额
+     *
+     * @param id 游戏投注金额主键
+     * @return 游戏投注金额
+     */
+    @Override
+    @DataSource(DataSourceType.SLAVE)
+    public AppGameMoney selectAppGameMoneyById(Long id) {
+        return appGameMoneyMapper.selectAppGameMoneyById(id);
+    }
+
+    /**
+     * 查询游戏投注金额列表
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 游戏投注金额
+     */
+    @Override
+    @DataSource(DataSourceType.SLAVE)
+    public List<AppGameMoney> selectAppGameMoneyList(AppGameMoney appGameMoney) {
+        return appGameMoneyMapper.selectAppGameMoneyList(appGameMoney);
+    }
+
+    /**
+     * 新增游戏投注金额
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 结果
+     */
+    @Override
+    @DataSource(DataSourceType.SLAVE)
+    public int insertAppGameMoney(AppGameMoney appGameMoney) {
+            return appGameMoneyMapper.insertAppGameMoney(appGameMoney);
+    }
+
+    /**
+     * 修改游戏投注金额
+     *
+     * @param appGameMoney 游戏投注金额
+     * @return 结果
+     */
+    @Override
+    @DataSource(DataSourceType.SLAVE)
+    public int updateAppGameMoney(AppGameMoney appGameMoney) {
+        return appGameMoneyMapper.updateAppGameMoney(appGameMoney);
+    }
+
+    /**
+     * 批量删除游戏投注金额
+     *
+     * @param ids 需要删除的游戏投注金额主键
+     * @return 结果
+     */
+    @Override
+    @DataSource(DataSourceType.SLAVE)
+    public int deleteAppGameMoneyByIds(Long[] ids) {
+        return appGameMoneyMapper.deleteAppGameMoneyByIds(ids);
+    }
+
+    /**
+     * 删除游戏投注金额信息
+     *
+     * @param id 游戏投注金额主键
+     * @return 结果
+     */
+    @Override
+    @DataSource(DataSourceType.SLAVE)
+    public int deleteAppGameMoneyById(Long id) {
+        return appGameMoneyMapper.deleteAppGameMoneyById(id);
+    }
+}

+ 11 - 4
game-business/src/main/resources/mapper/business/AppGameItemMapper.xml

@@ -10,21 +10,25 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="itemName"    column="item_name"    />
         <result property="itemMultiple"    column="item_multiple"    />
         <result property="itemLocation"    column="item_location"    />
+        <result property="bettingMoney"    column="betting_money"    />
         <result property="lotteryCount"    column="lottery_count"    />
         <result property="consecutive"    column="consecutive"    />
     </resultMap>
 
     <sql id="selectAppGameItemVo">
-        select id, game_id, item_name, item_multiple, item_location, lottery_count, consecutive from app_game_item
+        select id, game_id, item_name, item_multiple, item_location, betting_money, lottery_count, consecutive from app_game_item
     </sql>
 
     <select id="selectAppGameItemList" parameterType="com.game.business.domain.AppGameItem" resultMap="AppGameItemResult">
         <include refid="selectAppGameItemVo"/>
-        <where>  
+        <where>
             <if test="gameId != null "> and game_id = #{gameId}</if>
             <if test="itemName != null  and itemName != ''"> and item_name like concat('%', #{itemName}, '%')</if>
             <if test="itemMultiple != null "> and item_multiple = #{itemMultiple}</if>
             <if test="itemLocation != null  and itemLocation != ''"> and item_location = #{itemLocation}</if>
+            <if test="bettingMoney != null "> and betting_money = #{bettingMoney}</if>
+            <if test="lotteryCount != null "> and lottery_count = #{lotteryCount}</if>
+            <if test="consecutive != null "> and consecutive = #{consecutive}</if>
         </where>
     </select>
     
@@ -40,14 +44,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="itemName != null">item_name,</if>
             <if test="itemMultiple != null">item_multiple,</if>
             <if test="itemLocation != null">item_location,</if>
-            <if test="lotteryCount != null">#{lottery_count},</if>
-            <if test="consecutive != null">#{consecutive},</if>
+            <if test="bettingMoney != null">betting_money,</if>
+            <if test="lotteryCount != null">lottery_count,</if>
+            <if test="consecutive != null">consecutive,</if>
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="gameId != null">#{gameId},</if>
             <if test="itemName != null">#{itemName},</if>
             <if test="itemMultiple != null">#{itemMultiple},</if>
             <if test="itemLocation != null">#{itemLocation},</if>
+            <if test="bettingMoney != null">#{bettingMoney},</if>
             <if test="lotteryCount != null">#{lotteryCount},</if>
             <if test="consecutive != null">#{consecutive},</if>
          </trim>
@@ -60,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="itemName != null">item_name = #{itemName},</if>
             <if test="itemMultiple != null">item_multiple = #{itemMultiple},</if>
             <if test="itemLocation != null">item_location = #{itemLocation},</if>
+            <if test="bettingMoney != null">betting_money = #{bettingMoney},</if>
             <if test="lotteryCount != null">lottery_count = #{lotteryCount},</if>
             <if test="consecutive != null">consecutive = #{consecutive},</if>
         </trim>

+ 22 - 3
game-business/src/main/resources/mapper/business/AppGameMapper.xml

@@ -11,6 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="classifyId"    column="classify_id"    />
         <result property="gameDate"    column="game_date"    />
         <result property="gameTime"    column="game_time"    />
+        <result property="upItem"    column="up_item"    />
         <result property="logoUrl"    column="logo_url"    />
         <result property="liveImgUrl"    column="live_img_url"    />
         <result property="myImgUrl"    column="my_img_url"    />
@@ -18,6 +19,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="status"    column="status"    />
         <result property="createTime"    column="create_time"    />
         <result property="orderno"    column="orderno"    />
+        <result property="enable"    column="enable"    />
+        <result property="bettingCount"    column="betting_count"    />
         <result property="gameExpand1"    column="game_expand1"    />
         <result property="gameExpand2"    column="game_expand2"    />
         <result property="gameExpand3"    column="game_expand3"    />
@@ -25,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </resultMap>
 
     <sql id="selectAppGameVo">
-        select id, name, code, classify_id, game_date, game_time, logo_url,live_img_url,my_img_url, game_path, status, create_time, orderno, game_expand1, game_expand2, game_expand3, game_expand4 from app_game
+        select id, name, code, classify_id, game_date, game_time, up_item, logo_url, live_img_url, my_img_url, game_path, status, create_time, orderno, enable, betting_count, game_expand1, game_expand2, game_expand3, game_expand4 from app_game
     </sql>
 
     <select id="selectAppGameList" parameterType="com.game.business.domain.AppGame" resultMap="AppGameResult">
@@ -35,12 +38,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="code != null  and code != ''"> and code like concat('%', #{code}, '%')</if>
             <if test="gameDate != null  and gameDate != ''"> and game_date like concat('%', #{gameDate}, '%')</if>
             <if test="classifyId != null "> and classify_id = #{classifyId}</if>
+            <if test="upItem != null  and upItem != ''"> and up_item = #{upItem}</if>
             <if test="logoUrl != null  and logoUrl != ''"> and logo_url = #{logoUrl}</if>
             <if test="liveImgUrl != null  and liveImgUrl != ''"> and live_img_url = #{liveImgUrl}</if>
             <if test="myImgUrl != null  and myImgUrl != ''"> and my_img_url = #{myImgUrl}</if>
             <if test="gamePath != null  and gamePath != ''"> and game_path = #{gamePath}</if>
             <if test="status != null "> and status = #{status}</if>
             <if test="orderno != null "> and orderno = #{orderno}</if>
+            <if test="enable != null "> and enable = #{enable}</if>
+            <if test="bettingCount != null "> and betting_count = #{bettingCount}</if>
             <if test="gameExpand1 != null  and gameExpand1 != ''"> and game_expand1 = #{gameExpand1}</if>
             <if test="gameExpand2 != null  and gameExpand2 != ''"> and game_expand2 = #{gameExpand2}</if>
             <if test="gameExpand3 != null  and gameExpand3 != ''"> and game_expand3 = #{gameExpand3}</if>
@@ -60,6 +66,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="name != null">name,</if>
             <if test="code != null">code,</if>
             <if test="classifyId != null">classify_id,</if>
+            <if test="gameDate != null">game_date,</if>
+            <if test="gameTime != null">game_time,</if>
+            <if test="upItem != null">up_item,</if>
             <if test="logoUrl != null">logo_url,</if>
             <if test="liveImgUrl != null">live_img_url,</if>
             <if test="myImgUrl != null">my_img_url,</if>
@@ -67,6 +76,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="status != null">status,</if>
             <if test="createTime != null">create_time,</if>
             <if test="orderno != null">orderno,</if>
+            <if test="enable != null">enable,</if>
+            <if test="bettingCount != null">betting_count,</if>
             <if test="gameExpand1 != null">game_expand1,</if>
             <if test="gameExpand2 != null">game_expand2,</if>
             <if test="gameExpand3 != null">game_expand3,</if>
@@ -77,13 +88,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="name != null">#{name},</if>
             <if test="code != null">#{code},</if>
             <if test="classifyId != null">#{classifyId},</if>
+            <if test="gameDate != null">#{gameDate},</if>
+            <if test="gameTime != null">#{gameTime},</if>
+            <if test="upItem != null">#{upItem},</if>
             <if test="logoUrl != null">#{logoUrl},</if>
-            <if test="liveImgUrl != null">#{live_img_url},</if>
-            <if test="myImgUrl != null">#{my_img_url},</if>
+            <if test="liveImgUrl != null">#{liveImgUrl},</if>
+            <if test="myImgUrl != null">#{myImgUrl},</if>
             <if test="gamePath != null">#{gamePath},</if>
             <if test="status != null">#{status},</if>
             <if test="createTime != null">#{createTime},</if>
             <if test="orderno != null">#{orderno},</if>
+            <if test="enable != null">#{enable},</if>
+            <if test="bettingCount != null">#{bettingCount},</if>
             <if test="gameExpand1 != null">#{gameExpand1},</if>
             <if test="gameExpand2 != null">#{gameExpand2},</if>
             <if test="gameExpand3 != null">#{gameExpand3},</if>
@@ -99,6 +115,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="classifyId != null">classify_id = #{classifyId},</if>
             <if test="gameDate != null">game_date = #{gameDate},</if>
             <if test="gameTime != null">game_time = #{gameTime},</if>
+            <if test="upItem != null">up_item = #{upItem},</if>
             <if test="logoUrl != null">logo_url = #{logoUrl},</if>
             <if test="liveImgUrl != null">live_img_url = #{liveImgUrl},</if>
             <if test="myImgUrl != null">my_img_url = #{myImgUrl},</if>
@@ -106,6 +123,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="status != null">status = #{status},</if>
             <if test="createTime != null">create_time = #{createTime},</if>
             <if test="orderno != null">orderno = #{orderno},</if>
+            <if test="enable != null">enable = #{enable},</if>
+            <if test="bettingCount != null">betting_count = #{bettingCount},</if>
             <if test="gameExpand1 != null">game_expand1 = #{gameExpand1},</if>
             <if test="gameExpand2 != null">game_expand2 = #{gameExpand2},</if>
             <if test="gameExpand3 != null">game_expand3 = #{gameExpand3},</if>

+ 66 - 0
game-business/src/main/resources/mapper/business/AppGameMoneyMapper.xml

@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.game.business.mapper.AppGameMoneyMapper">
+    
+    <resultMap type="com.game.business.domain.AppGameMoney" id="AppGameMoneyResult">
+        <result property="id"    column="id"    />
+        <result property="appGame"    column="app_game"    />
+        <result property="bettingMoney"    column="betting_money"    />
+        <result property="delFlag"    column="del_flag"    />
+    </resultMap>
+
+    <sql id="selectAppGameMoneyVo">
+        select id, app_game, betting_money, del_flag from app_game_money
+    </sql>
+
+    <select id="selectAppGameMoneyList" parameterType="com.game.business.domain.AppGameMoney" resultMap="AppGameMoneyResult">
+        <include refid="selectAppGameMoneyVo"/>
+        <where>
+            del_flag = 0
+            <if test="appGame != null "> and app_game = #{appGame}</if>
+            <if test="bettingMoney != null "> and betting_money = #{bettingMoney}</if>
+        </where>
+    </select>
+    
+    <select id="selectAppGameMoneyById" parameterType="Long" resultMap="AppGameMoneyResult">
+        <include refid="selectAppGameMoneyVo"/>
+        where id = #{id} and del_flag = 0
+    </select>
+        
+    <insert id="insertAppGameMoney" parameterType="com.game.business.domain.AppGameMoney" useGeneratedKeys="true" keyProperty="id">
+        insert into app_game_money
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="appGame != null">app_game,</if>
+            <if test="bettingMoney != null">betting_money,</if>
+            <if test="delFlag != null">del_flag,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="appGame != null">#{appGame},</if>
+            <if test="bettingMoney != null">#{bettingMoney},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+         </trim>
+    </insert>
+
+    <update id="updateAppGameMoney" parameterType="com.game.business.domain.AppGameMoney">
+        update app_game_money
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="appGame != null">app_game = #{appGame},</if>
+            <if test="bettingMoney != null">betting_money = #{bettingMoney},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <update id="deleteAppGameMoneyById" parameterType="Long">
+        update app_game_money set del_flag = 1 where id = #{id}
+    </update>
+
+    <delete id="deleteAppGameMoneyByIds" parameterType="String">
+        update app_game_money set del_flag = 1 where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 22 - 7
game-ui/src/views/business/channel/index.vue

@@ -178,7 +178,16 @@
 <!--      <el-table-column label="${comment}" align="center" prop="id" />-->
       <el-table-column label="名称" align="center" prop="name" />
 <!--      <el-table-column label="渠道key" align="center" prop="channelKey" />-->
-      <el-table-column label="渠道费率" align="center" prop="rate" />
+      <el-table-column label="充值手续费" align="center" prop="rate">
+        <template slot-scope="scope">
+          {{scope.row.rate * 100 + "%"}}
+        </template>
+      </el-table-column>
+      <el-table-column label="提现手续费" align="center" prop="withdrawRate">
+        <template slot-scope="scope">
+          {{scope.row.withdrawRate * 100 + "%"}}
+        </template>
+      </el-table-column>
 <!--      <el-table-column label="logo" align="center" prop="logoUrl" />
       <el-table-column label="付款公司名" align="center" prop="company" />
       <el-table-column label="支付id" align="center" prop="appId" />
@@ -226,14 +235,14 @@
         <el-form-item label="名称" prop="name">
           <el-input v-model="form.name" placeholder="请输入名称" />
         </el-form-item>
-<!--        <el-form-item label="渠道key" prop="channelKey">
+        <el-form-item label="渠道key" prop="channelKey">
           <el-input v-model="form.channelKey" placeholder="请输入渠道key" />
-        </el-form-item>-->
-        <el-form-item label="渠道费率" prop="rate">
-          <el-input v-model="form.rate" placeholder="请输入渠道费率" />
         </el-form-item>
-        <el-form-item label="提现渠道费率" prop="withdrawRate">
-          <el-input v-model="form.withdrawRate" placeholder="请输入提现渠道费率" />
+        <el-form-item label="充值手续费(%)" prop="rate">
+          <el-input v-model="form.rate" placeholder="请输入充值手续费" />
+        </el-form-item>
+        <el-form-item label="提现手续费(%)" prop="withdrawRate">
+          <el-input v-model="form.withdrawRate" placeholder="请输入提现手续费" />
         </el-form-item>
 <!--        <el-form-item label="logo" prop="logoUrl">
           <el-input v-model="form.logoUrl" placeholder="请输入logo" />
@@ -403,6 +412,12 @@ export default {
       const id = row.id || this.ids
       getChannel(id).then(response => {
         this.form = response.data;
+        if(this.form.rate){
+          this.form.rate = this.form.rate * 100;
+        }
+        if(this.form.withdrawRate){
+          this.form.withdrawRate = this.form.withdrawRate * 100;
+        }
         this.open = true;
         this.title = "修改充值渠道";
       });