<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="AdminRoleManage.aspx.cs" Inherits="DreamerShop.Admin.AdminRoleManage" %>
<%@ Register TagPrefix="uc1" TagName="LanguagesDeal" Src="LanguagesDeal.ascx" %>
<!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 runat="server">
    <title>
			<%=myLanguagesDeal.GetMyString("TextAdminRoleManage")%>
			-
			<%=mConfigInf.strWebTitle%>
		</title>
		<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
		<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
		<meta content="C#" name="CODE_LANGUAGE">
		<meta content="JavaScript" name="vs_defaultClientScript">
		<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
		<META content="<%=mConfigInf.strDescription%>" name=description>
		<META content="<%=mConfigInf.strKeywords%>" name=keywords>
		<LINK href="../StyleSheet1.css" rel="stylesheet">
        <SCRIPT language="javascript" id="clientEventHandlersJS">
		<!--


            function selall1() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur1");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview1");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall2() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur2");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview2");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall3() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur3");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview3");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall4() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur4");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview4");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall5() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur5");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview5");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall6() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur6");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview6");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall7() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur7");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview7");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }

            function selall8() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur8");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview8");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }
            function selall9() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur9");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview9");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }
            function selall10() {
                var a = document.getElementsByTagName("input");

                var str;
                var len;
                var state;

                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("SelAllPur10");
                        if ((len * 1) >= 1) {
                            state = a[i].checked;
                            break;
                        }
                    }
                }
                for (var i = 0; i < a.length; i++) {
                    if (a[i].type == "checkbox") {
                        str = a[i].id;
                        len = str.lastIndexOf("Purview10");
                        if ((len * 1) >= 1)
                            a[i].checked = state;
                    }
                }
            }
		//-->
		</SCRIPT>
</head>
<body>
    <form id="Form1" method="post" runat="server">
			<asp:Label id="lbEditID" runat="server" Visible="False"></asp:Label>
			<uc1:languagesdeal id="myLanguagesDeal" runat="server" Visible="False"></uc1:languagesdeal>
			<table cellSpacing="0" cellPadding="0" width="97%" align="center" border="0">
				<tr>
					<td vAlign="top" height="262">
						<table cellSpacing="0" cellPadding="0" width="100%" border="0">
							<tr>
								<td vAlign="top" bgColor="#ffffff" height="300"><FONT face="宋体"><asp:panel id="Pan1" runat="server">
											<TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
												<TR>
													<TD class="p12black"><SPAN class="p9orange"><IMG height="11" src="IMAGES/icon_1.gif" width="12" align="absMiddle">&nbsp;<%=myLanguagesDeal.GetMyString("TextSystemSetting")%>--&gt;<%=myLanguagesDeal.GetMyString("TextAdminRoleManage")%></SPAN>
													</TD>
													<TD>
														<asp:ImageButton id="btAddNew" runat="server" 
                                                            ImageUrl="../Images/Admin/fb-new.gif" onclick="btAddNew_Click" ></asp:ImageButton><%=myLanguagesDeal.GetMyString("AdminRoleTextAddNew")%><!--新增--></TD>
                                                            <TD align="right" width="50"><!--BUTTON_BEGIN-->
																<TABLE>
																	<TR>
																		<TD vAlign="bottom" noWrap>
																			<asp:ImageButton id="ibtPreReturn" runat="server" 
                                                                                ImageUrl="../Images/Admin/fb-cancel.gif" CausesValidation="False" onclick="ibtPreReturn_Click" 
                                                                               ></asp:ImageButton><%=myLanguagesDeal.GetMyString("TextReturn")%><!--返回--></TD>
																	</TR>
																</TABLE> <!--BUTTON_END--></TD>
												</TR>
											</TABLE>
											<HR noShade SIZE="1">
											<asp:datagrid id="dgList" runat="server" DataKeyField="RoleID" Width="100%" AutoGenerateColumns="False"
												AllowPaging="false" PageSize="50" CssClass="table-shangxia" ondeletecommand="dgList_DeleteCommand" 
                                                    oneditcommand="dgList_EditCommand" onitemdatabound="dgList_ItemDataBound" >
												<HeaderStyle HorizontalAlign="Center" BackColor="#F1F1F1"></HeaderStyle>
												<Columns>
													<asp:BoundColumn DataField="RoleName" HeaderText="AdminRoleTextName">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
                                                    <asp:BoundColumn DataField="IsAddNew" HeaderText="AdminRoleTextIsAddNew">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
                                                    <asp:BoundColumn DataField="IsEdit" HeaderText="AdminRoleTextIsEdit">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
                                                    <asp:BoundColumn DataField="IsDelete" HeaderText="AdminRoleTextIsDelete">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
													 
													<asp:TemplateColumn HeaderText="TextOperation">
														<HeaderStyle></HeaderStyle>
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
														<ItemTemplate>
															<asp:Button id="btEdit" Text="修改" CssClass="go-wenbenkuang" CommandName="Edit" Runat="server"></asp:Button>
															<asp:Button id="btDelete" Text="删除" CssClass="go-wenbenkuang" CommandName="Delete" Runat="server"></asp:Button>
														</ItemTemplate>
													</asp:TemplateColumn>
												</Columns>
												<PagerStyle Visible="False" NextPageText="下一页" PrevPageText="上一页" HorizontalAlign="Right"></PagerStyle>
											</asp:datagrid>
										</asp:panel></FONT><asp:panel id="Pan2" runat="server" Visible="False">
										<TABLE class="p9black" cellSpacing="0" cellPadding="0" width="100%" border="0">
											<TR>
												<TD>
													<TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
														<TR>
															<TD class="p12black" align="left"><SPAN class="p9orange"><IMG height="11" src="IMAGES/icon_1.gif" width="12" align="absMiddle">&nbsp;<%=myLanguagesDeal.GetMyString("TextAdminRoleManage")%>--&gt;
																	<asp:Label id="lbMessage" runat="server"></asp:Label></SPAN></TD>
															<TD align="right" width="50"><!--BUTTON_BEGIN-->
																<TABLE>
																	<TR>
																		<TD vAlign="bottom" noWrap>
																			<asp:ImageButton id="ibtReturn" runat="server" 
                                                                                ImageUrl="../Images/Admin/fb-cancel.gif" CausesValidation="False" 
                                                                                onclick="ibtReturn_Click"></asp:ImageButton><%=myLanguagesDeal.GetMyString("TextReturn")%><!--返回--></TD>
																	</TR>
																</TABLE> <!--BUTTON_END--></TD>
														</TR>
													</TABLE>
												</TD>
											</TR>
										</TABLE>
										<HR noShade SIZE="1">
										<TABLE cellSpacing="1" cellPadding="5" width="700" align="center" bgColor="#cccccc" border="0">
											<TR bgColor="#ffffff">
												<TD width="25%" align="right"><%=myLanguagesDeal.GetMyString("AdminRoleTextName")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%></TD>
												<TD class="pad">
													<asp:textbox id="txtAdminRoleName" runat="server" Width="300px" CssClass="wenbenkuang" MaxLength="50"></asp:textbox>
													<asp:requiredfieldvalidator id="rfvAdminRoleName" runat="server" ErrorMessage="请输入名称" Display="Dynamic" ControlToValidate="txtAdminRoleName" ForeColor="#FF0000"></asp:requiredfieldvalidator></FONT></TD>
											</TR>
                                            <TR bgColor="#ffffff">
												<TD align="right"><%=myLanguagesDeal.GetMyString("AdminRoleTextIsAddNew")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--是否显示：--></TD>
												<TD class="pad">
													<asp:checkbox id="ckIsAddNew" runat="server" Checked="false" Text="是"></asp:checkbox></TD>
											</TR>
											<TR bgColor="#ffffff">
												<TD align="right"><%=myLanguagesDeal.GetMyString("AdminRoleTextIsEdit")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--是否显示：--></TD>
												<TD class="pad">
													<asp:checkbox id="ckIsEdit" runat="server" Checked="false" Text="是"></asp:checkbox></TD>
											</TR>
											<TR bgColor="#ffffff">
												<TD align="right"><%=myLanguagesDeal.GetMyString("AdminRoleTextIsDelete")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--是否显示：--></TD>
												<TD class="pad">
													<asp:checkbox id="ckIsDelete" runat="server" Checked="false" Text="是"></asp:checkbox></TD>
											</TR>
											<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur1" onclick="selall1()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview1" runat="server" RepeatDirection="Horizontal" RepeatColumns="4"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur2" onclick="selall2()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview2" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur3" onclick="selall3()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview3" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur4" onclick="selall4()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview4" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur5" onclick="selall5()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview5" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur6" onclick="selall6()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview6" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur7" onclick="selall7()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview7" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur8" onclick="selall8()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview8" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur9" onclick="selall9()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview9" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												<TR bgColor="#ffffff" style="display:none">
													<TD align="right">
														<asp:CheckBox id="ckSelAllPur10" onclick="selall10()" runat="server" Text="全选"></asp:CheckBox></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblPurview10" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"></asp:CheckBoxList></TD>
												</TR>
												
												<TR bgColor="#ffffff">
													<TD align="right">
														<%=myLanguagesDeal.GetMyString("AdminRoleTextOrderFormPurview")%></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblOFRemarkFlag" runat="server" RepeatDirection="Horizontal">
														<asp:ListItem Value="101"  >
															<Img src="Images/offlag_1.png"></asp:ListItem>
															<asp:ListItem Value="102">
																<Img src="Images/offlag_2.png"></asp:ListItem>
															<asp:ListItem Value="103">
																<Img src="Images/offlag_3.png"></asp:ListItem>
															<asp:ListItem Value="104">
																<Img src="Images/offlag_4.png"></asp:ListItem>
															<asp:ListItem Value="105">
																<Img src="Images/offlag_5.png"></asp:ListItem>
														</asp:CheckBoxList> 
														<asp:CheckBoxList id="cblOFOperation" runat="server" RepeatDirection="Horizontal" RepeatColumns="4"></asp:CheckBoxList>
														</TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right">
														<%=myLanguagesDeal.GetMyString("AdminRoleTextDepotPurview")%></TD>
													<TD class="pad" align=left>
														<asp:CheckBoxList id="cblDepotPurview" runat="server" RepeatDirection="Horizontal" RepeatColumns="3"></asp:CheckBoxList></TD>
												</TR>
											<TR bgColor="#ffffff">
												<TD align="right">&nbsp;</TD>
												<TD class="pad " width="75%">&nbsp;
													<asp:button id="btSubmit" runat="server" CssClass="go-wenbenkuang" Text="提交信息" 
                                                        onclick="btSubmit_Click" ></asp:button>
													<asp:button id="btSave" runat="server" CssClass="go-wenbenkuang" Text="更新信息" 
                                                        onclick="btSave_Click"></asp:button>&nbsp;&nbsp;</TD>
											</TR>
										</TABLE>
									</asp:panel>
									<div align="center"><asp:label id="lbInfo" runat="server" ForeColor="Red"></asp:label></div>
								</td>
							</tr>
						</table>
					</td>
				</tr>
			</table>
		</form>
</body>
</html>
