withdraw.jsp

<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<!DOCTYPE html>
<html>
<head>
<title>在线充值管理</title>
<jsp:include page="../inc.jsp"></jsp:include>
<c:if test="${fn:contains(sessionInfo.resourceList, '/withdrawController/withdrawAudit')}">
<script type="text/javascript">
$.canEdit = true;
</script>
</c:if>


<script type="text/javascript">
var dataGrid;
$(function() {
dataGrid = $('#dataGrid').datagrid({
url : '${pageContext.request.contextPath}/withdrawController/withdrawDataGrid',  //查询时候调用的类的函数
queryParams:{'withdrawStatus':'0'},//查询的时候,携带的参数
fit : true,                     是否自动适应父容器
fitColumns : true,     
border : false,              设置面板是否有边框
pagination : true,        在底下是否显示分页工具栏
idField : 'id',                  标示字段或者说主键字段
pageSize : 10,             每页显示10行
pageList : [ 10, 20, 30, 40, 50 ],              分页大小选择列
sortName : 'id',                                          排序列
sortOrder : 'asc',                                        排序的标准
checkOnSelect : false,
selectOnCheck : false,
nowrap : false,                                           是否包裹数据,默认被包裹的数据显示在第一行            
frozenColumns : [ [ {                                 冻结的列,默认放在左边
field : 'id',
title : '编号',
halign : 'center',
width : 150,
checkbox : true
}, {
field : 'userName',
title : '会员名',
halign : 'center',
align : 'left',
width : 100,
sortable : true
} ] ],
columns : [ [ {                                      DataGrid列配置对象
field : 'realName',
title : '真实姓名',
halign : 'center',
align : 'left',
width : 100,
sortable : true
}, {
field : 'withdrawMoney',
title : '提现金额',
halign : 'center',
width : 100
},
//begin  delete by denghongwei at 2014-12-12
{  
field : 'secondFee',
title : '提现手续费',
halign : 'center',
width : 80
} ,
//  end  delete by denghongwei at 2014-12-12 
{
field : 'addTimeFmt',
title : '提现时间',
halign : 'center',
align : 'left',
width : 150
}, {
field : 'withdrawStatus',
title : '提现状态',
halign : 'center',
align : 'left',
width : 160,
formatter : function(value, row, index) {
if(value=='0'){
return '申请中';
}else if(value=='1'){
return '审核通过,处理中';
}else if(value=='2'){
return '已提现';
}else if(value=='3'){
return '审核未通过';
}else{
return '未申请';
}
}
}, {
field : 'dealUser',
title : '处理人',
halign : 'center',
align : 'left',
width : 150,
formatter : function(value, row, index) {
if(value==''){
return '无';
}else{
return value;
}
}
}, {
field : 'dealTimeFmt',
title : '处理时间',
halign : 'center',
align : 'left',
width : 150,
formatter : function(value, row, index) {
if(value==''){
return '无';
}else{
return value;
}
}
}, {
field : 'dealInfo',
title : '处理说明',
halign : 'center',
align : 'left',
width : 150
}, {
field : 'action',
title : '操作',
halign : 'center',
width : 100,
formatter : function(value, row, index) {
var str = '';
if ($.canEdit&&row.withdrawStatus<=1) {
str += $.formatString('<img οnclick="editFun(\'{0}\');" src="{1}" title="审核"/>', row.id, '${pageContext.request.contextPath}/style/images/extjs_icons/pencil.png');
}
return str;
}
} ] ],
toolbar : '#toolbar',
onLoadSuccess : function() {                                    //调用远程数据成功时                     
$('#searchForm table').show();
parent.$.messager.progress('close');


$(this).datagrid('tooltip');
},
onRowContextMenu : function(e, rowIndex, rowData) {
e.preventDefault();
$(this).datagrid('unselectAll').datagrid('uncheckAll');
$(this).datagrid('selectRow', rowIndex);
$('#menu').menu('show', {
left : e.pageX,
top : e.pageY
});
}
});
});


function editFun(id) {
if (id == undefined) {
var rows = dataGrid.datagrid('getSelections');
id = rows[0].id;
} else {
dataGrid.datagrid('unselectAll').datagrid('uncheckAll');
}
parent.$.modalDialog({
title : '提现审核',
width : 500,
height : 500,
href : '${pageContext.request.contextPath}/withdrawController/withdrawAudit?id=' + id,
buttons : [ {
text : '确定',
handler : function() {
parent.$.modalDialog.openner_dataGrid = dataGrid;//因为添加成功之后,需要刷新这个dataGrid,所以先预定义好
var f = parent.$.modalDialog.handler.find('#form');
f.submit();
}
} ]
});
}


function searchFun() {
dataGrid.datagrid('load', $.serializeObject($('#searchForm')));
}
function cleanFun() {
$('#searchForm input').val('');
dataGrid.datagrid('load', {});
}

function exportToExcel() {
$('#searchForm').form({
            url : '${pageContext.request.contextPath}/withdrawController/withdrawDataGridToExport',
          
        }); 
$('#searchForm').submit();


        
    }
    
function timeFormatter(date){
        return date.getFullYear()+'-'+(date.getMonth()+1)+'-'+date.getDate();
    }

</script>
</head>
<body>
<div class="easyui-layout" data-options="fit : true,border : false">
<div data-options="region:'north',title:'查询条件',border:false" style="height: 160px; overflow: hidden;">
<form id="searchForm" >
<table class="table table-hover table-condensed" style="display: none;">
<tr>
<th>会员名:</th>
<td><input name="userName" placeholder="可以查询会员名" class="easyui-validatebox span2 "  data-options="validType:'length[0,50]'"/></td>
<th>提现金额:</th>
<td><input name="withdrawMoney" placeholder="可以查询提现金额" class="easyui-validatebox span2 "  data-options="validType:'number'"/></td>
<th>处理人:</th>
<td><input name="dealUser" placeholder="可以查询处理人" class="easyui-validatebox span2 "  data-options="validType:'length[0,50]'"/></td>
</tr>
<tr>
   <th>提现时间:</th>
<td colspan="3">
<input class="easyui-datebox easyui-validatebox" name="addTimeStart" formatter="timeFormatter" data-options="validType:'date'"></input>
-
<input class="easyui-datebox easyui-validatebox" name="addTimeEnd" formatter="timeFormatter" data-options="validType:'date'"></input>
</td>
<th>提现状态:</th>
<td>
<select id="withdrawStatus" name="withdrawStatus" style="width: 140px; height: 29px;">
<option value="">全部</option>
<option value="0" selected="selected">申请中</option>
<option value="1">审核通过,处理中</option>
<option value="2">已提现</option>
<option value="3">审核未通过</option>
</select>
</td>
</tr>
</table>
</form>
</div>
<div data-options="region:'center',border:false">
<table id="dataGrid"></table>
</div>
</div>
<div id="toolbar" style="display: none;">
<a href="javascript:void(0);" class="easyui-linkbutton" data-options="iconCls:'brick_add',plain:true" οnclick="searchFun();">查询</a>
<a href="javascript:void(0);" class="easyui-linkbutton" data-options="iconCls:'brick_delete',plain:true" οnclick="cleanFun();">清空条件</a>
<a href="javascript:void(0);" class="easyui-linkbutton" data-options="iconCls:'brick_delete',plain:true" οnclick="exportToExcel();">导出Excel</a>
</div>


<div id="menu" class="easyui-menu" style="width: 120px; display: none;">
<c:if test="${fn:contains(sessionInfo.resourceList, '/withdrawController/withdrawAudit')}">
<div οnclick="editFun();" data-options="iconCls:'pencil'">审核</div>
</c:if>
</div>
</body>
</html>
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值