Skip to content
This repository has been archived by the owner on Feb 12, 2018. It is now read-only.

Commit

Permalink
Final 01.02.00 changes
Browse files Browse the repository at this point in the history
  • Loading branch information
peppertree committed Jun 25, 2014
1 parent 2b272d1 commit 8f68c68
Show file tree
Hide file tree
Showing 18 changed files with 188 additions and 84 deletions.
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -149,3 +149,9 @@ $RECYCLE.BIN/

# Mac crap
.DS_Store
*.zip
*.dll
*.pdb
obj/Release/Connect.Modules.AccountRegistration.xml
obj/Release/Connect_AccountRegistration.vbproj.FileListAbsolute.txt
*.cache
12 changes: 12 additions & 0 deletions App_LocalResources/Settings.ascx.resx
Original file line number Diff line number Diff line change
Expand Up @@ -198,4 +198,16 @@
<data name="lblInterface.Text" xml:space="preserve">
<value>External Interface</value>
</data>
<data name="lblAddToRoleStatus.Help" xml:space="preserve">
<value>Select the status of the role membership after submitting the form</value>
</data>
<data name="lblAddToRoleStatus.Text" xml:space="preserve">
<value>Role status after submit:</value>
</data>
<data name="StatusApproved.Text" xml:space="preserve">
<value>Approved</value>
</data>
<data name="StatusPending.Text" xml:space="preserve">
<value>Pending</value>
</data>
</root>
4 changes: 2 additions & 2 deletions AssemblyInfo.vb
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")>

<Assembly: AssemblyVersion("01.01.00")>
<Assembly: AssemblyFileVersion("01.01.00")>
<Assembly: AssemblyVersion("01.02.00")>
<Assembly: AssemblyFileVersion("01.02.00")>
2 changes: 1 addition & 1 deletion Connect_AccountRegistration.dnn
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<dotnetnuke type="Package" version="5.0">
<packages>
<package name="Connect AccountRegistrationForm" type="Module" version="01.01.00">
<package name="Connect AccountRegistrationForm" type="Module" version="01.02.00">
<friendlyName>Connect: AccountRegistration</friendlyName>
<description>A community module that handles account registrations and login in DNN</description>
<iconFile>Images/icon_extensions.gif</iconFile>
Expand Down
16 changes: 16 additions & 0 deletions ReleaseNotes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,22 @@
<div class="License">
<h3>Release Notes</h3>

<p class="Owner">
<b>Version 01.02.00</b><br /><br />
</p>
<p>Extended Token Support</p>
<h4>Changes</h4>
<ul>
<li>New conditional token: [IFSOCIALMEMBERSHIPPENDING:XXX]...[/IFSOCIALMEMBERSHIPPENDING:XXX] renders everything in between the tokens if the current user is in the specified XXX social group and the group membership is pending.</li>
<li>New conditional token: [IFSOCIALMEMBERSHIPAPPROVED:XXX]...[/IFSOCIALMEMBERSHIPAPPROVED:XXX] renders everything in between the tokens if the current user is in the specified XXX social group and the group membership is pending.</li>
<li>New conditional token: [IFSOCIALMEMBERSHIPNONE:XXX]...[/IFSOCIALMEMBERSHIPNONE:XXX] renders everything in between the tokens if the current user is not yet in the specified XXX social group and also has not applied yet for becoming a member.</li>
<li>New conditional token: [IFISINROLE:XXX]...[/IFISINROLE:XXX] renders everything in between the tokens if the current user is in the specified XXX role.</li>
<li>New conditional token: [IFNOTISINROLE:XXX]...[/IFNOTISINROLE:XXX] renders everything in between the tokens if the current user is not in the specified XXX role.</li>
<li>New control token: [CTL:ROLEMEMBERSHP:XXX] renders a checkbox that - once checked - will add the user account to the specified XXX role.</li>
<li>New control token: [CTL:ROLEMEMBERSHP:XXX:Pending] will do the same but will rather make the role membership pending.</li>
<li>New Setting: When adding users to a role through the modulesettings you can now set the status of that role membership</li>
</ul>

<p class="Owner">
<b>Version 01.00.01</b><br /><br />
</p>
Expand Down
Binary file modified Resources.zip
Binary file not shown.
8 changes: 8 additions & 0 deletions Settings.ascx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,14 @@
<asp:DropDownList ID="drpAddToRole" runat="server" DataTextField="RoleName" DataValueField="RoleId"></asp:DropDownList>
</div>

<div class="dnnFormItem">
<dnn:Label ID="lblAddToRoleStatus" runat="server" Text="Role status once submitted:"></dnn:Label>
<asp:DropDownList ID="drpRoleStatus" runat="server">
<asp:ListItem Text="Pending" Value="Pending"></asp:ListItem>
<asp:ListItem Text="Approved" Value="Approved"></asp:ListItem>
</asp:DropDownList>
</div>

<div class="dnnFormItem">
<dnn:Label ID="lblNotifyRole" runat="server" Text="Send confirmation e-mail to Role:"></dnn:Label>
<asp:DropDownList ID="drpNotifyRole" runat="server" DataTextField="RoleName" DataValueField="RoleId"></asp:DropDownList>
Expand Down
18 changes: 18 additions & 0 deletions Settings.ascx.designer.vb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions Settings.ascx.vb
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ Namespace Connect.Modules.UserManagement.AccountRegistration
If (Settings.Contains("AddToRoleOnSubmit")) Then drpAddToRole.SelectedValue = Settings("AddToRoleOnSubmit").ToString()
If (Settings.Contains("NotifyRole")) Then drpNotifyRole.Items.FindByText(Settings("NotifyRole").ToString()).Selected = True
If (Settings.Contains("NotifyUser")) Then chkNotifyUser.Checked = CType(Settings("NotifyUser"), Boolean)
If (Settings.Contains("AddToRoleStatus")) Then drpRoleStatus.SelectedValue = CType(Settings("AddToRoleStatus"), String)

End If
Catch exc As Exception 'Module failed to load
Expand All @@ -45,6 +46,7 @@ Namespace Connect.Modules.UserManagement.AccountRegistration
'we need the rolename for sending mails to users, therefor store here the rolename rather than the id!
objModules.UpdateTabModuleSetting(TabModuleId, "NotifyRole", drpNotifyRole.SelectedItem.Text)
objModules.UpdateTabModuleSetting(TabModuleId, "NotifyUser", chkNotifyUser.Checked.ToString)
objModules.UpdateTabModuleSetting(TabModuleId, "AddToRoleStatus", drpRoleStatus.SelectedValue)

Catch exc As Exception 'Module failed to load
ProcessModuleLoadException(Me, exc)
Expand Down
9 changes: 6 additions & 3 deletions View.ascx.vb
Original file line number Diff line number Diff line change
Expand Up @@ -570,8 +570,7 @@ Namespace Connect.Modules.UserManagement.AccountRegistration
strAdminBody = strAdminBody.Replace("[REGISTRATIONMODE]", Localization.GetString("RegistrationMode_Public.Text", LocalResourceFile))
End If

strAdminBody = strAdminBody.Replace("[USERURL]", NavigateURL(UsermanagementTab, "", "uid=" & oUser.UserID.ToString))

strAdminBody = strAdminBody.Replace("[USERURL]", NavigateURL(UsermanagementTab, "", "uid=" & oUser.UserID.ToString, "RoleId=" & PortalSettings.RegisteredRoleId.ToString))


Dim ctrlRoles As New RoleController
Expand Down Expand Up @@ -639,7 +638,11 @@ Namespace Connect.Modules.UserManagement.AccountRegistration
If AddToRoleOnSubmit <> Null.NullInteger Then
Try
Dim rc As New RoleController
rc.AddUserRole(PortalId, oUser.UserID, AddToRoleOnSubmit, Null.NullDate)
If AddToRoleStatus.ToLower = "pending" Then
rc.AddUserRole(PortalId, oUser.UserID, AddToRoleOnSubmit, RoleStatus.Pending, False, Date.Now, Null.NullDate)
Else
rc.AddUserRole(PortalId, oUser.UserID, AddToRoleOnSubmit, RoleStatus.Approved, False, Date.Now, Null.NullDate)
End If
Catch
End Try
End If
Expand Down
Binary file modified obj/Release/Connect.Modules.AccountRegistration.dll
Binary file not shown.
Binary file modified obj/Release/Connect.Modules.AccountRegistration.pdb
Binary file not shown.
Loading

0 comments on commit 8f68c68

Please sign in to comment.