2021-12-15 16:21:52 +05:00
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
|
|
|
|
|
|
namespace AsbCloudDb.Model
|
|
|
|
{
|
2022-05-06 10:58:52 +05:00
|
|
|
#nullable disable
|
2021-12-15 16:21:52 +05:00
|
|
|
[Table("t_relation_user_role_permission"), Comment("Отношение ролей пользователей и разрешений доступа")]
|
|
|
|
public class RelationUserRolePermission
|
|
|
|
{
|
|
|
|
[Column("id_user_role")]
|
|
|
|
public int IdUserRole { get; set; }
|
|
|
|
|
|
|
|
[Column("id_permission")]
|
|
|
|
public int IdPermission { get; set; }
|
|
|
|
|
|
|
|
[ForeignKey(nameof(IdUserRole))]
|
|
|
|
[InverseProperty(nameof(Model.UserRole.RelationUserRolePermissions))]
|
|
|
|
public virtual UserRole UserRole { get; set; }
|
|
|
|
|
|
|
|
[ForeignKey(nameof(IdPermission))]
|
|
|
|
[InverseProperty(nameof(Model.Permission.RelationUserRolePermissions))]
|
|
|
|
public virtual Permission Permission { get; set; }
|
|
|
|
}
|
2022-05-06 10:58:52 +05:00
|
|
|
|
2021-12-15 16:21:52 +05:00
|
|
|
}
|