forked from dnnsoftware/Dnn.Platform
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Closes dnnsoftware#3906 Apparently some files where deleted as part of dnnsoftware#3843 This PR brings those files back and also fixes stylecop warnings. Some class names had to be changed both for clarity and to respect stylecop rule that the file name should match the class name. Because of that change, the dnn manifest was also changed so it all works with the new names.
- Loading branch information
Showing
18 changed files
with
367 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
Dnn.AdminExperience/Dnn.PersonaBar.Extensions/MenuControllers/AdminLogsMenuController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information | ||
|
||
namespace Dnn.PersonaBar.AdminLogs.MenuControllers | ||
{ | ||
using System.Collections.Generic; | ||
|
||
using Dnn.PersonaBar.Library.Controllers; | ||
using Dnn.PersonaBar.Library.Model; | ||
|
||
/// <summary> | ||
/// Controls the admin logs menu. | ||
/// </summary> | ||
public class AdminLogsMenuController : IMenuItemController | ||
{ | ||
/// <inheritdoc/> | ||
public void UpdateParameters(MenuItem menuItem) | ||
{ | ||
} | ||
|
||
/// <inheritdoc/> | ||
public bool Visible(MenuItem menuItem) | ||
{ | ||
return true; | ||
} | ||
|
||
/// <inheritdoc/> | ||
public IDictionary<string, object> GetSettings(MenuItem menuItem) | ||
{ | ||
var settings = new Dictionary<string, object>(); | ||
return settings; | ||
} | ||
} | ||
} |
26 changes: 13 additions & 13 deletions
26
...ons/MenuControllers/HostMenuController.cs → ...ontrollers/ConfigConsoleMenuController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
Dnn.AdminExperience/Dnn.PersonaBar.Extensions/MenuControllers/CssEditorMenuController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information | ||
|
||
namespace Dnn.PersonaBar.CssEditor.MenuControllers | ||
{ | ||
using System.Collections.Generic; | ||
|
||
using Dnn.PersonaBar.Library.Controllers; | ||
using Dnn.PersonaBar.Library.Model; | ||
using DotNetNuke.Entities.Portals; | ||
using DotNetNuke.Entities.Users; | ||
|
||
/// <summary> | ||
/// Controls the css editor menu. | ||
/// </summary> | ||
public class CssEditorMenuController : IMenuItemController | ||
{ | ||
/// <inheritdoc/> | ||
public void UpdateParameters(MenuItem menuItem) | ||
{ | ||
} | ||
|
||
/// <inheritdoc/> | ||
public bool Visible(MenuItem menuItem) | ||
{ | ||
var user = UserController.Instance.GetCurrentUserInfo(); | ||
return user.IsSuperUser || user.IsInRole(PortalSettings.Current?.AdministratorRoleName); | ||
} | ||
|
||
/// <inheritdoc/> | ||
public IDictionary<string, object> GetSettings(MenuItem menuItem) | ||
{ | ||
return null; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
Dnn.AdminExperience/Dnn.PersonaBar.Extensions/MenuControllers/LicensingMenuController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information | ||
|
||
namespace Dnn.PersonaBar.Licensing.MenuControllers | ||
{ | ||
using System.Collections.Generic; | ||
|
||
using Dnn.PersonaBar.Library.Controllers; | ||
using Dnn.PersonaBar.Library.Model; | ||
using DotNetNuke.Entities.Users; | ||
|
||
/// <summary> | ||
/// Controls the licensing menu. | ||
/// </summary> | ||
public class LicensingMenuController : IMenuItemController | ||
{ | ||
/// <inheritdoc/> | ||
public void UpdateParameters(MenuItem menuItem) | ||
{ | ||
} | ||
|
||
/// <inheritdoc/> | ||
public bool Visible(MenuItem menuItem) | ||
{ | ||
var user = UserController.Instance.GetCurrentUserInfo(); | ||
return user.IsSuperUser; | ||
} | ||
|
||
/// <inheritdoc/> | ||
public IDictionary<string, object> GetSettings(MenuItem menuItem) | ||
{ | ||
return null; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.