//--------------------------------------------------------------------
//     此代码由T4模板自动生成  byzhouhang 20210918
//	   生成时间 2021-11-03 09:38:51 
//     对此文件的更改可能会导致不正确的行为，并且如果重新生成代码，这些更改将会丢失。
//--------------------------------------------------------------------
using IRaCIS.Core.Domain.Share;
namespace IRaCIS.Core.Application.Contracts
{
    /// <summary> UserTypeRoleView  列表视图模型 </summary>
    public class UserTypeRoleView : UserTypeMenuAddOrEdit
    {
        public UserTypeEnum UserTypeEnum { get; set; }
        public List<UserTypeGroupInfo> UserTypeGroupList { get; set; } = new List<UserTypeGroupInfo>();

        public new  List<Guid> UserTypeGroupIdList => UserTypeGroupList.Select(t=>t.DictionaryId).ToList();

    }

    public class UserTypeGroupInfo
    {
        public Guid UserTypeId { get; set; }

        public Guid DictionaryId { get; set; }

        public string GroupName { get; set; }=string.Empty;

        public string GroupNameCN { get; set; } = string.Empty;
    }

    ///<summary>UserTypeRoleQuery  列表查询参数模型</summary>
    public class UserTypeQuery
    {
        public Guid? GroupId { get; set; }

        public string? SearchFilter { get; set; } = string.Empty;

    }

    public class UserTypeMenuAddOrEdit: UserTypeRoleAddOrEdit
    {
        public UserTypeEnum UserTypeEnum { get; set; }

        public List<Guid> MenuIds { get; set; } = new List<Guid>();

    }

    public class UserTypeRoleAddOrEdit
    {

        public Guid? Id { get; set; }
        public string UserTypeName { get; set; } = string.Empty;
        public string UserTypeShortName { get; set; } = string.Empty;
        public string Description { get; set; } = string.Empty;
        public string PermissionStr { get; set; } = string.Empty;
        public int Order { get; set; }



        public List<Guid> UserTypeGroupIdList { get; set; } = new List<Guid>();





    }

    public class TrialSelectUser
    {
        public Guid UserId { get; set; }

        public string UserName { get; set; }

        public string RealName { get; set; }

        public UserTypeEnum UserTypeEnum { get; set; }
    }

    public class TrialUserType
    {
        public Guid Id { get; set; }
        public string UserType { get; set; } = string.Empty;
        public UserTypeEnum UserTypeEnum { get; set; }
        public string UserTypeShortName { get; set; } = string.Empty;
        public string PermissionStr { get; set; } = String.Empty;



        //public UserTypeGroup Type { get; set; }

        //public bool IsInternal { get; set; }



    }


    public class UserTypeSimpleDTO
    {
        public Guid Id { get; set; }
        public string UserTypeName { get; set; } = string.Empty;
        public UserTypeEnum UserTypeEnum { get; set; }
        public string UserTypeShortName { get; set; } = string.Empty;
        public string PermissionStr { get; set; } = String.Empty;
    }

}


