Example #1
0
        public static async Task <bool> RefreshAsync(bool isPrimary)
        {
            /*
             *   isPrimary=true is Schedule 1
             *   isPrimary=false is Schedule 2
             */

            //create key
            var app_key  = Guid.NewGuid().ToString();
            var objVault = new Vault();

            //if Primary Refresh, get secondary key
            //if Secondary Refresh, get primary key
            var existingKey = await objVault.GetVaultKey(app_key, isPrimary?false : true);

            //update existing key from Vault in WAF which we are not updating currently
            //update rule
            return(await WAF.UpdateAllRegisteredWAFRulesAsync(existingKey.ToString())
                ? await objVault.UpdateAppKey(app_key, isPrimary)
                : false);
        }
Example #2
0
 void tabbedView_TabChanged(object sender, WAF.Presentation.Web.TabbedViewEventArgs e)
 {
     WAFContext.Session.SetModuleSetting("Users", "CurrentTab", e.NewTabId, PersistenceScope.UserSession);
     Response.Redirect(e.NewTabId + ".aspx"); // redirecting to correct file
 }
Example #3
0
 void tabbedView_TabChanged(object sender, WAF.Presentation.Web.TabbedViewEventArgs e)
 {
     WAFContext.Session.SetModuleSetting("Webshop", "CurrentTab", e.NewTabId, PersistenceScope.UserSession);
     Response.Redirect(e.NewTabId + ".aspx", false); // redirecting to correct file
     Context.ApplicationInstance.CompleteRequest();
 }