I'm not sure there is a very clean solution.
When switching to edit mode, you could set the User's Job to a new Job
instance if it is null. You don't have to reattach/reassign any form
components if you simply update the AbstractEntityModel's object. I.e. you
either do
model.getModelObject().setJo
Html does not support nested forms. Wicket works around this limitation and
allows form nesting. I think it changes the html so that the inner form
tags become span tags. This means that whenever any of the forms needs to
be posted, everything is posted since in the result html there's only one
for
In a similar case I've used a wrapper around validators which controls
whether they run or not. This way you can automatically parse the form
component tree, find all validators and wrap them in a new Validator that
runs them only if needed.
I've done this because I wanted to be able to have the s
In case your requirements for pdf generation are not very complex, you
could use FlyingSaucer (https://xhtmlrenderer.java.net/). It basically
converts html to pdf. So you can create your output in html and then
convert it to pdf using flying saucer.
On Mon, Dec 23, 2013 at 10:45 PM, Niranjan Rao
. So
it is acceptable that they update the cache even if the session has been
unbound, and when they are done they may as well be gc'ed.
Am I missing something?
Thanks
Marios
On Sun, Nov 24, 2013 at 1:13 PM, Martin Grigorov wrote:
> Hi,
>
>
> On Sat, Nov 23, 2013 at 2:11 PM,
ister a session invalidation listener, and when the session is
> invalidated, you can run some code to neatly stop and clean up your threads.
>
> Met vriendelijke groet,
> Kind regards,
>
> Bas Gooren
>
> schreef Marios Skounakis op 22-11-2013 23:45:
>
> Hi all,
&g
Hi all,
This is maybe a Spring question but as my app is a wicket app and I use
this list regularly and everyone is very helpful I thought I'd ask here
first.
I have a RequestCycleListener which during onBeginRequest() conditionally
spawns some background threads and runs them using an Executor.
rk as well.
>
> getJavaScriptLibrarySettings().setWicketAjaxReference(veilJsThatDependsOnOriginalWicketAjaxReference)
>
It's probably faster too...
>
>
> >
> > Nick
> >
> >
> > On Thu, Nov 14, 2013 at 3:04 PM, Marios Skounakis
> > wrote:
> >
> > >
es the Wicket JS libraries and is causing it to be added.
>
> N
>
>
>
> On Thu, Nov 14, 2013 at 8:56 AM, Marios Skounakis
> wrote:
>
> > Thanks Martin, this worked well.
> >
> > Sebastien and Nick, I tried the solution with
> JQueryPluginResour
nt/
>
>
> On Thu, Nov 14, 2013 at 2:59 PM, Marios Skounakis
> wrote:
>
> > If I'm not mistaken this will cause JQuery to be included whenever my js
> > reference is included. Effectively this will cause non-ajax pages to load
> > javascript which applies only
On Thu, Nov 14, 2013 at 2:04 PM, Sebastien wrote:
> Hi Marios,
>
> IMO the best way IMO is to make your js reference extending
> JQueryPluginResourceReference (wicket 6)
>
> Best regards,
> Sebastien.
>
>
> On Thu, Nov 14, 2013 at 12:20 PM, Marios Skounakis
>
Hi all,
I have a base page from which all my pages inherit. I want to conditionally
include a javascript reference (header item) if the page contains an ajax
component. The reference is a veil implementation based on BlockUI which is
redundant (and also causes a javascript error) if the page has n
An idea is to wrap the Properties object in a class of your own
implementing Map as follows:
class MyProps implements Map {
Properties props;
public void put(String key, String value) {
if (value == null) props.remove(key);
else props.put(key, value);
}
This does sound like a bug in
value to the post parameters. So I only had to use 'ep' to pass the
component's name so that AbstractDefaultAjaxBehavior#respond() can know
which component to update.
On Tue, Oct 8, 2013 at 10:49 PM, Ernesto Reinaldo Barreiro <
reier...@gmail.com> wrote:
> This link might
Hi all,
I want to implement an ajax behavior similar to
AjaxFormComponentUpdatingBehavior but which can be attached only once to a
parent container component and issue ajax calls for all contained form
components.
So what I did was extend AbstractDefaultAjaxBehavior and pretty much copy
the logic
Hi all,
I have a form with a few hundred components and I am calling
isVisibleInHierarchy for each one of them twice. The reason I am doing this
is because I am running some validations in onValidateModelObjects() and I
want them skip validations for invisible components in some cases.
None of th
Wicket has a setting that checks for missing components and throws an
exception in development but does not do so (I think it only logs a
warning) in deployment. You are actually missing component pageTitle...
On Sun, Sep 15, 2013 at 4:40 PM, William Speirs wrote:
> Turns out that Eclipse was
Hi all,
I have run into the following problem with request logger:
I have a RequestCycleListener which populates MDC (logging mapped
diagnostic context) with some custom properties such as the sessionId, the
userId, and some other stuff. The listener populates the MDC in
onBeginRequest and clears
Hi all,
I want to customize request logger to only log page requests. I.e. I don't
want resource requests, etc.
I have overridden log(RequestData rd, SessionData sd) as follows:
@Override
protected void log(RequestData rd, SessionData sd) {
if (rd.getResponseTarget() instanceof IPage
he idea is to mark the component/attributes somehow
> On Jul 27, 2013 12:04 AM, "Marios Skounakis" wrote:
>
> > Martin,
> >
> > Thanks for your answer. I'm not sure I understand though. What does mean
> > "mark any component with data-no-veil
AM, Martin Grigorov wrote:
> Hi,
>
> You may mark any component with data-no-veil attribute.
> Later you can check with: if ($(attrs.c).data("no-veil") !== null) {...}
>
>
> On Fri, Jul 26, 2013 at 1:40 AM, Marios Skounakis
> wrote:
>
> > Hi all,
> >
Hi all,
I am subscribing to the global ajax call listeners to show and hide a veil
during ajax calls. The veil is displayed during all ajax calls. I want a
way for some components / ajax behaviors to opt our from the veil.
What I'm doing now is adding an extra parameter to the ajaxAttributes and
Jeff,
What you should do is set the close/submit callback of the jquery login
popup before it's shown. This assumes that you show it using an ajax call
and not direct javascript. You should set the close callback to execute the
AjaxFormSubmitBehavior linked with the particular form that you want t
If you want to change the state of the input fields via javascript then do
what Richard said. I guess since you are using an AjaxCheckBox you want to
do it on the server side via ajax. So, here's what you need to do:
add a boolean property to the Panel (e.g. "componentsEnabled") and bind
AjaxCheck
cast
> > it to IPropertyReflectionAwareModel, get the property, and retrieve
> > validation annotations associated with it.
> >
> > -igor
> >
> >
> > On Tue, Jun 25, 2013 at 9:53 AM, Marios Skounakis
> > wrote:
> > > Hi all,
> >
Hi all,
What is the purpose of Validatable.model?
I don't seem to be able to find any usages of Validatable.getModel(),
setModel() or model...
Thanks
Marios
t 10:35 AM, Martin Grigorov wrote:
> On Mon, Jun 24, 2013 at 10:29 AM, Marios Skounakis
> wrote:
>
> > Martin,
> >
> > What I meant is that now I have my own
> > class MyInitializerStringResourceLoader extends
> > InitializerStringResourceLoader
>
>
> &
Yeah, my example is wicket 6. I believe (I may be wrong though) that the
logic is the same in 1.5.7 you just need to adapt the method calls.
On Mon, Jun 24, 2013 at 11:06 AM, grignette wrote:
> It doesn't work.
>
> You call commitBehavior.getCallbackScript() but :
>
> Multiple markers at this l
at knows exactly where is
> your resource bundle and knows how to load it.
>
>
> On Mon, Jun 24, 2013 at 10:16 AM, Marios Skounakis
> wrote:
>
> > Not sure if this is what you mean but in Application.init I replaced the
> > InitializerStringResourceLoader in
> &g
position.
It works.
Thanks
On Mon, Jun 24, 2013 at 9:09 AM, Cedric Gatay wrote:
> Hi,
> You can write your own IStringResourceLoader providing your set of
> translations and register it in front of the list through the IInitializer
> mechanism.
>
> Regards,
> Le 24 juin 2013 07:
Hi all,
I am developing a "framework" library with wicket components and utility
classes that is intended to be reused in all wicket apps developed by our
company. I wish to override some of the standard wicket messages (e.g.
wicket-extensions datatable.no-records-found=No Records Found).
I have
Here is the basic solution. I believe you can expand on this.
public class ServerSideConfirmationExamplePage extends WebPage {
Person person; // needs to be serializable
public ServerSideConfirmationExamplePage() {
this(new Person());
}
public ServerSideConfirmationExamp
o the db.
Perhaps if you use an AjaxFormSubmitBehavior instead of an
AbstractDefaultAjaxBehavior you can repost the form data after user
confirmation and avoid the need to store them in a serializable domain
object. I haven't tried this.
On Sat, Jun 22, 2013 at 12:46 AM, Marios Skounakis w
I personally like server side confirmations because they can be customized
based on the submitted data and you can use the model to customize the
confirmation. If you do it client side you need to do it in javascript and
using the component's values which is in my opinion ugly.
Usually I override
Martin,
Thank you for your replies. You are right that using
MultipartServletWebRequestImpl you can set the max size and handle the
error.
Cheers
Marios
On Fri, Jun 21, 2013 at 2:09 PM, Martin Grigorov wrote:
> On Fri, Jun 21, 2013 at 12:29 PM, Marios Skounakis
> wrote:
>
>
. What do you think?
On Fri, Jun 21, 2013 at 12:48 PM, Martin Grigorov wrote:
> On Fri, Jun 21, 2013 at 11:44 AM, Marios Skounakis
> wrote:
>
> > Actually I want to read the whole input, and increasing tomcat
> maxPostSize
> > is the solution.
> >
> > But I w
gt; On Fri, Jun 21, 2013 at 11:24 AM, Marios Skounakis
> wrote:
>
> > Some more info after further investigation:
> >
> > The problem is definitely related to tomcat maxPostSize parameter. I have
> > set this to a very small value (100) and the problem is occurrin
. getContainerRequest() is
a tomcat RequestFacade object so this is where I stopped tracing the
execution. Perhaps it's a tomcat bug. I'll go ahead and try with different
tomcat versions.
On Fri, Jun 21, 2013 at 10:40 AM, Martin Grigorov wrote:
> Hi,
>
>
> On Thu, Jun 20, 2013 at 10:1
Hi all,
I have the following problem:
- User submits form with lots of textareas via ajax
- User gets a blank page
I think (but I'm not quite sure yet) this happens when the textareas
contain so much text that either maxPostSize or connectionTimeout (submit
tries to store to db as well) are excee
This example is not quite optimized. The DetachableContactModel's
constructor is
public DetachableContactModel(Contact c)
{
this(c.getId());
}
but it should be:
public DetachableContactModel(Contact c)
{
this(c.getId());
setObject(c);
}
The way it's done
Hi all,
Is there any obvious reason why adding the same behavior instance that
implements onBeforeRender and onAfterRender cannot be used on multiple
components on the same form?
Thanks
Marios
d then can
> cleanly use that everywhere else.
>
> Carl-Eric
>
> On Thu, 30 May 2013 16:29:56 +0300
> Marios Skounakis wrote:
>
> > Hi all,
> >
> > I have what seems a rather common requirement: to be able to switch
> > form components to read-only mode on and
Hi all,
I have what seems a rather common requirement: to be able to switch form
components to read-only mode on and off in ajax updates.
The simple and clear solutions is to use the enabled property, but this
results in ugly disabled controls in the browser. And you can't really
handle this via
tains complete local disk page store. Not sure if/which containers
> provide such hooks.
>
> Dan
> On Mar 29, 2013 1:06 AM, "Marios Skounakis" wrote:
>
> > Dan, thanks for you answer.
> >
> > As you said, with the default implementation of DiskDataStore o
ession usage under
> > control.
> >
> > If Wicket clustering is new to you, also note that Wicket
> > uses RenderStrategy.REDIRECT_TO_RENDER by default. See javadoc for
> details,
> > but in short: you should configure your load balancer for sticky
> sessions.
> >
> >
Hi all,
I
'm planning to setup a terracotta tomcat cluster. The wicket site claims
that "all Wicket applications will work on a cluster automatically and
without additional work
"
.
I understand that basically since session state is kept in serializable
objects within the http session, it mostly
eier wrote:
> Seems like this is caused by WICKET-4959.
>
> Please file a Jira issue.
>
> Sven
>
>
> On 03/15/2013 09:56 PM, Marios Skounakis wrote:
>
>> Hi all,
>>
>> I am using a modal window as a substitute for messageboxes. E.g. I have a
>> few for
Hi all,
I am using a modal window as a substitute for messageboxes. E.g. I have a
few forms with an ajax submit button, and I am using the modal window to
first display a confirmation message, and if the user accepts it, to
display a success / failure message.
I am getting frequent errors in the
Yes it is. What Martin says will fix your problem.
On Thu, Mar 14, 2013 at 9:35 PM, eugenebalt wrote:
> Martin, we're already doing setOutputMarkupId(true) on both dropdowns. Is
> that one different from OutputMarkupId?
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n
Hi all,
I have created a component that extends NonCachingImage which overrides
getImageResource(). The intent was to include this in a form, and retrieve
the image data from a property of the form object.
However this does not work because Image.initModel() returns null and as a
result my compon
You probably want to override onSubmit and not onEvent. onEvent is for
handling events sent by the event mechanism, not for handling clicks...
On Wed, Feb 6, 2013 at 1:28 PM, Ondrej Zizka wrote:
> Hi all,
>
> With Wicket 1.5.9,
> I have a form with
>
>
>
> Form form
xhtml-tags.html#Wicket%2527sXHTMLtags-Elementwicket%253Aextend
> https://cwiki.apache.org/WICKET/markup-inheritance.html
>
> But if this was working for you in 5.x then I presume you do have the
> markup inheritence setup right.
>
> ~ Thank you,
>Paul Bors
> On Sat, Feb 2, 2013 at 3:52
I've seen this happen too. It's not related to inheritance. If you add a
component in code and omit it in the html file, you get different behavior
in the following cases:
- if your web.xml specifies configuration=deployment, you don't get an error
- if you web.xml specifies configuration=developm
I've considered using select2 (it looks very impressive) but I was put off
by the fact that its appearance is not consistent with the rest of the input
controls.
How do people solve this?
On Tue, Jan 15, 2013 at 6:34 PM, Paul Bors wrote:
> I gave up on the normal select in HTML and started to
rent(new ComponentRenderingRequestHandl
> er(...))
>
> This API has changed with Wicket 1.5. You may want to read its migration
> page since you migrate from older version directly to Wicket 6
>
>
> On Wed, Dec 12, 2012 at 10:51 AM, Marios Skounakis
> wrote:
>
> &
Hi Colin,
I find I am in agreement with your points about lazy loaded parts of the
data model and how this can be simplified if you use LDMs.
However, if you use LDMs for edit pages, you need to deal with concurrency
issues yourself. You cannot rely on Hibernate's optimistic concurrency
mechanism
Hi all,
I am using Wicket 1.5.8 with wicket-auth and I can across the following
problem.
I have implemented a MyWebSession extends AuthenticatedWebSession with my
own authentication, and a login page with the default loginpanel with the
remember option enabled.
All of my pages are showing the lo
Hi all,
I've recently started using wicket. I'm still examining the various ways to
do things in order to decide how to go about and implement the UI.
I've noticed (trial and error) that if you have a modal window with a page
content, it's not possible to pass values between the originating and t
58 matches
Mail list logo