<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="selectcallcustomer.aspx.cs" Inherits="HySoft.BaseCallCenter.Web.telmanage.selectcallcustomer" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>客户档案管理</title>
 <link href="../scripts/ui/skins/Aqua/css/ligerui-all.css" rel="stylesheet" type="text/css" />
    <script src="../scripts/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
    <script src="../scripts/ui/json2.js" type="text/javascript"></script>
    <script src="../scripts/ui/js/core/base.js" type="text/javascript"></script>
    <script src="../scripts/ui/js/ligerui.min.js" type="text/javascript"></script>
    <link href="../scripts/ui/skins/Tab/css/tab.css" rel="stylesheet" type="text/css" />
    <link href="../scripts/ui/skins/Tab/css/grid.css" rel="stylesheet" type="text/css" />
    <script src="../scripts/ui/js/plugins/ligerGrid.js" type="text/javascript"></script>
    <script src="../scripts/ui/js/plugins/ligerLayout.js" type="text/javascript"></script>
    <script src="../scripts/ui/js/plugins/ligerTree.js" type="text/javascript"></script>
    <script src="../scripts/ui/js/plugins/ligerMenu.js" type="text/javascript"></script>
    <script src="../scripts/CustomersData.js" type="text/javascript"></script>
    <link href="../scripts/ui/skins/ligerui-icons.css" rel="stylesheet" type="text/css" />
    <link href="../images/style.css" rel="stylesheet" type="text/css" />
    <script src="../scripts/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
    <script type="text/javascript">
        var singleClick;
        $(function () {
            InitList();
        });
        function InitList() {
            var sql = GetSql();
            try {
                gridlist = $("#divDataList").ligerGrid({
                    checkbox: false,
                    height: '90%',
                    columns: [
                { display: 'Id', name: '_f_customerid', hide: 'Id', width: '1%' },
                { display: '客户编号', name: '_f_customercode', align: 'left', width: 150 },
                { display: '客户名称', name: '_f_customername', width: 200 },
                { display: '负责人', name: '_f_chargename', width: 100 },
                { display: '联系电话', name: '_f_chargetelephone', width: 100 }
                ],
                    url: '../customermanage/ajax/customer.ashx?action=getcustomerlist' + sql, pageSize: 10, rownumbers: true,
                    onSelectRow: function (data, rowindex, rowobj) {
                        parent.SetTelphone(data._f_chargetelephone);
                    }
                });
            }
            catch (e) {
                alert(e.Message);
            }
            gridlist.changePage('first');
            $("#pageloading").hide();
        }
        function GetSql() {
            var sql = "";
            if (document.getElementById("txtKey").value != "") {
                sql += "&key=" + escape(document.getElementById("txtKey").value);
            }
            return sql;
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div class="tools_box">
        <div class="tools_bar">
            <div class="search_box">
                关键字：<asp:TextBox ID="txtKey" runat="server" CssClass="txtInput"></asp:TextBox>&nbsp;&nbsp;
                <input id="btnSearch" type="button" value="搜 索" class="btnSearch" onclick="InitList();" />
            </div>
        </div>
    </div>
    <div id="divDataList">
            </div>
    </form>
</body>
</html>
