寻爱-后台-分区
This commit is contained in:
@@ -10,15 +10,20 @@
|
||||
<section class="content">
|
||||
<div id="table"></div>
|
||||
<div id="toolbar">
|
||||
<form action="" id="searchForm" method="POST">
|
||||
<select name="search-type" id="search-type">
|
||||
<option value="0">请选择</option>
|
||||
<form action=""
|
||||
id="searchForm"
|
||||
method="POST">
|
||||
<select name="search-type"
|
||||
id="search-type">
|
||||
<option value="1">幸运许愿池偏差类型</option>
|
||||
<option value="4">梦幻许愿池池偏差类型</option>
|
||||
</select>
|
||||
<select id="partitionId"></select>
|
||||
</form>
|
||||
<button class="btn btn-primary" id="searchBtn">搜索</button>
|
||||
<button id="add" class="btn btn-default">
|
||||
<button class="btn btn-primary"
|
||||
id="searchBtn">搜索</button>
|
||||
<button id="add"
|
||||
class="btn btn-default">
|
||||
<i class="glyphicon glyphicon-plus"></i>新增
|
||||
</button>
|
||||
</div>
|
||||
@@ -26,21 +31,35 @@
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<div class="modal fade" id="deviateRangeModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal fade"
|
||||
id="deviateRangeModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel">
|
||||
<div class="modal-dialog"
|
||||
role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title" id="modalLabel">偏差范围</h4>
|
||||
<button type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title"
|
||||
id="modalLabel">偏差范围</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<form class="form-horizontal" id="deviateRangeForm">
|
||||
<input id="deviateRangeId" type="hidden" name="id" />
|
||||
<form class="form-horizontal"
|
||||
id="deviateRangeForm">
|
||||
<input id="deviateRangeId"
|
||||
type="hidden"
|
||||
name="id" />
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">下限:</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="number" id="deviateLowerLimit" name="lowerLimit" class=" validate[required]"
|
||||
<input type="number"
|
||||
id="deviateLowerLimit"
|
||||
name="lowerLimit"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">
|
||||
</div>
|
||||
</div>
|
||||
@@ -48,33 +67,58 @@
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">上限:</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="number" id="deviateUpperLimit" name="upperLimit" class=" validate[required]"
|
||||
<input type="number"
|
||||
id="deviateUpperLimit"
|
||||
name="upperLimit"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group type">
|
||||
<label for="type" class="col-sm-3 control-label">选择类型:</label>
|
||||
<label for="type"
|
||||
class="col-sm-3 control-label">选择类型:</label>
|
||||
<div class="col-sm-8">
|
||||
<select name="type" id="type" data-btn-class="btn btn-warning">
|
||||
<select name="type"
|
||||
id="type"
|
||||
data-btn-class="btn btn-warning">
|
||||
<option value="1">幸运许愿池偏差类型</option>
|
||||
<option value="4">梦幻许愿池池偏差类型</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group deviatePartitionId">
|
||||
<label for="type"
|
||||
class="col-sm-3 control-label">选择分区:</label>
|
||||
<div class="col-sm-8">
|
||||
<select name="partitionId"
|
||||
id="deviatePartitionId"
|
||||
data-btn-class="btn btn-warning">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建者:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="creator" name="creator" class="validate[required]" placeholder="必填项">
|
||||
<input type="text"
|
||||
id="creator"
|
||||
name="creator"
|
||||
class="validate[required]"
|
||||
placeholder="必填项">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-primary" id="save">保存</button>
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal">关闭</button>
|
||||
<button type="button"
|
||||
class="btn btn-primary"
|
||||
id="save">保存</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -97,6 +141,34 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
initData () {
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
url: '/partition/listPartitionInfo',
|
||||
dataType: 'json',
|
||||
success: function (json) {
|
||||
if (json.code == 200) {
|
||||
var deviatePartitionId = $("#deviatePartitionId");
|
||||
deviatePartitionId.empty();
|
||||
|
||||
var partitionId = $("#partitionId");
|
||||
partitionId.empty();
|
||||
|
||||
// 遍历数据并添加 option
|
||||
$.each(json.data, function (index, item) {
|
||||
// 创建新的 option 元素
|
||||
var option = $('<option></option>')
|
||||
.attr('value', item.id) // 设置 value 属性
|
||||
.text(item.desc); // 设置文本内容
|
||||
|
||||
// 追加到 select 元素
|
||||
partitionId.append(option.clone());
|
||||
|
||||
deviatePartitionId.append(option.clone());
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
$(function () {
|
||||
$('#table').bootstrapTable('destroy');
|
||||
$('#table').bootstrapTable({
|
||||
@@ -127,7 +199,8 @@ export default {
|
||||
var param = {
|
||||
pageNumber: params.pageNumber,
|
||||
pageSize: params.pageSize,
|
||||
type: parseInt($("#search-type").val())
|
||||
type: parseInt($("#search-type").val()),
|
||||
partitionId: parseInt($("#partitionId").val())
|
||||
};
|
||||
return param;
|
||||
},
|
||||
@@ -189,6 +262,7 @@ export default {
|
||||
$("#deviateRangeId").val(data.id);
|
||||
$("#deviateLowerLimit").val(data.lowerLimit);
|
||||
$("#deviateUpperLimit").val(data.upperLimit);
|
||||
$("#deviatePartitionId").val(data.partitionId);
|
||||
$("#creator").val(data.creator);
|
||||
ComboboxHelper.setDef("#type", data.type);
|
||||
// 打开编辑弹窗
|
||||
|
@@ -9,23 +9,53 @@
|
||||
<section class="content">
|
||||
<div id="table"></div>
|
||||
<div id="toolbar">
|
||||
<form action="" id="searchForm" method="POST">
|
||||
<form action=""
|
||||
id="searchForm"
|
||||
method="POST">
|
||||
|
||||
奖品名称:<input type="text" name="prizeName" id="prizeName" class="input-sm" placeholder="奖品名称">
|
||||
奖品名称:<input type="text"
|
||||
name="prizeName"
|
||||
id="prizeName"
|
||||
class="input-sm"
|
||||
placeholder="奖品名称">
|
||||
|
||||
奖品分类:<input type="text" name="prizeType" id="prizeType" class="input-sm" placeholder="奖品分类">
|
||||
奖品分类:<input type="text"
|
||||
name="prizeType"
|
||||
id="prizeType"
|
||||
class="input-sm"
|
||||
placeholder="奖品分类">
|
||||
|
||||
平台价值区间:<input type="text" name="priceStart" id="priceStart" class="input-sm" placeholder="最小值">
|
||||
-- <input type="text" name="priceEnd" id="priceEnd" class="input-sm" placeholder="最大值">
|
||||
平台价值区间:<input type="text"
|
||||
name="priceStart"
|
||||
id="priceStart"
|
||||
class="input-sm"
|
||||
placeholder="最小值">
|
||||
-- <input type="text"
|
||||
name="priceEnd"
|
||||
id="priceEnd"
|
||||
class="input-sm"
|
||||
placeholder="最大值">
|
||||
|
||||
<br />
|
||||
实际价值区间:<input type="text" name="actualStart" id="actualStart" class="input-sm"
|
||||
实际价值区间:<input type="text"
|
||||
name="actualStart"
|
||||
id="actualStart"
|
||||
class="input-sm"
|
||||
placeholder="最小值">
|
||||
-- <input type="text" name="actualEnd" id="actualEnd" class="input-sm" placeholder="最大值">
|
||||
-- <input type="text"
|
||||
name="actualEnd"
|
||||
id="actualEnd"
|
||||
class="input-sm"
|
||||
placeholder="最大值">
|
||||
|
||||
分区:<select id="partitionId"
|
||||
class="input-sm"></select>
|
||||
</form>
|
||||
|
||||
<button class="btn btn-primary" id="searchBtn">搜索</button>
|
||||
<button class="btn btn-primary" id="add">
|
||||
<button class="btn btn-primary"
|
||||
id="searchBtn">搜索</button>
|
||||
<button class="btn btn-primary"
|
||||
id="add">
|
||||
<i class="glyphicon glyphicon-plus"></i>增加
|
||||
</button>
|
||||
</div>
|
||||
@@ -35,24 +65,39 @@
|
||||
</section>
|
||||
|
||||
<!-- 弹窗 -->
|
||||
<div class="modal fade" id="awardModal" rabindex='-1' role="dialog" aria-labelledby="modalLabel">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal fade"
|
||||
id="awardModal"
|
||||
rabindex='-1'
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel">
|
||||
<div class="modal-dialog"
|
||||
role="document">
|
||||
<div class="modal-content">
|
||||
|
||||
<div class="modal-header">
|
||||
<button class="close" type="button" data-dismiss="modal" aria-label="Close">
|
||||
<button class="close"
|
||||
type="button"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close">
|
||||
<span aria-hidden="true">x</span>
|
||||
</button>
|
||||
|
||||
<div class="modal-title" id="editModalLabel">奖品设置</div>
|
||||
<div class="modal-title"
|
||||
id="editModalLabel">奖品设置</div>
|
||||
</div>
|
||||
|
||||
<div class="modal-body">
|
||||
<div class="" id="addModalLabel">
|
||||
<label for="" class="col-sm-3 control-label" style="margin-left: 30px;">奖品类型:</label>
|
||||
<div class=""
|
||||
id="addModalLabel">
|
||||
<label for=""
|
||||
class="col-sm-3 control-label"
|
||||
style="margin-left: 30px;">奖品类型:</label>
|
||||
|
||||
<div class="col-sm-8" style="margin-left: -20px;">
|
||||
<select name="addType" id="addType" data-btn-class="btn btn-warning"
|
||||
<div class="col-sm-8"
|
||||
style="margin-left: -20px;">
|
||||
<select name="addType"
|
||||
id="addType"
|
||||
data-btn-class="btn btn-warning"
|
||||
style="border-radius: 2px; width: 100px; height: 30px;">
|
||||
<option value="budGold">钻石</option>
|
||||
<option value="onlineGift">线上礼物</option>
|
||||
@@ -63,15 +108,20 @@
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<form action="" id="addForm" class="form-horizontal">
|
||||
<form action=""
|
||||
id="addForm"
|
||||
class="form-horizontal">
|
||||
|
||||
<!-- 选择礼物 -->
|
||||
<div class="form-group awardChoose">
|
||||
|
||||
<label for="awardChoose" class="col-sm-3 control-label">选择礼物:</label>
|
||||
<label for="awardChoose"
|
||||
class="col-sm-3 control-label">选择礼物:</label>
|
||||
|
||||
<div class="col-sm-4">
|
||||
<select name="awardChoose" id="awardChoose" onchange="updateAward(this)">
|
||||
<select name="awardChoose"
|
||||
id="awardChoose"
|
||||
onchange="updateAward(this)">
|
||||
<!-- <option value="0">选取礼物</option> -->
|
||||
</select>
|
||||
</div>
|
||||
@@ -80,10 +130,13 @@
|
||||
<!-- 选择装扮类型 -->
|
||||
<div class="form-group dressType">
|
||||
|
||||
<label for="dressType" class="col-sm-3 control-label">选择装扮类型:</label>
|
||||
<label for="dressType"
|
||||
class="col-sm-3 control-label">选择装扮类型:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<select name="dressType" id="dressType" data-btn-class="btn btn-warning">
|
||||
<select name="dressType"
|
||||
id="dressType"
|
||||
data-btn-class="btn btn-warning">
|
||||
<option value="4">头饰</option>
|
||||
<option value="3">座驾</option>
|
||||
<!--<option value="5">背景</option>-->
|
||||
@@ -94,30 +147,39 @@
|
||||
<!-- 选择具体装扮 -->
|
||||
<div class="form-group realDressType headwearGift">
|
||||
|
||||
<label for="realDressType" class="col-sm-3 control-label">选择具体装扮:</label>
|
||||
<label for="realDressType"
|
||||
class="col-sm-3 control-label">选择具体装扮:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<select name="realDressType" id="realDressType" class=" headwearContent">
|
||||
<select name="realDressType"
|
||||
id="realDressType"
|
||||
class=" headwearContent">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group realDressType carGift">
|
||||
|
||||
<label for="realDressType" class="col-sm-3 control-label">选择具体装扮:</label>
|
||||
<label for="realDressType"
|
||||
class="col-sm-3 control-label">选择具体装扮:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<select name="realDressType" id="realDressType" class=" carContent">
|
||||
<select name="realDressType"
|
||||
id="realDressType"
|
||||
class=" carContent">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group realDressType backgroundGift">
|
||||
|
||||
<label for="realDressType" class="col-sm-3 control-label">选择具体装扮:</label>
|
||||
<label for="realDressType"
|
||||
class="col-sm-3 control-label">选择具体装扮:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<select name="realDressType" id="realDressType" class=" backgroundContent">
|
||||
<select name="realDressType"
|
||||
id="realDressType"
|
||||
class=" backgroundContent">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
@@ -125,9 +187,14 @@
|
||||
<!-- 奖品名称 -->
|
||||
<div class="form-group giftName">
|
||||
|
||||
<label for="giftName" class="col-sm-3 control-label">奖品名称:</label>
|
||||
<label for="giftName"
|
||||
class="col-sm-3 control-label">奖品名称:</label>
|
||||
|
||||
<input type="text" class="validate[required]" name="giftName" id="giftName" placeholder="单行输入">
|
||||
<input type="text"
|
||||
class="validate[required]"
|
||||
name="giftName"
|
||||
id="giftName"
|
||||
placeholder="单行输入">
|
||||
</div>
|
||||
|
||||
<!-- 奖品图片 -->
|
||||
@@ -136,11 +203,20 @@
|
||||
<label class="col-sm-3 control-label">奖品图片:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<img src="" alt="" id="imgUrl" style="width: 50px; height: 50px;">
|
||||
<input type="file" id="uploadFile" name="uploadFile"
|
||||
<img src=""
|
||||
alt=""
|
||||
id="imgUrl"
|
||||
style="width: 50px; height: 50px;">
|
||||
<input type="file"
|
||||
id="uploadFile"
|
||||
name="uploadFile"
|
||||
accept="image/gif,image/jpeg,image/jpg,image/png,image/svg">
|
||||
<button class="btn btn-success" type="button" id="uploadBtn">上传</button>
|
||||
<input type="hidden" id="alertWinPic" name="alertWinPic"
|
||||
<button class="btn btn-success"
|
||||
type="button"
|
||||
id="uploadBtn">上传</button>
|
||||
<input type="hidden"
|
||||
id="alertWinPic"
|
||||
name="alertWinPic"
|
||||
class="form-control validate[required]">
|
||||
</div>
|
||||
</div>
|
||||
@@ -152,46 +228,67 @@
|
||||
|
||||
<div class="col-sm-8">
|
||||
<label for="">
|
||||
<input type="radio" name="setDay">
|
||||
<input type="text" class="input-sm" placeholder="0" style='width: 80px;'> 天
|
||||
<input type="radio"
|
||||
name="setDay">
|
||||
<input type="text"
|
||||
class="input-sm"
|
||||
placeholder="0"
|
||||
style='width: 80px;'> 天
|
||||
</label>
|
||||
<label for="">
|
||||
<input type="radio" name="setDay">
|
||||
<input type="text" class="input-sm" placeholder="0" style="width:80px;"> 月
|
||||
<input type="radio"
|
||||
name="setDay">
|
||||
<input type="text"
|
||||
class="input-sm"
|
||||
placeholder="0"
|
||||
style="width:80px;"> 月
|
||||
</label>
|
||||
<label for="">
|
||||
<input type="radio" name="setDay"> 永久
|
||||
<input type="radio"
|
||||
name="setDay"> 永久
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 平台价值 -->
|
||||
<div class="form-group platformPrice">
|
||||
<label for="platformPrice" class="col-sm-3 control-label">平台价值:</label>
|
||||
<label for="platformPrice"
|
||||
class="col-sm-3 control-label">平台价值:</label>
|
||||
|
||||
<div class="col-sm-3">
|
||||
<input type="text" id="platformPrice" name="platformPrice"
|
||||
class="form-control validate[required]" placeholder="">
|
||||
<input type="text"
|
||||
id="platformPrice"
|
||||
name="platformPrice"
|
||||
class="form-control validate[required]"
|
||||
placeholder="">
|
||||
</div>
|
||||
|
||||
<div class="col-sm-3" id="attention" style="color:lightgray;">平台价值和实际价值都指钻石价值</div>
|
||||
<div class="col-sm-3"
|
||||
id="attention"
|
||||
style="color:lightgray;">平台价值和实际价值都指钻石价值</div>
|
||||
</div>
|
||||
|
||||
<!-- 实际价值 -->
|
||||
<div class="form-group realPrice">
|
||||
<label for="realPrice" class="col-sm-3 control-label">实际价值:</label>
|
||||
<label for="realPrice"
|
||||
class="col-sm-3 control-label">实际价值:</label>
|
||||
|
||||
<div class="col-sm-3">
|
||||
<input type="text" id="realPrice" name="realPrice" class="form-control validate[required]">
|
||||
<input type="text"
|
||||
id="realPrice"
|
||||
name="realPrice"
|
||||
class="form-control validate[required]">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 礼物等级 -->
|
||||
<div class="form-group awardLevel">
|
||||
<label for="awardLevel" class="col-sm-3 control-label">礼物等级:</label>
|
||||
<label for="awardLevel"
|
||||
class="col-sm-3 control-label">礼物等级:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<select name="awardLevel" id="awardLevel">
|
||||
<select name="awardLevel"
|
||||
id="awardLevel">
|
||||
<option value="1">一级</option>
|
||||
<option value="2">二级</option>
|
||||
<option value="3">三级</option>
|
||||
@@ -201,12 +298,28 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创建者 -->
|
||||
<div class="form-group creator">
|
||||
<label for="creator" class="col-sm-3 control-label">创建者:</label>
|
||||
<!-- 分区 -->
|
||||
<div class="form-group awardPartitionId">
|
||||
<label for="awardPartitionId"
|
||||
class="col-sm-3 control-label">分区:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="creator" name="creator" class="form-control validate[required]"
|
||||
<select name="awardPartitionId"
|
||||
id="awardPartitionId">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创建者 -->
|
||||
<div class="form-group creator">
|
||||
<label for="creator"
|
||||
class="col-sm-3 control-label">创建者:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text"
|
||||
id="creator"
|
||||
name="creator"
|
||||
class="form-control validate[required]"
|
||||
placeholder="请输入你的名字(必填)">
|
||||
</div>
|
||||
</div>
|
||||
@@ -215,9 +328,14 @@
|
||||
|
||||
<div class="modal-footer">
|
||||
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal">取消</button>
|
||||
|
||||
<button type="button" class="btn btn-primary" data-primary="addSave" id="save">保存</button>
|
||||
<button type="button"
|
||||
class="btn btn-primary"
|
||||
data-primary="addSave"
|
||||
id="save">保存</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -244,7 +362,6 @@ export default {
|
||||
},
|
||||
created () {
|
||||
this.initData();
|
||||
|
||||
},
|
||||
methods: {
|
||||
initData () {
|
||||
@@ -276,6 +393,42 @@ export default {
|
||||
|
||||
getDataFromBack: function () {
|
||||
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
url: '/partition/listPartitionInfo',
|
||||
dataType: 'json',
|
||||
success: function (json) {
|
||||
if (json.code == 200) {
|
||||
var awardPartitionId = $("#awardPartitionId");
|
||||
awardPartitionId.empty();
|
||||
|
||||
var partitionId = $("#partitionId");
|
||||
partitionId.empty();
|
||||
|
||||
var defaultOption = $('<option></option>').attr('value', '').text("全部");
|
||||
partitionId.append(defaultOption);
|
||||
|
||||
// 遍历数据并添加 option
|
||||
$.each(json.data, function (index, item) {
|
||||
// 创建新的 option 元素
|
||||
var option = $('<option></option>')
|
||||
.attr('value', item.id) // 设置 value 属性
|
||||
.text(item.desc); // 设置文本内容
|
||||
|
||||
// 追加到 select 元素
|
||||
partitionId.append(option.clone());
|
||||
|
||||
awardPartitionId.append(option.clone());
|
||||
});
|
||||
|
||||
window.partitionInfo = json.data.reduce((acc, item) => {
|
||||
acc[item.id] = item.desc;
|
||||
return acc;
|
||||
}, {});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// 获取头饰的数据
|
||||
$.get('/admin/headwear/total/list', {}, function (res) {
|
||||
if (res.code == 200) {
|
||||
@@ -409,6 +562,11 @@ export default {
|
||||
// {filed: '', title: '历史被抽中数量', align: 'center', valign: 'middle', width: '10%'},
|
||||
{ field: 'platformValue', title: '平台价值', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'actualValue', title: '实际价值', align: 'center', valign: 'middle', width: '10%' },
|
||||
{
|
||||
field: 'partitionId', title: '分区', align: 'center', valign: 'middle', width: '10%', formatter: function (val, row, index) {
|
||||
return window.partitionInfo[val] || val;
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'tmp', title: '操作', align: 'center', valign: 'middle', width: '10%', formatter: function (val, row, index) {
|
||||
var key = row.id;
|
||||
@@ -449,7 +607,8 @@ export default {
|
||||
minPlatformValue: $('#priceStart').val(),
|
||||
maxPlatformValue: $('#priceEnd').val(),
|
||||
minActualValue: $('#actualStart').val(),
|
||||
maxActualValue: $('#actualEnd').val()
|
||||
maxActualValue: $('#actualEnd').val(),
|
||||
partitionId: $('#partitionId').val(),
|
||||
};
|
||||
return param;
|
||||
},
|
||||
@@ -619,8 +778,6 @@ export default {
|
||||
|
||||
$('.realPrice').find('#realPrice').val(data.actualValue);
|
||||
|
||||
console.log(data.prizeLevel);
|
||||
|
||||
$('.awardLevel').find('select').val(data.prizeLevel);
|
||||
|
||||
$('#imgUrl').attr('src', data.prizeImgUrl);
|
||||
@@ -631,6 +788,7 @@ export default {
|
||||
$('#addForm').data('wpType', data.prizeType);
|
||||
$('#addForm').data('referenceID', data.referenceId);
|
||||
|
||||
$('#awardPartitionId').val(data.partitionId);
|
||||
});
|
||||
|
||||
// 添加事件
|
||||
@@ -869,6 +1027,7 @@ export default {
|
||||
$('#tipMsg').text('等级选择栏不能为空')
|
||||
$('#tipModal').modal('show');
|
||||
}
|
||||
param.partitionId = $('#awardPartitionId').val();
|
||||
|
||||
$.ajax({
|
||||
type: 'post',
|
||||
@@ -882,7 +1041,8 @@ export default {
|
||||
prizeLevel: param.prizeLevel,
|
||||
creator: param.creator,
|
||||
platFormValue: param.platformValue,
|
||||
actualValue: param.actualValue
|
||||
actualValue: param.actualValue,
|
||||
partitionId: param.partitionId,
|
||||
},
|
||||
dataType: 'json',
|
||||
success: function (res) {
|
||||
@@ -903,7 +1063,11 @@ export default {
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
data () {
|
||||
return {
|
||||
partitionInfo: [],
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
</script>
|
||||
|
@@ -8,33 +8,63 @@
|
||||
<section class="content">
|
||||
|
||||
<div id="toolbar">
|
||||
<form action="" id="searchForm" method="POST">
|
||||
<form action=""
|
||||
id="searchForm"
|
||||
method="POST">
|
||||
<div class="col-sm-12">
|
||||
<label for="partitionId"
|
||||
class="qry_col control-label">分区:</label>
|
||||
<div class="col-sm-2">
|
||||
<select id="partitionId"
|
||||
class="input-sm"></select>
|
||||
</div>
|
||||
<div class="col-sm-4">
|
||||
<label for="timeBegin" class="qry_col control-label">日期:</label>
|
||||
<input type="text" name="timeBegin" id="timeBegin" class="input-sm" placeholder="起始时间">
|
||||
- <input type="text" name="timeEnd" id="timeEnd" class="input-sm" placeholder="结束时间">
|
||||
<label for="timeBegin"
|
||||
class="qry_col control-label">日期:</label>
|
||||
<input type="text"
|
||||
name="timeBegin"
|
||||
id="timeBegin"
|
||||
class="input-sm"
|
||||
placeholder="起始时间">
|
||||
- <input type="text"
|
||||
name="timeEnd"
|
||||
id="timeEnd"
|
||||
class="input-sm"
|
||||
placeholder="结束时间">
|
||||
</div>
|
||||
<label for="erbanNo" class="qry_col control-label">平台号:</label>
|
||||
<label for="erbanNo"
|
||||
class="qry_col control-label">平台号:</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" name="erbanNo" id="erbanNo" class="input-sm" placeholder="">
|
||||
<input type="text"
|
||||
name="erbanNo"
|
||||
id="erbanNo"
|
||||
class="input-sm"
|
||||
placeholder="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<label for="boxType" class="qry_col control-label">许愿池类型:</label>
|
||||
<label for="boxType"
|
||||
class="qry_col control-label">许愿池类型:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="boxType" id="boxType" class="col-sm-2 form-control"
|
||||
<select name="boxType"
|
||||
id="boxType"
|
||||
class="col-sm-2 form-control"
|
||||
data-btn-class="btn-warning">
|
||||
<option value="" selected="selected">全部</option>
|
||||
<option value=""
|
||||
selected="selected">全部</option>
|
||||
<option value="1">幸运许愿池</option>
|
||||
<option value="2">梦幻许愿池</option>
|
||||
</select>
|
||||
</div>
|
||||
<label for="poolType" class="qry_col control-label">奖池类型:</label>
|
||||
<label for="poolType"
|
||||
class="qry_col control-label">奖池类型:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="poolType" id="poolType" class="col-sm-2 form-control"
|
||||
<select name="poolType"
|
||||
id="poolType"
|
||||
class="col-sm-2 form-control"
|
||||
data-btn-class="btn-warning">
|
||||
<option value="" selected="selected">全部</option>
|
||||
<option value=""
|
||||
selected="selected">全部</option>
|
||||
<option value="1">幸运新人奖池</option>
|
||||
<option value="2">幸运普通奖池</option>
|
||||
<option value="3">幸运白名单奖池</option>
|
||||
@@ -46,17 +76,22 @@
|
||||
<option value="11">梦幻白名单奖池</option>
|
||||
</select>
|
||||
</div>
|
||||
<label for="dataType" class="qry_col control-label">数据类型:</label>
|
||||
<label for="dataType"
|
||||
class="qry_col control-label">数据类型:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="dataType" id="dataType" class="col-sm-2 form-control"
|
||||
<select name="dataType"
|
||||
id="dataType"
|
||||
class="col-sm-2 form-control"
|
||||
data-btn-class="btn-warning">
|
||||
<option value="1" selected="selected">普通用户数据</option>
|
||||
<option value="1"
|
||||
selected="selected">普通用户数据</option>
|
||||
<option value="2">被排除用户的数据</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<button class="btn btn-primary" id="searchBtn">筛选</button>
|
||||
<button class="btn btn-primary"
|
||||
id="searchBtn">筛选</button>
|
||||
<div class="tips">因数据量庞大,默认不会显示每天的结果,默认只展示平台总收益情况,请先选择时间范围再搜索</div>
|
||||
<div class="dataCount">
|
||||
<p>
|
||||
@@ -90,7 +125,6 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="table"></div>
|
||||
</section>
|
||||
</div>
|
||||
@@ -113,6 +147,37 @@ export default {
|
||||
methods: {
|
||||
initData () {
|
||||
$(function () {
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
url: '/partition/listPartitionInfo',
|
||||
dataType: 'json',
|
||||
success: function (json) {
|
||||
if (json.code == 200) {
|
||||
//var deviatePartitionId = $("#deviatePartitionId");
|
||||
//deviatePartitionId.empty();
|
||||
|
||||
var partitionId = $("#partitionId");
|
||||
partitionId.empty();
|
||||
|
||||
var defaultOption = $('<option></option>').attr('value', '').text("全部");
|
||||
partitionId.append(defaultOption);
|
||||
|
||||
// 遍历数据并添加 option
|
||||
$.each(json.data, function (index, item) {
|
||||
// 创建新的 option 元素
|
||||
var option = $('<option></option>')
|
||||
.attr('value', item.id) // 设置 value 属性
|
||||
.text(item.desc); // 设置文本内容
|
||||
|
||||
// 追加到 select 元素
|
||||
partitionId.append(option.clone());
|
||||
|
||||
//deviatePartitionId.append(option.clone());
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
var picker1 = $('#timeBegin').datetimepicker({
|
||||
format: 'yyyy-mm-dd',
|
||||
todayBtn: true,
|
||||
@@ -182,7 +247,8 @@ export default {
|
||||
endDate: $timeEnd,
|
||||
boxType: $('#boxType').val(),
|
||||
poolType: $('#poolType').val(),
|
||||
dataType: $('#dataType').val()
|
||||
dataType: $('#dataType').val(),
|
||||
partitionId: $("#partitionId").val(),
|
||||
}, function (res) {
|
||||
console.log(res);
|
||||
|
||||
@@ -284,6 +350,7 @@ export default {
|
||||
poolType: $('#poolType').val(),
|
||||
erbanNo: $('#erbanNo').val(),
|
||||
dataType: $('#dataType').val(),
|
||||
partitionId: $('#partitionId').val(),
|
||||
};
|
||||
return param;
|
||||
},
|
||||
@@ -329,4 +396,5 @@ export default {
|
||||
|
||||
.qry_col {
|
||||
float: left;
|
||||
}</style>
|
||||
}
|
||||
</style>
|
@@ -12,9 +12,14 @@
|
||||
<div id="toolbar">
|
||||
|
||||
<div class="col-sm-12">
|
||||
<form action="" id="searchForm" method="POST">
|
||||
|
||||
转盘分类:<select name="jackpotType" id="jackpotType" data-btn-class="btn btn-warning">
|
||||
<form action=""
|
||||
id="searchForm"
|
||||
method="POST">
|
||||
分区:<select id="partitionId"
|
||||
class="input-sm"></select>
|
||||
转盘分类:<select name="jackpotType"
|
||||
class="input-sm"
|
||||
id="jackpotType">
|
||||
<option value="1">幸运新人奖池</option>
|
||||
<option value="2">幸运普通奖池</option>
|
||||
<option value="3">幸运白名单奖池</option>
|
||||
@@ -29,17 +34,23 @@
|
||||
</select>
|
||||
<label class="deviateRange">
|
||||
偏差范围:
|
||||
<select name="deviateRange" id="deviateRange" data-btn-class="btn btn-warning">
|
||||
<select name="deviateRange"
|
||||
id="deviateRange"
|
||||
data-btn-class="btn btn-warning">
|
||||
</select>
|
||||
</label>
|
||||
<label class="diamondDeviateRange">
|
||||
偏差范围:
|
||||
<select name="diamondDeviateRange" id="diamondDeviateRange" data-btn-class="btn btn-warning">
|
||||
<select name="diamondDeviateRange"
|
||||
id="diamondDeviateRange"
|
||||
data-btn-class="btn btn-warning">
|
||||
</select>
|
||||
</label>
|
||||
</form>
|
||||
<button class="btn btn-primary" id="searchBtn">搜索</button>
|
||||
<button class="btn btn-primary" id="add">添加奖品</button>
|
||||
<button class="btn btn-primary"
|
||||
id="searchBtn">搜索</button>
|
||||
<button class="btn btn-primary"
|
||||
id="add">添加奖品</button>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-12 jackpot">
|
||||
@@ -51,10 +62,14 @@
|
||||
</p>
|
||||
|
||||
<p class="col-sm-12">
|
||||
<span class="col-sm-3" id="jackpotName"></span>
|
||||
<span class="col-sm-3" id="jackpotNum"></span>
|
||||
<span class="col-sm-3" id="prizeNum"></span>
|
||||
<span class="col-sm-3" id="expectNum"></span>
|
||||
<span class="col-sm-3"
|
||||
id="jackpotName"></span>
|
||||
<span class="col-sm-3"
|
||||
id="jackpotNum"></span>
|
||||
<span class="col-sm-3"
|
||||
id="prizeNum"></span>
|
||||
<span class="col-sm-3"
|
||||
id="expectNum"></span>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
@@ -65,31 +80,47 @@
|
||||
</section>
|
||||
|
||||
<!-- 添加弹窗 -->
|
||||
<div class="modal fade" id="addModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div class="modal fade"
|
||||
id="addModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel">
|
||||
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-dialog"
|
||||
role="document">
|
||||
<div class="modal-content">
|
||||
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<button type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close">
|
||||
<span aria-hidden="true">x</span>
|
||||
</button>
|
||||
|
||||
<h4 class="modal-title" id="addModalLabel">添加奖品</h4>
|
||||
<h4 class="modal-title"
|
||||
id="addModalLabel">添加奖品</h4>
|
||||
</div>
|
||||
|
||||
<div class="modal-body">
|
||||
<form action="" class="form-horizontal" id="addForm">
|
||||
<form action=""
|
||||
class="form-horizontal"
|
||||
id="addForm">
|
||||
|
||||
<!-- 选择奖品 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">选择奖品:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">选择奖品:</label>
|
||||
<div class="col-sm-8">
|
||||
<select name="awardType" id="awardType" data-btn-class="btn btn-warning">
|
||||
<select name="awardType"
|
||||
id="awardType"
|
||||
data-btn-class="btn btn-warning">
|
||||
<!-- <option value=""></option> -->
|
||||
</select>
|
||||
|
||||
<select name="awardChoose" id="awardChoose" data-btn-class="btn btn-warning">
|
||||
<select name="awardChoose"
|
||||
id="awardChoose"
|
||||
data-btn-class="btn btn-warning">
|
||||
<!-- <option value=""></option> -->
|
||||
</select>
|
||||
</div>
|
||||
@@ -97,19 +128,29 @@
|
||||
|
||||
<!-- 奖品个数 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">奖品个数:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">奖品个数:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="jackpotNumber" name="jackpotNumber" class=" validate[required]" placeholder="单行输入">
|
||||
<input type="text"
|
||||
id="jackpotNumber"
|
||||
name="jackpotNumber"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 中奖率 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">实际中奖率:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">实际中奖率:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="winningRate" name="winningRate" class=" validate[required]" placeholder="单行输入">%
|
||||
<input type="text"
|
||||
id="winningRate"
|
||||
name="winningRate"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">%
|
||||
<br />
|
||||
<div class="tips">
|
||||
<i class="glyphicon glyphicon-info-sign"></i>中奖率综合为100,当前概率不得超过100
|
||||
@@ -119,10 +160,15 @@
|
||||
|
||||
<!-- 展示中奖率 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">展示中奖率:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">展示中奖率:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="showRate" name="showRate" class=" validate[required]" placeholder="单行输入">%
|
||||
<input type="text"
|
||||
id="showRate"
|
||||
name="showRate"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">%
|
||||
<br />
|
||||
<div class="tips">
|
||||
<i class="glyphicon glyphicon-info-sign"></i>中奖率综合为100,当前概率不得超过100
|
||||
@@ -131,21 +177,41 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">是否默认奖品:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">是否默认奖品:</label>
|
||||
<div class="col-sm-8">
|
||||
<select name="itemType" id="itemType" data-btn-class="btn btn-warning">
|
||||
<select name="itemType"
|
||||
id="itemType"
|
||||
data-btn-class="btn btn-warning">
|
||||
<option value="1"> 默认奖品 </option>
|
||||
<option value="2"> 普通奖品 </option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创建者 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">创建者:</label>
|
||||
<!-- 分区 -->
|
||||
<div class="form-group awardPartitionId">
|
||||
<label for="awardPartitionId"
|
||||
class="col-sm-3 control-label">分区:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="creator" name="creator" class="validate[required]" placeholder="必填项">
|
||||
<select name="awardPartitionId"
|
||||
id="awardPartitionId">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创建者 -->
|
||||
<div class="form-group">
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">创建者:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text"
|
||||
id="creator"
|
||||
name="creator"
|
||||
class="validate[required]"
|
||||
placeholder="必填项">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -153,8 +219,12 @@
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<button class="btn btn-default" type="button" id="addReset">重置</button>
|
||||
<button class="btn btn-primary" type="button" id="addSave">保存</button>
|
||||
<button class="btn btn-default"
|
||||
type="button"
|
||||
id="addReset">重置</button>
|
||||
<button class="btn btn-primary"
|
||||
type="button"
|
||||
id="addSave">保存</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -162,35 +232,56 @@
|
||||
</div>
|
||||
|
||||
<!-- 编辑弹窗 -->
|
||||
<div class="modal fade" id="editModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal fade"
|
||||
id="editModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel">
|
||||
<div class="modal-dialog"
|
||||
role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<button type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close">
|
||||
<span aria-hidden="true">x</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="editModalLabel">编辑奖品</h4>
|
||||
<h4 class="modal-title"
|
||||
id="editModalLabel">编辑奖品</h4>
|
||||
</div>
|
||||
|
||||
<div class="modal-body">
|
||||
<form action="" class="form-horizontal" id="editForm">
|
||||
<input type="hidden" id="editId">
|
||||
<form action=""
|
||||
class="form-horizontal"
|
||||
id="editForm">
|
||||
<input type="hidden"
|
||||
id="editId">
|
||||
<!-- 奖品个数 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">奖品个数:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">奖品个数:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="jackpotNumber2" name="jackpotNumber2" class=" validate[required]"
|
||||
<input type="text"
|
||||
id="jackpotNumber2"
|
||||
name="jackpotNumber2"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 中奖率 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">实际中奖率:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">实际中奖率:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="winningRate2" name="winningRate2" class=" validate[required]" placeholder="单行输入">%
|
||||
<input type="text"
|
||||
id="winningRate2"
|
||||
name="winningRate2"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">%
|
||||
<br />
|
||||
<div class="tips">
|
||||
<i class="glyphicon glyphicon-info-sign"></i>中奖率综合为100,当前概率不得超过100
|
||||
@@ -200,10 +291,15 @@
|
||||
|
||||
<!-- 展示给用户看的中奖率 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">展示中奖率:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">展示中奖率:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="showRate2" name="showRate2" class=" validate[required]" placeholder="单行输入">%
|
||||
<input type="text"
|
||||
id="showRate2"
|
||||
name="showRate2"
|
||||
class=" validate[required]"
|
||||
placeholder="单行输入">%
|
||||
<br />
|
||||
<div class="tips">
|
||||
<i class="glyphicon glyphicon-info-sign"></i>中奖率综合为100,当前概率不得超过100
|
||||
@@ -211,29 +307,52 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">是否默认奖品:</label>
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">是否默认奖品:</label>
|
||||
<div class="col-sm-8">
|
||||
<select name="itemType" id="itemType2" data-btn-class="btn btn-warning">
|
||||
<select name="itemType"
|
||||
id="itemType2"
|
||||
data-btn-class="btn btn-warning">
|
||||
<option value="1"> 默认奖品 </option>
|
||||
<option value="2"> 普通奖品 </option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创建者 -->
|
||||
<div class="form-group">
|
||||
<label for="" class="col-sm-3 control-label">创建者:</label>
|
||||
<!-- 分区 -->
|
||||
<div class="form-group awardPartitionId">
|
||||
<label for="awardPartitionId2"
|
||||
class="col-sm-3 control-label">分区:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text" id="creator2" name="creator2" class="validate[required]">
|
||||
<select name="awardPartitionId2"
|
||||
id="awardPartitionId2">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创建者 -->
|
||||
<div class="form-group">
|
||||
<label for=""
|
||||
class="col-sm-3 control-label">创建者:</label>
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="text"
|
||||
id="creator2"
|
||||
name="creator2"
|
||||
class="validate[required]">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<button class="btn btn-default" type="button" id="editReset">重置</button>
|
||||
<button class="btn btn-primary" type="button" id="editSave">保存</button>
|
||||
<button class="btn btn-default"
|
||||
type="button"
|
||||
id="editReset">重置</button>
|
||||
<button class="btn btn-primary"
|
||||
type="button"
|
||||
id="editSave">保存</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -243,6 +362,7 @@
|
||||
<script>
|
||||
import TableHelper from '@/utils/bootstrap-table-helper';
|
||||
|
||||
var partitionInfo = {}
|
||||
var idObj = {};
|
||||
var typeObj = {};
|
||||
var pId = '', saveId = '';
|
||||
@@ -266,6 +386,47 @@ export default {
|
||||
this.$nextTick(function () {
|
||||
var main = {
|
||||
init: function () {
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
url: '/partition/listPartitionInfo',
|
||||
dataType: 'json',
|
||||
success: function (json) {
|
||||
if (json.code == 200) {
|
||||
var awardPartitionId = $("#awardPartitionId");
|
||||
awardPartitionId.empty();
|
||||
|
||||
var awardPartitionId2 = $("#awardPartitionId2");
|
||||
awardPartitionId2.empty();
|
||||
|
||||
var partitionId = $("#partitionId");
|
||||
partitionId.empty();
|
||||
|
||||
var defaultOption = $('<option></option>').attr('value', '').text("全部");
|
||||
partitionId.append(defaultOption);
|
||||
|
||||
// 遍历数据并添加 option
|
||||
$.each(json.data, function (index, item) {
|
||||
// 创建新的 option 元素
|
||||
var option = $('<option></option>')
|
||||
.attr('value', item.id) // 设置 value 属性
|
||||
.text(item.desc); // 设置文本内容
|
||||
|
||||
// 追加到 select 元素
|
||||
partitionId.append(option.clone());
|
||||
|
||||
awardPartitionId.append(option.clone());
|
||||
|
||||
awardPartitionId2.append(option.clone());
|
||||
});
|
||||
|
||||
partitionInfo = json.data.reduce((acc, item) => {
|
||||
acc[item.id] = item.desc;
|
||||
return acc;
|
||||
}, {});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
$('.deviateRange').hide();
|
||||
$('.chargeDeviateRange').hide();
|
||||
$('.diamondDeviateRange').hide();
|
||||
@@ -358,7 +519,7 @@ export default {
|
||||
$('#table').bootstrapTable('destroy');
|
||||
$('#table').bootstrapTable({
|
||||
columns: [
|
||||
{ field: 'id', title: '奖品编号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'id', title: '奖品编号', align: 'center', valign: 'middle', width: '3%' },
|
||||
{
|
||||
field: 'prizeName', title: '奖品名称', align: 'center', valign: 'middle', width: '10%', formatter: function (val, row, index) {
|
||||
var key = row.prizeId;
|
||||
@@ -448,6 +609,11 @@ export default {
|
||||
}
|
||||
},
|
||||
{ field: 'usePrizeNum', title: '被抽中数量', align: 'center', valign: 'middle', width: '10%' },
|
||||
{
|
||||
field: 'partitionId', title: '分区', align: 'center', valign: 'middle', width: '10%', formatter: function (val, row, index) {
|
||||
return partitionInfo[val] || val;
|
||||
}
|
||||
},
|
||||
{
|
||||
field: '', title: '操作', align: 'center', valign: 'middle', width: '10%', formatter: function (val, row, index) {
|
||||
var key = row.id;
|
||||
@@ -469,7 +635,8 @@ export default {
|
||||
pageSize: params.pageSize,
|
||||
pageNumber: params.pageNumber,
|
||||
poolType: parseInt($('#jackpotType').val()),
|
||||
deviateRangeId: getDeviateRangeId()
|
||||
deviateRangeId: getDeviateRangeId(),
|
||||
partitionId: $('#partitionId').val(),
|
||||
};
|
||||
|
||||
return param;
|
||||
@@ -587,7 +754,6 @@ export default {
|
||||
$('#addModal').find('#awardType').on('change', function () {
|
||||
$('#awardChoose').find('option').remove();
|
||||
var key = $(this).val();
|
||||
console.log(key);
|
||||
// var str = '<option></option>';
|
||||
// $('#awardChoose').append(str);
|
||||
var str;
|
||||
@@ -611,6 +777,7 @@ export default {
|
||||
$('#editModal').find('#showRate2').val(data.showRatio / ACCURACY);
|
||||
$('#editModal').find('#creator2').val(data.creator);
|
||||
$('#editModal').find('#itemType2').val(data.itemType);
|
||||
$('#editModal').find('#awardPartitionId2').val(data.partitionId);
|
||||
pId = data.prizeId;
|
||||
saveId = id;
|
||||
});
|
||||
@@ -660,7 +827,8 @@ export default {
|
||||
occupationRatio: $('#winningRate').val() * ACCURACY,
|
||||
showRatio: $('#showRate').val() * ACCURACY,
|
||||
creator: $('#creator').val(),
|
||||
itemType: $('#itemType').val()
|
||||
itemType: $('#itemType').val(),
|
||||
partitionId: $('#awardPartitionId').val(),
|
||||
}, function (res) {
|
||||
if (res.code == 200) {
|
||||
$('#addModal').modal('hide');
|
||||
@@ -715,7 +883,8 @@ export default {
|
||||
occupationRatio: $('#winningRate2').val() * ACCURACY,
|
||||
showRatio: $('#showRate2').val() * ACCURACY,
|
||||
creator: $('#creator2').val(),
|
||||
itemType: $('#itemType2').val()
|
||||
itemType: $('#itemType2').val(),
|
||||
partitionId: $('#awardPartitionId2').val(),
|
||||
}, function (res) {
|
||||
if (res.code == 200) {
|
||||
// console.log(res);
|
||||
|
@@ -10,23 +10,40 @@
|
||||
<div id="toolbar">
|
||||
<div class="col-sm-12">
|
||||
<div class="pull-left">
|
||||
<form action="/admin/box/record/export" id="searchForm" method="POST">
|
||||
平台号:<input type="text" id="msNo" name="msNo" class="input-sm" placeholder="请输入平台号">
|
||||
<form action="/admin/box/record/export"
|
||||
id="searchForm"
|
||||
method="POST">
|
||||
平台号:<input type="text"
|
||||
id="msNo"
|
||||
name="msNo"
|
||||
class="input-sm"
|
||||
placeholder="请输入平台号">
|
||||
|
||||
奖品名称:<input type="text" id="prizeName" name="prizeName" class="input-sm"
|
||||
奖品名称:<input type="text"
|
||||
id="prizeName"
|
||||
name="prizeName"
|
||||
class="input-sm"
|
||||
placeholder="请输入奖品名称">
|
||||
|
||||
日期:<input type="text" name="startDate" id="timeBegin" class="input-sm datetime"
|
||||
日期:<input type="text"
|
||||
name="startDate"
|
||||
id="timeBegin"
|
||||
class="input-sm datetime"
|
||||
placeholder="起始时间">
|
||||
- <input type="text" name="endDate" id="timeEnd" class="input-sm datetime"
|
||||
- <input type="text"
|
||||
name="endDate"
|
||||
id="timeEnd"
|
||||
class="input-sm datetime"
|
||||
placeholder="结束时间">
|
||||
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="pull-right">
|
||||
<button id="searchBtn" class="btn btn-primary">筛选</button>
|
||||
<button id="exportBtn" class="btn btn-primary">导出</button>
|
||||
<button id="searchBtn"
|
||||
class="btn btn-primary">筛选</button>
|
||||
<button id="exportBtn"
|
||||
class="btn btn-primary">导出</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -81,6 +98,7 @@ export default {
|
||||
{ field: 'uid', title: 'uid', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'erbanNo', title: '平台号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'nick', title: '用户昵称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'partition', title: '分区', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'prizeName', title: '奖品名称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{
|
||||
field: 'createTime', title: '抽奖时间', align: 'center', valign: 'middle', width: '20%', formatter: function (val, row, index) {
|
||||
|
@@ -9,30 +9,47 @@
|
||||
<div id="table"></div>
|
||||
<div id="toolbar">
|
||||
<label class="source">
|
||||
选择时间: <input type="text" name="startTime" id="startTime" class="input-sm">
|
||||
至 <input type="text" id="endTime" name="endTime" class="input-sm">
|
||||
选择时间: <input type="text"
|
||||
name="startTime"
|
||||
id="startTime"
|
||||
class="input-sm">
|
||||
至 <input type="text"
|
||||
id="endTime"
|
||||
name="endTime"
|
||||
class="input-sm">
|
||||
</label>
|
||||
<label class="source">
|
||||
宝箱类型: <select name="boxType" id="boxType" class="input-sm">
|
||||
宝箱类型: <select name="boxType"
|
||||
id="boxType"
|
||||
class="input-sm">
|
||||
<option value="0">全部</option>
|
||||
<option value="1">幸运许愿池</option>
|
||||
<option value="2">梦幻许愿池</option>
|
||||
</select>
|
||||
</label>
|
||||
<label class="source">
|
||||
查询凭据:<select name="source" id="source" class="input-sm">
|
||||
查询凭据:<select name="source"
|
||||
id="source"
|
||||
class="input-sm">
|
||||
<option value="1">平台号</option>
|
||||
<option value="2">偏差范围</option>
|
||||
</select>
|
||||
</label>
|
||||
<label class="msNo">
|
||||
平台号:<input type="text" placeholder="请输入草莓号" id="msNo" class="input-sm">
|
||||
平台号:<input type="text"
|
||||
placeholder="请输入草莓号"
|
||||
id="msNo"
|
||||
class="input-sm">
|
||||
</label>
|
||||
<label class="deviation">
|
||||
偏差值: <input type="text" id="minDis" class="input-m"> - <input type="text" id="maxDis"
|
||||
偏差值: <input type="text"
|
||||
id="minDis"
|
||||
class="input-m"> - <input type="text"
|
||||
id="maxDis"
|
||||
class="input-m">
|
||||
</label>
|
||||
<button id="btnSearch" class="btn btn-sm btn-primary">查询</button>
|
||||
<button id="btnSearch"
|
||||
class="btn btn-sm btn-primary">查询</button>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
@@ -66,6 +83,7 @@ export default {
|
||||
{ field: 'uid', title: 'uid', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'erbanNo', title: '平台号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'nick', title: '昵称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'partition', title: '分区', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'totalPurchaseMoney', title: '历史抽奖充值总额', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'totalDrawMoney', title: '历史抽奖总额', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'totalPlatformValue', title: '历史获奖平台价值', align: 'center', valign: 'middle', width: '10%' },
|
||||
@@ -293,4 +311,5 @@ export default {
|
||||
|
||||
#toolbar label {
|
||||
margin-right: 6px;
|
||||
}</style>
|
||||
}
|
||||
</style>
|
@@ -9,30 +9,47 @@
|
||||
<div id="table"></div>
|
||||
<div id="toolbar">
|
||||
<label class="source">
|
||||
选择时间: <input type="text" name="startTime" id="startTime" class="input-sm">
|
||||
至 <input type="text" id="endTime" name="endTime" class="input-sm">
|
||||
选择时间: <input type="text"
|
||||
name="startTime"
|
||||
id="startTime"
|
||||
class="input-sm">
|
||||
至 <input type="text"
|
||||
id="endTime"
|
||||
name="endTime"
|
||||
class="input-sm">
|
||||
</label>
|
||||
<label class="source">
|
||||
宝箱类型: <select name="boxType" id="boxType" class="input-sm">
|
||||
宝箱类型: <select name="boxType"
|
||||
id="boxType"
|
||||
class="input-sm">
|
||||
<option value="0">全部</option>
|
||||
<option value="1">幸运许愿池</option>
|
||||
<option value="2">梦幻许愿池</option>
|
||||
</select>
|
||||
</label>
|
||||
<label class="source">
|
||||
查询凭据:<select name="source" id="source" class="input-sm">
|
||||
查询凭据:<select name="source"
|
||||
id="source"
|
||||
class="input-sm">
|
||||
<option value="1">平台号</option>
|
||||
<option value="2">偏差范围</option>
|
||||
</select>
|
||||
</label>
|
||||
<label class="msNo">
|
||||
平台号:<input type="text" placeholder="请输入草莓号" id="msNo" class="input-sm">
|
||||
平台号:<input type="text"
|
||||
placeholder="请输入草莓号"
|
||||
id="msNo"
|
||||
class="input-sm">
|
||||
</label>
|
||||
<label class="deviation">
|
||||
偏差值: <input type="text" id="minDis" class="input-m"> - <input type="text" id="maxDis"
|
||||
偏差值: <input type="text"
|
||||
id="minDis"
|
||||
class="input-m"> - <input type="text"
|
||||
id="maxDis"
|
||||
class="input-m">
|
||||
</label>
|
||||
<button id="btnSearch" class="btn btn-sm btn-primary">查询</button>
|
||||
<button id="btnSearch"
|
||||
class="btn btn-sm btn-primary">查询</button>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
@@ -66,6 +83,7 @@ export default {
|
||||
{ field: 'uid', title: 'uid', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'erbanNo', title: '平台号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'nick', title: '昵称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'partition', title: '分区', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'totalPurchaseMoney', title: '历史抽奖充值总额', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'totalDrawMoney', title: '历史抽奖总额', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'totalPlatformValue', title: '历史获奖平台价值', align: 'center', valign: 'middle', width: '10%' },
|
||||
@@ -293,4 +311,5 @@ export default {
|
||||
|
||||
#toolbar label {
|
||||
margin-right: 6px;
|
||||
}</style>
|
||||
}
|
||||
</style>
|
Reference in New Issue
Block a user