class ApplicationTeamController {

    @PostMapping(params = "invite-to-existing-organisation")
    public String inviteToExistingOrganisation(@Valid @ModelAttribute("form") ApplicationTeamForm form,
                                               BindingResult bindingResult,
                                               ValidationHandler validationHandler,
                                               @PathVariable long applicationId,
                                               @PathVariable long questionId,
                                               @RequestParam("invite-to-existing-organisation") final long organisationId,
                                               Model model,
                                               UserResource user) {
        return inviteToOrganisation(form, validationHandler, applicationId, questionId, organisationId, model, user,
                invite -> inviteRestService.createInvitesByOrganisationForApplication(applicationId, organisationId, singletonList(invite))
        );
    }

}