Ejemplo n.º 1
0
        public HttpResponseMessage GetForm(string clubShortName, string formName)
        {
            HttpResponseMessage response = new HttpResponseMessage(HttpStatusCode.OK);
            FormModel           form     = FormModel.MapFormModel(FormsBLL.GetForm(clubShortName, formName), true);

            response.Content = new ObjectContent <FormModel>(form, new JsonMediaTypeFormatter());
            return(response);
        }
Ejemplo n.º 2
0
        public HttpResponseMessage GetForm(int formId)
        {
            HttpResponseMessage response     = new HttpResponseMessage(HttpStatusCode.OK);
            UserPrincipal       loggedInUser = (UserPrincipal)HttpContext.Current.User;
            FormModel           form         = FormModel.MapFormModel(FormsBLL.GetForm(loggedInUser.AccountSession.ClubId, formId), true);

            response.Content = new ObjectContent <FormModel>(form, new JsonMediaTypeFormatter());
            return(response);
        }