Ejemplo n.º 1
0
        public ActionResult webfooter()
        {
            webfooterViewModel model     = new webfooterViewModel();
            WebSettingsModel   setting   = webbll.GetWebSiteModel();
            MemberInfoModel    logmember = Session[AppContent.SESSION_WEB_LOGIN] as MemberInfoModel;

            if (logmember == null)
            {
                model.Linkurl = setting.DomainName;
            }
            else
            {
                model.Linkurl = setting.DomainName + Url.Action("Index", "Register", new { area = "WebFrontArea", msd = logmember.MobileNum });
            }
            return(View(model));
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 网站基本信息管理
        /// </summary>
        /// <returns></returns>
        public ActionResult websitemsg()
        {
            WebSettingsModel model = new WebSettingsModel();

            model = websetbll.GetWebSiteModel();
            return(View(model));
        }
Ejemplo n.º 3
0
        public override void OnActionExecuted(ActionExecutedContext ctx)
        {
            //部分视图不做验证
            if (ctx.IsChildAction)
            {
                return;
            }
            //判断是否当前系统状态为false,系统自动跳转至登录页面
            WebSettingsBLL   bll       = new WebSettingsBLL();
            WebSettingsModel sitemodel = bll.GetWebSiteModel();

            if (sitemodel.IsOpen == 0)
            {
                ctx.Result = new RedirectResult("/Home/CommingSoon");
                return;
            }
            if (ctx.ActionDescriptor.ControllerDescriptor.ControllerName == "Login")
            {
                return;
            }
            if (ctx.ActionDescriptor.ControllerDescriptor.ControllerName == "Register")
            {
                return;
            }
            if (ctx.ActionDescriptor.ControllerDescriptor.ControllerName == "public")
            {
                return;
            }
            string logurl = "/login.html";

            if (AppContent.TempleteName == "NewTemplateArea")
            {
                logurl = "/user/login.html";
            }
            if (ctx.HttpContext.Session[AppContent.SESSION_WEB_LOGIN] == null)
            {
                var url = ctx.RequestContext.HttpContext.Request == null
                        ? ""
                        : ctx.RequestContext.HttpContext.Request.Url.ToString();
                ctx.Result = new RedirectResult(logurl);
                return;
            }
        }
Ejemplo n.º 4
0
 public LoginController()
 {
     web = webbll.GetWebSiteModel();
 }
Ejemplo n.º 5
0
 public WebHomeController()
 {
     web = webbll.GetWebSiteModel();
 }
Ejemplo n.º 6
0
 public RegisterController()
 {
     web = webbll.GetWebSiteModel();
 }