From 1d32543f4f73656c452af8c9243e9b46a698e8ba Mon Sep 17 00:00:00 2001 From: Waldi Date: Mon, 6 Mar 2017 14:45:35 +0100 Subject: [PATCH] =?UTF-8?q?BeWoMobileClient=20Globale=20Einstellung=20erg?= =?UTF-8?q?=C3=A4nzt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BeWoPlanerMobil/BeWoPlanerMobil.csproj | 1 + BeWoPlanerMobil/BeWoPlanerMobil.csproj.user | 3 +++ .../Controllers/AbstractBaseController.cs | 8 ++++++-- BeWoPlanerMobil/Controllers/MainController.cs | 2 +- BeWoPlanerMobil/Global.asax.cs | 19 ++++++++++++++++--- BeWoPlanerMobil/Views/Login/Index.cshtml | 13 +++++++++---- BeWoPlanerMobil/Views/Main/Main.cshtml | 3 ++- BeWoPlanerMobil/Web.config | 7 +++++-- 8 files changed, 43 insertions(+), 13 deletions(-) diff --git a/BeWoPlanerMobil/BeWoPlanerMobil.csproj b/BeWoPlanerMobil/BeWoPlanerMobil.csproj index f6910771f..63d61abc6 100644 --- a/BeWoPlanerMobil/BeWoPlanerMobil.csproj +++ b/BeWoPlanerMobil/BeWoPlanerMobil.csproj @@ -20,6 +20,7 @@ + true diff --git a/BeWoPlanerMobil/BeWoPlanerMobil.csproj.user b/BeWoPlanerMobil/BeWoPlanerMobil.csproj.user index aded21cea..859a54480 100644 --- a/BeWoPlanerMobil/BeWoPlanerMobil.csproj.user +++ b/BeWoPlanerMobil/BeWoPlanerMobil.csproj.user @@ -1,5 +1,8 @@  + + true + diff --git a/BeWoPlanerMobil/Controllers/AbstractBaseController.cs b/BeWoPlanerMobil/Controllers/AbstractBaseController.cs index 782583c8b..d51342b2f 100644 --- a/BeWoPlanerMobil/Controllers/AbstractBaseController.cs +++ b/BeWoPlanerMobil/Controllers/AbstractBaseController.cs @@ -1,5 +1,8 @@ -using System.Web.Mvc; +using System; +using System.Web; +using System.Web.Mvc; using System.Web.Security; +using System.Web.UI; using BeWo.Service.ServiceContracts; using BeWoPlanerMobil.Service; @@ -22,7 +25,8 @@ namespace BeWoPlanerMobil.Controllers { MobileSessionFacade.LogUserOut(); FormsAuthentication.SignOut(); - return RedirectToActionPermanent("Index", "Login", new {tenant = MobileSessionFacade.Tenant}); + + return RedirectToActionPermanent("Index", "Login", new {tenant = MobileSessionFacade.Tenant}); } } } diff --git a/BeWoPlanerMobil/Controllers/MainController.cs b/BeWoPlanerMobil/Controllers/MainController.cs index 90eec20c9..eeecd9e5c 100644 --- a/BeWoPlanerMobil/Controllers/MainController.cs +++ b/BeWoPlanerMobil/Controllers/MainController.cs @@ -142,7 +142,7 @@ namespace BeWoPlanerMobil.Controllers [HttpPost] public new ActionResult Logout() - { + { return base.Logout(); } diff --git a/BeWoPlanerMobil/Global.asax.cs b/BeWoPlanerMobil/Global.asax.cs index b0543b6e0..589dfea11 100644 --- a/BeWoPlanerMobil/Global.asax.cs +++ b/BeWoPlanerMobil/Global.asax.cs @@ -1,8 +1,11 @@ -using System.Web.Http; +using System; +using System.Web; +using System.Web.Http; using System.Web.Mvc; using System.Web.Optimization; using System.Web.Routing; + namespace BeWoPlanerMobil { // Note: For instructions on enabling IIS6 or IIS7 classic mode, @@ -18,6 +21,16 @@ namespace BeWoPlanerMobil FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); BundleConfig.RegisterBundles(BundleTable.Bundles); - } - } + + } + + protected void Application_BeginRequest(object sender, EventArgs e) + { + Context.Response.Cache.SetExpires(DateTime.UtcNow.AddDays(-1)); + Context.Response.Cache.SetAllowResponseInBrowserHistory(false); + Context.Response.Cache.SetRevalidation(HttpCacheRevalidation.AllCaches); + Context.Response.Cache.SetCacheability(HttpCacheability.NoCache); + Context.Response.Cache.SetNoStore(); + } + } } \ No newline at end of file diff --git a/BeWoPlanerMobil/Views/Login/Index.cshtml b/BeWoPlanerMobil/Views/Login/Index.cshtml index 32220207a..b1a9caf45 100644 --- a/BeWoPlanerMobil/Views/Login/Index.cshtml +++ b/BeWoPlanerMobil/Views/Login/Index.cshtml @@ -4,10 +4,12 @@ @{ ViewBag.Title = "Login"; - var usernameDef = String.Empty; - var pwDef = String.Empty; + var usernameDef = String.Empty; + var pwDef = String.Empty; + } + BeWoPlanerMobil
@@ -40,5 +42,8 @@
\ No newline at end of file + loadGoalsUrl = ''; + + + + diff --git a/BeWoPlanerMobil/Views/Main/Main.cshtml b/BeWoPlanerMobil/Views/Main/Main.cshtml index f818aa045..70e9d064e 100644 --- a/BeWoPlanerMobil/Views/Main/Main.cshtml +++ b/BeWoPlanerMobil/Views/Main/Main.cshtml @@ -3,6 +3,7 @@ @model MainModel @{ ViewBag.Title = "Main"; + }
@@ -851,7 +852,7 @@ CheckEndDateUrl = '@Url.Action("CheckEndDate")'; CheckDokuReiterUrl = '@Url.Action("CheckDokuReiter")'; SetSaveSignatureUrl = '@Url.Action("SetSaveSignature")'; - + $(".toggle-btn").click(function () { toggleOnclick(this); diff --git a/BeWoPlanerMobil/Web.config b/BeWoPlanerMobil/Web.config index ab730e70e..5d3057b1c 100644 --- a/BeWoPlanerMobil/Web.config +++ b/BeWoPlanerMobil/Web.config @@ -51,7 +51,8 @@ - + + @@ -150,9 +151,11 @@ + - + +