diff --git a/Logic/Swarm/Participation.cs b/Logic/Swarm/Participation.cs index 8d5d11e3..bee9f273 100644 --- a/Logic/Swarm/Participation.cs +++ b/Logic/Swarm/Participation.cs @@ -181,6 +181,8 @@ namespace Swarmops.Logic.Swarm public void Terminate (EventSource eventSource, Person actingPerson, string description) { + // TODO: This needs a new overload for v5, which adds the Position and possibly removes the EventSource + if (base.Active) { diff --git a/Site5/Controls/v5/Base/DropDown.ascx.cs b/Site5/Controls/v5/Base/DropDown.ascx.cs index d8bd08af..fd020e53 100644 --- a/Site5/Controls/v5/Base/DropDown.ascx.cs +++ b/Site5/Controls/v5/Base/DropDown.ascx.cs @@ -1,5 +1,7 @@ using System; +using System.Web.UI; using System.Web.UI.WebControls; +using Newtonsoft.Json.Converters; namespace Swarmops.Frontend.Controls.v5.Base { @@ -24,6 +26,11 @@ namespace Swarmops.Frontend.Controls.v5.Base get { return this.ClientID + "_DropControl"; } } + public DropDownList ClientControl + { + get { return this.DropControl; } + } + protected void Page_Load (object sender, EventArgs e) { } diff --git a/Site5/Images/PageIcons/iconshock-database-star-40px.png b/Site5/Images/PageIcons/iconshock-database-star-40px.png new file mode 100644 index 00000000..b89b0f64 Binary files /dev/null and b/Site5/Images/PageIcons/iconshock-database-star-40px.png differ diff --git a/Site5/MainMenu-v5.xml b/Site5/MainMenu-v5.xml index 82d64fca..ca8561dc 100644 --- a/Site5/MainMenu-v5.xml +++ b/Site5/MainMenu-v5.xml @@ -42,7 +42,8 @@ People_SelfSignup 2 - SpecialSelfSignup + iconshock-database-star + SpecialSelfSignup diff --git a/Site5/Pages/v5/Public/GeoLookupHelpers.js.include b/Site5/Pages/v5/Public/GeoLookupHelpers.js.include new file mode 100644 index 00000000..2c532230 --- /dev/null +++ b/Site5/Pages/v5/Public/GeoLookupHelpers.js.include @@ -0,0 +1,187 @@ + \ No newline at end of file diff --git a/Site5/Pages/v5/Public/Signup.aspx b/Site5/Pages/v5/Public/Signup.aspx index b0da9800..418c3f87 100644 --- a/Site5/Pages/v5/Public/Signup.aspx +++ b/Site5/Pages/v5/Public/Signup.aspx @@ -11,6 +11,7 @@ + @@ -22,6 +23,8 @@ <%=Organization.Name %> - Signup + + @@ -47,6 +50,25 @@ font-size: 200%; text-align: center; } + + .swMain { + height: 420px !important; + } + + .stepContainer { + height: 380px !important; + } + + div.stepContainer > div.content { + overflow: initial !important; + } + + + + .entryLabelsAdmin { + width: 280px; + } + @@ -54,79 +76,274 @@
+ @@ -167,12 +384,19 @@
  • - Activity
    + Activity 1
    How much do you wish to engage?
  • + + Activity 2
    + What would you like to engage in? +
    +
  • +
  • + Complete
    All done. Let's login! @@ -184,11 +408,34 @@

    This is the organization's custom welcome text. It has not yet been written; it is set in Admin / Org Settings.

    -

    Initializing database

    - + +
    + ​
    + ​
    + ​
    + ​
    + ​
    + ​
    +
     
    XX–
    + ... 
    + ​
    + ​
    +
    +
    -

    Initializing database

    +

    Your Logon

    Creating the first user

    diff --git a/Site5/Pages/v5/Public/Signup.aspx.cs b/Site5/Pages/v5/Public/Signup.aspx.cs index 335079e7..afb2f2d2 100644 --- a/Site5/Pages/v5/Public/Signup.aspx.cs +++ b/Site5/Pages/v5/Public/Signup.aspx.cs @@ -4,7 +4,10 @@ using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; +using Resources; +using Swarmops.Logic.Security; using Swarmops.Logic.Structure; +using Swarmops.Logic.Swarm; namespace Swarmops.Frontend.Pages.Public { @@ -24,8 +27,81 @@ namespace Swarmops.Frontend.Pages.Public { throw new ArgumentException("Organization not specified"); // TODO: make a friendly landing page instead } + + + // Override style widths - (this will cause problems with a future responsive design; come back here to fix that) + + this.DropCountries.Style[HtmlTextWriterStyle.Width] = "162px"; + + /* + this.BoxTitle.Text = PageTitle = String.Format(Resources.Pages.Swarm.AddPerson_Title, + Participant.Localized(CurrentOrganization.RegularLabel)); + InfoBoxLiteral = String.Format(Resources.Pages.Swarm.AddPerson_Info, Global.Timespan_OneYear, + Participant.Localized(CurrentOrganization.RegularLabel, TitleVariant.Ship), + DateTime.Today.AddYears(1).ToLongDateString());*/ + + if (!Page.IsPostBack) + { + Localize(); + Populate(); + + this.TextName.Focus(); + } + } + private void Populate() + { + Countries allCountries = Countries.All; + this.DropCountries.Items.Clear(); + + foreach (Country country in allCountries) + { + string countryLocalName = country.Localized; + string countryDisplay = country.Code + " " + countryLocalName; + this.DropCountries.Items.Add (new ListItem (countryDisplay, country.Code)); + } + + if (this.Organization.DefaultCountry != null) + { + this.DropCountries.SelectedValue = this.Organization.DefaultCountry.Code; + } + + this.DropGenders.Items.Clear(); + this.DropGenders.Items.Add (new ListItem (Global.Global_UnknownUndisclosed, "Unknown")); + this.DropGenders.Items.Add (new ListItem (Global.Global_Female, "Female")); + this.DropGenders.Items.Add (new ListItem (Global.Global_Male, "Male")); + } + + private void Localize() + { + this.LiteralErrorCity.Text = Resources.Pages.Swarm.AddPerson_ErrorCity; + this.LiteralErrorMail.Text = Resources.Pages.Swarm.AddPerson_ErrorMail; + this.LiteralErrorName.Text = Resources.Pages.Swarm.AddPerson_ErrorName; + this.LiteralErrorStreet.Text = Resources.Pages.Swarm.AddPerson_ErrorStreet; + this.LiteralErrorDate.Text = Resources.Pages.Swarm.AddPerson_ErrorDate; + + this.LabelName.Text = Resources.Global.Global_Name; + this.LabelCountry.Text = Resources.Global.Global_Country; + this.LabelMail.Text = Resources.Global.Global_Mail; + this.LabelPhone.Text = Resources.Global.Global_Phone; + this.LabelStreet1.Text = Resources.Pages.Swarm.AddPerson_Street1PO; + this.LabelStreet2.Text = Resources.Pages.Swarm.AddPerson_Street2; + this.LabelPostalCode.Text = Resources.Global.Global_PostalCode; + this.LabelCity.Text = Resources.Global.Global_City; + this.LabelGeographyDetected.Text = Resources.Pages.Swarm.AddPerson_GeographyDetected; + this.LabelDateOfBirth.Text = Resources.Global.Global_DateOfBirth; + this.LabelLegalGender.Text = Resources.Pages.Swarm.AddPerson_LegalGender; + + this.TextDateOfBirth.Attributes["placeholder"] = Global.Global_DateFormatShortReadable; + this.TextName.Attributes["placeholder"] = "Joe Smith"; + this.TextMail.Attributes["placeholder"] = "joe@example.com"; + this.TextPhone.Attributes["placeholder"] = "+1 263 151 1341"; + this.TextStreet1.Attributes["placeholder"] = "78 West Avenue"; + this.TextPostal.Attributes["placeholder"] = "12345"; + } + + protected Organization Organization; } } \ No newline at end of file diff --git a/Site5/Pages/v5/Swarm/AddPerson.aspx b/Site5/Pages/v5/Swarm/AddPerson.aspx index b848f2f2..4f82aeca 100644 --- a/Site5/Pages/v5/Swarm/AddPerson.aspx +++ b/Site5/Pages/v5/Swarm/AddPerson.aspx @@ -3,17 +3,17 @@ +