public static Result submitProposal() {
Form<Proposal> submittedForm = proposalForm.bindFromRequest();
if(submittedForm.hasErrors()) {
return ok(views.html.newProposal.render(submittedForm));
} else {
Proposal proposal = submittedForm.get();
proposal.save();
flash("message", "Thanks for submitting a proposal");
return redirect(routes.Application.index());
}
}