AutoCompleteTextField and change AjaxFormComponentUpdatingBehavior

2016-01-20 Thread Zbynek Vavros
Hi, in our project we have an AutoCompleteTextField with AjaxFormComponentUpdatingBehavior ("change" event) attached. Small prototype I did proves that HTTP POST is done when an item is selected from choices (either by mouse or keyboard). But for some reason the same code doesn't work in our proj

Re: AutoCompleteTextField and change AjaxFormComponentUpdatingBehavior

2016-01-21 Thread Zbynek Vavros
; when you navigate to another form field. If this is the issue then try by > using OnChangeAjaxBehavior instead of AjaxFormComponentUpdatingBehavior. > > Martin Grigorov > Wicket Training and Consulting > https://twitter.com/mtgrigorov > > On Wed, Jan 20, 2016 at 2:44 PM, Zbynek V

Re: AutoCompleteTextField and change AjaxFormComponentUpdatingBehavior

2016-01-21 Thread Zbynek Vavros
gt; Martin Grigorov > Wicket Training and Consulting > https://twitter.com/mtgrigorov > > On Thu, Jan 21, 2016 at 9:48 AM, Zbynek Vavros > wrote: > > > Hey, > > > > sorry for not explaining properly... > > I already tried that and in this case the the ajax call

Re: AutoCompleteTextField and change AjaxFormComponentUpdatingBehavior

2016-01-21 Thread Zbynek Vavros
is a sample namespace for > wicket-autocomplete). The you can use > AjaxFormComponentUpdatingBehavior("itemselected.wa"). > Please create a ticket in our JIRA! > > Martin Grigorov > Wicket Training and Consulting > https://twitter.com/mtgrigorov > > On Thu, Jan 21, 2016 at 10:27 AM, Zb

Re: AutoCompleteTextField and change AjaxFormComponentUpdatingBehavior

2016-01-21 Thread Zbynek Vavros
ier wrote: > Hi, > > well, it seems you'll have to strip down your business app until it works > as expected :P > > Have fun > Sven > > > On 21.01.2016 11:47, Zbynek Vavros wrote: > >> I'm not sure we understand each other. >> Such a behavior is

WicketTester + DateTimeField

2016-04-26 Thread Zbynek Vavros
Hi, whats the proper way to work with WicketTester and DateTimeFields ? I am using FormTester.setValue("myDateTimeField". "formattedDateTime"); is there any way using proper date instead of string (that differs with locales) ? using DateTimeField.setModelObject() or DateTimeField.setDefaultModej

Re: WicketTester + DateTimeField

2016-04-26 Thread Zbynek Vavros
at 6:01 PM, Martin Grigorov wrote: > Hi, > > WicketTester simulates browser behavior, so it sends String that is > converted to a Date by the Wicket component. > You can use tester.getRequest().setLocale(aLocale) to simulate localized > browser. > On Apr 26, 2016 4:22 PM, &

Re: WicketTester + DateTimeField

2016-04-28 Thread Zbynek Vavros
Hi, finally got to fix that test and I don't have method setLocale(aLocale) on MockHttpServletRequest. I am on Wicket 7.0.0... Zbynek On Tue, Apr 26, 2016 at 6:12 PM, Zbynek Vavros wrote: > Hey, > > good point, thanks a lot ! > I was using the inner workings of DateTex

Re: WicketTester + DateTimeField

2016-04-29 Thread Zbynek Vavros
om/mtgrigorov > > On Thu, Apr 28, 2016 at 4:52 PM, Zbynek Vavros > wrote: > > > Hi, > > > > finally got to fix that test and I don't have method setLocale(aLocale) > on > > MockHttpServletRequest. > > I am on Wicket 7.0.0... > > > > Z

DropDownChoice models

2017-01-11 Thread Zbynek Vavros
Hey, I have a DropDownChoice for list of users. I want to display user's name but bind user's ID. So far I have come to this (ugly) solution that can surely be improved: // create model with Long userId... final DropDownChoice usersDropDown = new DropDownChoice<>( "userId", Li

Re: DropDownChoice models

2017-01-11 Thread Zbynek Vavros
;userId", > userModel, User.getUsers()); > > Both approaches have advantages and disadvantages. > > Have fun > Sven > > > > On 11.01.2017 11:38, Zbynek Vavros wrote: > >> Hey, >> >> I have a DropDownChoice for list of users. I want to display user&

Re: DropDownChoice models

2017-01-11 Thread Zbynek Vavros
Hey, I dont really think so because this kind of renderer will use these ("name" and "id) as property expression from User object. And then the DropDown selection itself would be of type User as well. I want the selection to be only user's ID, not the whole User object. The whole point is just to

Re: DropDownChoice models

2017-01-12 Thread Zbynek Vavros
findOne() is called for the currently selected user only - > that's the advantage. > > Regards > Sven > > > On 11.01.2017 13:16, Zbynek Vavros wrote: > >> Hi, >> >> Im not sure I got this right but seems to me you still have to call >> "U

Calling Wicket from JS

2018-05-25 Thread Zbynek Vavros
Hey, I am using the callBackScript() of AbstractDefaultAjaxBehavior: AbstractDefaultAjaxBehavior behavior = new AbstractDefaultAjaxBehavior() { @Override public CharSequence getCallbackFunction(CallbackParameter... extraParameters) { return super.getCallbac

Re: Calling Wicket from JS

2018-05-25 Thread Zbynek Vavros
Thanks Martin, exactly what I was looking for! On Fri, May 25, 2018 at 1:54 PM, Martin Grigorov wrote: > Hi, > > You need to use POST method for your Ajax request. > See AbstractDefaultAjaxBehavior#updateAjaxAttributes() > > On Fri, May 25, 2018 at 2:41 PM, Zbynek Vavros

Lazy loading of Wizard's steps

2018-05-28 Thread Zbynek Vavros
Hi, is it possible to lazy load wizard steps? I got a List that is initialized empty, filled in step1 and then printed in step2. But I can see that step2's constructor is being called when the wizard is constructed and getting empty list before it can be filled in step1. Thanks, Zbynek

Re: Lazy loading of Wizard's steps

2018-05-29 Thread Zbynek Vavros
I've played around with models but no success. DynamicWizardStep did the trick. Maybe one more question, is it possible to hide/change title of wizard buttons? Ideally in per-wizard fashion so I can customize each wizard in our app. Thanks On Tue, May 29, 2018 at 9:36 AM, Sven Meier wrote: >

Re: Lazy loading of Wizard's steps

2018-05-29 Thread Zbynek Vavros
> > Have fun > Sven > > Am 29. Mai 2018 09:40:42 MESZ schrieb Zbynek Vavros < > zbynekvav...@gmail.com>: > >I've played around with models but no success. > >DynamicWizardStep did the trick. > > > >Maybe one more question, is it possible to hi

Paint UI before starting long running task

2018-05-30 Thread Zbynek Vavros
Hi, I got a wizard and one of its steps display loading image while processing long running task. After this task JavaScript is being called. I've put the code into render renderHead() method of the step itself: @Override public void renderHead(IHeaderResponse response) { // process task

Re: Paint UI before starting long running task

2018-05-30 Thread Zbynek Vavros
anel's renderHead(). > > On Wed, May 30, 2018 at 3:05 PM, Zbynek Vavros > wrote: > > > Hi, > > > > I got a wizard and one of its steps display loading image while > > processing long running task. After this task JavaScript is being called. > >

Re: Paint UI before starting long running task

2018-05-30 Thread Zbynek Vavros
I could use onAfterRender() but I can't call JS from that. On Wed, May 30, 2018 at 5:00 PM, Zbynek Vavros wrote: > Hey, > > this is weird, I can see the Ajax loading during renderHead() processing > and then switch to my loading. > > Maybe I could describe what I'm

Re: Paint UI before starting long running tasked

2018-05-31 Thread Zbynek Vavros
Grigorov wrote: > On Wed, May 30, 2018 at 6:00 PM, Zbynek Vavros > wrote: > > > Hey, > > > > this is weird, I can see the Ajax loading during renderHead() processing > > and then switch to my loading. > > > > Maybe I could describe what I'm doing in mo

Ajax and async task

2018-06-20 Thread Zbynek Vavros
Hi, I've got an AjaxButton and hidden panel with progress bar and status message which is hidden in the beggining. My idea is to display the panel when the button is clicked and span long task. This task would update a counter that the progress will display using AjaxSelfUpdatingTimerBehavior. Th

Re: Ajax and async task

2018-06-20 Thread Zbynek Vavros
70/antilia-bits/tree/master/bgprocess > > On Wed, Jun 20, 2018 at 11:13 AM, Zbynek Vavros > wrote: > > > Hi, > > > > I've got an AjaxButton and hidden panel with progress bar and status > > message which is hidden in the beggining. > > My idea is to displ

Re: Ajax and async task

2018-06-20 Thread Zbynek Vavros
d, Jun 20, 2018 at 12:05 PM, Zbynek Vavros > wrote: > > > Still the same: > > > > org.apache.wicket.WicketRuntimeException: There is no application > attached > > to current thread pool-XX-thread-XX > > > > Zbynek > > > > > > >

Re: Ajax and async task

2018-06-20 Thread Zbynek Vavros
, Maxim Solodovnik wrote: > "There is no application attached to current thread" error is usually mean > Application.get() is not working > > On Wed, Jun 20, 2018 at 4:21 PM Zbynek Vavros > wrote: > > > Yeah the difference (from what I see) is th

Re: Ajax and async task

2018-06-20 Thread Zbynek Vavros
gprocess/src/main/java/com/antilia/task/TasksRunnable.java#L28 > > On Wed, Jun 20, 2018 at 12:10 PM, Ernesto Reinaldo Barreiro < > reier...@gmail.com> wrote: > > > Did you look at > > > > https://github.com/reiern70/antilia-bits/tree/master/bgprocess > > >

Wicket 8.1.0 changelog

2018-09-18 Thread Zbynek Vavros
The changelog in https://wicket.apache.org/start/wicket-8.x.html#change-log says " The change log is not available at the current state of the development process.". Since 8.1.0 was just released... or is there another place to look for changelog for 8.1.0 ? Zbynek

Re: Wicket 8.1.0 changelog

2018-09-18 Thread Zbynek Vavros
8.1.0/CHANGELOG-8.x > > On Tue, Sep 18, 2018 at 11:49 AM Zbynek Vavros > wrote: > > > The changelog in > > https://wicket.apache.org/start/wicket-8.x.html#change-log > > says " The change log is not available at the current state of the > > development proc

Re: [VOTE] drop wicketstuff-editable-grid

2018-11-24 Thread Zbynek Vavros
Hi, I have never used this module myself with Wicket but I did with my previous stack. And can surely imagine scenario to use it today! Can you please explain a bit what is the idea behind dropping this module? If its only in keeping it up-to-date with Wicket core version, isn't it enough to just

Re: [VOTE] drop wicketstuff-editable-grid

2018-11-24 Thread Zbynek Vavros
ne by one > If someone uses module - no problem, I'll search for other modules :) > > WBR, Maxim > (from mobile, sorry for the typos) > > On Sat, Nov 24, 2018, 18:40 Zbynek Vavros > > Hi, > > > > I have never used this module myself with Wicket but I did with m

Re: Wicket Spring boot versus actuator (wicket 8.2.0) + spring security (boot 2.1.2)

2019-01-24 Thread Zbynek Vavros
Hi, I did similar thing, the trick here is to use two WebSecurityConfigurerAdaptes. Zbynek On Thu, Jan 24, 2019 at 2:55 PM nino martinez wael < nino.martinez.w...@gmail.com> wrote: > Hope its okay to use the wicket user mailing list for this:) > > First of all thanks to MarcGiffing for making t

Re: Wicket Spring boot versus actuator (wicket 8.2.0) + spring security (boot 2.1.2)

2019-01-24 Thread Zbynek Vavros
rmitAll() > .and() > .logout() > .permitAll(); > http.headers().frameOptions().disable(); > > > On Thu, Jan 24, 2019 at 3:06 PM Zbynek Vavros > wrote: > > > Hi, > > > > I did similar thing,

Re: Wicket Spring boot versus actuator (wicket 8.2.0) + spring security (boot 2.1.2)

2019-01-24 Thread Zbynek Vavros
ilsService userDetailsService() { > InMemoryUserDetailsManager manager = new > InMemoryUserDetailsManager(); > manager.createUser( > User.withUsername("admin") > > .password(passwordEncoder().encode("admin")).authorities("USER

Re: Wicket Spring boot versus actuator (wicket 8.2.0) + spring security (boot 2.1.2)

2019-01-24 Thread Zbynek Vavros
d")); > } > > @Override > protected void onSubmit() { > AuthenticatedWebSession session = AuthenticatedWebSession.get(); > if (session.signIn(username, password)) { > setResponsePage(HomePage.class); > } else { > error("Login failed"); > } > }

Re: Wicket Spring boot versus actuator (wicket 8.2.0) + spring security (boot 2.1.2)

2019-01-25 Thread Zbynek Vavros
ed by basic auth)? Also every > wicket page which requires authentication should redirect to /login page if > you either lack permissions or arent logged in.. > > -Nino > > > > On Fri, Jan 25, 2019 at 8:18 AM Zbynek Vavros > wrote: > > > Took me some time to understand as

Internationalization

2019-01-27 Thread Zbynek Vavros
Hi, I'm trying to provide custom properties file for Wicket application. I was going to use BundleStringResourceLoader using getResourceSettings().getStringResourceLoaders().add(new BundleStringResourceLoader("MyWicketApplication")). Then I replaced "Required" message with my message it is not

Re: Internationalization

2019-01-27 Thread Zbynek Vavros
efaults. > > If this is not the case then use .add(0, new Bundle) and it will be > consulted first. > > > On Mon, Jan 28, 2019, 00:10 Zbynek Vavros > > Hi, > > > > I'm trying to provide custom properties file for Wicket application. >

Validation message parameters and internationalization

2019-01-28 Thread Zbynek Vavros
So I am using localized version of validation message for required fields Required=My custom message for field '${label}' but the resulting message contains field ID as parameters and result is i.e. "My custom message for field 'password'" since the whole page is not in English I would like to

WicketTester and stateless component

2019-02-03 Thread Zbynek Vavros
I have simple page for displaying messages: @MountPath("/wicket/page/error") public class ErrorPage extends WebPage { private String message; public ErrorPage() { this(null); } public ErrorPage(String msg) { if(StringUtils.hasText(msg)) { this.message

Re: WicketTester and stateless component

2019-02-03 Thread Zbynek Vavros
> setStatelessHint(false); > } else { > this.message = getString("sapi2.page.error.default_message"); > } > > Have fun > Sven > > > Am 03.02.19 um 16:20 schrieb Zbynek Vavros: > > I have simple page for displaying messages:

Model map with enum as a key

2019-02-04 Thread Zbynek Vavros
I got this class that has map with enums as keys: public class MasterClass { private Map config = Maps.newHashMap(); } enum is classic: public enum MyEnum { VALUE1, VALUE2 } now I would like to use one entry of this map as a model for TextField: new RequiredTextField<>("componentI

Re: Model map with enum as a key

2019-02-04 Thread Zbynek Vavros
Meillet wrote: > use MyEnum.valueOf("your string ») before saving the data > > François > > > > > Le 4 févr. 2019 à 13:51, Zbynek Vavros a écrit > : > > > > I got this class that has map with enums as keys: > > > > public class Maste

Wicket and material theme

2019-03-05 Thread Zbynek Vavros
Hi, for a new project we would like to use (hopefully) well known material design. After some discussion we discarded using any popular JS frameworks. Since most of us work with Wicket for quite some time and we all like it we would like to stick with it. Now would be the recommended way to use m

Re: Wicket and material theme

2019-03-06 Thread Zbynek Vavros
"bootstrap" theme is available by default. How to add new theme into provider? Thanks, Zbynek On Wed, Mar 6, 2019 at 9:51 AM Martin Grigorov wrote: > Hi, > > On Wed, Mar 6, 2019 at 1:36 AM Zbynek Vavros > wrote: > > > Hi, > > > > for a new project

Re: Wicket and material theme

2019-03-08 Thread Zbynek Vavros
Excelent! Thanks On Thu, Mar 7, 2019, 6:59 AM Martin Grigorov wrote: > Hi, > > On Thu, Mar 7, 2019 at 12:14 AM Zbynek Vavros > wrote: > > > Hi Martin, > > > > sorry if the message understood was to put this project in a bad light, > not > > at all!

Lazy modal window

2019-03-11 Thread Zbynek Vavros
Hi, I see content of modal windows being created even before the window was displayed. Is proper way to make this lazy by using AjaxLazyLoadPanel in ModalWindow.setContent ? Thanks

Re: Lazy modal window

2019-03-11 Thread Zbynek Vavros
ote: > Hi, > > On Mon, Mar 11, 2019 at 11:51 AM Zbynek Vavros > wrote: > > > Hi, > > > > I see content of modal windows being created even before the window was > > displayed. > > Is proper way to make this lazy by using AjaxLazyLoadPanel in > > Moda

Re: Lazy modal window

2019-03-11 Thread Zbynek Vavros
r 11, 2019 at 1:17 PM Martin Grigorov wrote: > On Mon, Mar 11, 2019 at 2:07 PM Zbynek Vavros > wrote: > > > Let's say modal windows does some quite expensive query and user never > > displays this window. > > In this case the query will be done even when not need

Re: Lazy modal window

2019-03-11 Thread Zbynek Vavros
osedCallback(target -> modal2.setContent(new > WebMarkupContainer(modal2.getContentId())) ); > modal2.show(target); > } > > Have fun > Sven > > > Am 11.03.19 um 17:20 schrieb Zbynek Vavros: > > Well for me the code in content's panel is executed wh

DropDownChoice - choices type vs model type

2019-07-01 Thread Zbynek Vavros
Hi, I don't have any specific use-case for this but I'm interested on how to do this properly. There is a DropDownChoice that displays list of Batches. Now the display option should be "id" and "name" concated together and the DropDownChoice selection model will be only the name. Batch is simple

Re: DropDownChoice - choices type vs model type

2019-07-01 Thread Zbynek Vavros
wn class file so it won't hurt so much :P. > > Have fun > Sven > > > On 01.07.19 14:45, Zbynek Vavros wrote: > > Hi, > > > > I don't have any specific use-case for this but I'm interested on how to > do > > this properly. > > > > There

Re: DropDownChoice - choices type vs model type

2019-07-01 Thread Zbynek Vavros
; Tobias > > > Am 01.07.2019 um 21:19 schrieb Zbynek Vavros : > > > > I don't want DTO - entity relation, the idea here is to make clear > > separation of JPA entities and DTOs that can be send over REST/RMI > > call/serialized. > > > > So you don&#x

Re: Wicket tests with Spring Boot

2019-07-10 Thread Zbynek Vavros
Not sure if it helps or it is what are you looking for but this is how I do it. I have abstract base class that - sets Wicket application into Spring ApplicationContext - creates WicketTester - uses static configuration class to create mocks of required Spring components in ApplicationContext that

DataTable and SelectAll checkbox

2019-07-17 Thread Zbynek Vavros
Hi, I know this is quite old but since I do migration to Wicket8 now I think if there is any "nice" way to do this. The thing is we have this "mighty" checkbox in the header of a checkbox column. For now we use jQuery but for sure there has to be better way. >From what I have found the best way

Re: DataTable and SelectAll checkbox

2019-07-18 Thread Zbynek Vavros
ckGroupPage.java > > That's the trick. > > Have fun > Sven > > > On 17.07.19 20:15, Zbynek Vavros wrote: > > Hi, > > > > I know this is quite old but since I do migration to Wicket8 now I think > if > > there is any "nice" way to do thi

Re: DataTable and SelectAll checkbox

2019-07-18 Thread Zbynek Vavros
/compref/CheckGroupPage.java > > > > That's the trick. > > > > Have fun > > Sven > > > > > > On 17.07.19 20:15, Zbynek Vavros wrote: > > > Hi, > > > > > > I know this is quite old but since I do migration to Wicket8 now

Re: DataTable and SelectAll checkbox

2019-07-18 Thread Zbynek Vavros
My bad, using Sven's example it works fine, my app wasn't reloaded properly. Zbynek On Thu, Jul 18, 2019 at 3:21 PM Zbynek Vavros wrote: > Hey Ilia, > > I am quite aware about this and we do something similar, I was just > wondering is there is "native" Wic

Re: Programmatic creation of messages with nested components

2019-07-25 Thread Zbynek Vavros
How about using org.apache.wicket.markup.IMarkupResourceStreamProvider ? Zbynek On Thu, Jul 25, 2019 at 6:48 AM Martin Terra < martin.te...@koodaripalvelut.com> wrote: > Hi! > > Can you show an example of solution now vs. solution after change, what are > the benefits of such visibility change t

StringResourceModel parameter and AJAX update

2020-01-21 Thread Zbynek Vavros
Hi, just simple use-case but I can't figure it out. I have DropDownChoice that selects User and Label having StringResourceModel where the parameter (new StringResourceModel(...).setParameter(selectedUser)) is the selected user. How do I update the Label's model so that it reflects User selected

Re: StringResourceModel parameter and AJAX update

2020-01-22 Thread Zbynek Vavros
del { > getObject() { > return selectedUser; > } > } > > as parameter. If you are using wicket 7.x then instead of IModel you could > use an AbstractReadonlyModel > > On Tue, Jan 21, 2020 at 11:31 PM Zbynek Vavros > wrote: > > > Hi, > >

Re: StringResourceModel parameter and AJAX update

2020-01-22 Thread Zbynek Vavros
t; } > > as parameter. If you are using wicket 7.x then instead of IModel you could > use an AbstractReadonlyModel > > On Tue, Jan 21, 2020 at 11:31 PM Zbynek Vavros > wrote: > > > Hi, > > > > just simple use-case but I can't figure it out. > > &

Stateless page with AjaxSelfUpdatingTimerBehavior

2020-06-23 Thread Zbynek Vavros
Hi, We have a page with AjaxSelfUpdatingTimerBehavior and now one of our customers is complaining about "weird" behavior when this page is opened in multiple browser tabs (yeah yeah we told him not to do it...). What happens is that after opening this page in new tab, the previous tab gets ajax r

Page with AjaxSelfUpdatingTimerBehavior in multiple browser tabs

2020-07-28 Thread Zbynek Vavros
Hi, We have a page with AjaxSelfUpdatingTimerBehavior and now one of our customers is complaining about "weird" behavior when this page is opened in multiple browser tabs (yeah yeah we told him not to do it...). What happens is that after opening this page in new tab, the previous tab gets ajax r

Re: Page with AjaxSelfUpdatingTimerBehavior in multiple browser tabs

2020-07-28 Thread Zbynek Vavros
artin Grigorov wrote: > Hi, > > On Tue, Jul 28, 2020 at 11:09 AM Zbynek Vavros > wrote: > > > Hi, > > > > We have a page with AjaxSelfUpdatingTimerBehavior and now one of our > > customers is complaining about "weird" behavior when this page is opened