Added redirect to Edit Org after Create Org
This commit is contained in:
@@ -147,7 +147,7 @@
|
||||
<comment>This can be "members", etc.</comment>
|
||||
</data>
|
||||
<data name="CreateOrganization_Success" xml:space="preserve">
|
||||
<value>The new organization has been created. You have been given an initial two-year {0} in the organization, so you can work with it and set it up properly. To switch to working with your new organization, use the control panel top right.</value>
|
||||
<value>The new organization has been created. You have been given an initial two-year {0} in the organization, so you can work with it and set it up properly. You have also been <strong>logged in</strong> to your new organization instead of the one you were logged in to before.<br/><br/>This is the Edit Organization panel, where you can set more parameters for your new organization.</value>
|
||||
<comment>The {0} is membership, employment, citizenship, residence, etc.</comment>
|
||||
</data>
|
||||
<data name="EditOrganization_Info" xml:space="preserve">
|
||||
|
||||
@@ -42,6 +42,6 @@ namespace Swarmops.Frontend.Controls.v5.UI
|
||||
}
|
||||
|
||||
public string Package { get; set; }
|
||||
public string Controls { get; set; }
|
||||
public new string Controls { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Web;
|
||||
using System.Web.UI.WebControls;
|
||||
using Swarmops.Logic.Financial;
|
||||
@@ -130,13 +131,11 @@ namespace Swarmops.Frontend.Pages.v5.Admin
|
||||
|
||||
string successMessage = String.Format(Resources.Pages_Admin.CreateOrganization_Success, Resources.Global.ResourceManager.GetString("Title_" + peopleLabel + "_Ship"));
|
||||
|
||||
// Create org here
|
||||
|
||||
Response.AppendCookie(new HttpCookie("DashboardMessage", HttpUtility.UrlEncode(successMessage)));
|
||||
|
||||
// Redirect to dashboard
|
||||
// Log in to new organization, then redirect to Edit
|
||||
|
||||
Response.Redirect("/", true);
|
||||
Response.Redirect("/Pages/v5/Security/SetCurrentOrganization.aspx?OrganizationId=" + newOrganization.Identity.ToString(CultureInfo.InvariantCulture) + "&ReturnUrl=/Pages/v5/Admin/EditOrganization.aspx", true);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ namespace Swarmops.Frontend.Pages.v5.Security
|
||||
throw new UnauthorizedAccessException("No"); // may cause problems on login screen?
|
||||
}
|
||||
|
||||
string returnUrlString = Request.QueryString["ReturnUrl"];
|
||||
string organizationIdString = Request.QueryString["OrganizationId"];
|
||||
int organizationId = Int32.Parse(organizationIdString);
|
||||
Organization suggestedOrganization = null;
|
||||
@@ -47,10 +48,19 @@ namespace Swarmops.Frontend.Pages.v5.Security
|
||||
logonFlags = currentIdentityParts[3];
|
||||
}
|
||||
|
||||
FormsAuthentication.RedirectFromLoginPage(
|
||||
CurrentUser.Identity.ToString(CultureInfo.InvariantCulture) + "," +
|
||||
suggestedOrganization.Identity.ToString(CultureInfo.InvariantCulture) + ",," +
|
||||
logonFlags, true);
|
||||
string userIdentityString = CurrentUser.Identity.ToString(CultureInfo.InvariantCulture) + "," +
|
||||
suggestedOrganization.Identity.ToString(CultureInfo.InvariantCulture) + ",," +
|
||||
logonFlags;
|
||||
|
||||
if (!string.IsNullOrEmpty(returnUrlString))
|
||||
{
|
||||
FormsAuthentication.SetAuthCookie(userIdentityString, true);
|
||||
Response.Redirect(returnUrlString);
|
||||
}
|
||||
else
|
||||
{
|
||||
FormsAuthentication.RedirectFromLoginPage(userIdentityString, true);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1031,6 +1031,14 @@ input.ButtonSwarmopsUpload:active {
|
||||
}
|
||||
|
||||
|
||||
/* JQUERY PLUGIN OVERRIDES */
|
||||
|
||||
|
||||
nav.alertify-buttons {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
|
||||
/* COLOR SCHEME
|
||||
|
||||
#A2BEFF #476EC7 #1C397E #C8D9FF #E4ECFF -- blue (hue 222)
|
||||
|
||||
Reference in New Issue
Block a user