<%@ page language="C#" autoeventwireup="true" inherits="ims.web.sidebar, ims.web" enableviewstatemac="false" enableEventValidation="false" %><!DOCTYPE html>
<html id="sidebar">
<head runat="server"><title></title><meta http-equiv="X-UA-Compatible" content="IE=edge" /><base target="mainFrame" /></head>
<body runat="server" id="body">
   <form id="form1" runat="server" target="_self">
   <asp:ScriptManager runat="server" ID="sm" EnablePageMethods="True" OnAsyncPostBackError="AsyncError" />
    <asp:UpdatePanel ID="main" runat="server" RenderMode="Block" OnPreRender="AddInitScript" UpdateMode="Conditional" ChildrenAsTriggers="false">
        <ContentTemplate>
        <div runat="server" id="b1" class="btitle" visible="false">预览区：</div>
        <div id="inMain" runat="server">
        <div runat="server" id="Starts" class="item">
         <div id="tabs" class="ui-tabs">
            <ul>
                <li><a href="#start" title="开始（首页）" rev="home.aspx" id="t0"></a></li>
                <li runat="server" id="liAdd"><a href="#add" rel="添加" rev="select.aspx" id="t1"></a></li>
                <li><a href="#browse" rel="浏览" rev="select.aspx?action=View" id="t2"></a></li>
                <li><a href="#serach" rel="搜索" rev="select.aspx?action=Search" id="t3"></a></li>
                <li runat="server" id="liFav"><a href="#fav" rel="收藏" rev="dataHome.aspx?Area=favs" id="t4"></a></li>
                <li><a href="#shortcut" rel="快捷方式" rev="dataHome.aspx?Area=shortcuts" id="t5"></a></li>
            </ul>
            <div id="start">
                <ul>
                    <li id="dataAdmin"><a href="templets.aspx?mode=data"><%= ims.Sys.DataCenterText %></a><span class="more"> &gt; <span runat="server" id="spanAdd"><a href="select.aspx">添加</a> &gt; </span><a href="select.aspx?action=View">浏览</a> &gt; <a href="select.aspx?action=Search">搜索</a></span></li>
                    <li runat="server" id="templets"><a href="templets.aspx">设计中心</a></li>
                    <li runat="server" id="liInfo"><a href="infoList.aspx"><%= ims.Sys.InfoCenterText %></a><span runat="server" id="addInfo" class="more"> &gt; <a href="infoEdit.aspx">发布信息</a></span></li>
                    <li runat="server" id="liSend"><a href="#" onclick="return user();">发讯息</a><span runat="server" id="spanSend" class="more"><span runat="server" id="spanMsg">&gt; <a href="msg.aspx" onclick="return toSend('msg');">消息</a></span><span runat="server" id="spanMail">&gt; <a href="mail.aspx" onclick="return toSend('mail');">邮件</a></span><span runat="server" id="spanSms">&gt; <a href="sms.aspx" onclick="return toSend('sms');">短信</a></span><span runat="server" id="spanWx">&gt; <a href="send.aspx" onclick="return toSend('weixin');">微信</a></span></span></li>
                    <li class="lastData"><a href="view.aspx" class="views">最近浏览的数据</a></li>
                    <li runat="server" id="admin"><a href="adminHome.aspx">系统管理</a></li>
                    <li id="help"><a href="#" title="查看与当前操作相关的帮助信息" onclick="return showHelp();">实时帮助</a></li>
                </ul>
            </div>
            <div runat="server" id="add">
                <asp:TreeView ID="d1" NodeWrap="true" ExpandDepth="0" LineImagesFolder="images" SkipLinkText="" ShowExpandCollapse="true" NodeIndent="16" runat="server" ShowLines="false" CssClass="tree"></asp:TreeView>
                <div runat="server" id="msg1" class="msg">无项目</div>
            </div>
            <div id="browse">
                <asp:TreeView ID="d2" NodeWrap="true" ExpandDepth="0" LineImagesFolder="images" SkipLinkText="" ShowExpandCollapse="true" NodeIndent="16" runat="server" ShowLines="false" CssClass="tree"></asp:TreeView>
                <div runat="server" id="msg2" class="msg">无项目</div>
            </div>
            <div id="serach">
                <asp:TreeView ID="d3" NodeWrap="true" ExpandDepth="0" LineImagesFolder="images" SkipLinkText="" ShowExpandCollapse="true" NodeIndent="16" runat="server" ShowLines="false" CssClass="tree"></asp:TreeView>
                <div runat="server" id="msg3" class="msg">无项目</div>
            </div>
            <div runat="server" id="fav">
                <ul runat="server" id="divFavs" class="tabul"></ul>
                <div runat="server" id="msg4" class="msg">无项目</div>
            </div>
            <div id="shortcut">
                <ul runat="server" id="divShortcuts" class="tabul"></ul>
                <div runat="server" id="msg5" class="msg">无项目</div>
            </div>
        </div>       
        </div>
        <div runat="server" id="Online" class="item">
            <div class="title bgd"><span></span>在线用户</div>
            <div class="taskArea clear hide">
                <ul id="ulOnline"></ul>
                <div class="msg">暂无</div>
            </div>
        </div>
        <div runat="server" id="InfoTree" class="item">
            <div class="title bgd"><span></span><%= ims.Sys.InfoCenterText %></div>
            <div class="taskArea">
                <ul id="ulInfoTree" class="ztree" runat="server"></ul>
            </div>
        </div>
        <div runat="server" id="MsgCenter" class="item">
            <div class="title bgu"><span></span>消息</div>
            <div class="taskArea">
                <ul>
                    <li id="liMsgs"><a href="msgs.aspx">我的消息</a><span runat="server" id="sendMsg" class="more"> &gt; <a href="msg.aspx" onclick="return toSend('msg');">发送消息</a></span></li>
                    <li id="unread"><img src="images/todo.gif" id="togMsgs" onclick="showUnread(true);" /><a href="msgs.aspx?tab=unread">未读消息</a><span class="total" onclick="openUnread();"></span></li>
                </ul>
                <ol id="olMsgList" class="list hide"></ol>
            </div>
        </div>
        <div runat="server" id="Worktable" class="item">
            <div class="title bgu"><span></span>事务</div>
            <div class="taskArea">
                <ul>
                    <li id="works"><a href="trans.aspx"><%= ims.Sys.TransCenterText %></a><span id="addWork" class="more"> &gt; <a href="select.aspx?action=AddFlow">发起流程</a></span></li>
                    <li id="todo"><img src="images/todo.gif" id="togTodo" onclick="showTodo(true);" /><a href="trans.aspx?tab=pending&sort=default">待办事项</a><span class="total" onclick="openTodo();"></span></li>
                </ul>
                <ol id="olList" class="list hide"></ol>
            </div>
        </div>
        <div runat="server" id="Dirs" class="item">
            <div class="title bgu"><span></span>目录</div>
            <div class="taskArea">
                <asp:TreeView ID="d" NodeWrap="true" ExpandDepth="1" LineImagesFolder="images/tree" SkipLinkText="" NodeStyle-ImageUrl="images/off.gif" NodeStyle-HorizontalPadding="3" runat="server" ShowLines="true" CssClass="tree">
                    <Nodes>
                        <asp:TreeNode NavigateUrl="0" Text="根目录" Value="0" ImageUrl="images/root.gif"></asp:TreeNode>
                    </Nodes>
                </asp:TreeView>
            </div>
        </div>
        <div runat="server" id="CurrentInfo" class="item">
        <div class="title bgu"><span></span>详细信息</div>
        <div class="taskArea">
            <ul style="display:none" id="fixedInfo">
                <li runat="server" id="liLoginView">当前状态：<asp:LoginView ID="lv" runat="server">
                        <AnonymousTemplate>未登录「<a href="Login.aspx">登录</a><span runat="server" id="spanReg">，<a href="reg.aspx">注册</a></span>」</AnonymousTemplate>
                        <LoggedInTemplate>已登录，<a href="javascript:__doPostBack('btnReload', 'logout');" title="退出登录" target="_self">注销</a></LoggedInTemplate>
                    </asp:LoginView>
                </li>
                <li id="liTitle">当前内容：<span id="curTitle"></span></li>
            </ul>
            <ul id="ulDetail">
            </ul>
        </div>
        </div>
        </div>
        <div id="views">
            <ul class="ui-corner-all">
                <li id="v2" href="table.aspx">表格视图</li>
                <li id="v4" href="detail.aspx?InSerial=true">详情视图</li>
                <li id="v1" href="thumb.aspx">缩略视图</li>
                <li id="v3" href="summary.aspx">概要视图</li>
                <li id="v5" href="chart.aspx">图表视图</li>
                <li id="v6" href="report.aspx">报表视图</li>
            </ul>
        </div>
        <asp:UpdatePanel ID="btns" runat="server" RenderMode="Block" UpdateMode="Conditional" Visible="false">
            <ContentTemplate>
            <input type="button" onclick="return preSave(this);" runat="server" id="btnSave" onserverclick="SaveLayout" value="保存" title="保存当前预览区的版式" class="btn" />
            <input type="button" runat="server" id="btnSaveas" onclick="return toPrompt('请输入名称：', toSaveas, '新建版式');" value="保存为…" title="将当前版式命名保存" class="btn" />
            <input type="button" runat="server" id="btnSelect" onserverclick="SelectLayout" value="选择版式" class="btn" />
            <input type="button" runat="server" id="btnManage" onserverclick="toManage" value="管理版式" class="btn" />
            <input type="button" onclick="return showHelp();" value="帮助" class="btn" />
            </ContentTemplate>
        </asp:UpdatePanel>
        <input type="button" runat="server" id="btnReload" class="hide" onserverclick="BuildDynContents" />
        </ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="btnReload" EventName="serverclick" />
        </Triggers>
    </asp:UpdatePanel>

        <div id="other" runat="server" visible="false">
            <div class="btitle" runat="server" id="b2">候选区：</div>
            <div id="inOther" runat="server"></div>
        </div>
        <asp:UpdatePanel ID="custom" runat="server" RenderMode="Block" ChildrenAsTriggers="false" UpdateMode="Conditional" Visible="false">
            <ContentTemplate>
                <div class="btitle">添加版块：</div>
                <div id="inCustom" class="item">
                <div class="title bgu"><span></span>标题：<asp:TextBox runat="server" ID="tbTitle" ToolTip="输入新版块的标题文字" onclick="CanelEvent();"></asp:TextBox></div>
                <div class="taskArea">
                    <ul runat="server" id="ulEles" class="ulCustom"></ul>
                    <div id="cmds"><a href="#" onclick="return toAddEle();">添加元素</a>&nbsp;&nbsp;<a href="#" runat="server" id="aAddTree" onclick="return addTree();">添加树形结构</a>&nbsp;&nbsp;<asp:LinkButton runat="server" ID="lbClear" OnClick="ClearElements" Text="清空元素"></asp:LinkButton></div>
                </div>
                </div>
                <div class="center">
                    <asp:Button runat="server" ID="btnAdd" CssClass="btn" OnClick="AddBlock" OnClientClick="return PreAddBlock();" Text="添加到候选区" />
                </div>
                <input type="button" runat="server" id="btnHelper" class="hide" onserverclick="OperaBlock" />
            </ContentTemplate>
        </asp:UpdatePanel>
        <ims:Pop runat="server" ID="addEle" Title="添加元素" OkButtonText="添加" HideOnOkClientClick="false" OnOkClick="AddElement" Width="490" Visible="false" OnOkClientClick="return PreAddEle();" OnClientUpdated="InitAddPop();">
            <ContentTemplate>
                <asp:DropDownList runat="server" ID="ddlTypes" AutoPostBack="true" OnSelectedIndexChanged="FillLayouts" ToolTip="选择要添加的元素的类型">
                    <asp:ListItem Selected="True" Value="">-选择类型-</asp:ListItem>
                    <asp:ListItem Value="Browse">浏览</asp:ListItem>
                    <asp:ListItem Value="Add">添加</asp:ListItem>
                    <asp:ListItem Value="Start">发起</asp:ListItem>
                    <asp:ListItem Value="Search">搜索</asp:ListItem>
                    <asp:ListItem Value="Dir">目录</asp:ListItem>
                    <asp:ListItem Value="Page">页面</asp:ListItem>
                    <asp:ListItem Value="Table">表格视图</asp:ListItem>
                    <asp:ListItem Value="Thumb">缩略视图</asp:ListItem>
                    <asp:ListItem Value="Summary">概要视图</asp:ListItem>
                    <asp:ListItem Value="Detail">详情视图</asp:ListItem>
                    <asp:ListItem Value="Chart">图表视图</asp:ListItem>
                    <asp:ListItem Value="Report">报表视图</asp:ListItem>
                    <asp:ListItem Value="Favorite">我的收藏</asp:ListItem>
                    <asp:ListItem Value="Shortcut">快捷方式</asp:ListItem>
                    <asp:ListItem Value="Html">自由编辑内容</asp:ListItem>
                </asp:DropDownList><span>：</span>
                <span class="hide" for="Browse Table Thumb Summary Detail Chart Report">
                    <asp:DropDownList runat="server" ID="ddlBrowse" OnDataBound="FillFilters" ToolTip="选择要浏览的数据" AutoPostBack="true" OnSelectedIndexChanged="FillFilters"></asp:DropDownList>&nbsp;<asp:DropDownList runat="server" ToolTip="可在此选择过滤器" ID="ddlFilters"></asp:DropDownList>
                </span>
                <asp:DropDownList runat="server" ID="ddlStart" for="Start" CssClass="hide" ToolTip="选择要发起的流程"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="ddlSearch" for="Search" CssClass="hide" ToolTip="选择搜索的对象"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="ddlAdd" OnSelectedIndexChanged="FillLayouts" AutoPostBack="true" for="Add" CssClass="hide" ToolTip="选择模板"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="ddlFav" for="Favorite" CssClass="hide" ToolTip="选择收藏的项目"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="ddlShortcut" for="Shortcut" CssClass="hide" ToolTip="选择快捷方式"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="ddlPage" for="Page" CssClass="hide" ToolTip="选择页面">
                    <asp:ListItem Value="home.aspx" Selected="True">首页</asp:ListItem>
                    <asp:ListItem Value="infolist.aspx">信息中心</asp:ListItem>
                    <asp:ListItem Value="infoEdit.aspx">发布信息</asp:ListItem>
                    <asp:ListItem Value="templets.aspx?mode=data">数据中心</asp:ListItem>
                    <asp:ListItem Value="templets.aspx">设计中心</asp:ListItem>
                    <asp:ListItem Value="trans.aspx">事务中心</asp:ListItem>
                    <asp:ListItem Value="msgs.aspx">消息</asp:ListItem>
                    <asp:ListItem Value="datahome.aspx">搜索</asp:ListItem>
                    <asp:ListItem Value="select.aspx?action=Search">高级搜索</asp:ListItem>
                    <asp:ListItem Value="adminhome.aspx">系统管理</asp:ListItem>
                </asp:DropDownList>
                <a id="selectDir" for="Dir" class="hide" title="点击选择目录" runat="server" style="color:Blue" onclick="return showDirTree();" onserverclick="DirChanged"></a>
                <asp:DropDownList runat="server" ID="laysTable" for="Table" ToolTip="指定版式"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="laysDetail" for="Detail" ToolTip="指定版式"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="laysChart" for="Chart" ToolTip="指定图表"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="laysReport" for="Report" ToolTip="指定报表"></asp:DropDownList>
                <asp:DropDownList runat="server" ID="laysEdit" for="Add" ToolTip="指定版式"></asp:DropDownList>
                <div for="Html" class="hide">
                <asp:TextBox runat="server" ID="tbHtml" TextMode="MultiLine" Width="98%"></asp:TextBox>
                </div>
            </ContentTemplate>
        </ims:Pop>
        <ims:Pop runat="server" ID="addNode" Title="编辑元素" ShowProgress="false" OnOkClientClick="return nodeEdited();">
            <ContentTemplate>
                <div class="padbox">
                    文字：<input type="text" id="tbName" />
                    <div class="mtop_s">
                        链接：<input type="text" id="tbUrl" style="width:328px" />
                    </div>
                </div>
                <div class="right mtop_s"><a class="u" onclick="return toGetUrl();" href="#">获取内部页面链接</a>&nbsp;</div>
            </ContentTemplate>
        </ims:Pop>
        <ims:Pop runat="server" ID="manage" OkButtonText="我的版式" OnOkClick="SelectLayout" Title="管理版式" CanelButtonText="关闭" Width="420" CustomCss="noline" ShowProgress="false">
            <ContentTemplate>
                <table class="normal" id="layouts">
                    <tr><th>版 式</th><th style="width:60px">设为默认</th><th style="width:32px">更名</th><th style="width:32px">编辑</th><th style="width:32px">删除</th></tr>
                    <asp:PlaceHolder runat="server" ID="phLayouts"></asp:PlaceHolder>
                </table>
                <fieldset class="mtop_n"><legend>角色的默认版式</legend>
                    <div class="padbox">
                        角色：<asp:DropDownList runat="server" ID="ddlRoles" OnSelectedIndexChanged="ddlRolesChanged" AutoPostBack="true"></asp:DropDownList>
                        <asp:DropDownList runat="server" ID="ddlLayouts"></asp:DropDownList> <asp:Button runat="server" ID="btnSet" Text="确定" CssClass="btn" OnClick="setForRole" />
                    </div>
                </fieldset>
                <asp:CheckBox runat="server" ID="cbDisChange" Text="禁止普通用户自定义左侧栏" onclick="switchChange();" />
                <asp:Button runat="server" ID="btnOpera" OnClick="OperaLayout" CssClass="hide" />
            </ContentTemplate>
        </ims:Pop>
        <ims:Pop runat="server" ID="assign" Width="475" ShowProgress="false" OnOkClick="ApplyTo">
            <ContentTemplate>
                <asp:CheckBoxList runat="server" ID="cblRoles" CssClass="colorText" RepeatLayout="Flow" RepeatDirection="Horizontal"></asp:CheckBoxList>
            </ContentTemplate>
        </ims:Pop>
        <ims:Pop runat="server" ID="src" Title="选择我的默认左侧栏版式" ShowProgress="false" OnOkClick="SetLayoutSource">
            <ContentTemplate>
                <asp:RadioButton runat="server" ID="rbMy" GroupName="src" Text="我的自定义左侧栏" /><br />
                <asp:RadioButton runat="server" ID="rbRole" GroupName="src" Text="优先使用" /><asp:DropDownList runat="server" ID="ddlMyRole" onclick="$('#src_rbRole').prop('checked',true);"></asp:DropDownList> <label for="src_rbRole">角色的默认版式</label>
            </ContentTemplate>
        </ims:Pop>
        <ims:Pop runat="server" ID="edit" ShowProgress="false" CustomCss="noline" Width="460" OnOkClientClick="preUpdate();" OnOkClick="SaveBlock">
            <ContentTemplate>
                标题： <asp:TextBox runat="server" ID="tbNewTitle" CssClass="mbottom_s" ToolTip="版块标题" Width="240"></asp:TextBox>
                <asp:TextBox runat="server" ID="tbCon" CssClass="ck" TextMode="MultiLine" Width="98%" Height="160"></asp:TextBox>
                <ul runat="server" id="ulTree" title="点击元素显示操作按钮，拖动元素调整位置"></ul>
                <div id="newBlock" runat="server" class="hide"></div>
            </ContentTemplate>
        </ims:Pop>
        <div id="rt" runat="server"><span runat="server" id="diy">&#10011;</span><span id="close">&#10007;</span></div>
        <script src="js/comm.js"></script><script src="js/ztree.js"></script><script src="js/sidebar.js"></script>
    </form>
</body>
</html>