forked from Baud-UCS/DEF
-
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.
Positions, Roles and Users now display their links in Details. Relate…
…s to Baud-UCS#26 and Baud-UCS#27.
- Loading branch information
Showing
18 changed files
with
203 additions
and
3 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
12 changes: 12 additions & 0 deletions
12
...eploymentFramework/BusinessLogic/Domain/Security/Contracts/IRolePositionLinkRepository.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,12 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace Baud.Deployment.BusinessLogic.Domain.Security.Contracts | ||
{ | ||
public interface IRolePositionLinkRepository | ||
{ | ||
} | ||
} |
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
12 changes: 12 additions & 0 deletions
12
...eploymentFramework/BusinessLogic/Domain/Security/Contracts/IUserPositionLinkRepository.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,12 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace Baud.Deployment.BusinessLogic.Domain.Security.Contracts | ||
{ | ||
public interface IUserPositionLinkRepository | ||
{ | ||
} | ||
} |
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
17 changes: 17 additions & 0 deletions
17
src/Server/DeploymentFramework/Database/Security/RolePositionLinkRepository.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,17 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using Baud.Deployment.BusinessLogic.Domain.Security.Contracts; | ||
|
||
namespace Baud.Deployment.Database.Security | ||
{ | ||
public class RolePositionLinkRepository : RepositoryBase<SecurityDbContext>, IRolePositionLinkRepository | ||
{ | ||
public RolePositionLinkRepository(SecurityDbContext context) | ||
: base(context) | ||
{ | ||
} | ||
} | ||
} |
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
17 changes: 17 additions & 0 deletions
17
src/Server/DeploymentFramework/Database/Security/UserPositionLinkRepository.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,17 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using Baud.Deployment.BusinessLogic.Domain.Security.Contracts; | ||
|
||
namespace Baud.Deployment.Database.Security | ||
{ | ||
public class UserPositionLinkRepository : RepositoryBase<SecurityDbContext>, IUserPositionLinkRepository | ||
{ | ||
public UserPositionLinkRepository(SecurityDbContext context) | ||
: base(context) | ||
{ | ||
} | ||
} | ||
} |
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
46 changes: 46 additions & 0 deletions
46
src/Server/DeploymentFramework/Web/Areas/Security/Views/Positions/Detail.cshtml
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,46 @@ | ||
@model Baud.Deployment.BusinessLogic.Domain.Security.Entities.Position | ||
@using Baud.Deployment.Resources | ||
|
||
@{ | ||
ViewBag.Title = StringResources.PositionDetail; | ||
} | ||
|
||
<h2>@ViewBag.Title</h2> | ||
|
||
@using (var f = Html.BeginReadOnlyForm()) | ||
{ | ||
using (var s = f.BeginSection()) | ||
{ | ||
@s.FieldFor(m => m.Name) | ||
@s.FieldFor(m => m.IsActive) | ||
|
||
<div class="row"> | ||
<div class="col-md-6"> | ||
<div class="well"> | ||
<h3>@StringResources.Users</h3> | ||
<div class="form-group"> | ||
@foreach (var user in Model.UserLinks) | ||
{ | ||
@s.FieldFor(m => user.User.Login).Label("") | ||
} | ||
</div> | ||
</div> | ||
</div> | ||
<div class="col-md-6"> | ||
<div class="well"> | ||
<h3>@StringResources.Roles</h3> | ||
<div class="form-group"> | ||
@foreach (var role in Model.RoleLinks) | ||
{ | ||
@s.FieldFor(m => role.Role.Name).Label("") | ||
} | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
|
||
} | ||
} | ||
|
||
@Html.GuardedActionLink(StringResources.BackToList, MVC.Security.Positions.Index(), new SimpleHtmlAttributes("class", "btn btn-default")) |
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
src/Server/DeploymentFramework/Web/Areas/Security/Views/Roles/Detail.cshtml
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 @@ | ||
@model Baud.Deployment.BusinessLogic.Domain.Security.Entities.Role | ||
@using Baud.Deployment.Resources | ||
|
||
@{ | ||
ViewBag.Title = StringResources.RoleDetail; | ||
} | ||
|
||
<h2>@ViewBag.Title</h2> | ||
|
||
@using (var f = Html.BeginReadOnlyForm()) | ||
{ | ||
using (var s = f.BeginSection()) | ||
{ | ||
@s.FieldFor(m => m.Name) | ||
@s.FieldFor(m => m.IsActive) | ||
|
||
<div class="row"> | ||
<div class="col-md-12"> | ||
<div class="well"> | ||
<h3>@StringResources.Positions</h3> | ||
<div class="form-group"> | ||
@foreach (var position in Model.PositionLinks) | ||
{ | ||
@s.FieldFor(m => position.Position.Name).Label("") | ||
} | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
|
||
} | ||
} | ||
|
||
@Html.GuardedActionLink(StringResources.BackToList, MVC.Security.Roles.Index(), new SimpleHtmlAttributes("class", "btn btn-default")) | ||
|
||
|
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