Skip to main content

[dojo.table]Problems with values

8 replies [Last post]
mauriff
Offline
Joined: 2006-08-19
Points: 0

Hi! I am using jmaki's components, but I have a problem in a minute from utilizing dynamic values in dojo.table.
For example this does not show nothing
<%
String value = "{columns: { 'title' : 'Title', 'author':'Author', 'isbn': 'ISBN #', 'description':'Description'}, rows:[['JavaScript 101', 'Lu Sckrepter','4412', 'Some long description'], ['Ajax with Java', 'Jean Bean','4413', 'Some long description']]}";
%>

"[/b] />

No himself as he is error...
Regards

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
mauriff
Offline
Joined: 2006-08-19
Points: 0

Thanks.

mauriff
Offline
Joined: 2006-08-19
Points: 0

I have introduced the code in the version 6 preview 4 and he gives me the following exception:

org.apache.jasper.JasperException: /dojo/table.jsp(23,1) [b]Según el TLD o la directiva attribute del archivo tag, el atributo value no acepta expresiones[/b]
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:512)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:377)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

I seem to great the dojo table, But not yet I get by dynamic parameters.
I want to be able to bring data from a servlet Of the following form
<%
String per=request.getParameter("comPeriodo");
%>

does There be any another form?

pd: sorry for my bad English. Abrazos desde Argentina

Message was edited by: mauriff

Message was edited by: mauriff

gmurray71
Offline
Joined: 2003-07-31
Points: 0

The service attribute is not set up to take expressions as the message states. I will update this in preview 5 which you can get at:

https://ajax.dev.java.net/servlets/ProjectDocumentList

gmurray71
Offline
Joined: 2003-07-31
Points: 0

Looking at the code the service should allow for this behavior already.

What container are you using? Tomcat/Glassfish?

mauriff
Offline
Joined: 2006-08-19
Points: 0

Hi, I'm using tomcat.
Greetings!

mauriff
Offline
Joined: 2006-08-19
Points: 0

t works well when I change from the table.jsp of example, but when I do it from netbeans 5.5 with j2ee4 and following exception knocks down tomcat to me

org.apache.jasper.JasperException: According to TLD or attribute directive in tag file, attribute value does not accept any expressions

Greetings!

gmurray71
Offline
Joined: 2003-07-31
Points: 0

Currently we don't allow dynamic values as the attributes though I would like to investigate Enabling this.

Currenly it is recommended to create a JSON file containg the value and using a service tab to read in the data:

Example:

mybooks.json

{columns: { 'title' : 'Title', 'author':'Author', 'isbn': 'ISBN #', 'description':'Description'}, rows:[['JavaScript 101', 'Lu Sckrepter','4412', 'Some long description'], ['Ajax with Java', 'Jean Bean','4413', 'Some long description']]}

We will investigate enabling dynamic values. Stay tunned.

gmurray71
Offline
Joined: 2003-07-31
Points: 0

I've added support for dynamic values with jMaki version .6 Preview 4. The following code will work now:

<%
String value = "{columns: { 'title' : 'Title2', 'author':'Author', 'isbn': 'ISBN #', 'description':'Description'}, rows:[['JavaScript 101', 'Lu Sckrepter','4412', 'Some long description'], ['Ajax with Java', 'Jean Bean','4413', 'Some long description']]}";
request.setAttribute("table", value);

%>