Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
is that use protected void populateTreeItem(WebMarkupContainer item, int level) {} to set the redirect link ? thanks Matej Knopp-2 wrote: I believe, that what you want, is not to set response page, but rather to switch panel components. At least that sounds much more reasonable to me. -Matej On 7/4/07, kenixwong [EMAIL PROTECTED] wrote: the reason i using the tree is my menu will be cover a lot of reports ( i m develop the report module). So if using the tree style, the interface will be look more nicer and structure. Plus the dynamic feel to the user :p (more attractive). is that the wicket - tree is hard to maintain? Actually i had build the tree, sub tree and report name. All i listed in array and then called up the array to execute became a tree. Anyway, i found that the wicket example did not show the use of the node link. Any place can help ? As i went through this forum but still cant get any idea to solve it .. :( how ar?? Eelco Hillenius wrote: sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. If you are looking for menus, why not use something like this: http://developer.yahoo.com/yui/menu/? That will be much easier to set up than bending the Tree component into something it is not meant for. Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11426246 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11459276 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
ok... maybe i m new to wicket. Some of the example i cant really get what it means. Anyway, for temporary, i had solved my problem (think is not so practical :p) . hard code for the node link.. protected void onNodeLinkClicked(AjaxRequestTarget ajaxRequestTarget, TreeNode node) { treeNode = (DefaultMutableTreeNode)node; String treeNodeIndex = tree.getNodeComponent(node).getId(); System.out.println( treeNodeIndex = +treeNodeIndex); if(buildTreeList.size()0){ // tree- root if(tree.getNodeComponent(node).getId().equals(0)){ ReportsPortalPage page = new ReportsPortalPage(); setResponsePage(page); } // request module else if( tree.getNodeComponent(node).getId().equals(1)){ RequestReportsPortalPage page = new RequestReportsPortalPage(); setResponsePage(page); } //hardware module else if( tree.getNodeComponent(node).getId().equals(5)){ HardwareReportsPortalPage page = new HardwareReportsPortalPage(); setResponsePage(page); } //software module else if( tree.getNodeComponent(node).getId().equals(9)){ SoftwareReportsPortalPage page = new SoftwareReportsPortalPage(); setResponsePage(page); } //admin module else if( tree.getNodeComponent(node).getId().equals(13)){ AdminReportsPortalPage page = new AdminReportsPortalPage(); setResponsePage(page); } } } At the moment, it works. But in future , i will study and amend it. Thanks for everybody :) Here, i got another question... is there any place to enlarge the tree border size ? Caused by some of the node link name is long (eg: Workstation Network Card Details Report (PDF) ) , when the tree was expand, i cant see the whole name ... thanks Matej Knopp-2 wrote: I believe, that what you want, is not to set response page, but rather to switch panel components. At least that sounds much more reasonable to me. -Matej On 7/4/07, kenixwong [EMAIL PROTECTED] wrote: the reason i using the tree is my menu will be cover a lot of reports ( i m develop the report module). So if using the tree style, the interface will be look more nicer and structure. Plus the dynamic feel to the user :p (more attractive). is that the wicket - tree is hard to maintain? Actually i had build the tree, sub tree and report name. All i listed in array and then called up the array to execute became a tree. Anyway, i found that the wicket example did not show the use of the node link. Any place can help ? As i went through this forum but still cant get any idea to solve it .. :( how ar?? Eelco Hillenius wrote: sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. If you are looking for menus, why not use something like this: http://developer.yahoo.com/yui/menu/? That will be much easier to set up than bending the Tree component into something it is not meant for. Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11426246 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML.
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
ok... maybe i m new to wicket. Some of the example i cant really get what it means. Anyway, for temporary, i had solved my problem (think is not so practical :p) . hard code for the node link.. protected void onNodeLinkClicked(AjaxRequestTarget ajaxRequestTarget, TreeNode node) { treeNode = (DefaultMutableTreeNode)node; String treeNodeIndex = tree.getNodeComponent(node).getId(); System.out.println( treeNodeIndex = +treeNodeIndex); if(buildTreeList.size()0){ // tree- root if(tree.getNodeComponent(node).getId().equals(0)){ ReportsPortalPage page = new ReportsPortalPage(); setResponsePage(page); } // request module else if( tree.getNodeComponent(node).getId().equals(1)){ RequestReportsPortalPage page = new RequestReportsPortalPage(); setResponsePage(page); } //hardware module else if( tree.getNodeComponent(node).getId().equals(5)){ HardwareReportsPortalPage page = new HardwareReportsPortalPage(); setResponsePage(page); } //software module else if( tree.getNodeComponent(node).getId().equals(9)){ SoftwareReportsPortalPage page = new SoftwareReportsPortalPage(); setResponsePage(page); } //admin module else if( tree.getNodeComponent(node).getId().equals(13)){ AdminReportsPortalPage page = new AdminReportsPortalPage(); setResponsePage(page); } } } At the moment, it works. But in future , i will study and amend it. Thanks for everybody :) Here, i got another question... is there any place to enlarge the tree border size ? Caused by some of the node link name is long (eg: Workstation Network Card Details Report (PDF) ) , when the tree was expand, i cant see the whole name ... As i looked for the wicket example, it was automatic.. but when i implemented it, it is not ? thanks Matej Knopp-2 wrote: I believe, that what you want, is not to set response page, but rather to switch panel components. At least that sounds much more reasonable to me. -Matej On 7/4/07, kenixwong [EMAIL PROTECTED] wrote: the reason i using the tree is my menu will be cover a lot of reports ( i m develop the report module). So if using the tree style, the interface will be look more nicer and structure. Plus the dynamic feel to the user :p (more attractive). is that the wicket - tree is hard to maintain? Actually i had build the tree, sub tree and report name. All i listed in array and then called up the array to execute became a tree. Anyway, i found that the wicket example did not show the use of the node link. Any place can help ? As i went through this forum but still cant get any idea to solve it .. :( how ar?? Eelco Hillenius wrote: sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. If you are looking for menus, why not use something like this: http://developer.yahoo.com/yui/menu/? That will be much easier to set up than bending the Tree component into something it is not meant for. Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11426246 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
the reason i using the tree is my menu will be cover a lot of reports ( i m develop the report module). So if using the tree style, the interface will be look more nicer and structure. Plus the dynamic feel to the user :p (more attractive). is that the wicket - tree is hard to maintain? Actually i had build the tree, sub tree and report name. All i listed in array and then called up the array to execute became a tree. Anyway, i found that the wicket example did not show the use of the node link. Any place can help ? As i went through this forum but still cant get any idea to solve it .. :( how ar?? Eelco Hillenius wrote: sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. If you are looking for menus, why not use something like this: http://developer.yahoo.com/yui/menu/? That will be much easier to set up than bending the Tree component into something it is not meant for. Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11426246 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
I believe, that what you want, is not to set response page, but rather to switch panel components. At least that sounds much more reasonable to me. -Matej On 7/4/07, kenixwong [EMAIL PROTECTED] wrote: the reason i using the tree is my menu will be cover a lot of reports ( i m develop the report module). So if using the tree style, the interface will be look more nicer and structure. Plus the dynamic feel to the user :p (more attractive). is that the wicket - tree is hard to maintain? Actually i had build the tree, sub tree and report name. All i listed in array and then called up the array to execute became a tree. Anyway, i found that the wicket example did not show the use of the node link. Any place can help ? As i went through this forum but still cant get any idea to solve it .. :( how ar?? Eelco Hillenius wrote: sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. If you are looking for menus, why not use something like this: http://developer.yahoo.com/yui/menu/? That will be much easier to set up than bending the Tree component into something it is not meant for. Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11426246 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
Sorry, cant get u.. can you show me the some partial code ? My tree example was refer from the wicket example. but it only shown how to create a tree without some example to click the node and redirect to another page. I had tried search from the forum and do testing... still failed. Can everybody give ma some guide ? Maybe i am new to the wicket.. anyway, it is fun to learn and play around :) thanks igor.vaynberg wrote: On 7/2/07, kenixwong [EMAIL PROTECTED] wrote: i m using wicket1.2.4 i done with the nice tree and can display it. Just i did not get any resource on the link. Once i click all the node link, i wish to redirect to different pages that i defined. I had search in the wicket-user forum, but cant get any result yet. Can u help for it. (btw: i m the new to wicket) in wicket 1.2.x we do not support setresponsepage() from an ajax request (which is what i assume is going on since setresponsepage isnt working). what you have to do instead is ajaxtarget.appendjavascript(window.location=+urlfor(MyPage.class)); -igor here is my partial code final Tree tree = new Tree(tree, treeModel) { protected String renderNode(TreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; return String.valueOf(treeNode.getUserObject()); } protected void nodeLinkClicked(DefaultMutableTreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; setResponsePage(ReportTreePanel.class); } }; Eelco Hillenius wrote: Can anyone give me an example of override onNodeLinkClicked(...) for display the tree. I want to click the menu intree structure. It's fine i can did it now. But i cant setResponce to another page when i clicked on the link.. thanks in future So calling setResponsePage (to another page I pressume) doesn't work in the link clicked handler of the tree component? I wouldn't know how this might be a problem tbh. Which version of Wicket are you using, and which tree component (from the core project or the extensions project)? Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11391373 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11424058 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
Sorry, cant get u.. can you show me the some partial code ? My tree example was refer from the wicket example. but it only shown how to create a tree without some example to click the node and redirect to another page. I had tried search from the forum and do testing... still failed. Can everybody give ma some guide ? Maybe i am new to the wicket.. anyway, it is fun to learn and play around :) If you are just playing around, could you please do that with Wicket 1.3, as you won't have those problems you are having with that version to start with :) See http://martijndashorst.com/blog/2007/07/02/apache-wicket-130-beta-2-released/ Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
thx for reply... i waiting and waiting somebody to reply it.. :p sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. thx a lot Eelco Hillenius wrote: Sorry, cant get u.. can you show me the some partial code ? My tree example was refer from the wicket example. but it only shown how to create a tree without some example to click the node and redirect to another page. I had tried search from the forum and do testing... still failed. Can everybody give ma some guide ? Maybe i am new to the wicket.. anyway, it is fun to learn and play around :) If you are just playing around, could you please do that with Wicket 1.3, as you won't have those problems you are having with that version to start with :) See http://martijndashorst.com/blog/2007/07/02/apache-wicket-130-beta-2-released/ Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11425136 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
sorry for understood.. i m not just play around. i wish to build a new module for my current project. And i wish to manage all the menus in a tree style outlook. So, can i get some guide frou u , Eelco .. If you are looking for menus, why not use something like this: http://developer.yahoo.com/yui/menu/? That will be much easier to set up than bending the Tree component into something it is not meant for. Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
Can anyone give me an example of override onNodeLinkClicked(...) for display the tree. I want to click the menu intree structure. It's fine i can did it now. But i cant setResponce to another page when i clicked on the link.. thanks in future So calling setResponsePage (to another page I pressume) doesn't work in the link clicked handler of the tree component? I wouldn't know how this might be a problem tbh. Which version of Wicket are you using, and which tree component (from the core project or the extensions project)? Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
i m using wicket1.2.6 i done with the nice tree and can display it. Just i did not get any resource on the link. Once i click all the node link, i wish to redirect to different pages that i defined. I had search in the wicket-user forum, but cant get any result yet. Can u help for it. (btw: i m the new to wicket) here is my partial code final Tree tree = new Tree(tree, treeModel) { protected String renderNode(TreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; return String.valueOf(treeNode.getUserObject()); } protected void nodeLinkClicked(DefaultMutableTreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; setResponsePage(ReportTreePanel.class); } }; Eelco Hillenius wrote: Can anyone give me an example of override onNodeLinkClicked(...) for display the tree. I want to click the menu intree structure. It's fine i can did it now. But i cant setResponce to another page when i clicked on the link.. thanks in future So calling setResponsePage (to another page I pressume) doesn't work in the link clicked handler of the tree component? I wouldn't know how this might be a problem tbh. Which version of Wicket are you using, and which tree component (from the core project or the extensions project)? Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11390711 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
i m using wicket1.2.4 i done with the nice tree and can display it. Just i did not get any resource on the link. Once i click all the node link, i wish to redirect to different pages that i defined. I had search in the wicket-user forum, but cant get any result yet. Can u help for it. (btw: i m the new to wicket) here is my partial code final Tree tree = new Tree(tree, treeModel) { protected String renderNode(TreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; return String.valueOf(treeNode.getUserObject()); } protected void nodeLinkClicked(DefaultMutableTreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; setResponsePage(ReportTreePanel.class); } }; Eelco Hillenius wrote: Can anyone give me an example of override onNodeLinkClicked(...) for display the tree. I want to click the menu intree structure. It's fine i can did it now. But i cant setResponce to another page when i clicked on the link.. thanks in future So calling setResponsePage (to another page I pressume) doesn't work in the link clicked handler of the tree component? I wouldn't know how this might be a problem tbh. Which version of Wicket are you using, and which tree component (from the core project or the extensions project)? Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11391373 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Tree - override onNodeLinkClicked(...)?
On 7/2/07, kenixwong [EMAIL PROTECTED] wrote: i m using wicket1.2.4 i done with the nice tree and can display it. Just i did not get any resource on the link. Once i click all the node link, i wish to redirect to different pages that i defined. I had search in the wicket-user forum, but cant get any result yet. Can u help for it. (btw: i m the new to wicket) in wicket 1.2.x we do not support setresponsepage() from an ajax request (which is what i assume is going on since setresponsepage isnt working). what you have to do instead is ajaxtarget.appendjavascript(window.location=+urlfor(MyPage.class)); -igor here is my partial code final Tree tree = new Tree(tree, treeModel) { protected String renderNode(TreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; return String.valueOf(treeNode.getUserObject()); } protected void nodeLinkClicked(DefaultMutableTreeNode node) { DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode)node; setResponsePage(ReportTreePanel.class); } }; Eelco Hillenius wrote: Can anyone give me an example of override onNodeLinkClicked(...) for display the tree. I want to click the menu intree structure. It's fine i can did it now. But i cant setResponce to another page when i clicked on the link.. thanks in future So calling setResponsePage (to another page I pressume) doesn't work in the link clicked handler of the tree component? I wouldn't know how this might be a problem tbh. Which version of Wicket are you using, and which tree component (from the core project or the extensions project)? Eelco - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- View this message in context: http://www.nabble.com/Tree---override-onNodeLinkClicked%28...%29--tf4010264.html#a11391373 Sent from the Wicket - User mailing list archive at Nabble.com. - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user