Exemple #1
0
        public async Task<IHttpActionResult> Submit(IdeaSubmissionRequest ideaSubmissionRequest)
        {
            if (ModelState.IsValid)
            {
                _ideaService.SaveIdea(ideaSubmissionRequest);

                return Ok(new  IdeaSubmissionResponse
                {
                    Message = "Idea submitted ok",
                    Success = true
                });
            }

            return BadRequest(ModelState);
        }
Exemple #2
0
 public SaveIdeaArgs(IdeaSubmissionRequest ideaSubmissionRequest)
 {
     IdeaSubmissionRequest = ideaSubmissionRequest;
 }
Exemple #3
0
 public void SaveIdea(IdeaSubmissionRequest ideaSubmissionRequest)
 {
     _pipelineFactory.Run(PipelineNames.SaveIdea, new SaveIdeaArgs(ideaSubmissionRequest));
 }