Further clarification after digging deeper. Looks like it's the
onBeforeRender method that is getting called twice for page a. I think I
may have oversimplified the example. Does it make sense, given the
situation I explained, that onBeforeRender would be called twice for page a?
We are doing a
It's an instance. Specifically in my case it looks like this:
this.setResponsePage(new FormsPage());
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Calling-setResponsePage-during-Ajax-submit-tp4677132p4677137.html
Sent from the Users forum mailing list archive at Na
Let me try to elaborate a bit more with some pseudo code:
PageOne {
onInitialize() {
AjaxButton b = new AjaxButton(...) {
onSubmit() {
...
setResponsePage(PageB)
}
}
// initialize components for page one
TextField t = new TextField(.
I have the following situation:
- ajax button clicked
- request cycle begins
- the button's onSubmit method is called
- onSubmit method calls setResponsePage
- request cycle continues, *components are initialized*, etc
- request cycle ends with a response that contains an ajax-response redirect
-
I have a rather unique situation where I need to use the same page with
different properties files. Just wondering if there is any support for
this. By default properties are loaded and cached based on the class name.
My situation requires more flexibility. Also, inheritance doesn't work in
my
Brilliant - thanks
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Non-managed-CSS-tp4674080p4674082.html
Sent from the Users forum mailing list archive at Nabble.com.
-
To unsubscribe, e-mail: users-
Just wondering if there is a way to have unmanaged CSS appear last in the
HTML head. I want Wicket to include managed CSS but have the unmanaged CSS
appear last so it can contain overrides. Currently it appears at the top of
the head section. I am using Wicket 6.
--
View this message in context
Thanks for the reply. I suspect this is exactly the case we have created for
ourselves. Although we have a good grasp on the detach process I suspect
that there are places where this rule of thumb is not being followed.
Although the example I gave is somewhat fictitious, any of the LDMs we have
It's hard to give specifics as the form is very complex. I do have a general
example of a pattern prevalent throughout the form. The pseudo code goes
something like this:
// Page
class MyPage extends Page {
onInitialize() {
Panel p = PanelFactory.createPanel("myPanel", "myObject");
We are using LoadableDetachableModels heavily. The page we have created has
a lot of repeating nested sections. The repeating panels have a model chain
that leads back to the topmost LDM. The topmost LDM implements a load that
retrieves the model object from a document cache. As far as I can te
I asked this question a couple of years ago and at the time it appeared that
portlet support wasn't much of a priority. I thought I would ask again
since I am about to start a project that could really benefit from using
JetSpeed or Liferay. I see that there is a portlet project in Wicket stuff
s
The problem is that my business objects do implement serializable for another
reason. However, I don't want Wicket to serialize them. So I could remove
Serializable and see what happens but I was hoping for a way to just look at
what is getting serialized.
--
View this message in context:
http:
Thanks for the tip. I'm a little unclear on what this is telling me though.
Wouldn't this just tell me if the detach method of all my LDMs was called?
What I'm interested in determining is where my LDMs are directly referencing
objects that will inadvertantly get serialized with the LDM. For e
I would like to be able to analyze a particular Wicket page to determine
where I might be using models incorrectly. The model behind the page is a
very nested serializable object that is kept in a document cache. The idea
is to use a loadable detachable model that will retrieve the object from th
When submitting an inner form it appears that the request contains all of the
outer and inner form fields. Is this the expected behaviour? From what I
can see it appears that the outer form is submitted, and only the inner form
parameters are validated and used for model updates.
--
View this me
Maybe I'm missing something but it seems to me that the submittingComponent
parameter passed to process is just an anonymously generated class that
implements IFormSubmitter. Although it is not null when process is called,
it only gives me access to the form and whether or not default form
process
Its not so much that the user will actively be working on the form that long.
Its more a case that users can get distracted for extended periods of time
while they are working with our form. If they half finish the data entry,
then have to take a few phone calls, it wouldn't be great if they lost
I had tried that but unfortunately at the point I'm trying to make the
determination this call returns null.
Form myForm = new EasyForm("myForm") {
public void process(IFormSubmitter submittingComponent) {
// this returns null
IFormSubmitter btn
I have a form with two AjaxButtons. I need to know which button was pressed
before form validation takes place. By the time the onSubmit or onError
methods on AjaxButton are called, its to late for what I need. Is there
anything that can be done to identify the button prior to the process method
The idea would be to save the form data as work in progress in a separate
storage area. If the user's session times out they would be directed to a
page telling them that their session timed out which would give them the
option to attempt to resume the work.
I was able to bypass validation by set
Interesting but unfortunately our form is very complex with repeaters, etc.
So I don't think this would work for us.
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Auto-save-feature-tp4663517p4663522.html
Sent from the Users forum mailing list archive at Nabble.com.
I am looking at implementing an auto save feature on a form I have created.
This would save the data that the user had entered prior to their session
timing out. The form has various validations that would have to be disabled
before this could work. I have seen numerous posts around disabling
va
I am using the wicketGlobalPostCallHandler function to perform some tasks
after an AJAX post. For example, I have a composite text field that can
support a hint that is displayed in the input field. The hint is managed
using the onfocus and onblur events. When the form is submitted, the pre
hand
Considering two alternative ways to set a model:
...
final CompoundPropertyModel myModel = new
CompoundPropertyModel(myObject);
control1.setModel(myModel.bind("field1"));
control2.setModel(myModel.bind("field2"));
control3.setModel(myModel.bind("field3"));
One of the great features of wicket is the ability to allow a developer to
focus on the Java behind the pages while a designer can work on the
HTML/CSS. The object oriented nature of a wicket page complicates this
somewhat. Our pages are broken up into many panels each with their own code
and HTM
Follow up. I turned on the access valve on tomcat and I can see a request
for each JavaScript file. Each request completes in a fraction of a second,
so there is no one file that is causing the slowdown. However, about half
way through requesting the files, it seems to take a 20 to 25 second bre
I'm having a strange problem with page load times slowing down significantly.
Its strange but it seems related to the total size of the JavaScript
contribution being made to the header. We include common JavaScript
required by all of our pages in a base class (things like jquery). In total
there
My company is looking for developers with in-depth wicket experience,
preferably in Atlantic Canada or the Toronto area. This could be full-time
or contract work. The position would involve mentoring Wicket developers as
well as assisting with on-going wicket development. Anyone interested can
r
Update - I forgot to mention that my LDM is a class nested in the panel
class.
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Access-to-Page-from-LoadableDetachableModel-tp4649586p4649603.html
Sent from the Users forum mailing list archive at Nabble.com.
Update - Access the page with MyPanel.this.getPage() seems to work fine.
More testing is required but looks like I have a solution.
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Access-to-Page-from-LoadableDetachableModel-tp4649586p4649602.html
Sent from the Users f
Thank you so much Sebastien and Sven! Sebastien I altered my actual code to
put the panel on the LDM and it didn't work on the initial try. The problem
with the illegal state exception I was having seems to happen if you
construct your components in the panel constructor instead of the
onInitiali
Well I gave this approach a try but unfortunately the first time the load
method gets called the getPage method throws an illegal state exception
java.lang.IllegalStateException: No Page found for component
So I guess this means that during the construction of the panel the load is
getting called
The reason for the detachable stuff is that when the page gets serialized it
is going to serialize all the components in the page hierarchy and the
models bound to them. When that happens MyPOJO is going also get serialized
which I'm trying to avoid. In my application these objects can be very
la
But if I do that won't the panel get serialized with the loadable detachable
model? I would have to store a reference on the detachable model in order
to use it in the load method. I could mark it transient and it would be
there when the page is initially rendered but not on subsequent requests.
My quick example isn't real and perhaps a bit misleading. Actually there is
nothing special about MyModel, its just a POJO that I am wrapping up in a
detachable model. Maybe I misunderstood what you were trying to tell me.
/** Specialization of MyPage that gets the POJO from a database. */
publi
I have a situation where I need to access the page from the load method of a
loadableDetachableModel. The loadableDetachableModel is used deep down on a
panel that needs access to the page in order to access the model object. To
complicate things this page is abstract and can be extended to provi
Has support for portlets been completely dropped from wicket? I was
interested to see if I could get a simple portlet running in Liferay
- Thanks
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Portlet-Support-tp4610364.html
Sent from the Users forum mailing list ar
Good to know. I am planning on making the move some time in the coming
months and had anticipated that this may not work exactly like this in 1.5.
>From what I have described is there any reason to think this can't be done
in 1.5? Can I take "reimplement it completely" to mean that it is possibl
Follow up:
I managed to get this working with an entirely different approach. By
creating my own WebRequestCodingStrategy implementation I was able to add a
conversation id parameter to every URL that Wicket generates. Essentially
things look like this:
WebApplication class:
@Override
My intention is not to re-implement it but to extend the functionality it
offers and include the concept of a conversation. Do you mean that this is
not possible? Or that I'm just not doing it right :). Should I be
attempting to encapsulate the AjaxButton instead of inheritance?
thanks
--
View
Hmm more problems. This is definitely turning out to be more difficult than
I expected. If a component already has an Ajax behavior added, then my
behavior conflicts. Either my behavior is used and the original behavior is
affected, or vice versa. For example if I try to do this:
public class
Got it. I was overriding the wrong getCallbackURL method:
public CharSequence getCallbackUrl()
instead of:
public CharSequence getCallbackUrl(final boolean onlyTargetActivePage);
Thanks a lot!!
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Adding-extra-request-p
I appreciate all the help but still no luck. I changed things to look like
this:
DropDownChoice myDropDown = new DropDownChoice("myDropDown");
myDropDown.add(new ConversationAjaxBehavior("onchange"));
add(myDropDown);
and:
class ConversationAjaxBehavior extends AjaxEventBehavio
I gave that a try on a DropDownChoice with no success. I'm probably doing
something wrong. Here is what I tried:
I added this to the constructor of the page:
DropDownChoice myDropDown = new DropDownChoice("myDropDown");
myDropDown.add(new ConversationAjaxBehavior());
add
Thanks for the quick response. However, I'm still a bit lost. I'm currently
still using Wicket 1.4 (although upgrading to 1.5 is possible). Both of the
links in your reply take me to pages that appear to be related to Wicket 6.
They both talk about a class named "AjaxRequestAttributes" that doe
The project I am working on currently requires that we introduce the concept
of request scope using request parameters. To do this we need to add a
conversation id to any URLs that are generated by wicket controls. Does
wicket support this? So all AJAX buttons, link, drop down choices, etc will
46 matches
Mail list logo