Jump to content
We've recently updated our Privacy Statement, available here ×

Creation of new Pages for Jasper Intelligence


senton9999

Recommended Posts

hi everyone!

 

i'm playing with the tutorial in the JasperServer-Developer-Guide. I've tried to follow the instructions, but i'm not sure, where exactly to safe the hello.html and the *.jsp for it.

 

Further it is not clear for me, where i have to add the following lines of code:

 

public ModelAndView hello(HttpServletRequest req,

HttpServletResponse res)

throws ServletException {

return new ModelAndView("hello");

}

 

Ok, you got me, i'm an absolute newbie, but i hope, anyone can help me.

 

thx in advance.

 

Senton

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Senton,

 

You don't actually need to make a hello.html. Instead, the configuration jasperserver-servlet.xml sets things up so that the user can type "http://<path>/hello.html" in the URL and will end up executing a JSP file (that is what the mapping does).

 

In addition, we are using Spring MVC which is a model, view, control framework. So, what really happens is that hello.html is mapped to a controller (normal .java file) and is also mapped to "hello".jsp.

 

So, as mentioned in the guide the "public ModelAndView hello( etc, etc)" should be added to the controller located at jasperserver-war-jar/src/main/java/

com/jaspersoft/jasperserver/war/control/JSCommonController.java

 

And the hello.jsp should go into the ~/WEB-INF/jsp/example/hello.jsp

 

Now, the only tricky part is that the controller java file needs to actually be compiled and a new jasperserver.war created in order for the controller to be updated in your environment.

 

So, what you need to do is get an actual build environment setup on your system. To do this you would follow the steps in the "Source Code Build" section of the jasperintelligence-source-build-and-developer-guide.pdf

 

Hope this helps!

 

-Tony

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...