using CoreModels.ModelsSecurity;
using ToolsModule.Attributes;
using ToolsModule.Enums;
using ToolsModule.ViewModels;
using System;
namespace SecurityContract.ViewModels
{
///
/// Список пользователей
///
public class UserRoleListViewModel : ListViewModel { }
///
/// Элемент пользователей
///
[ViewModelControlElementClass()]
public class UserRoleViewModel : ElementViewModel, IUserRoleModel
{
[ViewModelControlElementProperty("Пользователь", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "SecurityWindowsDesktop.EntityControls.ControlUserList, SecurityWindowsDesktop")]
public Guid UserId { get; set; }
[ViewModelControlListProperty("Пользователь")]
[MapConfiguration("User.ToString", IsDifficle = true, AllowCopyWithoutRigth = false)]
public string UserName { get; set; }
[ViewModelControlElementProperty("Роль", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "SecurityWindowsDesktop.EntityControls.ControlRoleList, SecurityWindowsDesktop")]
public Guid RoleId { get; set; }
[ViewModelControlListProperty("Роль")]
[MapConfiguration("Role.ToString", IsDifficle = true, AllowCopyWithoutRigth = false)]
public string RoleName { get; set; }
}
}