public static UserGroup ToUserGroup(this ShortGroupDto dto)
        {
            if (dto == null)
            {
                return(null);
            }

            var entity = new UserGroup();

            entity.GroupId = dto.Id;

            return(entity);
        }
        public static ShortGroupDto ToShortGroupDto(this Group entity)
        {
            if (entity == null)
            {
                return(null);
            }

            ShortGroupDto dto = new ShortGroupDto();

            dto.CopyPropertiesFrom(entity);

            return(dto);
        }