<%@ Page Language="VB" AutoEventWireup="false" Inherits="work_plan_web_deploy.department_config" Codebehind="department_config.aspx.vb" %>
<%@ Import namespace="work_plan_web_deploy"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<HTML>
	<HEAD id="HEAD1" runat="server">
		<title>单位部门管理</title>
		<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
		<LINK href="site_css.css" type="text/css" rel="stylesheet">
        <script type="text/javascript" src="js/myjs.js" language="javascript"></script>
	    </HEAD>
	<body onload="">
			<form id="Form1" runat="server">
			<div id="title">
				<table cellSpacing="0" cellPadding="5" width="100%" border="0">
					<tr>
						<td align="center" height="20">系统高级管理 — 单位部门管理</td>
					</tr>
				</table>
			</div>
			<div id="place">
				<table cellSpacing="0" cellPadding="5" width="100%" border="0">
					<tr>
						<td height="30">您当前的位置：系统高级管理 &gt;&gt; 单位部门管理</td>
					</tr>
				</table>
			</div>
			<div id="contentdiv">
				<table class="maintable" cellSpacing="0" cellPadding="0" width="100%" border="0">
					<TBODY>
						<tr>
							<td vAlign="middle" align="left" height="30">
						 
								<STRONG>单位部门数：<asp:label id="Label1" runat="server" ForeColor="Red">Label</asp:label>&nbsp;<asp:button id="Button1" runat="server" CausesValidation="False" Text="当页全选" Width="72px"></asp:button>
                                &nbsp;<asp:button id="Button2" runat="server" CausesValidation="False" Text="取消选择" Width="72px"></asp:button>
                                &nbsp;<asp:button 
                                    id="Button3" runat="server" ForeColor="Red" CausesValidation="False" Text="删除选中单位部门"
											Width="120px" ToolTip="请谨慎操作"></asp:button>&nbsp;<asp:TextBox 
                                    ID="scqr" runat="server" Width="183px" style="width:183px;">要删除选中，先此处输入“删除”</asp:TextBox>
&nbsp;&nbsp;分类显示<asp:TextBox 
                                    ID="fids" runat="server" ReadOnly="True" 
                                    onclick="showDIV(this,dwtrees);">所有级别|000000000</asp:TextBox>
                                    <br />
                                    添加新单位部门：</STRONG>编号<asp:TextBox ID="did" 
                                        runat="server" Width="65px" MaxLength="9" style="width:65px;"></asp:TextBox>
                                    名称<asp:TextBox ID="mc" 
                                        runat="server" Width="65px" style="width:65px;"></asp:TextBox>
                                    上级单位部门<asp:TextBox ID="fid" onclick="showDIV(this,dwtree);" 
                                    runat="server" ReadOnly="True">无|000000000</asp:TextBox>
                                排序权重<asp:TextBox ID="qz" runat="server" Width="29px" style="width:29px;">20</asp:TextBox>
                                
							    <asp:button id="Button4" runat="server" 
                                    Text="添加" Width="50px"></asp:button><STRONG>
                               
							    <asp:RegularExpressionValidator ID="RegularExpressionValidator11" 
                                    runat="server" ControlToValidate="did" ErrorMessage="编号格式不对" 
                                    ValidationExpression="[1-9]\d{8}"></asp:RegularExpressionValidator>
							<asp:requiredfieldvalidator id="RequiredFieldValidator3" runat="server" 
                                    ControlToValidate="did" ErrorMessage="编号不能为空"></asp:requiredfieldvalidator>
							<asp:requiredfieldvalidator id="RequiredFieldValidator1" runat="server" 
                                    ControlToValidate="mc" ErrorMessage="名称不能为空"></asp:requiredfieldvalidator>
							<asp:requiredfieldvalidator id="RequiredFieldValidator2" runat="server" 
                                    ControlToValidate="qz" ErrorMessage="权重不能为空"></asp:requiredfieldvalidator>
							<asp:regularexpressionvalidator id="RegularExpressionValidator3" runat="server" 
                                    ControlToValidate="qz" ErrorMessage="权重必须为整数"
								ValidationExpression="^\d+$"></asp:regularexpressionvalidator>
                               
                               </STRONG>
							</td>
						</tr>
						<tr>
							<td>
                                <asp:GridView ID="GridView1" runat="server" BackColor="White" 
                                    BorderColor="#999999" BorderStyle="None" BorderWidth="1px" CellPadding="3" 
                                    Width="100%" AutoGenerateColumns="False" GridLines="Vertical" 
                                    EnableModelValidation="True">
                                    <RowStyle ForeColor="Black" BackColor="#EEEEEE" Height="20px" />
                                    <Columns>
                                        <asp:TemplateField HeaderText="选择">
                                            <ItemTemplate>
                                                <asp:CheckBox ID="CheckBox1" runat="server" />
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:BoundField DataField="id" HeaderText="单位部门编号" ReadOnly="True" />
                                        <asp:TemplateField HeaderText="单位部门名称">
                                            <EditItemTemplate>
                                                <asp:TextBox ID="mc2" runat="server" 
                                                    Text='<%# DataBinder.Eval(Container, "DataItem.mc") %>'></asp:TextBox>
                                            </EditItemTemplate>
                                            <ItemTemplate>
                                                <asp:Label ID="mc1" runat="server" 
                                                    Text='<%# DataBinder.Eval(Container, "DataItem.mc") %>'></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="上级单位部门名称">
                                            <EditItemTemplate>
                                                <asp:TextBox ID="fid2" runat="server" onclick="showDIV(this,dwtree2);" Text='<%# getdepartmentname2(DataBinder.Eval(Container, "DataItem.fid")) %>'  ReadOnly="True"></asp:TextBox>
                                            </EditItemTemplate>
                                            <ItemTemplate>
                                                <asp:Label ID="fid1" runat="server" Text='<%# getdepartmentname(DataBinder.Eval(Container, "DataItem.fid")) %>'></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                          <asp:TemplateField HeaderText="权重">
                                            <EditItemTemplate>
                                                <asp:TextBox ID="qz2" runat="server" 
                                                    Text='<%# DataBinder.Eval(Container, "DataItem.qz") %>' Width="40px" style="width:40px;"></asp:TextBox>
                                            </EditItemTemplate>
                                            <ItemTemplate>
                                                <asp:Label ID="qz1" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.qz") %>'></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                         <asp:TemplateField HeaderText="编辑" ShowHeader="False">
                                            <EditItemTemplate>
                                                <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" 
                                                    CommandName="Update" Text="更新"></asp:LinkButton>
                                                &nbsp;<asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" 
                                                    CommandName="Cancel" Text="取消"></asp:LinkButton>
                                            </EditItemTemplate>
                                            <ItemTemplate>
                                                <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" 
                                                    CommandName="Edit" Text="编辑"></asp:LinkButton>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                    </Columns>
                                    <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
                                    <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
                                    <EmptyDataTemplate>
                                        暂无单位部门信息！
                                    </EmptyDataTemplate>
                                    <SelectedRowStyle BackColor="#008A8C" Font-Bold="True" ForeColor="White" />
                                    <HeaderStyle BackColor="#006699" Font-Bold="True" ForeColor="White" 
                                        Height="20px" />
                                    <EditRowStyle Height="25px" />
                                    <AlternatingRowStyle BackColor="#DCDCDC" Height="20px" />
                                </asp:GridView>
                            </td>
						</tr>
					</TBODY></table>
					 </div>
					<!--隐藏开始-->
			<div class="menudiv" id="dwtree">
            <asp:TreeView ID="fidTreeView" runat="server" ImageSet="XPFileExplorer" 
        NodeIndent="15" ShowLines="True">
            <HoverNodeStyle Font-Underline="True" ForeColor="#6666AA" />
            <NodeStyle Font-Names="Tahoma" Font-Size="8pt" ForeColor="Black" 
                HorizontalPadding="2px" NodeSpacing="0px" VerticalPadding="2px" />
            <ParentNodeStyle Font-Bold="False" />
            <SelectedNodeStyle BackColor="#B5B5B5" Font-Underline="False" 
                HorizontalPadding="0px" VerticalPadding="0px" />
        </asp:TreeView>
            </div>
			<!--隐藏结束-->
            <!--隐藏开始-->
			<div class="menudiv" id="dwtrees">
            <asp:TreeView ID="fidTreeViews" runat="server" ImageSet="XPFileExplorer" 
        NodeIndent="15" ShowLines="True">
            <HoverNodeStyle Font-Underline="True" ForeColor="#6666AA" />
            <NodeStyle Font-Names="Tahoma" Font-Size="8pt" ForeColor="Black" 
                HorizontalPadding="2px" NodeSpacing="0px" VerticalPadding="2px" />
            <ParentNodeStyle Font-Bold="False" />
            <SelectedNodeStyle BackColor="#B5B5B5" Font-Underline="False" 
                HorizontalPadding="0px" VerticalPadding="0px" />
        </asp:TreeView>
            </div>
			<!--隐藏结束-->
            <div class="menudiv" id="dwtree2">
            <asp:TreeView ID="fidTreeView2" runat="server" ImageSet="XPFileExplorer" 
        NodeIndent="15" ShowLines="True">
            <HoverNodeStyle Font-Underline="True" ForeColor="#6666AA" />
            <NodeStyle Font-Names="Tahoma" Font-Size="8pt" ForeColor="Black" 
                HorizontalPadding="2px" NodeSpacing="0px" VerticalPadding="2px" />
            <ParentNodeStyle Font-Bold="False" />
            <SelectedNodeStyle BackColor="#B5B5B5" Font-Underline="False" 
                HorizontalPadding="0px" VerticalPadding="0px" />
        </asp:TreeView>
            </div>
			<!--隐藏结束-->				

				</form>
	</body>

</HTML>
