added data action to return json formatted data passed to pdf