123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142 |
- @using Bowin.Web.Controls.Mvc;
- @using EMISOnline.Web.Controls;
- @using Bowin.Common;
- @{
- Layout = "~/Views/Shared/_FrameLayout.cshtml";
- List<string> lurl = new List<string>();
- lurl.Add("Content/");
- lurl.Add("Doc/");
- lurl.Add("Scripts/");
- lurl.Add("Login/");
- lurl.Add("UploadFile/");
- lurl.Add("Account/ChangePassword");
- FormsAuthenticationHelper fahelper = new FormsAuthenticationHelper();
- var cookieName = EMISOnline.Utility.Const.LOCAL_SETTING_LOGIN_COOKIENAME;
- fahelper.AuthenticateRequest(HttpContext.Current, cookieName, lurl);
- }
- @section scripts{
- <script type="text/javascript">
- $(function () {
- //$(".easyui-tree").tree('collapseAll');
- //$.System.addTab('首页', '@Url.Content("~/Home/Main")', 'Main', false);
- initMenu();
- });
- function initMenu() {
- $(".index_left_menu").mouseover(function () {
- //隐藏子菜单
- $(".index_left_menu_child").hide();
- $(".index_left_menu").removeClass("index_left_menuover");
- $(this).addClass("index_left_menuover");
- var child = $("#mc_" + $(this).attr("id"));
- if (child.length > 0) {
- child.css("top", $(this).offset().top);
- child.show();
- }
- });
- $(".index_left_menu").mouseout(function () {
- //$(this).removeClass("index_left_menuover");
- //var child = $("#mc_" + $(this).attr("id"));
- //if (child.length > 0) child.hide();
- });
- $(".index_left_menu").click(function () {
- $(".index_left_menu").removeClass("index_left_menuclick");
- $(this).addClass("index_left_menuclick");
- });
- $("div .index_left_menu_child").mouseout(function () {
- //$(this).hide();
- //$(".index_left_menu").removeClass("index_left_menuover");
- });
- $(".index_left_menu").each(function (i, e) {
- var cdiv = $(this).find(".index_left_menu_child");
- $(this).attr("id", i);
- $(this).find("a").attr("cid", i);
- if (cdiv.length > 0) {
- cdiv.attr("id", "mc_" + i);
- cdiv.attr("cid", i);
- cdiv.css("top", $(this).offset().top);
- $("#center").append(cdiv);
- }
- });
- //加载首页
- if ($(".index_left_menu").length > 0) {
- $(".index_left_menu")[0].click();
- }
- }
- function onMenu(url,e) {
- $(".index_left_menu_child").hide();
- $(".index_left_menu").removeClass("index_left_menuover");
- $(".index_left_menu").removeClass("index_left_menuclick");
- if (e) {
- var cid = $(e).attr("cid");
- var div = $("#" + cid);
- div.addClass("index_left_menuclick");
- }
- if (url.length > 0) {
- $("#centerIframe").attr("src", url);
- }
- return false;
- }
- function changePassword() {
- $.System.addTab('修改密码', '@Url.Content("~/Account/ChangePassword")', 'ChangePassword', false);
- }
- </script>
- }
- <div id="index_left" class="index_left_bg" data-options="region:'west',title:'',split:false,tools:'#tab-tools'"
- style="width: 150px;background-image:url(@Url.Content("~/Content/images/homeLeftbg" + (((EMISOnline.Utility.FormValidate.CustomPrincipal)Context.User).IsStudent?"":"Mgr") + ".jpg"));">
- <!--Logo-->
- <div class="index_left_top">
- <img src = "@Url.Content("~/Content/images/homeLogo.png")" />
- </div>
- <!--菜单排版示例
- <div class="index_left_menu" style=" display:none;">
- <a href="#">选课</a>
- <div class="index_left_menu_child">
- <ul>
- <li><a href="javascript:void();" onclick="onMenu(this,'http://www.baidu.com');">菜单1</a></li>
- <li><a href="#">菜单2</a></li>
- <li><a href="#">菜单消息</a></li>
- </ul>
- </div>
- </div>-->
- @Html.MenuTree(new AccordionTreeOptions()
- {
- OnClick = "onMenu(this,'{MnuProgram}');",
- DataOptions = "fit: true"
- })
- <!--用户头像、名称-->
- <div class="index_left_header">
- <img src = "@Url.Content("~/Content/images/homeHeader.png")" />
- <br>
- @(((EMISOnline.Utility.FormValidate.CustomPrincipal)Context.User).Name +
- (((EMISOnline.Utility.FormValidate.CustomPrincipal)Context.User).IsStudent ? "(同学)" : "(老师)"))
- <p>
- <a href="@Url.Content("~/account/logoff")" style="color:Blue;text-decoration:underline;" >退出</a>
- </p>
-
- </div>
- </div>
- <div id="center" region="center" border="true" title="" class="index_center_bg">
- <iframe id="centerIframe" frameborder="0" scrolling="no" style="border:0;width:100%;height:99.6%;" src="">
- </iframe>
- </div>
- <div id="sysWindow">
- </div>
|