<%@ page language="C#" autoeventwireup="true" inherits="admin_iframe_iframeTop, DianCMS" enableviewstatemac="false" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Import Namespace="D.Common" %>
<%@ Import Namespace="D.BLL" %>
<!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></title>
    <link id="CssName" rel="stylesheet" type="text/css" runat="server" />
    <link rel="stylesheet" href="../css/skin/fashion/css/font-awesome.min.css" />
    <script src="../../js/<%=B_Lang.getLang() %>/SelectCheckBox.js" type="text/javascript"></script>
    <script src="../../js/Common.js" type="text/javascript"></script>
    <script src="../../js/lhgdialog/lhgcore.lhgdialog.min.js?self=true&skin=<%=Function.GetCssNameColor()%>" type="text/javascript"></script>
    <script type="text/javascript">
        function SelectIcon(obj)
        {
            var id = obj.id.split("_")[0] + "_" + obj.id.split("_")[1] + "_txtFa";
            WinOpenLhgDialog('选择小图标', 'fashionicon.aspx?ControlId=' + id + '', 720, 480, '');
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <table class="dh" cellpadding="0" cellspacing="0" border="0" align="center">
        <tr>
            <td>
                <asp:Image ID="P_Go" runat="server" ImageAlign="AbsMiddle" />
                您现在的位置：<a href="../info.aspx">后台管理</a> >> <a href="ProgramList.aspx">导航方案</a> >>
                <asp:Literal ID="Literal1" runat="server"></asp:Literal>
            </td>
        </tr>
    </table>
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <asp:GridView ID="GridView1" HeaderStyle-CssClass="title" runat="server" AutoGenerateColumns="False"
                CssClass="border" DataKeyNames="Id" RowStyle-CssClass="tdMoveTr" HorizontalAlign="Center"
                OnRowDataBound="GridView1_RowDataBound" OnRowCancelingEdit="GridView1_RowCancelingEdit"
                OnRowDeleting="GridView1_RowDeleting" OnRowEditing="GridView1_RowEditing" OnRowUpdating="GridView1_RowUpdating"
                Font-Bold="False" RowHeaderColumn="10" onrowcommand="GridView1_RowCommand">
                <RowStyle CssClass="tdMoveTr" />
                <Columns>
                    <asp:TemplateField HeaderText="选择" ItemStyle-Width="30">
                        <ItemTemplate>
                            <asp:CheckBox ID="CheckBox1" runat="server" />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="ID">
                        <ItemTemplate>
                            <asp:Literal ID="LitId" runat="server" Text='<%#Eval("Id") %>'></asp:Literal>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="头部导航菜单名称" ItemStyle-HorizontalAlign="Center">
                        <EditItemTemplate>
                            <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("Name") %>' CssClass="in1"></asp:TextBox>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <asp:Literal runat="server" Text='<%# Bind("Name") %>' ID="Literal1"></asp:Literal>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="小图标样式" ItemStyle-HorizontalAlign="Center">
                        <EditItemTemplate>
                            <asp:TextBox ID="txtFa" runat="server" Text='<%# Bind("fa") %>' CssClass="in1" style="float:left;"></asp:TextBox><input id="Button3" type="button" value=" 选择小图标 " runat="server" class="btn" onclick="SelectIcon(this)" style="float:left;"/>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <span class="fa <%#Eval("fa","{0}")%>"></span>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="排序" ItemStyle-HorizontalAlign="Center">
                        <EditItemTemplate>
                            <asp:TextBox ID="TextBox3" runat="server" Text='<%# Bind("OrderId") %>' CssClass="in1" Columns="10"></asp:TextBox>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <asp:Label ID="Label3" runat="server" Text='<%# Bind("OrderId") %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="Aspx.cs">
                        <EditItemTemplate>
                            <asp:RadioButtonList ID="RadAspxcs" runat="server" RepeatDirection="Horizontal" SelectedValue='<%# Bind("aspxcs") %>'>
                            <asp:ListItem Value="0">系统默认</asp:ListItem>
                            <asp:ListItem Value="1">手动输入</asp:ListItem>
                        </asp:RadioButtonList>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <asp:Label ID="Label4" runat="server" Text='<%# getAspxcs(Eval("aspxcs","{0}")) %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>  
                    <asp:TemplateField HeaderText="生成Left文件" ItemStyle-HorizontalAlign="Center">
                        <ItemTemplate>
                            <asp:LinkButton ID="LinkButton1" runat="server" CommandName="left" CommandArgument='<%# Eval("Id") %>'>生成Left文件</asp:LinkButton> ┊ 
                                <asp:Literal ID="LitAspxcs" runat="server"></asp:Literal>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:CommandField ShowEditButton="True" HeaderText="编辑" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" />
                    <asp:CommandField ShowDeleteButton="True" HeaderText="删除" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" />
                </Columns>
                <HeaderStyle CssClass="title" Font-Bold="True" />
                <EmptyDataTemplate>
                    <tr class="title">
                        <td class="t1">
                            ID
                        </td>
                        <td>
                            头部导航菜单名称
                        </td>
                        <td>
                            小图标样式
                        </td>
                        <td>
                            排序
                        </td>
                        <td>
                            编辑
                        </td>
                        <td>
                            删除
                        </td>
                    </tr>
                </EmptyDataTemplate>
            </asp:GridView>
            <table cellpadding="0" cellspacing="1" class="dh2" align="center">
                <tr>
                    <td height="30"><input id="checkDel" onclick="CheckDelBox(this)"
                                type="checkbox"><span id="ShowA">选择全部</span>
                        <asp:Button ID="Button2" runat="server" Text="生成选中Left文件" CssClass="btn" 
                            style="margin-left:10px" onclick="Button2_Click"></asp:Button>
                    </td>
                </tr>
            </table>
            <table class="border" cellspacing="1" cellpadding="0" width="99%" border="0" align="center"
                style="margin-top: 5px">
                <tr>
                    <td class="bqleft">
                        顶部导航菜单名称：
                    </td>
                    <td class="bqright">
                        <asp:TextBox ID="txtName" runat="server" CssClass="in1"></asp:TextBox>
                        如：内容管理
                    </td>
                </tr>
                <tr>
                    <td class="bqleft">
                        小图标样式：
                    </td>
                    <td class="bqright">
                        <asp:TextBox ID="txtfa" runat="server" CssClass="in1" style="float:left"></asp:TextBox><input id="Button3" type="button" value=" 选择小图标 " class="btn" onclick="WinOpenLhgDialog('选择小图标', 'fashionicon.aspx?ControlId=txtfa', 720, 480, '')" />
                        针对风尚版导航时使用
                    </td>
                </tr>
                <tr>
                    <td class="bqleft">
                        排序值：
                    </td>
                    <td class="bqright">
                        <asp:TextBox ID="txtOrderId" runat="server" CssClass="in1" Text="1"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td class="bqleft">
                        生成左侧Aspx.cs方式：
                    </td>
                    <td class="bqright">
                        <asp:RadioButtonList ID="RadAspxcs" runat="server" RepeatDirection="Horizontal">
                            <asp:ListItem Value="0" Selected="True">系统默认</asp:ListItem>
                            <asp:ListItem Value="1">手动输入</asp:ListItem>
                        </asp:RadioButtonList>
                    </td>
                </tr>
                <tr>
                    <td class="bqleft">
                    </td>
                    <td class="bqright" height="40">
                        <asp:Button ID="Button1" runat="server" CssClass="btn radius30 pad_0_30" Text=" 确认 " OnClick="Button1_Click" />
                    </td>
                </tr>
            </table>
            <table cellspacing="1" cellpadding="0" width="99%" border="0" align="center" style="margin-top: 5px" runat="server" id="iframeTop">
                <tr>
                    <td height="50">效果展示</td>
                </tr>
                <tr>
                    <td>
                        <table width="100%" border="0" cellspacing="0" cellpadding="0">
                            <tr>
                                <td background="../css/skin/<%=Function.GetCssName() %>/images/main_03.gif" style="height: 5px">
                                </td>
                            </tr>
                            <tr>
                                <td height="36" background="../css/skin/<%=Function.GetCssName() %>/images/main_07.gif">
                                    <table width="100%" border="0" cellspacing="0" cellpadding="0">
                                        <tr>
                                            <td height="52" background="../css/skin/<%=Function.GetCssName() %>/images/main_07.gif"
                                                valign="bottom">
                                                <table border="0" cellspacing="0" cellpadding="0" id="topTable">
                                                    <tr>
                                                        <asp:Repeater ID="Repeater1" runat="server">
                                                            <ItemTemplate>
                                                                <td>
                                                                    <a href='iframeLeft.aspx?ParentId=<%#Eval("Id") %>'><span><%#Eval("Name") %></span></a>
                                                                </td>
                                                            </ItemTemplate>
                                                        </asp:Repeater>
                                                    </tr>
                                                </table>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
        </ContentTemplate>
    </asp:UpdatePanel>
    </form>
</body>
</html>
