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

Commit

Permalink
Implemented External Interface
Browse files Browse the repository at this point in the history
  • Loading branch information
peppertree committed Feb 18, 2014
1 parent 85dacd5 commit d184575
Show file tree
Hide file tree
Showing 9 changed files with 204 additions and 6 deletions.
151 changes: 151 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.

# User-specific files
*.suo
*.user
*.sln.docstates

# Build results

[Dd]ebug/
[Rr]elease/
x64/
build/
[Bb]in/
[Oo]bj/

# Enable "build/" folder in the NuGet Packages folder since NuGet packages use it for MSBuild targets
!packages/*/build/

# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*

*_i.c
*_p.c
*.ilk
*.meta
*.obj
*.pch
*.pdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.log
*.scc

# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opensdf
*.sdf
*.cachefile

# Visual Studio profiler
*.psess
*.vsp
*.vspx

# Guidance Automation Toolkit
*.gpState

# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper

# TeamCity is a build add-in
_TeamCity*

# DotCover is a Code Coverage Tool
*.dotCover

# NCrunch
*.ncrunch*
.*crunch*.local.xml

# Installshield output folder
[Ee]xpress/

# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html

# Click-Once directory
publish/

# Publish Web Output
*.Publish.xml
*.pubxml

# NuGet Packages Directory
## TODO: If you have NuGet Package Restore enabled, uncomment the next line
#packages/

# Windows Azure Build Output
csx
*.build.csdef

# Windows Store app package directory
AppPackages/

# Others
sql/
*.Cache
ClientBin/
[Ss]tyle[Cc]op.*
~$*
*~
*.dbmdl
*.[Pp]ublish.xml
*.pfx
*.publishsettings

# RIA/Silverlight projects
Generated_Code/

# Backup & report files from converting an old project file to a newer
# Visual Studio version. Backup files are not needed, because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm

# SQL Server files
App_Data/*.mdf
App_Data/*.ldf

# =========================
# Windows detritus
# =========================

# Windows image file caches
Thumbs.db
ehthumbs.db

# Folder config file
Desktop.ini

# Recycle Bin used on file shares
$RECYCLE.BIN/

# Mac crap
.DS_Store
6 changes: 6 additions & 0 deletions App_LocalResources/Settings.ascx.resx
Original file line number Diff line number Diff line change
Expand Up @@ -192,4 +192,10 @@
<data name="Username_Lastname" xml:space="preserve">
<value>Create from Lastname</value>
</data>
<data name="lblInterface.Help" xml:space="preserve">
<value>Enter the external interface qualifier. See &lt;a href="https://github.com/DNN-Connect/UserAccountUpdate/wiki/External-Interfaces" target="_blank"&gt;this article&lt;/a&gt; on how to do that and how it can help you.</value>
</data>
<data name="lblInterface.Text" xml:space="preserve">
<value>External Interface</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.00.01")>
<Assembly: AssemblyFileVersion("01.00.01")>
<Assembly: AssemblyVersion("01.01.00")>
<Assembly: AssemblyFileVersion("01.01.00")>
4 changes: 2 additions & 2 deletions Connect_AccountUpdate.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 AccountUpdateForm" type="Module" version="01.00.01">
<package name="Connect AccountUpdateForm" type="Module" version="01.01.00">
<friendlyName>Connect: AccountUpdate</friendlyName>
<description>A community module that handles account updates in DNN</description>
<iconFile>Images/icon_extensions.gif</iconFile>
Expand All @@ -14,7 +14,7 @@
<releaseNotes src="ReleaseNotes.txt" />

<dependencies>
<dependency type="CoreVersion">07.01.00</dependency>
<dependency type="CoreVersion">07.02.01</dependency>
</dependencies>

<components>
Expand Down
5 changes: 5 additions & 0 deletions Settings.ascx
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,9 @@
<div class="dnnFormItem">
<dnn:Label ID="lblNotifyUser" runat="server" Text="Send confirmation e-mail to user:"></dnn:Label>
<asp:CheckBox ID="chkNotifyUser" runat="server" />
</div>

<div class="dnnFormItem">
<dnn:Label ID="lblInterface" runat="server" Text="External Interface:"></dnn:Label>
<asp:TextBox ID="txtInterface" runat="server"></asp:TextBox>
</div>
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.

3 changes: 2 additions & 1 deletion Settings.ascx.vb
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Namespace Connect.Modules.UserManagement.AccountUpdate
BindPages()
BindRoles()

If (Settings.Contains("ExternalInterface")) Then txtInterface.Text = Settings("ExternalInterface").ToString()
If (Settings.Contains("ShowUserName")) Then drpUsernameMode.SelectedValue = Settings("ShowUserName").ToString()
If (Settings.Contains("ShowDisplayName")) Then drpDisplaynameMode.SelectedValue = Settings("ShowDisplayName").ToString()
If (Settings.Contains("RedirectAfterSubmit")) Then drpRedirectAfterSubmit.SelectedValue = Settings("RedirectAfterSubmit").ToString()
Expand All @@ -35,7 +36,7 @@ Namespace Connect.Modules.UserManagement.AccountUpdate
Try
Dim objModules As New Entities.Modules.ModuleController


objModules.UpdateTabModuleSetting(TabModuleId, "ExternalInterface", txtInterface.Text)
objModules.UpdateTabModuleSetting(TabModuleId, "ShowUserName", drpUsernameMode.SelectedValue)
objModules.UpdateTabModuleSetting(TabModuleId, "ShowDisplayName", drpDisplaynameMode.SelectedValue)
objModules.UpdateTabModuleSetting(TabModuleId, "RedirectAfterSubmit", drpRedirectAfterSubmit.SelectedValue)
Expand Down
3 changes: 2 additions & 1 deletion Templates.ascx.vb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Imports Telerik.Web.UI
Imports DotNetNuke.Security.Roles
Imports DotNetNuke.Entities.Profile
Imports DotNetNuke.UI.Skins.Controls
Imports DotNetNuke.Framework.JavaScriptLibraries

Namespace Connect.Modules.UserManagement.AccountUpdate

Expand All @@ -15,7 +16,7 @@ Namespace Connect.Modules.UserManagement.AccountUpdate

Private Sub Page_Init(sender As Object, e As System.EventArgs) Handles Me.Init

DotNetNuke.Framework.jQuery.RequestDnnPluginsRegistration()
JavaScript.RequestRegistration(CommonJs.DnnPlugins)

End Sub

Expand Down
16 changes: 16 additions & 0 deletions View.ascx.vb
Original file line number Diff line number Diff line change
Expand Up @@ -440,6 +440,22 @@ Namespace Connect.Modules.UserManagement.AccountUpdate
lblSucess.Text = "<ul><li>" & Localization.GetString("AccountUpdateSuccess.Text", LocalResourceFile) & "</li></ul>"
pnlSuccess.Visible = True

If ExternalInterface <> Null.NullInteger Then

Dim objInterface As Object = Nothing

If ExternalInterface.Contains(",") Then
Dim strAssembly As String = ExternalInterface.Split(Char.Parse(","))(0).Trim
Dim strClass As String = ExternalInterface.Split(Char.Parse(","))(1).Trim
objInterface = System.Activator.CreateInstance(strAssembly, strClass).Unwrap
End If

If Not objInterface Is Nothing Then
CType(objInterface, Interfaces.iAccountUpdate).FinalizeAccountUpdate(Server, Response, Request, oUser)
End If

End If

If Not Request.QueryString("ReturnURL") Is Nothing Then
Response.Redirect(Server.UrlDecode(Request.QueryString("ReturnURL")), True)
End If
Expand Down

0 comments on commit d184575

Please sign in to comment.