コード例 #1
0
        public async Task <User> RegistrationAsync(User model)
        {
            var studentRole = await roleReadRepository.GetStudentRoleAsync();

            model.RoleId = studentRole.Id;

            return(await userWriteRepository.AddAsync(model));
        }
コード例 #2
0
        public async Task<Role> GetStudentRoleAsync()
        {
            var result = await roleReadRepository.GetStudentRoleAsync();

            return result;
        }