Re: Toggle AjaxEditableLabel from other component?

2012-10-15 Thread Nick Pratt
Just use a regular TextField and toggle its enabled status in the Ajax callback handler. Be sure to refresh the element (target.add( yourTextComponent ) ); or the containing form if you have multiple components to toggle. For custom bindings, take a look at AbstractDefaultAjaxBehavior and its

Re: [DISCUSS] Security Frameworks

2012-10-18 Thread Nick Pratt
[X] I use my own custom framework We rolled our own because it gave us the most flexibility (components are annotated and the permissions are kept separate from users and groups/roles). We can reconfigure the permissions on the fly (since everything is stored in the DB, cached in mem) and plug

Adding Behavior to FormComponents

2012-10-18 Thread Nick Pratt
Im trying to automate the addition of some markup on my required FormComponents. Inside a Behavior, can I access any associated label elements of a form component so that I can attach some markup, or inject an additional span tag in between the label and the input elements? If this cant be done

Re: Unit testing with Spring injected Application

2012-10-19 Thread Nick Pratt
Ill finish that email now... Im running in to a problem with unit tests when I inject my Application: @ContextConfiguration( classpath:junit-web-context.xml ) @TransactionConfiguration( transactionManager = txManager ) public class CreateFirstUserPageTest extends

Re: Unit testing with Spring injected Application

2012-10-19 Thread Nick Pratt
:46 PM, Nick Pratt wrote: java.lang.**IllegalStateException: Application name can only be set once. --**--**- To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.orgusers-unsubscr...@wicket.apache.org For additional

Re: Unit testing with Spring injected Application

2012-10-19 Thread Nick Pratt
suite, and I'd expect that to improve as I add more tests. Hope this helps. N On Fri, Oct 19, 2012 at 10:11 AM, Nick Pratt nbpr...@gmail.com wrote: No other way? Destroying the context and recreating for every unit test really slows things down. I guess I can manually set the various Beans

WiQuery 6.0

2012-10-22 Thread Nick Pratt
I added an AutocompleteAjaxComponent to a Form on a Page. While the component renders, Im not seeing any of the associated WiQuery JS bindings in the rendered page (so my getValues() method never gets invoked) - I copied the example code from the WiQuery-examples project, and that sample has the

Re: WiQuery 6.0

2012-10-22 Thread Nick Pratt
I do see the imports of jquery and jquery.ui.autocomplete (which I checked are available and served by the web server) - there's just no wiquery-gen-uniqueid script in the page On Mon, Oct 22, 2012 at 7:24 PM, Nick Pratt nbpr...@gmail.com wrote: I added an AutocompleteAjaxComponent to a Form

Re: Generically Append a JavaScript Method to all Buttons/Links Throughout App

2012-10-31 Thread Nick Pratt
Maybe you could add a Component Visitor to a Base Page (assuming you have a BasePage) and then inspect all the components that way. IVisitorComponent, Void Then based on the type of the Component being visited, attach a Behavior. N On Wed, Oct 31, 2012 at 1:57 PM, eugenebalt

Re: Generically Append a JavaScript Method to all Buttons/Links Throughout App

2012-10-31 Thread Nick Pratt
I would expect the Visitor to run after Page construction, so all Components should be ready. I use a similar technique for Form components (to add error behaviors etc) - I dont see why the IVisitor approach wouldnt work at the BasePage level as well though. N On Wed, Oct 31, 2012 at 2:50 PM,

Re: Wicket 6 and wicket push

2012-11-14 Thread Nick Pratt
, 2012 at 9:38 AM, Martin Grigorov mgrigo...@apache.orgwrote: So you basically ask to just drop wicket-native-websocket module and continue with wicket-atmosphere only ? On Wed, Nov 14, 2012 at 4:32 PM, Nick Pratt nbpr...@gmail.com wrote: Could we combine the wicket-websocket and wicket

DropDownChoice.setNullValid

2012-11-14 Thread Nick Pratt
public ListString choices = Arrays.asList(null,RENDER,ENABLE); DropDownChoiceString defaultPerm = new DropDownChoice( perm, permModel, choices ); defaultPerm.setNullValid( true ); When this renders, I see a select box with 4 options - 2 blanks, and the two text options. I expected to only see

Re: DropDownChoice.setNullValid

2012-11-14 Thread Nick Pratt
As a followup - if you dont pass the null in the choices list, then it works as expected. On Wed, Nov 14, 2012 at 5:35 PM, Nick Pratt nbpr...@gmail.com wrote: public ListString choices = Arrays.asList(null,RENDER,ENABLE); DropDownChoiceString defaultPerm = new DropDownChoice( perm, permModel

Re: Asking for user confirmation - Wicket 6

2012-11-16 Thread Nick Pratt
Thanks - I noticed that also - the wiki entry has the correct code. Nick On Fri, Nov 16, 2012 at 4:26 AM, Dieter Tremel tre...@tremel-computer.dewrote: Am 15.11.2012 18:47, schrieb Sven Meier: ajaxCallListener.onPrecondition(return confirm('are you sure'?);); I made a test and found the

Re: Force Ajax onClick event on empty a

2012-11-23 Thread Nick Pratt
Try putting a non-breaking space in there: anbsp;/a On Fri, Nov 23, 2012 at 6:41 AM, ronny.v...@consult.nordea.com wrote: Hi all I seem to struggle more than expected on this scenario: An empty A tag wont trigger Ajax HTML is pretty simple span class=myIcon id=id3192 a

RE: Ideas on implementing dynamic addition of components that use AJAX?

2012-11-24 Thread Nick Pratt
Chris Ive been following this thread with interest - what is the use case that drives your need to add components dynamically - why can't you just add a SytemPanel in the panel constructor - is your HTML markup being generated outside of your Wicket app? N On Nov 24, 2012 1:26 AM, Chris Colman

Re: Behavior.renderHeader being invoked twice

2012-11-25 Thread Nick Pratt
Any thoughts on why Im seeing two invocations of the renderHead method? On Wed, Nov 21, 2012 at 12:14 PM, Nick Pratt nbpr...@gmail.com wrote: I've created a custom Behavior, and attached it to a DataTable. I'm seeing two invocations per Page load of myBehavior.renderHeader method, stacks

Re: Adding Components to fit markup

2012-11-27 Thread Nick Pratt
the MarkupStream yourself. On Tue, Nov 27, 2012 at 3:53 AM, Nick Pratt nbpr...@gmail.com wrote: If I create an empty element (a div) in HTML (via jQuery), and assign it an ID, is it possible to create a Wicket Panel (via an Ajax callback) to replace that element? N -- Martin

Re: a question on different data grid components available for wicket

2012-11-28 Thread Nick Pratt
Ive been working on an improved DataTables.net wrapper for Wicket. Its applied as a Behavior on top of the existing Wicket repeaters/datatables - with one caveat that the Behavior requires a table element to work with that has a complete structure - table, thead, tbody. With some assistance

Re: View and edit panel

2012-11-28 Thread Nick Pratt
You can set the Panel non-editable, and all those Form components will become non-editable. On Wed, Nov 28, 2012 at 4:06 AM, Thomas Götz t...@decoded.de wrote: Hi there, I'm currently implementing a panel that is used for viewing and editing of some entity. I wonder if there is an elegant

Re: Jqwicket

2012-11-28 Thread Nick Pratt
The current version on wiquery uses an older jquery version than does Wicket 6.3.0 which was causing issues for us. N On Nov 28, 2012 1:23 PM, vishal vrvai...@gmail.com wrote: Hi Folks - has there been any progress on JQWicket for Wicket 6.0? I am unable to upgrade to Wicket 6.3 because I am

Dynamic Components

2012-11-28 Thread Nick Pratt
Martin The approach of adding the Sub/Details Panel to a DummyPage works fine for basic Panels, but there are a few problems I've hit: 1. onInitialize() isnt called - Im assuming this is because the Panel doesnt go through a normal lifecycle before being rendered back to the ART? 2. None of the

Re: What is Atmosphere doing wrong so i cant debug the websocket

2012-11-29 Thread Nick Pratt
Are you sure web socket connection was established? Maybe your connection is long-polling. N On Nov 29, 2012 7:36 AM, MattyDE ufer.mar...@gmail.com wrote: Hi Folks, iam using Wicket 6.2.0 with Wicket-Atmosphere 0.4 and everything works great, but Iam not able to debug the websocket-transfer

Re: Dynamic Components

2012-11-29 Thread Nick Pratt
and popups. Met vriendelijke groet, Kind regards, Bas Gooren Op 28-11-2012 21:00, schreef Nick Pratt: Martin The approach of adding the Sub/Details Panel to a DummyPage works fine for basic Panels, but there are a few problems I've hit: 1. onInitialize() isnt called - Im assuming

Re: What is Atmosphere doing wrong so i cant debug the websocket

2012-11-29 Thread Nick Pratt
Its likely your web server capabilities / configuration On Thu, Nov 29, 2012 at 8:18 AM, MattyDE ufer.mar...@gmail.com wrote: How should i test this? I did no special configuration and testing it with the latest google chrome, which supports WebSockets. I think the atmosphere implementation

Re: Jetty Gzip Compression

2012-11-30 Thread Nick Pratt
httpServletResponse.setContentType(text/application) and httpServletResponse.write(someStringWithJS). GZipFilter's job is to change the content type and gzip the JS string. I recommend you to put a breakpoint in GZipFilter and see what happens. On Thu, Nov 29, 2012 at 8:30 PM, Nick Pratt nbpr...@gmail.com wrote: Ive

Re: which server?

2012-12-03 Thread Nick Pratt
Tomcat is stable, very widely used, and has lots of documentation / examples out there. Jetty also works well. We normally deploy on Tomcat (7.x now) On Mon, Dec 3, 2012 at 10:28 AM, Lucio Crusca lu...@sulweb.org wrote: Hello *, I'm approaching my 1st web application deployment (be it

Re: Upload file and display its contents using AJAX

2012-12-04 Thread Nick Pratt
Once the file is uploaded, set the contents of the IModel backing the TextArea, and then add the Form(or TextArea) to the AjaxRequestTarget. On Tue, Dec 4, 2012 at 11:51 AM, pureza pur...@gmail.com wrote: Hi, I need to upload a file, parse it and display its contents inside a textarea, all

Re: How to display PDF in wicket 6.0?

2012-12-04 Thread Nick Pratt
Do you want to display the PDF on screen, or provide a PDF download so that the file could be opened in Acrobat Reader (or PDF viewer of your choice)? On Tue, Dec 4, 2012 at 11:06 AM, appwicket wwx@gmail.com wrote: Hi all, I have been trying all the ways to display PDF through wicket. I

Re: Conditional JS includes

2012-12-07 Thread Nick Pratt
Do TextTemplate's aggregate, and can that aggregate be provided as a single Resource? N On Fri, Dec 7, 2012 at 3:28 AM, Martin Grigorov mgrigo...@apache.orgwrote: You can also use TextTemplate(s) to construct/concat the JS dynamically. On Fri, Dec 7, 2012 at 12:51 AM, Nick Pratt nbpr

Create/Edit domain object data

2012-12-07 Thread Nick Pratt
Im looking for recommendations on how to work with Form data and a JPA/Hibernate model, specifically around creating and editing domain data. I have a JPA backed domain model, and I want to create a page/panel/form that allows entry of a new Foo, as well as being able to pass an existing LDMFoo

Re: Create/Edit domain object data

2012-12-07 Thread Nick Pratt
As a followup, Ive used both approaches - although we tended to wrap the non-persisted entity inside a DomainLDM N On Fri, Dec 7, 2012 at 1:14 PM, Nick Pratt nbpr...@gmail.com wrote: Im looking for recommendations on how to work with Form data and a JPA/Hibernate model, specifically around

Form submit with CollectionChild

2012-12-10 Thread Nick Pratt
My understanding of Form submit behavior with models is that onSubmit, Wicket loads the model, and then applies all the changed form values to that model. This works fine for non-collection types (Strings, ints etc) set from all the input types Ive been using (TextField, RadioChoice, DDC etc.).

Re: Form submit with CollectionChild

2012-12-10 Thread Nick Pratt
. ~ Thank you, Paul Bors -Original Message- From: Nick Pratt [mailto:nbpr...@gmail.com] Sent: Monday, December 10, 2012 1:11 PM To: users@wicket.apache.org Subject: Form submit with CollectionChild My understanding of Form submit behavior with models is that onSubmit, Wicket

Re: Form submit with CollectionChild

2012-12-10 Thread Nick Pratt
I have an LDM that I pass in to the Panel containing the Form. I wrap the passed-in LDM IModel with a CompoundPropertyModel which I supply to the Form. All my components then use wicketid--propertyExpressions. I supply the A.b name as the Wicket Id when I construct the LV. N On Mon, Dec 10,

Re: Form submit with CollectionChild

2012-12-10 Thread Nick Pratt
can get access to it or in a Jira ticket. Hopefully in doing so you'll spot what's wrong and fix it :) ~ Thank you, Paul Bors -Original Message- From: Nick Pratt [mailto:nbpr...@gmail.com] Sent: Monday, December 10, 2012 2:21 PM To: users@wicket.apache.org Subject: Re: Form

Re: Form submit with CollectionChild

2012-12-10 Thread Nick Pratt
I just found this: http://wicketinaction.com/2008/10/building-a-listeditor-form-component/which works great. N On Mon, Dec 10, 2012 at 3:56 PM, Nick Pratt nbpr...@gmail.com wrote: Here is a quickstart: https://dl.dropbox.com/u/107816727/quickstart.tar.gz Two problems: 1. Hit add more

Re: Form submit with CollectionChild

2012-12-11 Thread Nick Pratt
It works well, but not ideal - making it work with JPA does require some tweaking to prevent the Collection being replaced (and thus Hibernate will complain about the Collection not being the one it was managing) or duplicates being created. On Mon, Dec 10, 2012 at 4:11 PM, Nick Pratt nbpr

Re: Best way to set up a handler for 'Internal error'

2012-12-25 Thread Nick Pratt
Does Application getExceptionSettings().setUnexpectedExceptionDisplay( ); help? Look at DefaultExceptionMapper (which I think you can also set in Application.init() ) N On Tue, Dec 25, 2012 at 3:15 PM, Chris Colman chr...@stepaheadsoftware.comwrote: When running in production mode and an

Re: Component to String

2013-01-24 Thread Nick Pratt
The real issue here is that most Email clients render HTML really badly, or dont render it at all (or their implementations of such rendering is just wrong). Even modern email clients, like the latest Outlook or GMail dont render significant portions of HTML/CSS correctly, and you will likely

Re: collecting JavaScripts evals to improve client side rendering times and decrease response sizes

2013-01-25 Thread Nick Pratt
Couldn't we make some of these additional optimizations part of the deployment options, similar to how other things are enabled in development vs deployment? N On Fri, Jan 25, 2013 at 8:42 AM, Martin Grigorov mgrigo...@apache.orgwrote: On Fri, Jan 25, 2013 at 3:30 PM, Ernesto Reinaldo Barreiro

Re: ReferenceError: wicketGet is not defined

2013-02-01 Thread Nick Pratt
Some examples here for 6.0: https://cwiki.apache.org/WICKET/calling-wicket-from-javascript.html On Fri, Feb 1, 2013 at 11:27 AM, Martin Grigorov mgrigo...@apache.orgwrote: wicketGet - Wicket.get() (or Wicket.$()) For Wicket 6 all such small methods were moved into Wicket.** namespace. There

Re: a loading ... something ...

2013-02-13 Thread Nick Pratt
AjaxLazyLoadingPanel or write your own async models. Look back at the recent mailing list history - someone kindly posted an example application utilizing various async loading techniques. This would be a good topic for the new ref docs! N On Wed, Feb 13, 2013 at 12:15 PM, grazia

Re: Infinite Scrolling in Wicket 6

2013-02-27 Thread Nick Pratt
Ive used Datatables (www.datatables.net) for similar features and it works pretty well. N On Wed, Feb 27, 2013 at 4:58 AM, Martin Dietze d...@fh-wedel.de wrote: I will soon have to implement infinite scrolling in my project and would thus like to know if there are already libraries or code

Re: Conditional Logic in HTML

2013-02-28 Thread Nick Pratt
, Nick Pratt nbpr...@gmail.com wrote: Should the following work with Wicket 6.5/6.6? !DOCTYPE html !--[if IE] html class=IE ![endif]-- !--[if !IE] -- html class=NOT_IE !-- ![endif]-- /html Wicket is not parsing the conditional when its around the html element itself - its failing

Re: Dynamic Sidebar

2013-03-02 Thread Nick Pratt
You can use a ListView or any of the other repeaters to achieve this. Your repeated markup will be an anchor. N On Mar 2, 2013 3:35 PM, Stephen Walsh step...@connectwithawalsh.com wrote: I want to create a sidebar panel that is dynamic based on the links attach to it. So far I have created a

Re: Dynamic Sidebar

2013-03-04 Thread Nick Pratt
This is what I started with and it's not working currently. Thanks for the help. ___ Stephen Walsh | http://connectwithawalsh.com On Sat, Mar 2, 2013 at 3:45 PM, Nick Pratt nbpr...@gmail.com wrote: You can use a ListView or any of the other repeaters to achieve

Re: Loading different ApplicationContexts(Spring) for each WicketServlet

2013-03-05 Thread Nick Pratt
You could embed Jetty inside your app (rather than deploying a war to tomcat) and run multiple copies taking a couple of command line params - namely port number and config file location. N On Mar 5, 2013 7:19 AM, MG miha.go...@gmail.com wrote: You can try with different interfaces for the

Re: ThreadLocal with ajax

2013-03-06 Thread Nick Pratt
How are you ensuring that the thread that created the page is the same one that's used to service the AJAX call? N On Mar 6, 2013 6:37 AM, Ann Baert ann.ba...@tvh.com wrote: Hi, I have a springbean with a ThreadLocal property. On the page (constructor and onBeforeRenderer) I set a value to

Re: JS execution order problem

2013-03-06 Thread Nick Pratt
Thanks - that seems to confirm the problem - delaying the Datatables JS to after the Wicket link listeners have executed will fix it, since the errors are coming from the Wicket Link Listeners not being able to find markup IDs that the Datatables JS paginates out of view. (load fires after ready

Re: JS execution order problem

2013-03-06 Thread Nick Pratt
the order of the JS of the parent and child elements? N On Wed, Mar 6, 2013 at 12:27 PM, Nick Pratt nbpr...@gmail.com wrote: Thanks - that seems to confirm the problem - delaying the Datatables JS to after the Wicket link listeners have executed will fix it, since the errors are coming from

Re: JS execution order problem

2013-03-06 Thread Nick Pratt
I logged: https://issues.apache.org/jira/browse/WICKET-5082 and added some comments with my interpretation of what's going on. N On Wed, Mar 6, 2013 at 12:31 PM, Nick Pratt nbpr...@gmail.com wrote: I take some of that back: In the initial page rendering, the Javascript is ordered as I expect

Re: Page Hierachy and Packages

2013-03-08 Thread Nick Pratt
Do the pages in your auth package inherit from your BasePage class? In your auth package pages markup, do you have wicket:extend tags? Nick On Fri, Mar 8, 2013 at 9:17 AM, David Beer david.m.b...@gmail.com wrote: Hi All I am new Wicket and like what I have found so far. My problem is that I

Re: Wicket and Stripe integration

2013-03-12 Thread Nick Pratt
This really boils down to being able to intercept the form submit action, fire off the Stripe JS, and then once that action returns, trigger the normal Wicket form submission. Can such form interception be done? On Tue, Mar 12, 2013 at 3:36 PM, Nick Pratt nbpr...@gmail.com wrote: Has anyone

Re: Tracking performance issues on requests best practices

2013-04-01 Thread Nick Pratt
We use JProfiler, but Ive also used Yourkit (both very good profilers). N On Mon, Apr 1, 2013 at 3:45 PM, Serban.Balamaci thespamtr...@gmail.comwrote: Hello guys, I'm trying to have a finer look at what is taking time on the serverside in our application. What I have so far is that I'm

Markup ID set on a container

2013-04-03 Thread Nick Pratt
Ive started to see this in my logs: 2013-04-03 14:11:31,332 WARN [http-bio-8080-exec-2] org.apache.wicket.Component - Markup id set on a component that is usually not rendered into markup. Markup id: wmcb7, component id: wmc, component tag: container. 2013-04-03 14:11:35,079 WARN

Re: Markup ID set on a container

2013-04-03 Thread Nick Pratt
() wont be there either - thus the warning. -igor On Wed, Apr 3, 2013 at 11:18 AM, Nick Pratt nbpr...@gmail.com wrote: Ive started to see this in my logs: 2013-04-03 14:11:31,332 WARN [http-bio-8080-exec-2] org.apache.wicket.Component - Markup id set on a component that is usually

Repainting repeaters - why the need for the enclosing element

2013-04-09 Thread Nick Pratt
I've never really understood this concept, and Im hoping that someone can explain: When I have a repeater, say a ListView, and I have the tags set up: div wicket:id=myRepeater ... whatever ... /div Why cant I repaint that component via Ajax? There's an ID etc. - what in Wicket forces us to

AddOrReplace with Ajax

2013-04-11 Thread Nick Pratt
I use addOrReplace fairly frequently in normal requests, but Im having trouble making this work in an Ajax request. 1. Add EmptyPanel(someId); to page 2. User clicks link, and then on the server side I do: addOrReplace(new DetailPanel(someId)); and the Details Panel appears in place of the

Re: Update ListView with Ajax, performance.

2013-04-12 Thread Nick Pratt
Id use one of various Javascript libs to implement this sort of functionality - I think select2 and datatables would both work for such a list (I think they both support infinite scrolling lists) that only render/send a page of information at a time. There's a wicket-select2 library, but its

Re: Update ListView with Ajax, performance.

2013-04-12 Thread Nick Pratt
I guess you could build something with just the core framework, but I think it would be a lot clunkier than one of the libs - for instance, on the client side JS libs, you get events that can trigger Ajax callbacks to load the next set of data while the user is scrolling through the list - since

Changes in Wicket 6.x branch related to page instantiation?

2013-04-19 Thread Nick Pratt
Has anything changed in the Wicket 6.x branch with regards to page instantiation and authentication? I had code that was working that did the following: Page page = new MyAuthProtectedPage( someParams, someIModel ); This page was then passed to a RedirectPanel, where I did this in the Panel's

Re: Changes in Wicket 6.x branch related to page instantiation?

2013-04-19 Thread Nick Pratt
There is no stack. All I see in the Exception is: org.apache.wicket.RestartResponseAtInterceptPageException Nick On Fri, Apr 19, 2013 at 9:42 AM, Martin Grigorov mgrigo...@apache.orgwrote: Show us the stacktrace. On Fri, Apr 19, 2013 at 4:36 PM, Nick Pratt nbpr...@gmail.com wrote

Re: Skip dynamically an item in populateItem of ListView

2013-04-30 Thread Nick Pratt
Surely the list is provided to the ListView (either via a List or IModelList). So just wrap that List or IModel in another IModel (LoadableDetachableModel) and then filter the List contents inside the getObject() call. N On Tue, Apr 30, 2013 at 9:21 AM, Marco Di Sabatino Di Diodoro

Re: May Ajax handlers in Wicket 6 slow down rendering?

2013-05-02 Thread Nick Pratt
Any demos of this with Wicket form components or simple click listeners ? I'd much rather a repeater have a single listener for grouped events (or maybe at the column level for tables) N On May 2, 2013 6:10 PM, Dan Retzlaff dretzl...@gmail.com wrote: Martin-G elaborated a bit on this last

Re: May Ajax handlers in Wicket 6 slow down rendering?

2013-05-03 Thread Nick Pratt
family. On Fri, May 3, 2013 at 12:15 AM, Nick Pratt nbpr...@gmail.com wrote: Any demos of this with Wicket form components or simple click listeners ? I'd much rather a repeater have a single listener for grouped events (or maybe at the column level for tables) N

Re: Redirect user in Ajax response

2013-05-06 Thread Nick Pratt
case works as expected. Enter anything for user and password. On Mon, May 6, 2013 at 11:04 AM, Nick Pratt nbpr...@gmail.com wrote: Im trying to redirect a user from an emailed link to an authenticated page. The user clicks the link, I show a page (after checking the link validity etc

Re: Adding javascript to form submit

2013-05-06 Thread Nick Pratt
Add an AjaxFormSubmitBehavior and override getPreconditionScript() (or override that for your AjaxButton) On Mon, May 6, 2013 at 11:39 AM, krishnamohank k.krishnamoha...@gmail.comwrote: I have a wicket Form and a AjaxButton on it, my requirement is to create a cookie/local storage on form

Re: Spring @Autowire not working

2013-05-11 Thread Nick Pratt
@Autowired is a Spring thing. If you want to use auto wired beans within a Wicket instantiated page (as opposed to an object instantiated inside/by the Spring container) you need to use the @SpringBean annotation (which is a Wicket provided annotation) N On Sat, May 11, 2013 at 11:27 AM,

Re: Spring @Autowire not working

2013-05-11 Thread Nick Pratt
Are your unit tests extending one of the Spring unit test base classes, or are you running with one of the Spring Junit Test runners? On Sat, May 11, 2013 at 12:12 PM, ORACLEADF ora@gmail.com wrote: Nick, you are probably right and maybe this post doesn't belong on the Wicket forum. The

Re: Spring @Autowire not working

2013-05-12 Thread Nick Pratt
OK, your test doesnt test anything Wicket related, and is purely a Spring application. In order to use Spring in a wicket app, you need to check out some of the articles on the web - Google for Wicket spring application and there are several full working examples of how to use Spring in a Wicket

Re: Introduction and some questions about Wicket

2013-06-13 Thread Nick Pratt
For 3.) here are some of our experiences: 1.) If you are building from scratch and utilizing a separate design/styling team, we found its far easier/quicker to let the CSS folks do their thing and provide static pages, which the dev team then interprets and builds towards. Most devs can read

Re: Wicket mail and pdf

2013-06-13 Thread Nick Pratt
Did you modify your pom.xml to include the PDF? In buildresources you should have something similar to: resource filteringfalse/filtering directorysrc/main/java/directory includes include**/include

Re: Wicket with Spring for IOC

2013-06-25 Thread Nick Pratt
I have the following in my web.xml: filter filter-nameWicketAppFilter/filter-name filter-classorg.apache.wicket.protocol.http.WicketFilter/filter-class init-param param-name*applicationClassName*/param-name

Re: receive non-wicket json payload via wicket website

2013-08-04 Thread Nick Pratt
Write a servlet. On Aug 4, 2013 10:35 AM, ricb r...@brinydeep.net wrote: I have a requirement to receive some json payloads via a wicket website. (I have IP and port restrictions that make it difficult to receive it elsewhere.) These payloads are unrelated to the content of the website, and

Re: Rendering conditional html tags for IE CSS targetting

2013-08-14 Thread Nick Pratt
The workaround we use is to have multiple html close tags: !--[if lt IE 7]/html![endif]-- !--[if IE 7]/html![endif]-- !--[if IE 8]/html![endif]-- !--[if gt IE 8]!--/html!--![endif]-- On Wed, Aug 14, 2013 at 7:17 AM, Robert Gründler r.gruend...@gmail.comwrote: Hi, i'm trying to use the

Re: continueToOriginalDestination issue

2013-10-02 Thread Nick Pratt
One thing to check is if your login page is stateless. If its not, and you attempt to login using your login page some time after your initially loaded the page in the browser, then the original login page displayed would have timed out and the attempted login wont succeed. Ive seen this

Re: continueToOriginalDestination issue

2013-10-02 Thread Nick Pratt
Any components on your Page that aren't stateless cause the Page containing them to be Stateful- Forms are stateful by default. Add this to your page's onInitialize() and it will help you see what's going on. Check out Wicket's StatelessForm class. @Override protected void onInitialize() {

Re: continueToOriginalDestination issue

2013-10-02 Thread Nick Pratt
No - it the login page was redisplayed. N On Oct 2, 2013 6:31 PM, shimin_q smq...@hotmail.com wrote: Just to make sure the problem I am seeing is due to the timed out Login page...when you say the original login page displayed would have timed out and the attempted login wont succeed.

Re: continueToOriginalDestination issue

2013-10-02 Thread Nick Pratt
Are you entering the URL of your main page or your login page? You also have to check if there is a continue-to-destination field set and if not you have to send your user to a default home page. N On Oct 2, 2013 8:18 PM, shimin_q smq...@hotmail.com wrote: Thanks - that sounds exactly what I

CSS include order

2013-10-23 Thread Nick Pratt
Is there a quick/simple way to ensure that our site-wide CSS is included last (as included in our BasePage.html head section), after all other Components have contributed their CSS files? N

Re: CSS include order

2013-10-24 Thread Nick Pratt
See http://wicketinaction.com/2012/07/wicket-6-resource-management/ for explanation of all of those approaches. On Wed, Oct 23, 2013 at 6:34 PM, Nick Pratt nbpr...@gmail.com wrote: Is there a quick/simple way to ensure that our site-wide CSS is included last (as included in our BasePage.html

RequestCycle with multiple handlers

2013-10-31 Thread Nick Pratt
Wicket 6.11 I have an AbstractDefaultAjaxBehavior that returns JSON in its protected void respond( AjaxRequestTarget target ) method by: requestCycle.scheduleRequestHandlerAfterCurrent( new TextRequestHandler( text/plain, UTF-8, json ) ); This ADAB is used for returning status information back

Re: RequestCycle with multiple handlers

2013-10-31 Thread Nick Pratt
you can return your JSON as part as a javaScript eval target.append(myEvalaJSON('JSON')) ? On Thu, Oct 31, 2013 at 8:35 PM, Nick Pratt nbpr...@gmail.com wrote: Wicket 6.11 I have an AbstractDefaultAjaxBehavior that returns JSON in its protected void respond( AjaxRequestTarget

Re: RequestCycle with multiple handlers

2013-10-31 Thread Nick Pratt
On Thu, Oct 31, 2013 at 5:28 PM, Nick Pratt nbpr...@gmail.com wrote: The JS component sends JSON to the server and expects JSON in response. I was stepping through the Wicket code, and it looks like I can only invoke scheduleRequestHandlerAfterCurrent once since there is only a single 'next

Component detecting Ajax update

2013-11-01 Thread Nick Pratt
Is there a way for a Component to detect if its been added to an AjaxRequestTarget? N

Re: Issue w/ Ajax and setting form containers visible in Deployment mode.

2013-11-07 Thread Nick Pratt
This functionality does work - can you put your code up on pastebin/gist/whatever so we can take a look? (Markup and Source please) On Wed, Nov 6, 2013 at 8:14 PM, Ben S br...@yahoo.com wrote: Hello, I've been trying to work on this issue for hours and have had no luck. Basically, my code

Re: Conditionally include header item when page contains ajax components

2013-11-14 Thread Nick Pratt
The javascript will only be included if your Ajax enabled component is included that in turn references the JS ResourceReference, otherwise it wont be. N On Thu, Nov 14, 2013 at 7:59 AM, Marios Skounakis msc...@gmail.com wrote: If I'm not mistaken this will cause JQuery to be included

Re: Conditionally include header item when page contains ajax components

2013-11-14 Thread Nick Pratt
Then you're doing something odd :-) If you have dependencies like this: CustomComponent -- Custom JS Reference (and this is added in the public void renderHead( Component component, IHeaderResponse response ) method) -- Wicket's JQuery JS Reference Page A (no Ajax components or components

Re: Conditionally include header item when page contains ajax components

2013-11-14 Thread Nick Pratt
basis but this would be cumbersome and error prone. So instead I used Martin's solution and conditionally render veil.js only if the headerResponse renders Wicket-Event. On Thu, Nov 14, 2013 at 5:09 PM, Nick Pratt nbpr...@gmail.com wrote: Then you're doing something odd :-) If you have

WicketTester - asserting on HTML

2013-11-21 Thread Nick Pratt
Is it possible to to make assertions on the rendered HTML of a Wicket page? Im trying to make assertions on element attributes (class contents specifically). Is this possible with WicketTester? N

Form submit without URL modification

2013-12-20 Thread Nick Pratt
Is it possible to create a form submission that hits a specific URL and doesn't modify the original URL displayed in the browser. e.g. I have a single simple Page, that has a StatelessForm on it. I hit this via http://localhost:8080/ When I hit the form submit button, the URL in the browser

Re: Teaming up remotely

2014-01-29 Thread Nick Pratt
We found the simplest way to handle this situation was to let the HTML/CSS folks design and style the page in pure HTML, no Wicket tags, with sample data they made up. They then committed their changes into the shared VCS. The designers Ive worked with in the past just didn't (or didn't want to)

ListView - onComponentTag

2014-03-10 Thread Nick Pratt
Is there any reason why onComponentTag() wouldn't be invoked on a ListView: ListViewUser users = new ListViewUser( team-members, usersModel ) { @Override protected void onComponentTag( ComponentTag tag ) { super.onComponentTag( tag ); int i = 0; } ... I set a breakpoint on 'int i =0'; but

Testing Form with AjaxSubmitLink

2014-03-13 Thread Nick Pratt
How do you submit a form via WicketTester and an AjaxSubmitLink? *HomePage.java:* public class HomePage extends WebPage { private static final long serialVersionUID = 1L; private String email; public HomePage( final PageParameters parameters ) { super( parameters ); Form form = new Form(

Re: Testing Form with AjaxSubmitLink

2014-03-13 Thread Nick Pratt
#clickLink(java.lang.String, boolean) Martin Grigorov Wicket Training and Consulting On Thu, Mar 13, 2014 at 8:06 PM, Nick Pratt nbpr...@gmail.com wrote: How do you submit a form via WicketTester and an AjaxSubmitLink? *HomePage.java:* public class HomePage extends WebPage

Re: WildCard URL strategy for E-Commerce Products

2014-03-15 Thread Nick Pratt
Mount your product details page and then use PagePatameters to extract the query params. N On Mar 15, 2014 10:44 AM, Arjun Dhar dhar...@yahoo.com wrote: Hi, for the sake of SEO. It is recommended that URL path params for a product look like: Example --

Behavior rendering

2014-05-11 Thread Nick Pratt
I have a Behavior attached to a WebMarkupContainer with a bind() method as follows: @Override public void bind( Component component ) { this.boundComponent = component; component.setOutputMarkupId( true ); component.setOutputMarkupPlaceholderTag( true );

Re: Behavior rendering

2014-05-12 Thread Nick Pratt
in the beforeRender() and afterRender(), is there anything better than adding something like: WebRequest request = (WebRequest) component.getRequest(); boolean ajax = request.isAjax(); if( ajax ) { return; } prior to appending the additional markup? On Fri, May 9, 2014 at 2:34 PM, Nick

Re: Behavior rendering

2014-05-12 Thread Nick Pratt
This works great - thank you. Nick On Sun, May 11, 2014 at 3:26 PM, Martin Grigorov mgrigo...@apache.orgwrote: Hi, See org.apache.wicket.ajax.IAjaxRegionMarkupIdProvider Martin Grigorov Wicket Training and Consulting On Fri, May 9, 2014 at 9:34 PM, Nick Pratt nbpr...@gmail.com wrote

  1   2   >