<%@ page language="C#" autoeventwireup="true" inherits="general_ClientManage_ClientTract, CrmCommand" %>
<%@ Register TagPrefix="C1WebGrid" Namespace="C1.Web.C1WebGrid" Assembly="C1.Web.C1WebGrid.2" %>


<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
   <script src="../../Javascript/CheckALL.js"  language=javascript></script>
   <script>
   function CheckForm(formName,chkName,str,width,heigth)
   {
       if(!CheckOk(formName,chkName,str,width,heigth))
       {
          
          return false;
       }
       else
       {
         return  confirm('确定要删除吗？');
       }
   }
   function OpenWin(str)
   {
      var id=document.getElementById("HidCid").value;
     
      var url=str+"?id="+id;
    
         if(id !="")
         {
          
           var R=  window.showModalDialog(url,"newwindow","dialogWidth=610px;dialogHeight=440px");
           
              if(R == "ok")
              {
                  location.href='ClientTract.aspx?id='+id;
              }
               
         }
       return false;
   
   }
     function ShowWin(id)
   {
    
     
      var url="TractInfo.aspx?id="+id;
    
         if(id !="")
         {
          
           var R=  window.showModalDialog(url,"newwindow","dialogWidth=650px;dialogHeight=300px");
           
              if(R == "ok")
              {
                  location.reload();
              }
             
               
         }
       return false;
   
   }
        function CheckEdit(formName,chkName,str,width,heigth)
   {
       var R= CheckOk(formName,chkName,str,width,heigth)
         if(R == "ok")
              {
                  location.reload();
              }
     
          return false;
      
      
   }

   </script>
    <title>无标题页</title>
	<style type="text/css">
.style1 {
	text-align: center;
}
</style>
</head>
<body>
    <form id="form1" runat="server">
   <div  id="pnlMain">
   <table style="width: 100%">
	<tr>
		<td>
		<table style="width: 100%">
			<tr>
				<td class="TableData"><IMG height="18" src="../images/notify_new.gif" width="18" align="absMiddle">
				<SPAN class="big3">
				客户跟踪记录</span></td>
			</tr>
		</table>
		</td>
	</tr>
	<tr>
		<td class="TableData" align="center">
				 <c1webgrid:c1webgrid   SkinId="gridviewSkin" Width=700px   ID="C1WebGrid1" 

  runat="server" AutoGenerateColumns="False"  AllowPaging=True  

PageSize=10 AllowColSizing="True" OnPageIndexChanging="C1WebGrid1_PageIndexChanging" OnItemCreated="C1WebGrid1_ItemCreated"   >
        <Columns>
            <C1WebGrid:C1TemplateColumn HeaderText="全选">
                <HeaderTemplate>
                  
                    <input id="all" type="checkbox"   value="全选" onclick="CheckAll

('form1','item','all')" />
                </HeaderTemplate>
                <ItemStyle Width="22px" />
                <ItemTemplate>
                  
                    <input id="item" type="checkbox" 

runat="server"  value='<%#Eval("Client_TrackID") %>'/>
                </ItemTemplate>
            </C1WebGrid:C1TemplateColumn>
           
            <C1WebGrid:C1BoundColumn DataField="Client_TrackTypeName" HeaderText="跟踪类型">
            </C1WebGrid:C1BoundColumn>
            <C1WebGrid:C1BoundColumn DataField="Exp1" HeaderText="跟踪人员">
             
            </C1WebGrid:C1BoundColumn>
            <C1WebGrid:C1TemplateColumn HeaderText="跟踪活动">
                <ItemStyle Width="250px" />
                <ItemTemplate>
                    <asp:Label     ID="Lkb" Text='<%# Server.HtmlDecode(Eval("Client_TrackContent").ToString()).Length > 20 ? Server.HtmlDecode(Eval("Client_TrackContent").ToString()).Substring(0, 19) + "..." : Server.HtmlDecode(Eval("Client_TrackContent").ToString())%>'  ToolTip='<%# Server.HtmlDecode(Eval("Client_TrackContent").ToString())%>' runat="server"></asp:Label>
 
                </ItemTemplate>
            </C1WebGrid:C1TemplateColumn>
            <C1WebGrid:C1BoundColumn DataField="Client_TrackDate" HeaderText="记录日期">
                
            </C1WebGrid:C1BoundColumn>
 
        				</Columns> 


        </c1webgrid:c1webgrid>
</td></tr>
<tr>
		<td class="TableData" align="center">
<input id="Button1" type="button"  class="BigButton" value="新增跟踪记录" onclick="return OpenWin('AddTract.aspx')" />
        <asp:Button ID="Button3" OnClientClick=" return  CheckEdit('form1','item','TractInfo.aspx','530px','340px')" class="BigButton" runat="server" Text="查看跟踪记录"  Width="90px" />
            <asp:Button ID="Button2" OnClientClick=" return  CheckForm('form1','item','','','')" class="BigButton" runat="server" Text="删除跟踪记录" OnClick="BtnDel_Click" Width="95px" />&nbsp;
        </td></tr>
</table>

    	 
    </div>
      <input id="HidCid" runat=server  type="hidden" />
    </form>
</body>
</html>
