Пример #1
0
        public HttpResponseMessage Update(JobApplicationUpdateRequest model)
        {
            if (!ModelState.IsValid)
            {
                return(Request.CreateResponse(HttpStatusCode.BadRequest, ModelState));
            }

            _jobApplicationService.Update(model);

            SuccessResponse response = new SuccessResponse();

            return(Request.CreateResponse(HttpStatusCode.OK, response));
        }
Пример #2
0
        public void Update(JobApplicationUpdateRequest model)
        {
            model.Notes = model.Notes ?? String.Empty;

            DataProvider.ExecuteNonQuery(GetConnection, "dbo.JobApplication_Update",
                                         inputParamMapper : delegate(SqlParameterCollection paramCollection)
            {
                paramCollection.AddWithValue("@Id", model.Id);
                paramCollection.AddWithValue("@StatusId", model.StatusId);
                paramCollection.AddWithValue("@Notes", model.Notes);
            }
                                         );
            return;
        }