Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Scaffolding JSON response is incorrectly decorated

Voormedia August 15, 2013

When I try to create a new page using the scaffolding plugin, saving the form fails. It seems like the JSON response from the Scaffolding plugin is decorated by the Confluence main decorator (even though I can see decorator: none in the JSON query parameters).

When saving the form, a Javascript error appears in the console:

POST http://localhost:1990/pages/doeditscaffold.action

SyntaxError: JSON.parse: unexpected character
return window.JSON.parse( data );
Checking the reponse of the post, I noticed the rendered result of
/net/customware/confluence/plugin/scaffolding/action/editscaffold-forms-response-json.vm
is the JSON response
{"errors" : null }

decorated by the main decorator:

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
  <head>
    <title></title>
  </head>
  <body>
    <p>
      ... <!-- \#header -->
    </p>
    <div id="main" class=" aui-page-panel">
      <div id="main-header">
        <h1 id="title-heading" class="pagetitle with-breadcrumbs"></h1>
        <div id="breadcrumb-section">
          <h1 id="title-heading" class="pagetitle with-breadcrumbs">
            <span id="title-text" class="with-breadcrumbs"></span>
          </h1>
        </div>
      </div><!-- \#main-header -->
      <div id="sidebar-container"></div><!-- \#sidebar-container -->
      {"errors" : null }
    </div><!-- \#main -->
    <!-- \#full-height-container -->
    <!-- \#page -->
  </body>
</html>

Any ideas about what is causing this?

I use Confluene version 5.1.5 and version 5.0.4 of the CustomWare Scaffolding plugin.

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

1 vote
Answer accepted
AbiD August 18, 2013

Hi There,

I'm one of the developer in ServiceRocket ( formerly known as Customware).

This is a known high priority bug and we are in the midst of fixing this issue to render json using https://developer.atlassian.com/display/CONFDEV/Generating+JSON+output+in+Confluence+with+Jsonator

Together, we will release the plugin with compatibility for Confluence 5.2. We will update about the release soon.

Thanks for raising the issue,

Abi

Voormedia August 18, 2013

Hi Abi,

Thanks for your reply. If there is anything I can do to help, please let me know. I would be happy to do some beta testing.

-- Jippe

TAGS
AUG Leaders

Atlassian Community Events