活动管理-抽奖记录列表修改
This commit is contained in:
parent
6e3a0f4b8f
commit
cd5f52c1b5
|
|
@ -525,6 +525,21 @@ var table = {
|
|||
});
|
||||
return actions.join('');
|
||||
},
|
||||
// 回显奖品名称
|
||||
selectprivename: function(datas, value) {
|
||||
if ($.common.isEmpty(datas) || $.common.isEmpty(value)) {
|
||||
return '';
|
||||
}
|
||||
var actions = [];
|
||||
$.each(datas, function(index, draw) {
|
||||
if (draw.prizecode == ('' + value)) {
|
||||
var listClass = $.common.equals("default", draw.listClass) || $.common.isEmpty(draw.listClass) ? "" : "badge badge-" + draw.listClass;
|
||||
actions.push($.common.sprintf("<span class='%s'>%s</span>", listClass, draw.prizename));
|
||||
return false;
|
||||
}
|
||||
});
|
||||
return actions.join('');
|
||||
},
|
||||
// 回显数据字典(字符串数组)
|
||||
selectDictLabels: function(datas, value, separator) {
|
||||
if ($.common.isEmpty(datas) || $.common.isEmpty(value)) {
|
||||
|
|
|
|||
|
|
@ -33,6 +33,8 @@ public interface DrawPrizeInfoMapper
|
|||
*/
|
||||
public List<DrawPrizeInfo> selectDrawPrizeInfoList(DrawPrizeInfo drawPrizeInfo);
|
||||
|
||||
List<DrawPrizeInfo> findDrawPrizeInfoList();
|
||||
|
||||
/**
|
||||
* 新增存储奖品的基础信息
|
||||
*
|
||||
|
|
|
|||
|
|
@ -27,6 +27,12 @@ public interface IDrawPrizeInfoService
|
|||
*/
|
||||
public List<DrawPrizeInfo> selectDrawPrizeInfoList(DrawPrizeInfo drawPrizeInfo);
|
||||
|
||||
/**
|
||||
* 奖品列表-下拉框
|
||||
* @return
|
||||
*/
|
||||
List<DrawPrizeInfo> findDrawPrizeInfoList();
|
||||
|
||||
/**
|
||||
* 新增存储奖品的基础信息
|
||||
*
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ import com.ruoyi.common.core.text.Convert;
|
|||
* @author dy
|
||||
* @date 2021-03-25
|
||||
*/
|
||||
@Service
|
||||
@Service("drawPrize")
|
||||
public class DrawPrizeInfoServiceImpl implements IDrawPrizeInfoService
|
||||
{
|
||||
@Autowired
|
||||
|
|
@ -45,6 +45,11 @@ public class DrawPrizeInfoServiceImpl implements IDrawPrizeInfoService
|
|||
return drawPrizeInfoMapper.selectDrawPrizeInfoList(drawPrizeInfo);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DrawPrizeInfo> findDrawPrizeInfoList() {
|
||||
return drawPrizeInfoMapper.findDrawPrizeInfoList();
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增存储奖品的基础信息
|
||||
*
|
||||
|
|
|
|||
|
|
@ -36,6 +36,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
</where>
|
||||
</select>
|
||||
|
||||
<select id="findDrawPrizeInfoList" resultMap="DrawPrizeInfoResult">
|
||||
<include refid="selectDrawPrizeInfoVo"/>
|
||||
</select>
|
||||
|
||||
<select id="selectDrawPrizeInfoById" parameterType="java.lang.String" resultMap="DrawPrizeInfoResult">
|
||||
<include refid="selectDrawPrizeInfoVo"/>
|
||||
where PRIZEID = #{PRIZEID}
|
||||
|
|
|
|||
|
|
@ -10,18 +10,22 @@
|
|||
<form id="formId">
|
||||
<div class="select-list">
|
||||
<ul>
|
||||
<li>
|
||||
<label>抽奖流水:</label>
|
||||
<input type="text" name="DRAWTRANSEQNO"/>
|
||||
</li>
|
||||
<!-- <li>-->
|
||||
<!-- <label>抽奖流水:</label>-->
|
||||
<!-- <input type="text" name="DRAWTRANSEQNO"/>-->
|
||||
<!-- </li>-->
|
||||
<li>
|
||||
<label>活动代码:</label>
|
||||
<input type="text" name="DRAWCODE"/>
|
||||
<select name="DRAWCODE" th:with="drawinfo=${@drawInfo.findDrawInfoList()}">
|
||||
<option value="">所有</option>
|
||||
<option th:each="drawInfo : ${drawinfo}" th:text="${drawInfo.DRAWNAME}"
|
||||
th:value="${drawInfo.DRAWCODE}"></option>
|
||||
</select>
|
||||
</li>
|
||||
<li>
|
||||
<label>用户标识:</label>
|
||||
<input type="text" name="USERID"/>
|
||||
</li>
|
||||
<!-- <li>-->
|
||||
<!-- <label>用户标识:</label>-->
|
||||
<!-- <input type="text" name="USERID"/>-->
|
||||
<!-- </li>-->
|
||||
<!-- <li>-->
|
||||
<!-- <label>抽奖时间:</label>-->
|
||||
<!-- <input type="text" class="time-input" placeholder="请选择抽奖时间" name="DRAWTIME"/>-->
|
||||
|
|
@ -32,19 +36,24 @@
|
|||
</li>
|
||||
<li>
|
||||
<label>奖品代码:</label>
|
||||
<input type="text" name="PRIZECODE"/>
|
||||
<select name="PRIZECODE" th:with="drawPrize=${@drawPrize.findDrawPrizeInfoList()}">
|
||||
<option value="">所有</option>
|
||||
<option th:each="drawPrize : ${drawPrize}" th:text="${drawPrize.PRIZENAME}"
|
||||
th:value="${drawPrize.PRIZECODE}"></option>
|
||||
</select>
|
||||
</li>
|
||||
<li>
|
||||
<label>用户名:</label>
|
||||
<input type="text" name="USERNAME"/>
|
||||
</li>
|
||||
<li>
|
||||
<label>奖品类型:</label>
|
||||
<select name="PRIZETYPE" th:with="type=${@dict.getType('prizeType')}" style="width: 100px">
|
||||
<option value="">所有</option>
|
||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||
</select>
|
||||
</li>
|
||||
<!-- <li>-->
|
||||
<!-- <label>奖品类型:</label>-->
|
||||
<!-- <select name="PRIZETYPE" th:with="type=${@dict.getType('prizeType')}" style="width: 100px">-->
|
||||
<!-- <option value="">所有</option>-->
|
||||
<!-- <option th:each="dict : ${type}" th:text="${dict.dictLabel}"-->
|
||||
<!-- th:value="${dict.dictValue}"></option>-->
|
||||
<!-- </select>-->
|
||||
<!-- </li>-->
|
||||
<!-- <li>-->
|
||||
<!-- <label>账务日期:</label>-->
|
||||
<!-- <input type="text" class="time-input" placeholder="请选择账务日期" name="CHECKINGDATE"/>-->
|
||||
|
|
@ -61,13 +70,14 @@
|
|||
<!-- <label>渠道:</label>-->
|
||||
<!-- <input type="text" name="CHANNEL"/>-->
|
||||
<!-- </li>-->
|
||||
<li>
|
||||
<label>奖品等级:</label>
|
||||
<select name="PRIZELEVEL" th:with="type=${@dict.getType('prizeLevel')}" style="width: 80px">
|
||||
<option value="">所有</option>
|
||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||
</select>
|
||||
</li>
|
||||
<!-- <li>-->
|
||||
<!-- <label>奖品等级:</label>-->
|
||||
<!-- <select name="PRIZELEVEL" th:with="type=${@dict.getType('prizeLevel')}" style="width: 80px">-->
|
||||
<!-- <option value="">所有</option>-->
|
||||
<!-- <option th:each="dict : ${type}" th:text="${dict.dictLabel}"-->
|
||||
<!-- th:value="${dict.dictValue}"></option>-->
|
||||
<!-- </select>-->
|
||||
<!-- </li>-->
|
||||
<!-- <li>-->
|
||||
<!-- <label>奖品项目编码:</label>-->
|
||||
<!-- <input type="text" name="PROJECTCODE"/>-->
|
||||
|
|
@ -81,8 +91,10 @@
|
|||
<input type="text" name="PHONE"/>
|
||||
</li>
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
|
||||
class="fa fa-search"></i> 搜索</a>
|
||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
|
||||
class="fa fa-refresh"></i> 重置</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
@ -115,6 +127,8 @@
|
|||
var prefix = ctx + "activity/record";
|
||||
var datas = [[${@dict.getType('prizeLevel')}]];
|
||||
var prizetypes = [[${@dict.getType('prizeType')}]];
|
||||
var drawInfoList = [[${@drawInfo.findDrawInfoList()}]];
|
||||
var drawPrizeList = [[${@drawPrize.findDrawPrizeInfoList()}]];
|
||||
|
||||
$(function () {
|
||||
var options = {
|
||||
|
|
@ -132,21 +146,24 @@
|
|||
title: '主键',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field: 'drawtranseqno',
|
||||
title: '抽奖流水'
|
||||
},
|
||||
{
|
||||
field: 'drawcode',
|
||||
title: '抽奖活动代码'
|
||||
},
|
||||
{
|
||||
field: 'userid',
|
||||
title: '用户标识'
|
||||
},
|
||||
{
|
||||
field: 'DRAWTIME',
|
||||
title: '抽奖时间'
|
||||
field: 'username',
|
||||
title: '用户名'
|
||||
},
|
||||
{
|
||||
field: 'phone',
|
||||
title: '手机号'
|
||||
},
|
||||
{
|
||||
field: 'drawcode',
|
||||
title: '抽奖活动代码',
|
||||
formatter: function (value, row, index) {
|
||||
return $.table.selectDrawname(drawInfoList, value);
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'drawresult',
|
||||
|
|
@ -154,18 +171,37 @@
|
|||
},
|
||||
{
|
||||
field: 'prizecode',
|
||||
title: '奖品代码'
|
||||
title: '奖品名称',
|
||||
formatter: function (value, row, index) {
|
||||
return $.table.selectprivename(drawPrizeList, value);
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'DRAWTIME',
|
||||
title: '抽奖时间'
|
||||
},
|
||||
{
|
||||
field: 'drawtranseqno',
|
||||
title: '抽奖流水',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field: 'projectcode',
|
||||
title: '奖品项目编码',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field: 'prizetype',
|
||||
title: '奖品类型',
|
||||
visible: false,
|
||||
formatter: function (value, row, index) {
|
||||
return $.table.selectDictLabel(prizetypes, value);
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'CHECKINGDATE',
|
||||
title: '账务日期'
|
||||
title: '账务日期',
|
||||
visible: false
|
||||
},
|
||||
// {
|
||||
// field: 'CREATETIMESTAMP',
|
||||
|
|
@ -177,34 +213,29 @@
|
|||
// },
|
||||
{
|
||||
field: 'channel',
|
||||
title: '渠道'
|
||||
},
|
||||
{
|
||||
field: 'username',
|
||||
title: '用户名'
|
||||
title: '渠道',
|
||||
visible: false,
|
||||
},
|
||||
|
||||
{
|
||||
field: 'prizelevel',
|
||||
title: '奖品等级',
|
||||
visible: false,
|
||||
formatter: function (value, row, index) {
|
||||
return $.table.selectDictLabel(datas, value);
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'projectcode',
|
||||
title: '奖品项目编码'
|
||||
},
|
||||
|
||||
{
|
||||
field: 'source',
|
||||
title: '请求来源'
|
||||
},
|
||||
{
|
||||
field: 'phone',
|
||||
title: '手机号'
|
||||
title: '请求来源',
|
||||
visible: false
|
||||
},
|
||||
|
||||
{
|
||||
field: 'extarea',
|
||||
title: '扩展域'
|
||||
title: '扩展域',
|
||||
visible: false
|
||||
},
|
||||
// {
|
||||
// title: '操作',
|
||||
|
|
|
|||
Loading…
Reference in New Issue