示例#1
0
        public IHttpActionResult UpdateStepParagraph(StepParagraphRequest request)
        {
            StepParagraphMessage message = new StepParagraphMessage();
            List <string>        errors  = ValidateUpdateStepParagraph(request);

            if (errors != null && errors.Any())
            {
                message.ErrorMessage     = StepMessageResource.ValidationErrors;
                message.ErrorType        = ErrorType.ValidationError;
                message.Errors           = new List <string>();
                message.OperationSuccess = false;
                message.Errors.AddRange(errors);
            }
            else
            {
                message = _serviceStepParagraphClient.UpdateStepParagraph(request);
            }
            return(Json(message));
        }
        public IHttpActionResult UpdateStepParagraph(StepParagraphRequest request)
        {
            StepParagraphMessage message = serviceStepParagraphClient.UpdateStepParagraph(request);

            return(Json(message));
        }