<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="employee_editlist.aspx.cs" Inherits="VA.Modules.JDingMember.basic.employee_editlist" %>

<%@ Import Namespace="System.Data"%>

<!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>
<title>员工管理</title>    
    <!--#include virtual="/include/css/editlist.aspx"-->
    <!--#include virtual="/include/js/editlist.aspx"--> 
    <script type="text/javascript">
                 
        //添加；
        function add() {
            openFrameWindow("添加员工", 540, 210, "employee_edit.aspx");
        }

        //单条修改；
        function smodify(keyValue) {
            var ids = keyValue;
            openFrameWindow("修改员工信息", 540, 210, "employee_edit.aspx?employeeCode=" + ids);
            event.stopPropagation();  //阻止事件冒泡，避免行被选中；            
        }

        //单条删除；
        function sdel(keyValue) {
            singleActWrapper("Del", keyValue, "确定要删除该项吗？", "");
        }

        //设为在职；
        function setOnTheJob() {
            batchllyActWrapper("SetOnTheJob", "", "");
        }

        //设为离职；
        function setDimission() {
            batchllyActWrapper("SetDimission", "", "");
        }

        $(function () {
            initListPage();
        });

    </script>

    <style type="text/css">
        #toolBar{    
            border-top:solid 1px #B9CAD3;
        }
    </style>

</head>
<body>
<!--说明：该页面是以 employee_editlist_nofresh_5.aspx 为原型封装的结果-->
<form id="Form1" method="post" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>

<div id="pageWrapper" class="pageWrapper">   
    
    <div id="toolBar">    
        <a href="javascript:add()" class="jtongui-toolbarbutton" icon="icon-add">添加</a>                                      
        <a href="javascript:setOnTheJob()" class="jtongui-toolbarbutton" icon="icon-enable">设为在职</a>        
        <a href="javascript:setDimission()" class="jtongui-toolbarbutton" icon="icon-disable">设为离职</a>        
        <a href="javascript:refresh()" class="jtongui-toolbarbutton" icon="icon-reload">刷新</a>            
    </div><!--toolBar.END-->   
                     
    <div id="searchBar">
    
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>

        <asp:DropDownList ID="ddlShops" runat="server"
             AutoPostBack="true" 
            onselectedindexchanged="ddlShops_SelectedIndexChanged">             
        </asp:DropDownList>

        <asp:DropDownList ID="ddlEmployeeStatus" runat="server"
             AutoPostBack="true" 
            onselectedindexchanged="ddlEmployeeStatus_SelectedIndexChanged">             
        </asp:DropDownList>
                               
        <asp:TextBox ID="txtKeyWords" runat="server"
            CssClass="input"
            Width="150px" />
   
        <asp:Button ID="btnSearch" runat="server" 
             CssClass="simpleBtn"
             Text="搜索" 
             Onclick="btnSearch_Click" />
        
    </ContentTemplate>
    </asp:UpdatePanel>

    </div><!--searchBar.END-->    

    <div id="dataBar">

    <!--MainList.Start-->    
    <div class="jtongui-smartlisttable" id="jtongui-smartlisttable">

    <table cellpadding="3" cellspacing="0" class="tableheader" id="tb1_header" >
    <thead>
    <tr>
        <td style="width:30px;text-align:center;"><input type="checkbox" id="ckb_selectAll"/></td>
        <td style="width:50px;text-align:center;">编号</td>
        <td style="width:100px;text-align:center;">姓名</td>
        <td style="width:70px;text-align:center;">输入码</td>
        <td style="width:70px;text-align:center;">状态</td> 
        <td style="width:100px;text-align:center;">所属门店</td> 
        <td style="width:30px;text-align:center;">修改</td>	      
        <td></td>
    </tr>    
    </thead>
    </table>

    <div id="dataBody">
    <asp:Repeater ID="myRepeater" Runat="server" EnableViewState="False"  >
    <HeaderTemplate>    
    <div class="bodyContainer">
    <% = base.ShowNoRecordInfo() %>
    <table cellpadding="3" cellspacing="0" class="tablebody" tbHeader="tb1_header">
    </HeaderTemplate>
    <ItemTemplate>
    <tr>
        <td style="text-align:center;"><input type="checkbox" name="ckb_dataItem" value="<%# Eval("Employee_Code")%>" /></td>        
        <td align="center"><%# Eval("Employee_Code")%></td>
        <td align="center"><%# Eval("Employee_Name")%></td>
        <td align="left"><%# Eval("Input_Code")%></td>                
        <td align="center"><%# VA.Modules.JDingMember.Core.Enums.EmployeeStatusConverter.Convert_Value_ToText(Eval("Status").ToString(),true)%></td>                         	       	     
        <td align="center"><%# Eval("Shop_Name")%></td>
        <td align="center">
            <a href="#" onclick="javascript:smodify('<%# Eval("Employee_Code")%>');"><img src="/app_themes/icons/edit.png" alt="修改"/>  </a>
        </td>     
        <td></td>
    </tr>
    </ItemTemplate>
    <FooterTemplate>
    </table>
    </div><!--bodyContainer.END-->        

    <div id="divPagerInfo" style="display:none">
        <%=base.pageInfo%>
    </div>

    <input type="hidden" id="hidden_pageCnt" value="<% = base.PageCnt%>" />
    <input type="hidden" id="hidden_rdCnt" value="<% = base.RdCnt%>" />
    <input type="hidden" name="chkNum" value="<%=chkNum%>" />

    </FooterTemplate>
    </asp:Repeater>    
    </div><!--dataBody.END-->

    </div><!--jtongui-smartlisttable.END-->        
    <!--MainList.End-->  

    </div><!--dataBar.END-->

    <div id="pagerBar">
       ……
    </div><!--pageNavBar.END-->
    
    <asp:HiddenField runat="server" ID="hfCurrPage" EnableViewState="true" />
    
</div>

<!--添加窗口-->
<div id="winAdd" style="display:none;"></div> 

<%
    Response.Write("<script type='text/javascript'>keywords_ToolTip = '"+ base.keywords_ToolTip +"';</script>");    
%>

</form>
</body>
</html> 