216 lines
8.0 KiB
HTML
216 lines
8.0 KiB
HTML
<!DOCTYPE html>
|
||
<html lang="en">
|
||
<head>
|
||
<title>权限管理</title>
|
||
<meta charset="UTF-8">
|
||
<meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no">
|
||
<meta http-equiv="X-UA-Compatible" content="IE=8">
|
||
<meta http-equiv="Cache" content="no-cache">
|
||
<meta http-equiv="Pragma" content="no-cache">
|
||
<meta http-equiv="Cache-Control" content="no-cache">
|
||
<meta http-equiv="Expires" content="0">
|
||
<link rel="stylesheet" type="text/css" href="css/style.css?__HTML_VERSION__=6">
|
||
<link rel="stylesheet" href="./libs/bootstrap/bootstrap.min.css?__HTML_VERSION__=3">
|
||
</head>
|
||
<body class="bg_hui">
|
||
<div class="count_full" id="app" v-show="!isLoading" style="display: none">
|
||
<header class="header header-pos-fix">
|
||
<div onclick="history.back(-1)">
|
||
<img src="img/fahui.png" class="img">
|
||
<span class="text_wen">返回</span>
|
||
</div>
|
||
</header>
|
||
<div style="width: 100%;height: 45px;display: block;"></div>
|
||
<section class="buju">
|
||
<div class="chongka" id="fengwan">
|
||
<div class="rowh he">
|
||
<span class="name">账号:</span>
|
||
<input type="number" placeholder="请输入账号" class="input" autofocus v-model="queryInfo.queryID">
|
||
<a href="javascript:;" class="btn btn-blue chaxun" @click="queryplayer()">查询</a>
|
||
</div>
|
||
<div class="rowh he">
|
||
<span class="name">昵称:</span>
|
||
<input type="text" placeholder="空" class="input" v-model="queryInfo.queryName">
|
||
</div>
|
||
<div class="rowh he" style="height: auto;">
|
||
<span class="name">通过账号赠卡:</span>
|
||
<div class="margin-left-30">
|
||
<label for="s_0">
|
||
<input id="s_0" type="radio" name="salespower" value="0" checked="checked" v-model="queryInfo.powerSales">
|
||
无权限
|
||
</label>
|
||
<label for="s_1">
|
||
<input id="s_1" type="radio" name="salespower" value="1" v-model="queryInfo.powerSales"> 给下级赠卡的权限
|
||
</label><br/>
|
||
<label for="s_2">
|
||
<input id="s_2" type="radio" name="salespower" value="2" v-model="queryInfo.powerSales"> 给任意赠卡的权限
|
||
</label>
|
||
</div>
|
||
</div>
|
||
<div class="rowh he" style="height: auto;">
|
||
<span class="name">给玩家赠卡:</span>
|
||
<div class="margin-left-30">
|
||
<label for="p_0">
|
||
<input id="p_0" type="radio" name="cardpower" value="0" checked="" v-model="queryInfo.powerCard"> 无权限
|
||
</label>
|
||
<label for="p_1">
|
||
<input id="p_1" type="radio" name="cardpower" value="1" v-model="queryInfo.powerCard"> 给下级玩家赠卡的权限
|
||
</label><br/>
|
||
<label for="p_2">
|
||
<input id="p_2" type="radio" name="cardpower" value="2" v-model="queryInfo.powerCard"> 给任意玩家赠卡的权限
|
||
</label>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="rowh he" style="height: auto;">
|
||
<span class="name">给玩家充{{lang.singStarName}}:</span>
|
||
<div class="margin-left-30">
|
||
<label for="t_0">
|
||
<input id="t_0" type="radio" name="starpower" value="0" checked="" v-model="queryInfo.powerStar"> 无权限
|
||
</label>
|
||
<label for="t_2">
|
||
<input id="t_2" type="radio" name="starpower" value="2" v-model="queryInfo.powerStar"> 给任意玩家转{{lang.starName}}的权限
|
||
</label>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="rowh he" style="height: auto; display: none;">
|
||
<span class="name">自助购卡:</span>
|
||
<div class="margin-left-30">
|
||
<label for="b_0">
|
||
<input id="b_0" type="radio" name="buypower" value="0" checked="" v-model="queryInfo.powerBuy"> 无权限
|
||
</label>
|
||
<label for="b_2">
|
||
<input id="b_2" type="radio" name="buypower" value="2" v-model="queryInfo.powerBuy"> 有权限
|
||
</label>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="rowh he">
|
||
<span class="name">是否是VIP:</span>
|
||
<div class="margin-left-30">
|
||
<label>
|
||
<input type="radio" name="is_vip" value="0" checked="" v-model="queryInfo.is_vip"> 否
|
||
</label>
|
||
<label>
|
||
<input type="radio" name="is_vip" value="1" v-model="queryInfo.is_vip"> 是
|
||
</label>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="rowh text-center conkabtn">
|
||
<a href="javascript:;" class="btn btn-danger closes" @click="tokill_salespower">确定</a>
|
||
</div>
|
||
</div>
|
||
|
||
</section>
|
||
|
||
</div>
|
||
|
||
<script src="./libs/jquery.min.js?__HTML_VERSION__=3"></script>
|
||
<script src="./libs/bootstrap/bootstrap.min.js?__HTML_VERSION__=3"></script>
|
||
<script src="./libs/vue.min.js?__HTML_VERSION__=3"></script>
|
||
<script src="./libs/layer_mobile/layer.js?__HTML_VERSION__=3"></script>
|
||
<script src="./lang/lang.js?__HTML_VERSION__=14"></script>
|
||
<script src="./js/function.js?__HTML_VERSION__=18"></script>
|
||
<script src="./components/home-nav.js?__HTML_VERSION__=12"></script>
|
||
|
||
<script>
|
||
|
||
var vm = new Vue(
|
||
{
|
||
el: "#app",
|
||
data: {
|
||
isLoading: true,
|
||
lang: {},
|
||
myInfo: {},
|
||
urlParam: {},
|
||
queryInfo: {
|
||
queryID: '',
|
||
queryName: '',
|
||
powerSales: 0,
|
||
powerCard: 0,
|
||
powerStar: 0,
|
||
powerBuy: 0,
|
||
is_vip: 0,
|
||
}
|
||
},
|
||
components: {
|
||
'home-nav': homeNav
|
||
},
|
||
methods: {
|
||
goHome: function () {
|
||
window.location.href = 'index.html?agentid=' + this.urlParam.agentid + '&channelid=' + this.urlParam.channelid+'&__HTML_VERSION__=3';
|
||
},
|
||
queryplayer: function () {
|
||
var param = {
|
||
agentid: this.urlParam.agentid,
|
||
channelid: this.urlParam.channelid,
|
||
queryid: this.queryInfo.queryID,
|
||
salesid: this.myInfo.salesid
|
||
};
|
||
$.api(
|
||
"agent.agent.getPower",
|
||
param,
|
||
function (res) {
|
||
|
||
this.queryInfo.queryName = res.saus_nickname;
|
||
this.queryInfo.powerSales = res.saus_power.substring(0, 1);
|
||
if (this.queryInfo.powerSales === undefined || this.queryInfo.powerSales == null || this.queryInfo.powerSales == '') {
|
||
this.queryInfo.powerSales = 0;
|
||
}
|
||
|
||
this.queryInfo.powerCard = res.saus_power.substring(1, 2);
|
||
if (this.queryInfo.powerCard === undefined || this.queryInfo.powerCard == null || this.queryInfo.powerCard == '') {
|
||
this.queryInfo.powerCard = 0;
|
||
}
|
||
|
||
this.queryInfo.powerStar = res.saus_power.substring(2, 3);
|
||
if (this.queryInfo.powerStar === undefined || this.queryInfo.powerStar == null || this.queryInfo.powerStar == '') {
|
||
this.queryInfo.powerStar = 0;
|
||
}
|
||
|
||
this.queryInfo.powerBuy = res.saus_power.substring(2, 3);
|
||
if (this.queryInfo.powerBuy === undefined || this.queryInfo.powerBuy == null || this.queryInfo.powerBuy == '') {
|
||
this.queryInfo.powerBuy = 0;
|
||
}
|
||
|
||
this.queryInfo.is_vip = res.is_vip;
|
||
}.bind(this), 1
|
||
)
|
||
},
|
||
tokill_salespower: function () {
|
||
|
||
var power = this.queryInfo.powerSales + this.queryInfo.powerCard + this.queryInfo.powerStar + this.queryInfo.powerBuy;
|
||
var param = {
|
||
agentid: this.urlParam.agentid,
|
||
channelid: this.urlParam.channelid,
|
||
queryid: this.queryInfo.queryID,
|
||
salesid: this.myInfo.salesid,
|
||
power: power,
|
||
is_vip: this.queryInfo.is_vip,
|
||
};
|
||
$.api(
|
||
"agent.agent.setPower",
|
||
param,
|
||
function (res) {
|
||
|
||
$.alert('修改成功');
|
||
}, 1
|
||
)
|
||
}
|
||
},
|
||
created: function () {
|
||
|
||
this.urlParam = $.getQueryObj();
|
||
this.lang = lang[this.urlParam.agentid] ? lang[this.urlParam.agentid] : lang.default;
|
||
|
||
$.getUserInfo(function (r) {
|
||
this.myInfo = r;
|
||
this.isLoading = false;
|
||
}.bind(this));
|
||
}
|
||
})
|
||
</script>
|
||
</body>
|
||
</html> |