Thanks Igor for the quick response... I got it solved... - nazeem
nazeem wrote: > > I have the same case where I wanted to customize the navigation toolbar to > add few action menu items as well. So I have written my own version of > AjaxFallbackCustomDataTable by just copying the > AjaxFallbackDefaultDataTable code in to my package and renaming. There I > have commented all addition of toolbars and I am adding them at the time > of declaring it. > > > public AjaxFallbackCustomDataTable(String id, final IColumn[] columns, > SortableDataProvider dataProvider, int rowsPerPage) > { > super(id, columns, dataProvider, rowsPerPage); > setOutputMarkupId(true); > setVersioned(false); > //addTopToolbar(new AjaxNavigationToolbar(this)); > //addTopToolbar(new AjaxCustomNavigationToolbar(this)); > //addTopToolbar(new AjaxFallbackHeadersToolbar(this, > dataProvider)); > addBottomToolbar(new NoRecordsToolbar(this)); > } > > During declaration, > > AjaxFallbackCustomDataTable table = new > AjaxFallbackCustomDataTable("employeesAjax", columns, dataProvider, 7); > AbstractToolbar navigationTB = new AjaxCustomNavigationToolbar(table); > navigationTB.add(new Label("newSpan")); > table.addTopToolbar(navigationTB); > table.addTopToolbar(new AjaxFallbackHeadersToolbar(table, dataProvider)); > AjaxPagingNavigator pgNav = new AjaxPagingNavigator("paging", table); > add(table); > > From the above code, it is clear that I have customized the > AjaxDefaultNavigationToolbar to AjaxCustomNavigationToolbar. The markup > html is also copied and renamed to the same..html. So the problem here is > that I am trying to add some action menus to the navigation toolbar, at > declaration, but it doesn't work. > navigationTB.add(new Label("newSpan")); > > I have also modified the markup to contain wicket:id="newSpan". > > <wicket:panel> > <tr class="navigation"> > <td wicket:id="span"> > <div class="actionmenu" style="float: left; width: > 50%;"> > <span wicket:id="newSpan"></span> > New > # Save > # Delete > Filter <input type="text" > style=""/> > resr/table/img/find.png > </div> > <div style="float: left; padding-right: > 20px;">[navigator-label]</div> > <div style="text-align: right;">[navigator]</div> > </td> > </tr> > </wicket:panel> > > > But I am getting the error that > > [2007-07-12 10:24:11,453] [ERROR] [btpool0-2] > [wicket.RequestCycle.step(1043)] - Unable to find component with id > 'newSpan' in [MarkupContainer [Component id = thirdPartyDetails, page = > com.bp.way2sky.web.layout.Index, path = > 0:tabs:panel:thirdPartyDetails.ThirdParty, isVisible = true, isVersioned = > true]]. This means that you declared wicket:id=newSpan in your markup, but > that you either did not add the component to your page at all, or that the > hierarchy does not match. > [markup = > file:/C:/Documents%20and%20Settings/mnazeem/Local%20Settings/Temp/Jetty_0_0_0_0_8080__bizpad_/webapp/WEB-INF/classes/com/bp/way2sky/web/logistics/tp/ThirdParty.html, > index = 16, current = '' (line 14, column 2)] > wicket.markup.MarkupException: Unable to find component with id 'newSpan' > in [MarkupContainer [Component id = thirdPartyDetails, page = > com.bp.way2sky.web.layout.Index, path = > 0:tabs:panel:thirdPartyDetails.ThirdParty, isVisible = true, isVersioned = > true]]. This means that you declared wicket:id=newSpan in your markup, but > that you either did not add the component to your page at all, or that the > hierarchy does not match. > [markup = > file:/C:/Documents%20and%20Settings/mnazeem/Local%20Settings/Temp/Jetty_0_0_0_0_8080__bizpad_/webapp/WEB-INF/classes/com/bp/way2sky/web/logistics/tp/ThirdParty.html, > index = 16, current = '' (line 14, column 2)] > > > Trying to achieve something like this... > http://www.nabble.com/file/p11554095/dtable.jpg > - nazeem > > > igor.vaynberg wrote: >> >> extend datatable instead of defaultdatatable and add your own toolbars :) >> >> defaultdatatable is just a convinience >> >> -Igor >> >> >> On 8/29/06, Jaime De La Jara <[EMAIL PROTECTED]> wrote: >>> >>> If I knew how that would be an honor , but I'm a wicket begginer yet, >>> besides >>> I've been browsing the source code and I found what seems to be a >>> problem >>> with the suclassing of NavigatorLabel and PagingNavigator approach, and >>> this is the construction of a DefaultDataTable because there are the >>> toolnbars added to the table.How could this be tackled? >>> >>> Thanks, >>> >>> >>> Jaime. >>> >>> *Igor Vaynberg <[EMAIL PROTECTED]>* wrote: >>> >>> you are more then welcome to patch it :) >>> >>> -Igor >>> >>> >>> On 8/29/06, Jaime De La Jara <[EMAIL PROTECTED] > wrote: >>> > >>> > Ok thanks, maybe that properties could be parametrized in some way, so >>> > one would configure them instead of subclassing each time a custom >>> display >>> > is required? >>> > >>> > Jaime. >>> > >>> > >>> > >>> > *Igor Vaynberg <[EMAIL PROTECTED] >* wrote: >>> > >>> > you would create your own pagingnavigator y subclassing the existing >>> and >>> > changing markup/customizing labels >>> > >>> > then create your own paginglabel >>> > >>> > then override NavigationToolbar.newPagingNavigator/newPagingLabel and >>> > return your own subclasses >>> > >>> > -Igor >>> > >>> > >>> > On 8/29/06, Jaime De La Jara <[EMAIL PROTECTED]> wrote: >>> > > >>> > > Continuing with my dissection of the phonebook application I've come >>> > > to the customization of the NavigatorLabel and PagingNavigator >>> classes. How >>> > > would be a nice way to customize them, so for example change the >>> message >>> > > "Showing .. to .. of .." and the less than and greater than symbols >>> for an >>> > > internationalized message and arrow images. I've noticed that the >>> former >>> > > message is included in the NavigatorLabel class and the symbols >>> appear in >>> > > the markup associated with the Paging Navigator component. >>> > > >>> > > Thanks, >>> > > >>> > > Jaime. >>> > > ------------------------------ >>> > > All-new Yahoo! Mail >>> > > >>> <http://us.rd.yahoo.com/evt=43256/*http://advision.webevents.yahoo.com/mailbeta>- >>> > > Fire up a more powerful email and get things done faster. >>> > > >>> > > >>> > > >>> ------------------------------------------------------------------------- >>> > > Using Tomcat but need to do more? Need to support web services, >>> > > security? >>> > > Get stuff done quickly with pre-integrated technology to make your >>> job >>> > > easier >>> > > Download IBM WebSphere Application Server v.1.0.1 based on Apache >>> > > Geronimo >>> > > >>> > > >>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >>> > > >>> > > _______________________________________________ >>> > > Wicket-user mailing list >>> > > Wicket-user@lists.sourceforge.net >>> > > https://lists.sourceforge.net/lists/listinfo/wicket-user >>> > > >>> > > >>> > > >>> > >>> > >>> ------------------------------------------------------------------------- >>> > Using Tomcat but need to do more? Need to support web services, >>> > security? >>> > Get stuff done quickly with pre-integrated technology to make your job >>> > easier >>> > Download IBM WebSphere Application Server v.1.0.1 based on Apache >>> > Geronimo >>> > >>> > >>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642_______________________________________________ >>> > Wicket-user mailing list >>> > Wicket-user@lists.sourceforge.net >>> > https://lists.sourceforge.net/lists/listinfo/wicket-user >>> > >>> > >>> > ------------------------------ >>> > Yahoo! Messenger with Voice. Make PC-to-Phone >>> Calls<http://us.rd.yahoo.com/mail_us/taglines/postman1/*http://us.rd.yahoo.com/evt=39663/*http://voice.yahoo.com>to >>> the US (and 30+ countries) for 2¢/min or less. >>> > >>> > >>> > >>> ------------------------------------------------------------------------- >>> > Using Tomcat but need to do more? Need to support web services, >>> > security? >>> > Get stuff done quickly with pre-integrated technology to make your job >>> > easier >>> > Download IBM WebSphere Application Server v.1.0.1 based on Apache >>> > Geronimo >>> > >>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >>> > >>> > _______________________________________________ >>> > Wicket-user mailing list >>> > Wicket-user@lists.sourceforge.net >>> > https://lists.sourceforge.net/lists/listinfo/wicket-user >>> > >>> > >>> > >>> ------------------------------------------------------------------------- >>> Using Tomcat but need to do more? Need to support web services, >>> security? >>> Get stuff done quickly with pre-integrated technology to make your job >>> easier >>> Download IBM WebSphere Application Server v.1.0.1 based on Apache >>> Geronimo >>> >>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642_______________________________________________ >>> Wicket-user mailing list >>> Wicket-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/wicket-user >>> >>> >>> ------------------------------ >>> Yahoo! Messenger with Voice. Make PC-to-Phone >>> Calls<http://us.rd.yahoo.com/mail_us/taglines/postman1/*http://us.rd.yahoo.com/evt=39663/*http://voice.yahoo.com>to >>> the US (and 30+ countries) for 2¢/min or less. >>> >>> >>> ------------------------------------------------------------------------- >>> Using Tomcat but need to do more? Need to support web services, >>> security? >>> Get stuff done quickly with pre-integrated technology to make your job >>> easier >>> Download IBM WebSphere Application Server v.1.0.1 based on Apache >>> Geronimo >>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >>> >>> _______________________________________________ >>> Wicket-user mailing list >>> Wicket-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/wicket-user >>> >>> >>> >> >> ------------------------------------------------------------------------- >> Using Tomcat but need to do more? Need to support web services, security? >> Get stuff done quickly with pre-integrated technology to make your job >> easier >> Download IBM WebSphere Application Server v.1.0.1 based on Apache >> Geronimo >> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >> _______________________________________________ >> 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/Navigator-customization-tf2184602.html#a11557365 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