<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Staff_WorkExp.aspx.cs" Inherits="TotCms.Web.Office.Staff.Staff_WorkExp" %>

<!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="../style/global.css" rel="stylesheet" type="text/css" />
    <link href="../../js/jquery-ui-1.8.10/css/ui-lightness/jquery-ui-1.8.10.custom.css" rel="stylesheet" type="text/css" />
  <script src="../../js/jquery-1.5.1.min.js" type="text/javascript"></script>
  <script src="../../js/jquery-ui-1.8.10/js/jquery.ui.core.min.js" type="text/javascript"></script>
  <script src="../../js/jquery-ui-1.8.10/js/jquery.ui.widget.min.js" type="text/javascript"></script>
  <script src="../../js/jquery-ui-1.8.10/js/jquery.ui.datepicker.min.js" type="text/javascript"></script>
  <script src="../../js/jquery-ui-1.8.10/js/i18n/jquery.ui.datepicker-zh-CN.js" type="text/javascript"></script>
  <script type="text/javascript">
    $(function () {
      $('.dates').datepicker($.datepicker.regional["zh-CN"]);
    });
  </script>
</head>
<body>
    <form id="form1" runat="server">    
    <asp:ListView ID="lvList" runat="server" ItemPlaceholderID="items" InsertItemPosition="LastItem" 
        onselectedindexchanged="lvList_SelectedIndexChanged" 
        onitemdeleting="lvList_ItemDeleting" onitemediting="lvList_ItemEditing" 
        oniteminserting="lvList_ItemInserting" 
        onitemupdating="lvList_ItemUpdating" onitemcommand="lvList_ItemCommand" 
        onitemcanceling="lvList_ItemCanceling" 
      onitemdatabound="lvList_ItemDataBound" DataKeyNames="id">
        <LayoutTemplate>
          <table cellpadding="0" cellspacing="1" border="0" width="100%" class="border">            
          <tr class="suphead">
              <td>单位名称</td>
              <td>部门名称</td>
              <td>担任职务</td>
              <td>开始日期</td>
              <td>结束日期</td>
              <td>操作</td>
          </tr>
          <asp:PlaceHolder runat="server" ID="items"></asp:PlaceHolder>
          </table>
        </LayoutTemplate>
        <EditItemTemplate>
            <tr class="lines">
            <td><asp:TextBox ID="tbComName" runat="server" Text='<%# Eval("ComName") %>'></asp:TextBox></td>
            <td><asp:TextBox ID="tbDeptName" runat="server" Text='<%# Eval("DeptName") %>'></asp:TextBox></td>
            <td><asp:TextBox ID="tbPositionAt" runat="server" Text='<%# Eval("PositionAt") %>' CssClass="input_mini"></asp:TextBox></td>
            <td><asp:TextBox ID="tbStartDate" runat="server" Text='<%# Eval("StartDate") %>' CssClass="dates"></asp:TextBox></td>
            <td><asp:TextBox ID="tbEndDate" runat="server" Text='<%# Eval("EndDate") %>' CssClass="dates"></asp:TextBox></td>           
            <td>
              <asp:Button ID="UpdateButton" runat="server" CommandName="Update" 
                    Text="完成" />
                <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" 
                    Text="取消" />
            </td>
            </tr>
            <tr class="contentlines">
              <td colspan="6">工作内容：<asp:TextBox ID="tbContent" runat="server" Text='<%# Eval("Content") %>' TextMode="MultiLine" CssClass="text_normal"></asp:TextBox></td>
            </tr>
        </EditItemTemplate>
        <EmptyDataTemplate>
            暂时没有数据.
        </EmptyDataTemplate>
        <InsertItemTemplate>
            <tr class="alterlines">
            <td><asp:TextBox ID="tbComName" runat="server"></asp:TextBox></td>
            <td><asp:TextBox ID="tbDeptName" runat="server"></asp:TextBox></td>
            <td><asp:TextBox ID="tbPositionAt" runat="server" CssClass="input_mini"></asp:TextBox></td>
            <td><asp:TextBox ID="tbStartDate" runat="server" CssClass="dates"></asp:TextBox></td>
            <td><asp:TextBox ID="tbEndDate" runat="server" CssClass="dates"></asp:TextBox></td>            
            <td>
            <asp:Button ID="InsertButton" runat="server" CommandName="Insert" 
                    Text="添加" />
                <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" 
                    Text="取消" />
            </td>
            </tr>
            <tr class="contentlines">
              <td colspan="6">工作内容：<asp:TextBox ID="tbContent" runat="server" TextMode="MultiLine" CssClass="text_normal"></asp:TextBox></td>
            </tr>
        </InsertItemTemplate>

        <ItemTemplate>
            <tr class="lines">
            <td><%# Eval("ComName")%></td>
            <td><%# Eval("DeptName")%></td>
            <td><%# Eval("PositionAt")%></td>
            <td><%# Eval("StartDate")%></td>
            <td><%# Eval("EndDate") %></td>            
            <td>
            <asp:Button ID="EditButton" runat="server" CommandName="Edit" Text="编辑" />
                    <asp:Button ID="DeleteButton" runat="server" CommandName="Delete" 
                        Text="删除" OnClientClick="return confirm('确定删除吗?')" />
            </td>
            </tr>
            <tr class="contentlines">
              <td colspan="6">工作内容：<%# Eval("Content") %></td>
            </tr>
        </ItemTemplate>
        
    </asp:ListView>
    </form>
</body>
</html>
