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.

155 lines
5.7 KiB
Plaintext

2 months ago
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PostFeeList.aspx.cs" Inherits="TradeManage.SysManage.PostFeeList" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<link rel="stylesheet" type="text/css" href="../themes/default/easyui.css" />
<link rel="stylesheet" type="text/css" href="../themes/icon.css" />
<link rel="stylesheet" type="text/css" href="../themes/New.css" />
<link rel="stylesheet" type="text/css" href="../themes/DataGrid.css" />
<script src="../Scripts/MicrosoftAjax.js" type="text/javascript"></script>
<script src="../Scripts/jquery.min.js" type="text/javascript"></script>
<script src="../Scripts/jquery.easyui.min.js" type="text/javascript"></script>
<script src="../Scripts/DataGrid.js" type="text/javascript"></script>
<script src="../Scripts/DataPager.js" type="text/javascript"></script>
<script src="../Scripts/jquery.bgiframe.min.js" type="text/javascript"></script>
<script src="../Scripts/Global.js" type="text/javascript"></script>
<script src="../Scripts/WindowLoad.js" type="text/javascript"></script>
<script type="text/javascript">
var Model = null;
var datagrid1 = new nblf.ui.DataGrid("DataGrid1");
var WindowLoadModel = new WindowLoad();
$(document).ready(function () {
WindowLoadModel.ApplicationPath = "../";
WindowLoadModel.ControlID = "WindowLoad";
WindowLoadModel.Isbgiframe = true;
WindowLoadModel.Load();
ajaxInit(WindowLoadModel);
CreateDataGrid();
GetExpressPostList();
ReadData();
$("#cmdAdd").click(function () {
window.location = "PostFeeDetail.aspx";
});
$("#cmdGet").click(function () {
ReadData();
});
$("#" + datagrid1.TableID + " input[CommandName]").live("click", function () {
var index = $(this).parentsUntil("tr").parent().attr("index");
Model = datagrid1.Get_Model(index);
var ColName = $(this).attr("CommandName");
if (ColName == "cmdEdit") {
window.location = "PostFeeDetail.aspx?ExpressID=" + Model.ExpressID;
}
});
});
//#region 读取物流渠道
function GetExpressPostList() {
$.ajax({
url: "../BaseData.asmx/GetExpressPostList",
async: false,
success: function (data) {
var html = new Sys.StringBuilder();
html.append("<option value='0'>全部</option>");
$(data.d).each(function () {
html.append("<option value='" + this.ExpressID + "'>" + this.Name + "</option>");
});
$('#listExpress,#listExpress2').html(html.toString());
}
});
}
//#endregion
//#region 初始化DataGrid
function CreateDataGrid() {
var col = new nblf.ui.DataGridColumn();
col.HeaderText = "物流渠道";
col.CellTemplate = "<span>{Bind ExpressName}</span>";
Array.add(datagrid1.Columns, col);
col = new nblf.ui.DataGridColumn();
col.HeaderText = "计费类型";
col.CellTemplate = "<span>{Bind FeeTypeName}</span>";
Array.add(datagrid1.Columns, col);
col = new nblf.ui.DataGridColumn();
col.HeaderText = "操作";
col.Width = "100px";
col.CellTemplate = "<input CommandName='cmdEdit' class='btnClass dgbtnEdit' type='button' value='编辑'></input>";
Array.add(datagrid1.Columns, col);
datagrid1.IsFixHeader = false;
datagrid1.ShowIndexColumn = false;
datagrid1.AllowPaging = true;
datagrid1.Width = "100%";
datagrid1.SelectMode = nblf.ui.SelectMode.None;
datagrid1.Init();
datagrid1.add_PageIndexChanged(function () { ReadData(); });
}
//#endregion
//#region 读取数据
function ReadData() {
var param = new Object();
param.ExpressID = $("#listExpress").val();
param.PageSize = datagrid1.Get_PageSize();
param.PageIndex = datagrid1.Get_PageIndex();
WindowLoadModel.Show();
$.ajax({
url: "SysManageService.asmx/GetListJC_PostFee",
data: Sys.Serialization.JavaScriptSerializer.serialize(param),
success: function (data) {
WindowLoadModel.Hide();
datagrid1.Set_RowCount(data.d.RowCount);
datagrid1.DataBind(data.d.DataSource);
}
});
}
//#endregion
</script>
</head>
<body class="headbody">
<div class="title_ico">
快递费率
</div>
<table id="tb1" class="tableAll" style="width: 100%;">
<colgroup>
<col style="width: 80px;" />
<col />
<col />
</colgroup>
<tr>
<td class="f1">物流渠道
</td>
<td>
<select id="listExpress" class="selectClass" style="width: 150px;"></select>
</td>
<td>
<input id="cmdGet" type="button" class="btnClass btnClassFind" value="查询" />
</td>
</tr>
<tr>
<td valign="top" colspan="3">
<div id="DataGrid1" class="DataGridStyle"></div>
</td>
</tr>
</table>
</body>
</html>