JavaRanch » Java Forums »
Frameworks »
Struts
| Author |
[Struts2][Jqueryplugin] problem to populate grid .
|
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
hi greenhorn people
i can not understand a lot of thing about the tuto Jquery grid
i try to populate my grid but its blanked .
i put my code action before my jsp page.
code action
my jsp :
on my JsonTable
struts
well i put println() in method execute on my JsonTable and no display something
i miss something
|
 |
Johannes Geppert
Ranch Hand
Joined: Jan 12, 2010
Posts: 67
|
|
what is happens when you call your JsonTable action directly?
Do You get an valid JSON Result?
Johannes
|
My Java and Webprogramming Blog
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
hi tx to answer me johannes
Are you JqueryTeam ?because the package has your name in the queryshowcase.war
well
when i call directly jsontable a window is open and displayed ( download file ,inconnu file do you want seach a application who can read or save on the disk or ignore.)
i think i miss something
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
application cannot entry on the jsontable.
|
 |
Johannes Geppert
Ranch Hand
Joined: Jan 12, 2010
Posts: 67
|
|
I guesss the problem is the name of your gridmodel. You have named it in your action listfriend but in your grid tag you named it gridModel.
Johannes
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
no i think its not that because app d'ont entry to the method execute ..i changed to test if friendlist can display it.
i put my code
totoAction:
totoaction redirect to the toto/toto.jsp
my jsontable
on my default package i have
totoaction
on showcase package
i have
jsontable
on my struts
<package>
<action name="totoAction" class="totoAction">
<result name="success">/toto/toto.jsp</result>
</action>
</package>
<package name="showcase" namespace="/" extends="struts-default,json-default">
<action name="jsontable" >
<result type="json"/> </action>
</package>
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
my struts
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
i instance my listfriend and populate it on the method and its work thank you
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
why i have to instance all my field?
i have getter and setter ?
shoud i put on my value stack ?
its very strange
sombody can help me ?
i think i use jsonno effeciently because i have to instanciate alll my field on the classe its is normal ?
i think not because on action on the ewample it not instanciate session map.
|
 |
debraj mallick
Ranch Hand
Joined: Mar 08, 2011
Posts: 188
|
|
hi khekhone,
use "excludeProperties" followed by the service names, put these in your code
otherwise you will all the instance of your setter-getters...
hope this would help.
|
 |
khekhone yvan
Ranch Hand
Joined: May 08, 2011
Posts: 75
|
|
its good to know
but i want have all rhe property and i dont understand why i cannot link with value stack
i think i understand json at all
|
 |
 |
|
|
subject: [Struts2][Jqueryplugin] problem to populate grid .
|
|
|
|