Re: reuse Form Panel code for WizardStep?
The problem is wicket:idfor example: Formjavanew RequiredTextField( "companyName" );WizardStepjavanew RequiredTextField( "company.companyName" ); -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/reuse-Form-Panel-code-for-WizardStep-tp4659295p4659302.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AjaxEventBehavior("onclick")
thanks very much, sven works exactly as i want! have a nice evening boris On 06/08/2013 10:58 PM, Sven Meier wrote: attributes.getDynamicExtraParameters().add( "return {'ctrl' : attrs.event.ctrlKey, 'shift' : attrs.event.shiftKey}" ); } - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AjaxEventBehavior("onclick")
Override the following in your event behavior: @Override protected void updateAjaxAttributes(AjaxRequestAttributes attributes) { super.updateAjaxAttributes(attributes); attributes.getDynamicExtraParameters().add( "return {'ctrl' : attrs.event.ctrlKey, 'shift' : attrs.event.shiftKey}" ); } You can then analyse the parameters 'ctrl' and 'shift' in your #onEvent() hook. Hope this helps Sven On 06/08/2013 10:31 PM, Boris Brinza wrote: Hello how to get status of keyboard in onclick handler, i mean status of ctrl or alt keys? i want to select multiple lines in my table using ctrl-click on lines. i.ve found some solutions using overriden getCallbackScript, but it seems it;'s working only in older wicket versions, after several hours i've not found any working solution for wicket 6. Thanks for any advice boris - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
AjaxEventBehavior("onclick")
Hello how to get status of keyboard in onclick handler, i mean status of ctrl or alt keys? i want to select multiple lines in my table using ctrl-click on lines. i.ve found some solutions using overriden getCallbackScript, but it seems it;'s working only in older wicket versions, after several hours i've not found any working solution for wicket 6. Thanks for any advice boris - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AjaxFallbackDefaultDataTable: cell not receiving event after sorting
Hi, when a column is sorted, the whole table will be updated on the Ajax request: That includes its HTML markup *and* the JavaScript in the header. So normally the markup ids should match. I can't think of a reason why this fails on your project. Could you create a quickstart? Sven On 06/08/2013 12:37 PM, dlock wrote: Hi Sven. Thanks for taking a look at my question. I have been trying to debug the issue (Ajax is new to me so please be patient). It looks like the issue is more fundamental than what I first thought. I added a simple row listener like so... @Override protected Item newRowItem(String id, int index, IModel model) { Item item = super.newRowItem(id, index, model); item.add(new RowBehavior("onclick", model) { private static final long serialVersionUID = 1L; @Override protected void onEvent(IModel model, AjaxRequestTarget target) { m_logger.info("row clicked: {}", model.getObject()); } }); return item; } Prior to sorting, the content of the row is printed when clicked. After sorting nothing is printed, sorting again to revert back to the original state will print the contents on a row click. Every other sort (the one that results in the failure scenario) results in the following errors being logged in the Wicket Ajax Debug Window ERROR: Cannot find element with id: iconc2 ERROR: Cannot find element with id: id21c3 ERROR: Cannot find element with id: iconc4 ERROR: Cannot find element with id: id22c5 ERROR: Cannot find element with id: orderByLinkc6 ERROR: Cannot find element with id: orderByLinkc7 ERROR: Cannot find element with id: orderByLinkc8 The ids obviously change with each sort. From what I can tell the orderByLink ones are the header links that result in a sort when clicked and the icon and id ones relate to the label/icon described in the original problem. There is JavaScript created that links the above ids to their behaviours Something like this Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-body-rows-25-cells-3-cell-icon","e":"click","c":"iconc6"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.0-usersTable-table-body-rows-25","e":"click","c":"id25c7"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-body-rows-26-cells-3-cell-icon","e":"click","c":"iconc8"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.0-usersTable-table-body-rows-26","e":"click","c":"id26c9"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-topToolbars-toolbars-1-headers-49-header-orderByLink","e":"click","c":"orderByLinkca"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-topToolbars-toolbars-1-headers-50-header-orderByLink","e":"click","c":"orderByLinkcb"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-topToolbars-toolbars-1-headers-52-header-orderByLink","e":"click","c":"orderByLinkcc"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorLis When everything is working the markup and javascript ids align. When it fails, it looks like the previous javascript remains (hence why the row listener is failing) So, the (new) question I have is, where/how does the JavaScript and markup get associated and why can't the newly generated ids be found (yet on a resort they can). Some possibly (not) important points. The table resides in an extension to Panel which is added to a page. I am using Wicket 6.8.0 Any help/pointers would be appreciated. dl -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/AjaxFallbackDefaultDataTable-cell-not-receiving-event-after-sorting-tp4659277p4659294.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: reuse Form Panel code for WizardStep?
You could move most of the stuff out of your WizardStep into a new Panel subclass. Use this class inside your WizardStep or separately on other places. Sven On 06/08/2013 05:47 PM, always_rick wrote: Hi, How can I reuse a form panel code for WizardStep, in both html and java class? My current project, required a lot to create new stuff by wizard, and create/edit them by normal form as well. Since the logic/code is basically same, I think it is doable. So, I tried, but no luck. Any advice will be appreciated. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/reuse-Form-Panel-code-for-WizardStep-tp4659295.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Wicket mail and pdf
I wanted to integrate mail and pdf creation in my wicket application. Till now I manage this by sending a request to a cocoon-2.2.0 application. This is a good solution but because I see no upgrade way using my cocoon application and integrating newer versions of spring I am looking for an alternative. Heiner - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
reuse Form Panel code for WizardStep?
Hi, How can I reuse a form panel code for WizardStep, in both html and java class? My current project, required a lot to create new stuff by wizard, and create/edit them by normal form as well. Since the logic/code is basically same, I think it is doable. So, I tried, but no luck. Any advice will be appreciated. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/reuse-Form-Panel-code-for-WizardStep-tp4659295.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AjaxFallbackDefaultDataTable: cell not receiving event after sorting
Hi Sven. Thanks for taking a look at my question. I have been trying to debug the issue (Ajax is new to me so please be patient). It looks like the issue is more fundamental than what I first thought. I added a simple row listener like so... @Override protected Item newRowItem(String id, int index, IModel model) { Item item = super.newRowItem(id, index, model); item.add(new RowBehavior("onclick", model) { private static final long serialVersionUID = 1L; @Override protected void onEvent(IModel model, AjaxRequestTarget target) { m_logger.info("row clicked: {}", model.getObject()); } }); return item; } Prior to sorting, the content of the row is printed when clicked. After sorting nothing is printed, sorting again to revert back to the original state will print the contents on a row click. Every other sort (the one that results in the failure scenario) results in the following errors being logged in the Wicket Ajax Debug Window ERROR: Cannot find element with id: iconc2 ERROR: Cannot find element with id: id21c3 ERROR: Cannot find element with id: iconc4 ERROR: Cannot find element with id: id22c5 ERROR: Cannot find element with id: orderByLinkc6 ERROR: Cannot find element with id: orderByLinkc7 ERROR: Cannot find element with id: orderByLinkc8 The ids obviously change with each sort. From what I can tell the orderByLink ones are the header links that result in a sort when clicked and the icon and id ones relate to the label/icon described in the original problem. There is JavaScript created that links the above ids to their behaviours Something like this Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-body-rows-25-cells-3-cell-icon","e":"click","c":"iconc6"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.0-usersTable-table-body-rows-25","e":"click","c":"id25c7"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-body-rows-26-cells-3-cell-icon","e":"click","c":"iconc8"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.0-usersTable-table-body-rows-26","e":"click","c":"id26c9"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-topToolbars-toolbars-1-headers-49-header-orderByLink","e":"click","c":"orderByLinkca"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-topToolbars-toolbars-1-headers-50-header-orderByLink","e":"click","c":"orderByLinkcb"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorListener.1-usersTable-table-topToolbars-toolbars-1-headers-52-header-orderByLink","e":"click","c":"orderByLinkcc"});; Wicket.Ajax.ajax({"u":"./users?2-5.IBehaviorLis When everything is working the markup and javascript ids align. When it fails, it looks like the previous javascript remains (hence why the row listener is failing) So, the (new) question I have is, where/how does the JavaScript and markup get associated and why can't the newly generated ids be found (yet on a resort they can). Some possibly (not) important points. The table resides in an extension to Panel which is added to a page. I am using Wicket 6.8.0 Any help/pointers would be appreciated. dl -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/AjaxFallbackDefaultDataTable-cell-not-receiving-event-after-sorting-tp4659277p4659294.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org