示例#1
0
 /// <summary>
 /// There are no comments for vw_aspnet_UsersInRoles in the schema.
 /// </summary>
 public void AddTovw_aspnet_UsersInRoles(vw_aspnet_UsersInRoles vw_aspnet_UsersInRoles)
 {
     base.AddObject("vw_aspnet_UsersInRoles", vw_aspnet_UsersInRoles);
 }
        public Guid GetRoleIdBasedOnUserId(Guid id)
        {
            vw_aspnet_UsersInRoles result = ent.vw_aspnet_UsersInRoles.Where(x => x.UserId == id).FirstOrDefault();

            return(result.RoleId);
        }
示例#3
0
 /// <summary>
 /// Create a new vw_aspnet_UsersInRoles object.
 /// </summary>
 /// <param name="userId">Initial value of UserId.</param>
 /// <param name="roleId">Initial value of RoleId.</param>
 public static vw_aspnet_UsersInRoles Createvw_aspnet_UsersInRoles(global::System.Guid userId, global::System.Guid roleId)
 {
     vw_aspnet_UsersInRoles vw_aspnet_UsersInRoles = new vw_aspnet_UsersInRoles();
     vw_aspnet_UsersInRoles.UserId = userId;
     vw_aspnet_UsersInRoles.RoleId = roleId;
     return vw_aspnet_UsersInRoles;
 }