Exemplo n.º 1
0
 public CompaniesController(ICompanyReadService companyReadService, ICompanyCommandService companyCommandService,
                            IReviewReadService reviewReadService, IConfiguration config)
 {
     this.companyReadService    = companyReadService;
     this.companyCommandService = companyCommandService;
     this.reviewReadService     = reviewReadService;
     this.config = config;
 }
Exemplo n.º 2
0
 public AccountController(
     ICompanyCommandService companyCommand,
     ICompanyQueryService companyQuery,
     UserManager <Core.Model.User> userManager,
     SignInManager <Core.Model.User> signInManager,
     IConfiguration configuration,
     ILogger <AccountController> logger)
 {
     _companyCommand    = companyCommand;
     _companyQuery      = companyQuery;
     this.userManager   = userManager;
     this.signInManager = signInManager;
     this.configuration = configuration;
     this.logger        = logger;
 }
Exemplo n.º 3
0
 public CompanyCommandTest(Fixture fixture) : base(fixture)
 {
     _commandService = Services.GetService <ICompanyCommandService>();
     _context        = Services.GetService <IBaseCommandContext>();
 }
        public async Task <string> Activate([Service] ICompanyCommandService service, string id)
        {
            await service.Activate(id);

            return(Ok());
        }
        public async Task <string> Update([Service] ICompanyCommandService service, UpdateCompanyVm model)
        {
            await service.Update(model);

            return(Ok());
        }
 public async Task <string> Add([Service] ICompanyCommandService service, CreateCompanyVm model)
 {
     return(Ok(await service.Create(model)));
 }
Exemplo n.º 7
0
 public CompanyController(ICompanyCommandService command, ICompanyQueryService query)
 {
     _command = command;
     _query   = query;
 }