Ejemplo n.º 1
0
        public void SubmitDraft(EditSubmitRequest req)
        {
            try
            {
                new Workflow().SubmitDraft(decimal.Parse(req.ProtocolCKey), decimal.Parse(req.AuthorCKey));
            }
            catch (Exception ex)
            {
                var response = new HttpResponseMessage(HttpStatusCode.BadRequest);
                response.Content = new StringContent(ex.Message);

                throw new HttpResponseException(response);
            }
        }
Ejemplo n.º 2
0
        public void UpdateStatus(EditSubmitRequest req)
        {
            try
            {
                new Workflow().UpdateEditStatus(decimal.Parse(req.ProtocolCKey), decimal.Parse(req.AuthorCKey), req.Status);
            }
            catch (Exception ex)
            {
                var resp = new HttpResponseMessage(HttpStatusCode.ExpectationFailed)

                {
                    ReasonPhrase = ex.Message
                };

                throw new HttpResponseException(resp);
            }
        }