public string AddTournamentPin( [FromRoute] string cpr, [FromBody] TournamentReq tournament, [FromServices] IMembershipRepo repo ) { var member = repo.GetMember(cpr); member.TournamentPin = new TournamentPin(tournament.Date); repo.UpdateMember(member); return("ok"); }
public string UpdateName( [FromRoute] string cpr, [FromBody] NameReq nameReq, [FromServices] IMembershipRepo repo ) { var member = repo.GetMember(cpr); member.Name = nameReq.Name; repo.UpdateMember(member); return("ok"); }
public string UpdatePhone( [FromRoute] string cpr, [FromBody] PhoneReq phoneReq, [FromServices] IMembershipRepo repo ) { var member = repo.GetMember(cpr); if (member is Employee e) { e.Phone = phoneReq.Phone; repo.UpdateMember(e); } return("ok"); }
public string UpdateCompany( [FromRoute] string cpr, [FromBody] CompanyReq companyReq, [FromServices] IMembershipRepo repo ) { var member = repo.GetMember(cpr); if (member is Employee e) { e.Company = companyReq.Company; repo.UpdateMember(e); } return("ok"); }
public string UpdateAddress( [FromRoute] string cpr, [FromBody] AddressReq addressReq, [FromServices] IMembershipRepo repo ) { var member = repo.GetMember(cpr); if (member is Employee e) { e.Address = addressReq.Address; repo.UpdateMember(e); } return("ok"); }
public string UpdateEmail( [FromRoute] string cpr, [FromBody] EmailReq emailReq, [FromServices] IMembershipRepo repo ) { var member = repo.GetMember(cpr); if (member is Employee e) { e.Email = emailReq.Email; repo.UpdateMember(e); } return("ok"); }
public IndexModel (IMeProvider meProvider , IEventRepo eventRepo , IMembershipRepo membershipRepo , IParticipationRepo participationRepo , IParticipationTextProvider participationTextProvider , IPostRepo postRepo , IMailService mailService ) { //this.dbContext = dbContext; this.meProvider = meProvider; this.eventRepo = eventRepo; this.membershipRepo = membershipRepo; this.participationRepo = participationRepo; this.participationTextProvider = participationTextProvider; this.postRepo = postRepo; this.mailService = mailService; }
public EditModel(IMembershipRepo repo) { this.repo = repo; }
// private UtisDb db = new UtisDb(); public MembershipsController(IMembershipRepo repo) { this.repo = repo; }
public MembershipService(IMembershipRepo membershipRepo) { _membershipRepo = membershipRepo; }
public DeleteModel(IMembershipRepo repo) { this.repo = repo; }
public SearchInteractor(IMembershipRepo repo, ISearchPresenter presenter) { _repo = repo; _presenter = presenter; }
public IndexModel(IMembershipRepo repo, IMeProvider meProvider) { this.repo = repo; this.meProvider = meProvider; }
public CreateMembershipInteractor(ICreateMembershipPresenter cmPresenter, IMembershipRepo mRepo) { _cmPresenter = cmPresenter; _mRepo = mRepo; }