コード例 #1
0
        public HttpResponseMessage UpdateContactNote(UpdateContactNoteRequest model)
        {
            if (!ModelState.IsValid)
            {
                return(Request.CreateErrorResponse(HttpStatusCode.BadRequest, ModelState));
            }

            SuccessResponse response = new SuccessResponse();

            ContactNotesService.UpdateContactNote(model);
            return(Request.CreateResponse(response));
        }
コード例 #2
0
        public HttpResponseMessage AddContactNote(AddContactNoteRequest model)
        {
            if (!ModelState.IsValid)
            {
                return(Request.CreateErrorResponse(HttpStatusCode.BadRequest, ModelState));
            }

            ItemResponse <int> response = new ItemResponse <int>();

            response.Item = ContactNotesService.UpdateContactNote(model);
            return(Request.CreateResponse(response));
        }