Follow these steps to validate the registration:
- We do our service implementations in Services/Core folder. Our service implementation is as follows:
using RestBuy.Application.ViewModels;using RestBuy.Application.Repos;using RestBuy.Application.Services.Queries;using System.ComponentModel.DataAnnotations;using System.Threading;using System.Threading.Tasks;using RestBuy.Application.Services;namespace Restbuy.Application.Services.Core{ public class RestBuyRegistrationService : IRegistrationService { readonly IUserRepo userRepo; readonly IUoW uow;...... }}
At the constructor, our Unit of Work is injected. Then we fulfil our interface contract. By using validation ...