|
@@ -436,7 +436,7 @@
|
|
|
</el-dialog>
|
|
|
|
|
|
<!-- 充值对话框 -->
|
|
|
- <el-dialog :title="title" :visible.sync="chargeopen" width="700px" append-to-body>
|
|
|
+ <el-dialog :title="title" :visible.sync="chargeopen" width="80%" append-to-body>
|
|
|
<el-form ref="chargeForm" :model="chargeForm" :rules="currentRules" :validate-on-rule-change=false label-width="150px">
|
|
|
<el-form-item label="用户id" prop="userId">
|
|
|
<el-input v-model="chargeForm.userId" disabled />
|
|
@@ -485,10 +485,90 @@
|
|
|
</template>
|
|
|
|
|
|
</el-form>
|
|
|
- <div slot="footer" class="dialog-footer">
|
|
|
+ <div style="text-align: right">
|
|
|
<el-button type="primary" @click="submitChargeForm">确 定</el-button>
|
|
|
<el-button @click="cancel">取 消</el-button>
|
|
|
</div>
|
|
|
+ <div style="border-top: 4px solid #c2b8b8; margin-top: 22px;">
|
|
|
+ <h3><b>充值记录</b></h3>
|
|
|
+ </div>
|
|
|
+ <div style=" margin-bottom: 18px;">
|
|
|
+ <span>已充值余额:{{rechargeSum.totalDiamondCoin}}</span>
|
|
|
+ <span style="padding-left: 15px">已充值金币:{{rechargeSum.totalCoin}}</span>
|
|
|
+ </div>
|
|
|
+ <el-form :model="rechargeQueryParams" ref="rechargeQueryForm" size="small" :inline="true" v-show="showSearch" label-width="120px">
|
|
|
+ <el-form-item label="充值渠道" prop="channelId">
|
|
|
+ <el-select v-model="rechargeQueryParams.channelId" placeholder="请选择充值渠道">
|
|
|
+ <el-option
|
|
|
+ v-for="item in rechargeTypeList"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="日期" prop="rechargeDaterange">
|
|
|
+ <el-date-picker
|
|
|
+ v-model="rechargeDaterange"
|
|
|
+ style="width: 240px"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ type="daterange"
|
|
|
+ range-separator="-"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期"
|
|
|
+ @change="rechargeDateChage"
|
|
|
+ ></el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button type="primary" icon="el-icon-search" size="mini" @click="rechargeHandleQuery">搜索</el-button>
|
|
|
+ <el-button icon="el-icon-refresh" size="mini" @click="resetRechareQuery">重置</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+
|
|
|
+ <el-table v-loading="rechargeLoading" :data="chargeList">
|
|
|
+ <el-table-column type="selection" width="55" align="center" />
|
|
|
+ <el-table-column label="" align="center" prop="id" />
|
|
|
+ <el-table-column label="UID" align="center" prop="uid" />
|
|
|
+ <el-table-column label="充值类型" align="center" prop="type">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ {{scope.row.type==4?"手工充值":"在线充值"}}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="充值渠道" align="center" prop="channelId">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span>{{ getRechargeTypeName(scope.row.channelId) }}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="充值时间" align="center" prop="addtime" width="180">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span>{{ parseTime(scope.row.addtime, '{y}-{m}-{d} {h}:{i}:{s}')}}</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="充值金额" align="center" prop="coin" />
|
|
|
+ <el-table-column label="货币类型" align="center" prop="coinType">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <dict-tag :options="dict.type.app_user_coin_type" :value="scope.row.coinType"/>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="赠送金额" align="center" prop="coinGive"></el-table-column>
|
|
|
+ <el-table-column label="备注" align="center" prop="remarks" />
|
|
|
+ <el-table-column label="状态" align="center" prop="status">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <dict-tag :options="dict.type.app_users_charge_status" :value="scope.row.status"/>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="平台服务费" align="center" prop="platformService" width="100"/>
|
|
|
+
|
|
|
+ <el-table-column label="订单号" align="center" prop="orderno" width="180"/>
|
|
|
+ <el-table-column label="四方方平台订单号" align="center" prop="tradeNo" width="180"/>
|
|
|
+ </el-table>
|
|
|
+ <pagination
|
|
|
+ v-show="rechargeTotal>0"
|
|
|
+ :total="rechargeTotal"
|
|
|
+ :page.sync="rechargeQueryParams.pageNum"
|
|
|
+ :limit.sync="rechargeQueryParams.pageSize"
|
|
|
+ @pagination="getRechargeList"
|
|
|
+ />
|
|
|
</el-dialog>
|
|
|
|
|
|
<!-- 补足流水对话框 -->
|
|
@@ -497,6 +577,9 @@
|
|
|
<el-form-item label="用户id" prop="userId">
|
|
|
<el-input v-model="resetWithdrawForm.userId" disabled />
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="打码量剩余" prop="userId">
|
|
|
+ <el-input v-model="rechargeAmount.lackAmount" disabled />
|
|
|
+ </el-form-item>
|
|
|
<el-form-item label="金额" prop="amount">
|
|
|
<el-input type="text" v-model="resetWithdrawForm.amount" placeholder="请输入金额" />
|
|
|
</el-form-item>
|
|
@@ -955,12 +1038,13 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { listUser, getUser, delUser, addUser, updateUser,resetUser,userCharge,channelList,withdraw,openLive,userDetail,liveCommission,getGift,updateUserAgent,updateGameCommissionAgent,restPayPwd } from "@/api/business/user";
|
|
|
+import { listUser, getUser, delUser, addUser, updateUser,resetUser,userCharge,channelList,withdraw,openLive,userDetail,liveCommission,getGift,updateUserAgent,updateGameCommissionAgent,restPayPwd,getRechargeAmount } from "@/api/business/user";
|
|
|
import { listAccount} from "@/api/business/account";
|
|
|
import { listOrder } from "@/api/business/order";
|
|
|
import { listHistoryWeb} from "@/api/business/betting";
|
|
|
import {allGameList } from "@/api/business/game_item";
|
|
|
import {allList} from "@/api/business/lottery";
|
|
|
+import { listCharge, selectRechargeSum } from "@/api/business/charge";
|
|
|
|
|
|
export default {
|
|
|
name: "User",
|
|
@@ -973,6 +1057,7 @@ export default {
|
|
|
activeName2:"first",
|
|
|
// 遮罩层
|
|
|
loading: true,
|
|
|
+ rechargeLoading: true,
|
|
|
ipLoading: true,
|
|
|
accountLoading: true,
|
|
|
orderLoading: true,
|
|
@@ -989,6 +1074,7 @@ export default {
|
|
|
showSearch: true,
|
|
|
// 总条数
|
|
|
total: 0,
|
|
|
+ rechargeTotal: 0,
|
|
|
ipTotal: 0,
|
|
|
accountTotal: 0,
|
|
|
orderTotal: 0,
|
|
@@ -1015,6 +1101,7 @@ export default {
|
|
|
// 是否显示弹出层
|
|
|
chargeopen: false,
|
|
|
channelList:[],
|
|
|
+ rechargeDaterange:[],
|
|
|
isReadOnly:true,
|
|
|
rate:null,
|
|
|
channelMap:{},
|
|
@@ -1029,6 +1116,11 @@ export default {
|
|
|
downUserList:[],
|
|
|
typeMap:{},
|
|
|
typeList:[],
|
|
|
+ chargeList:[],
|
|
|
+ rechargeSum:{},
|
|
|
+ rechargeTypeMap:{},
|
|
|
+ rechargeTypeList:[],
|
|
|
+ rechargeAmount:{},
|
|
|
gameItemMap:{},
|
|
|
gameItemList:[],
|
|
|
gameItemShowList:[],
|
|
@@ -1107,6 +1199,42 @@ export default {
|
|
|
diamondCoin: null,
|
|
|
mobile:null,
|
|
|
},
|
|
|
+ // 查询参数
|
|
|
+ rechargeQueryParams: {
|
|
|
+ pageNum: 1,
|
|
|
+ pageSize: 10,
|
|
|
+ addtime: null,
|
|
|
+ afterCoin: null,
|
|
|
+ agentId: null,
|
|
|
+ ambient: null,
|
|
|
+ coin: null,
|
|
|
+ coinType: null,
|
|
|
+ coinGive: null,
|
|
|
+ isAgent: null,
|
|
|
+ isDelete: null,
|
|
|
+ isWater: null,
|
|
|
+ money: null,
|
|
|
+ optType: null,
|
|
|
+ optUser: null,
|
|
|
+ orderno: null,
|
|
|
+ pid: null,
|
|
|
+ pidLevel1: null,
|
|
|
+ pidLevel2: null,
|
|
|
+ pidLevel3: null,
|
|
|
+ pidLevel4: null,
|
|
|
+ remarks: null,
|
|
|
+ ruleId: null,
|
|
|
+ status: null,
|
|
|
+ touid: null,
|
|
|
+ tradeNo: null,
|
|
|
+ type: null,
|
|
|
+ uid: null,
|
|
|
+ platformService: null,
|
|
|
+ platformServiceRate: null,
|
|
|
+ channelId: null,
|
|
|
+ beginTime:null,
|
|
|
+ endTime:null
|
|
|
+ },
|
|
|
// 表单参数
|
|
|
form: {},
|
|
|
//重置密码
|
|
@@ -1181,6 +1309,20 @@ export default {
|
|
|
that.getList();
|
|
|
|
|
|
});
|
|
|
+ channelList().then(response => {
|
|
|
+ if(response.data){
|
|
|
+ for(var i in response.data){
|
|
|
+ var item = response.data[i];
|
|
|
+ that.rechargeTypeMap[item.id.toString()] = item.name;
|
|
|
+ that.rechargeTypeList.push({
|
|
|
+ value:item.id,
|
|
|
+ label:item.name
|
|
|
+ })
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.getList();
|
|
|
+
|
|
|
+ })
|
|
|
},
|
|
|
computed: {
|
|
|
currentRules:function(){
|
|
@@ -1195,6 +1337,31 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
methods: {
|
|
|
+ /** 搜索按钮操作 */
|
|
|
+ rechargeHandleQuery() {
|
|
|
+ this.rechargeQueryParams.pageNum = 1;
|
|
|
+ this.getRechargeList();
|
|
|
+ },
|
|
|
+ /** 查询充值记录列表 */
|
|
|
+ getRechargeList() {
|
|
|
+ this.rechargeLoading = true;
|
|
|
+ listCharge(this.rechargeQueryParams).then(response => {
|
|
|
+ this.chargeList = response.rows;
|
|
|
+ this.rechargeTotal = response.total;
|
|
|
+ this.rechargeLoading = false;
|
|
|
+ });
|
|
|
+ selectRechargeSum(this.rechargeQueryParams).then(response=>{
|
|
|
+ if(response.data != null && response.data != undefined){
|
|
|
+ this.rechargeSum = response.data;
|
|
|
+ }else{
|
|
|
+ this.rechargeSum = {
|
|
|
+ totalDiamondCoin:0,
|
|
|
+ totalCoin:0
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ console.log(this.chargeList)
|
|
|
+ },
|
|
|
getBettingInfo(row){
|
|
|
let detailsCountVOList = row.detailsCountVOList;
|
|
|
if(!detailsCountVOList){
|
|
@@ -1281,6 +1448,15 @@ export default {
|
|
|
getTypeName(id) {
|
|
|
return this.typeMap[id.toString()];
|
|
|
},
|
|
|
+ getRechargeTypeName(id) {
|
|
|
+ if(id == null || id == undefined){
|
|
|
+ return "-";
|
|
|
+ }
|
|
|
+ if(undefined == this.typeMap[id.toString()] || null == this.typeMap[id.toString()]){
|
|
|
+ return "-";
|
|
|
+ }
|
|
|
+ return this.typeMap[id.toString()];
|
|
|
+ },
|
|
|
/** 查询app用户列表 */
|
|
|
getList() {
|
|
|
this.loading = true;
|
|
@@ -1571,6 +1747,20 @@ export default {
|
|
|
this.resetForm("queryForm");
|
|
|
this.handleQuery();
|
|
|
},
|
|
|
+ /** 重置按钮操作 */
|
|
|
+ resetRechareQuery() {
|
|
|
+ this.resetForm("rechareQueryForm");
|
|
|
+ this.rechargeDaterange = [];
|
|
|
+ this.chargeList = [];
|
|
|
+ this.rechargeQueryParams.beginTime = null;
|
|
|
+ this.rechargeQueryParams.endTime = null;
|
|
|
+ this.rechargeQueryParams.uid = this.chargeForm.userId;
|
|
|
+ this.rechargeSum = {
|
|
|
+ totalDiamondCoin:0,
|
|
|
+ totalCoin:0
|
|
|
+ };
|
|
|
+ this.rechargeHandleQuery();
|
|
|
+ },
|
|
|
// 多选框选中数据
|
|
|
handleSelectionChange(selection) {
|
|
|
this.ids = selection.map(item => item.userid)
|
|
@@ -1629,8 +1819,20 @@ export default {
|
|
|
userId:userid,
|
|
|
password:""
|
|
|
};
|
|
|
- this.resetWithdrawopen = true;
|
|
|
- this.title = "补足提现流水";
|
|
|
+ const loading = this.$loading({
|
|
|
+ lock: true,
|
|
|
+ text: '加载中',
|
|
|
+ spinner: 'el-icon-loading',
|
|
|
+ background: 'rgba(0, 0, 0, 0.7)'
|
|
|
+ });
|
|
|
+ getRechargeAmount(userid).then(response=>{
|
|
|
+ this.rechargeAmount = response.data;
|
|
|
+ this.resetWithdrawopen = true;
|
|
|
+ this.resetWithdrawForm.amount = this.rechargeAmount.lackAmount;
|
|
|
+ this.title = "补足提现流水";
|
|
|
+ loading.close();
|
|
|
+ })
|
|
|
+
|
|
|
},
|
|
|
/** 充值按钮操作 */
|
|
|
handleCharge(row) {
|
|
@@ -1654,9 +1856,11 @@ export default {
|
|
|
const userid = row.userid;
|
|
|
this.chargeForm = {
|
|
|
userId:userid,
|
|
|
+ nickname:row.nickname,
|
|
|
type: null,
|
|
|
amount:null
|
|
|
};
|
|
|
+ this.resetRechareQuery();
|
|
|
this.chargeopen = true;
|
|
|
this.title = "充值";
|
|
|
|
|
@@ -1746,7 +1950,6 @@ export default {
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(0, 0, 0, 0.7)'
|
|
|
});
|
|
|
- setTimeout(function (){loading.close();},1000);
|
|
|
withdraw(this.resetWithdrawForm).then(response => {
|
|
|
this.$modal.msgSuccess("补足流水成功");
|
|
|
this.resetWithdrawopen = false;
|
|
@@ -1759,33 +1962,41 @@ export default {
|
|
|
/** 充值提交按钮 */
|
|
|
submitChargeForm() {
|
|
|
var that =this;
|
|
|
- this.$refs["chargeForm"].validate(valid => {
|
|
|
- if (valid) {
|
|
|
- if(that.chargeForm.isRate != 1){
|
|
|
- that.chargeForm.rate = null;
|
|
|
- }
|
|
|
- if(that.chargeForm.channelId == -1 && (undefined == that.chargeForm.rate || null == that.chargeForm.rate)){
|
|
|
- this.$modal.msgError("请输入手续费比例");
|
|
|
- return;
|
|
|
- }
|
|
|
- if(that.chargeForm.channelId == -1 && that.chargeForm.rate >= 1){
|
|
|
- this.$modal.msgError("手续费比例超过最大值");
|
|
|
- return;
|
|
|
+ this.$confirm('是否确认给用户'+that.chargeForm.nickname+'('+that.chargeForm.userId+')充值金额'+that.chargeForm.amount+'?', '充值提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ this.$refs["chargeForm"].validate(valid => {
|
|
|
+ if (valid) {
|
|
|
+ if(that.chargeForm.isRate != 1){
|
|
|
+ that.chargeForm.rate = null;
|
|
|
+ }
|
|
|
+ if(that.chargeForm.channelId == -1 && (undefined == that.chargeForm.rate || null == that.chargeForm.rate)){
|
|
|
+ this.$modal.msgError("请输入手续费比例");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ if(that.chargeForm.channelId == -1 && that.chargeForm.rate >= 1){
|
|
|
+ this.$modal.msgError("手续费比例超过最大值");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ const loading = this.$loading({
|
|
|
+ lock: true,
|
|
|
+ text: '加载中',
|
|
|
+ spinner: 'el-icon-loading',
|
|
|
+ background: 'rgba(0, 0, 0, 0.7)'
|
|
|
+ });
|
|
|
+ // setTimeout(function (){loading.close();},1000);
|
|
|
+ userCharge(this.chargeForm).then(response => {
|
|
|
+ this.$modal.msgSuccess("修改成功");
|
|
|
+ this.chargeopen = false;
|
|
|
+ this.getList();
|
|
|
+ loading.close();
|
|
|
+ });
|
|
|
}
|
|
|
- const loading = this.$loading({
|
|
|
- lock: true,
|
|
|
- text: '加载中',
|
|
|
- spinner: 'el-icon-loading',
|
|
|
- background: 'rgba(0, 0, 0, 0.7)'
|
|
|
- });
|
|
|
- // setTimeout(function (){loading.close();},1000);
|
|
|
- userCharge(this.chargeForm).then(response => {
|
|
|
- this.$modal.msgSuccess("修改成功");
|
|
|
- this.chargeopen = false;
|
|
|
- this.getList();
|
|
|
- loading.close();
|
|
|
- });
|
|
|
- }
|
|
|
+ });
|
|
|
+ }).catch(() => {
|
|
|
+ //取消
|
|
|
});
|
|
|
},
|
|
|
/** 开关播提交按钮 */
|
|
@@ -1985,6 +2196,15 @@ export default {
|
|
|
if("eight" == tab.$options.propsData.name){
|
|
|
this.getBettingList();
|
|
|
}
|
|
|
+ },
|
|
|
+ rechargeDateChage(val){
|
|
|
+ if(undefined != val && null != val && val.length > 1){
|
|
|
+ this.rechargeQueryParams.beginTime = val[0];
|
|
|
+ this.rechargeQueryParams.endTime = val[1];
|
|
|
+ }else{
|
|
|
+ this.rechargeQueryParams.beginTime = null;
|
|
|
+ this.rechargeQueryParams.endTime = null;
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
};
|