You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

340 lines
10 KiB
HTML

3 years ago
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="UTF-8">
<title>游戏登陆列表|----软件管理平台</title>
<link href="http://admin.vlcms.com/Public/icon.ico" type="image/x-icon" rel="shortcut icon">
<link rel="stylesheet" type="text/css" href="__CSS__/base.css" media="all">
<link rel="stylesheet" type="text/css" href="__CSS__/common.css" media="all">
<link rel="stylesheet" type="text/css" href="__CSS__/module.css">
<link rel="stylesheet" type="text/css" href="__CSS__/style.css" media="all">
<link rel="stylesheet" href="__CSS__/select2.min.css" type="text/css" />
<link rel="stylesheet" type="text/css" href="__CSS__/default_color.css" media="all">
<script type="text/javascript" src="__STATIC__/jquery-2.0.3.min.js"></script>
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js"></script>
<script type="text/javascript" src="__JS__/select2.min.js"></script>
</head>
<style>
html {
min-width:100%;
height: 1000px;
}
body {
padding: 0px;
}
.trunk-search .form-group {
margin-left: 10px;
}
.normal_table input {
position: relative;
padding: 5px;
border: 1px solid #E5E5E5;
border-radius: 4px;
height: 25px;
}
.normal_table td {
padding: 5px;
text-align: center;
}
.normal_table td select {
width: 100%;
}
.normal_table td button {
width: 70px;
height: 35px;
display: block;
background: #409eff;
color: #fff;
border: none;
border-radius: 4px;
cursor: pointer;
}
.normal_table td button.delete-row {
background-color: rgb(249,104,104);
}
.btn-row {
position: relative;
font-size: 11px;
margin-top: 28px;
text-align: center;
}
.btn-row button {
width: 70px;
height: 35px;
background: #409eff;
color: #fff;
border: none;
border-radius: 4px;
cursor: pointer;
display: inline-block;
padding: 0px;
}
.btn-row button.close-btn {
background: #E5E5E5;
color: #535875;
}
.form-group .static-input {
line-height: 32px;
display: inline-block;
}
.trunk-search button {
width: 70px;
height: 35px;
display: block;
background: #409eff;
color: #fff;
border: none;
border-radius: 4px;
cursor: pointer;
display: inline-block;
}
.info-row {
margin-top: 10px;
}
.info-row button {
width: auto;
height: 25px;
display: block;
background: #E5E5E5;
color: #535875;
border: none;
border-radius: 3px;
cursor: pointer;
display: inline-block;
margin-left: 10px;
padding: 0px 10px;
}
.info-row button.bind-btn {
background: #409eff;
color: #fff;
}
.form-group {
3 years ago
margin-bottom: 10px;
}
.form-group label {
width: 100px;
display: inline-block;
text-align: right;
margin-right: 10px;
vertical-align: middle;
3 years ago
}
.form-group input {
padding: 5px;
border: 1px solid #E5E5E5;
border-radius: 4px;
height: 24px;
3 years ago
width: 280px;
}
.form-group .static-input {
width: 280px;
}
.form-group select {
3 years ago
width: 290px;
3 years ago
}
.form-group textarea {
padding: 5px;
border: 1px solid #E5E5E5;
border-radius: 4px;
3 years ago
}
.clearfix:after {
content: "\20";
display: block;
height: 0;
clear: both;
}
.clearfix {
*zoom: 1;
}
.select2-container--open {
z-index: 1001;
}
</style>
<body>
<div id="main" class="main" style="min-height: 342px;">
<div class="page-search normal_list promoteCoin-record-search" style="padding: 20px;">
<div class="trunk-content article">
<div class="trunk-search clearfix" style="margin-bottom: 10px;">
<form method="post" class="clearfix">
<div class="clearfix">
<div class="form-group">
3 years ago
<label>游戏名称</label>
<select id="game-select" name="" class="select_gallery" <?php if($role):?>disabled<?php endif;?>>
3 years ago
<option value="0">请选择游戏</option>
<?php foreach($baseGames as $game):?>
3 years ago
<option value="<?=$game['id']?>">
3 years ago
<?=$game['name']?>
3 years ago
</option>
<?php endforeach;?>
</select>
</div>
<div class="form-group">
3 years ago
<label>角色ID</label>
<input type="text" id="role-id" name="role_id" class="txt normal_txt" placeholder="请输入角色ID" value="" style="width: 205px;">
<button id="search-role-btn" class="add-row" type="button">查询</button>
3 years ago
</div>
<div class="form-group">
3 years ago
<label>角色区服</label>
<p id="server-name" class="static-input">--</p>
3 years ago
</div>
3 years ago
<div class="form-group">
<label>角色名称</label>
3 years ago
<p id="role-name" class="static-input">--</p>
3 years ago
</div>
3 years ago
<div class="form-group">
<label>当前累充</label>
3 years ago
<p id="pay-amount" class="static-input">--</p>
3 years ago
</div>
3 years ago
<div class="form-group">
<label>当前模拟累充</label>
<p id="simulate-amount" class="static-input">--</p>
</div>
3 years ago
<div class="form-group">
<label>模拟发放金额</label>
3 years ago
<input type="text" id="amount" name="amount" class="txt normal_txt" placeholder="请输入模拟发放金额" value="">
3 years ago
</div>
3 years ago
<div class="form-group">
<label>备注</label>
3 years ago
<textarea id="remark" name="remark" class="txt normal_txt" style="width: 280px;" rows="10" placeholder="请输入备注"></textarea>
3 years ago
<!-- <input type="text" name="remark" class="txt normal_txt" placeholder="请输入备注" value=""> -->
3 years ago
</div>
3 years ago
<div class="form-group">
<label></label>
3 years ago
<button id="submit-btn" class="add-row" type="button">增加</button>
3 years ago
</div>
</div>
</form>
</div>
</div>
3 years ago
</div>
3 years ago
</div>
<script type="text/javascript">
$(".select_gallery").select2()
function isFloat(num){
if(!num) {
return false
}
var strPreg = /^\d+(\.\d+)?$/;
if(!strPreg.test(num)) {
return false
}
try{
if(parseFloat(num) != num) {
return false
}
} catch(ex) {
return false
}
return true
}
function isNumber(num){
if(!num) {
return false
}
var strPreg = /^\d+$/
if(!strPreg.test(num)) {
return false
}
return true
}
$('#bind-btn').click(function () {
var box = $('#bind-box')
layer.open({
title: '绑定玩家角色',
type: 1,
content: box,
area: ['500px', '250px'],
zIndex: 250,
scrollbar: false
})
});
3 years ago
$('#search-role-btn').click(function () {
3 years ago
var gameId = $('#game-select').val()
if (gameId == 0) {
return layer.msg('请选择游戏')
}
3 years ago
var roleId = $('#role-id').val()
if (roleId == '') {
return layer.msg('请输入角色ID')
3 years ago
}
$.ajax({
3 years ago
url: "{:U('Ajax/searchRoleInfo')}",
type: "get",
data: { base_game_id: gameId, role_id: roleId},
3 years ago
dataType: 'json',
success: function(result){
if (result.status == 1) {
3 years ago
$('#role-name').html(result.data.role_name)
$('#server-name').html(result.data.server_name)
$('#pay-amount').html(result.data.pay_amount)
3 years ago
$('#simulate-amount').html(result.data.simulate_amount)
3 years ago
} else {
layer.msg(result.message)
3 years ago
$('#role-name').html('查询失败')
$('#server-name').html('查询失败')
$('#pay-amount').html('查询失败')
3 years ago
$('#simulate-amount').html('查询失败')
3 years ago
}
}
3 years ago
})
3 years ago
})
$('#submit-btn').on({
click: function () {
3 years ago
var gameId = $('#game-select').val()
if (gameId == 0) {
return layer.msg('请选择游戏')
3 years ago
}
3 years ago
var roleId = $('#role-id').val()
if (roleId == '') {
return layer.msg('请输入角色ID')
3 years ago
}
3 years ago
var amount = $('#amount').val()
var remark = $('#remark').val()
3 years ago
if (gameId == 0) {
return layer.msg('请选择游戏')
}
3 years ago
if (roleId == '') {
return layer.msg('请输入角色ID')
3 years ago
}
3 years ago
if (amount == '') {
return layer.msg('请输入模拟发放金额')
3 years ago
}
$.ajax({
3 years ago
url: "{:U('saveSimulateSpend')}",
3 years ago
type: "post",
3 years ago
data: { base_game_id: gameId, amount: amount, remark: remark, role_id: roleId},
3 years ago
dataType: 'json',
success: function(result){
if (result.status == 1) {
layer.msg(result.message, function(){
3 years ago
parent.window.location.href = parent.window.location.href
3 years ago
})
} else {
layer.msg(result.message)
}
}
})
}
})
$('#close-btn').on({
click: function () {
var index = parent.layer.getFrameIndex(window.name)
parent.layer.close(index)
}
})
</script>
</body>
</html>