-
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.
Role kontrolü tamamlandı ajax loader ve datepicker kaldı
- Loading branch information
batuhan çiftçi
committed
May 21, 2022
1 parent
e72070f
commit 2fa253c
Showing
8 changed files
with
99 additions
and
26 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Web; | ||
using System.Web.Security; | ||
using UserManagement.Models; | ||
|
||
namespace UserManagement.Helper.Security | ||
{ | ||
public class UserRoleProvider : RoleProvider | ||
{ | ||
public override string ApplicationName { get => throw new NotImplementedException(); set => throw new NotImplementedException(); } | ||
|
||
public override void AddUsersToRoles(string[] usernames, string[] roleNames) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override void CreateRole(string roleName) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override bool DeleteRole(string roleName, bool throwOnPopulatedRole) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override string[] FindUsersInRole(string roleName, string usernameToMatch) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override string[] GetAllRoles() | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override string[] GetRolesForUser(string username) | ||
{ | ||
UserManagementDbContext db = new UserManagementDbContext(); | ||
Enums.Roles userRole = db.Users.FirstOrDefault(f => f.Email == username).Role; | ||
return new string[] { userRole.ToString()}; | ||
} | ||
|
||
public override string[] GetUsersInRole(string roleName) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override bool IsUserInRole(string username, string roleName) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override void RemoveUsersFromRoles(string[] usernames, string[] roleNames) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
public override bool RoleExists(string roleName) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
} | ||
} |
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
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