Deployment models (was: Re: Wicket job market)

2013-02-04 Thread Emmanouil Batsis (Manos)

On 02/04/2013 02:05 PM, Philippe Demaison wrote:

What needs to be improved to get a wider adoption of Wicket ?


That is probably the most relevant subject IMHO.

FWIW, a largely disruptive factor is a new but increasingly important 
business/deployment model, that of the cross-domain, embedded 
client-side app.


Imagine you have an webapp that does XYZ and you offer that as a 
service. You may want to allow your clients to embed this functionality 
using Ajax+JSONP+cross domain (VS an iframe), i.e. embed your app by 
offering a pure javascript client. That's what I'm currently missing 
from wicket. This actually forces me to largely rewrite app by exposing 
REST interfaces and patching up a REST javascript client from scratch 
using something like backbone.js.


Just my 0.25.

Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Theoretical Q: JQuery client-only/RPC app?

2012-10-26 Thread Emmanouil Batsis (Manos)


Now that wicket uses jquery, would it be possible to implement a 
jquery/client-only app for a wicket backend?


To be more specific, I am asking mainly about the possibility of 
producing a javascript-only application client for a wicket6 app/json 
RPC backend.



Thanks,

Maons

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Help migrating page mounts to 1.5

2012-08-06 Thread Emmanouil Batsis (Manos)

Hello,

I've spent a couple of days migrating 1.4 code to compile with 1.5. The 
docs have been helpfull but I'm stuck and would appreciate if someone 
could point out what i am missing tryint ot migrate this:


//-
mount(new IndexedParamUrlCodingStrategy(/item, ItemViewPage.class));
mount(new IndexedParamUrlCodingStrategy(/itemreport,
 ItemTemplateViewPage.class));
MixedParamUrlCodingStrategy newItemUrls =
new MixedParamUrlCodingStrategy(/newItem,
NewItemPage.class,
new String[]{spaceCode}
);
mount(newItemUrls);


into this:
//-
mountPage(/item/${0}, ItemViewPage.class);
mountPage(/itemreport/${0}, ItemTemplateViewPage.class);
mountPage(/newItem/${spaceCode}, NewItemPage.class);

The exceptions I get are NPEs when looking for a constructor with a 
single param's argument that however exists and is public:


org.apache.wicket.WicketRuntimeException: Can't instantiate page using 
constructor 'public 
gr.abiss.calipso.wicket.NewItemPage(org.apache.wicket.request.mapper.parameter.PageParameters)' 
and argument 'spaceCode=[TTAOS]'. Might be it doesn't exist, may be it 
is not visible (public).
	at 
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:196)
	at 
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:99)
	at 
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:47)
	at 
org.apache.wicket.DefaultMapperContext.newPageInstance(DefaultMapperContext.java:107)
	at 
org.apache.wicket.request.handler.PageProvider.resolvePageInstance(PageProvider.java:264)
	at 
org.apache.wicket.request.handler.PageProvider.getPageInstance(PageProvider.java:165)
	at 
org.apache.wicket.request.handler.render.PageRenderer.getPage(PageRenderer.java:78)
	at 
org.apache.wicket.request.handler.render.WebPageRenderer.renderPage(WebPageRenderer.java:105)
	at 
org.apache.wicket.request.handler.render.WebPageRenderer.respond(WebPageRenderer.java:224)
	at 
org.apache.wicket.request.handler.RenderPageRequestHandler.respond(RenderPageRequestHandler.java:167)
	at 
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:784)
	at 
org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)
	at 
org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:255)
	at 
org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:212)
	at 
org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:283)
	at 
org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:188)
	at 
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:244)
	at 
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
	at 
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
	at 
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
	at 
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)

at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
	at 
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)

at 
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at 
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
	at 
org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
	at 
org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)

at 
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at 
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
	at 
org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:928)

at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:549)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
	at 
org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
	at 
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)

Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
	at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)

at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
	at 
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:173)


Re: igor's select2 script

2012-05-13 Thread Emmanouil Batsis (Manos)

On 05/13/2012 05:45 PM, Uwe Schäfer wrote:

On 05/09/2012 09:23 PM, Dan Retzlaff wrote:

Here you go, Uwe (and all): https://github.com/dretzlaff/wicket-select2



thanks a lot. i'll provide feedback as soon as i have tweaked it work
with 1.4.


pls share that when you do, wanted to have a go but haven't managed to 
get the time...


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: igor's select2 script

2012-05-09 Thread Emmanouil Batsis (Manos)



this is cool! Any chance it works with wicket 1.4.x?

Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: reload model each time

2012-04-14 Thread Emmanouil Batsis (Manos)

On 04/14/2012 03:03 PM, Christoph Leiter wrote:

Here's a good article about EntityModel, which does what you want:

http://wicketinaction.com/2008/09/building-a-smart-entitymodel/


Sorry for jumping in but wanted to make sure I get this right. In the 
example given above, does it make sense to conditionally set the entity 
to null within detach() based on whether the object has been persisted 
(i.e. id != null in my case) or not?


My intention is to serialize the model object when that not yet 
persisted to handle multistep create forms etc., making this a generic 
model implementation for al my CRUD operations.


Manos



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Handling nested form submission on enter

2012-04-11 Thread Emmanouil Batsis (Manos)


I have a nested form that works as expected when it's submit button (an 
IndicatingAjaxButton) is pressed but not when the user presses the enter 
key when one of it's form fields is focused. Is it possible to capture 
this enter key press to trigger the nested form's submit instead?


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Handling nested form submission on enter

2012-04-11 Thread Emmanouil Batsis (Manos)

On 04/11/2012 04:14 PM, Andrea Del Bene wrote:

already tried form setDefaultButton method (see JavaDoc)?


Thanks, I just did and the flow is the one desired, but for some reason 
the nested form field models are not updated with the field inputs when 
the submit buttons onSubmit() is called. Is there something obvious I 
might be missing?


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Handling nested form submission on enter

2012-04-11 Thread Emmanouil Batsis (Manos)

On 04/11/2012 05:39 PM, Andrea Del Bene wrote:

Well, I couldn't say why it doesn't work. Can you post some code of your
nested forms?


Sort of found what the problem is but have no clue on how to solve it. 
Pressing enter in one of the nested forms submits the last nested form 
in the page.


Each form is within a custom FormComponentPanel I made to implement a 
widget, but it seems the nested forms are mixed up if more than one of 
these are used in the same page. Each of these FormComponentPanels is an 
instance of my MultipleValuesTextField:


http://code.google.com/p/calipso/source/browse/trunk/calipso-war/src/main/java/gr/abiss/calipso/wicket/components/formfields/MultipleValuesTextField.java

 Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Handling nested form submission on enter

2012-04-11 Thread Emmanouil Batsis (Manos)

On 04/11/2012 07:53 PM, Andrea Del Bene wrote:

It's like if JavaScript can't tell apart a form from another. Can you
check the HTML generated for your page and see if forms have an unique id?


Checked, the IDs are unique. I couldn't figure out what the actual 
problem is so, to bypass it, I just added this to intercept the enter 
key and explicitly use my nested form's submit:



final TextFieldString newValueField =
		new TextFieldString(newValueField, new 
PropertyModel(newSubFieldValues, [ + index + ])){

@Override
protected void onComponentTag(ComponentTag tag){
super.onComponentTag(tag);
tag.put(onkeypress, if(event.keyCode == 13) 
{document.getElementById('  + addButton.getMarkupId() + 
').click();return false;});

}
};

Hope this helps someone else with nested forms and the enter key.

Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



HOWTO to only skip required validators

2012-03-31 Thread Emmanouil Batsis (Manos)


I have a usecase for saving a draft of a form before actually submitting it.

I'm trying to figure out how to only skip the required validators 
using a save draft submit button in my form. Disabling default form 
processing sounds like using a bazooka to shoot down a fly considering 
my form has a dynamic number of fields etc.


My only thought so far is to keep a reference of mandatory fields and 
call their setRequired with false within the submit button's onSubmit.


Would that work? Is there a better way?

Cheers,

Maons

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket/Spring Boilerplate

2012-03-01 Thread Emmanouil Batsis (Manos)

On 03/01/2012 02:07 AM, Michael Laccetti wrote:

Just a quick note to folks that may be interested that I've created a Maven 
archetype that ties together Wicket 1.5 and Spring 3.1, along with Hibernate 
4.1/JPA 2 and logback.  It is purely annotation driven, and has no XML 
configuration files.  Currently, users must clone the git repository [1] to use 
the archetype, but it should be hosted on Sonatype's OSS Nexus shortly.

Questions and comments appreciated.  :)


Michael, I have an app on  wicket 1.4.x, spring 2.5.x and *non-JPA* 
hibernate 3.5.x. Without taking wicket or other API changes into 
account, can you suggest whether or even how this archetype could be 
helpful in migrating to 1.5/3.1/4.1 and perhaps JPA later on? I wouldn't 
want to migrate to JPA right now.


Many thanks for the archetype in any case!

Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Howto go for editable grid with add/remove row in wicket 1.4?

2012-02-20 Thread Emmanouil Batsis (Manos)

On 02/20/2012 03:49 AM, Emmanouil Batsis (Manos) wrote:

On 02/19/2012 10:56 PM, Jorge Rodrigez wrote:

You just need to add/remove an item to your data source.
Next time you rerender the grid it will show/hide the added/removed


Any custom datasource examples out there? Essentially I'd like to bind
the grid to a POJO collection member.


That was easy:
final ListDataProvider listDataProvider = new 
ListDataProvider(pojo.getChildren());


final DataGrid grid = new DefaultDataGrid(foo, new 
DataProviderAdapter(listDataProvider), cols);


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Howto go for editable grid with add/remove row in wicket 1.4?

2012-02-19 Thread Emmanouil Batsis (Manos)
Subject says it all... currently using inmethod from wicketstuff but 
there is no add/remove row in the 1.4.x versions.


Manos


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Howto go for editable grid with add/remove row in wicket 1.4?

2012-02-19 Thread Emmanouil Batsis (Manos)

On 02/19/2012 10:56 PM, Jorge Rodrigez wrote:

You just need to add/remove an item to your data source.
Next time you rerender the grid it will show/hide the added/removed


Any custom datasource examples out there? Essentially I'd like to bind 
the grid to a POJO collection member.


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



How to render a Tree with a preselected node?

2011-12-09 Thread Emmanouil Batsis (Manos)


Looking around the APIs and all, but haven't figured out how to have a 
LabelTree rendered with the tree expanded properly to point to a 
preselected node.


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: How to render a Tree with a preselected node?

2011-12-09 Thread Emmanouil Batsis (Manos)

On 12/09/2011 03:30 PM, Emmanouil Batsis (Manos) wrote:


Looking around the APIs and all, but haven't figured out how to have a
LabelTree rendered with the tr


To answer my own email, it's all about

// select the apropriate node, in my case a
// DefaultMutableTreeNode
tree.getTreeState().selectNode(selectedNode, true);

// call a recursive method to
// expand accordingly
expandToNode(selectedNode);

// the method can be something like
private void expandToNode(DefaultMutableTreeNode node) {
tree.getTreeState().expandNode(node);
if(!node.isRoot()){
expandToNode((DefaultMutableTreeNode) node.getParent());
}
}


I still need to figure out how to scroll into-view though, I've wrapped 
the trees into fixed-height divs.


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Tree selection form component?

2011-12-09 Thread Emmanouil Batsis (Manos)

On 12/06/2011 02:55 PM, Emmanouil Batsis (Manos) wrote:


On 11/19/2011 05:09 PM, Emmanouil Batsis (Manos) wrote:
  I was wondering if anyone has implemented a reusable component for
  handling hierarchical/dependent dropdowns as I'm thinking of having a go
  at it... I hijacked the thread as it seems relevant.

At first I was after a component that adds an arbitrary number of
chained selects (the example bellow was just that), but a tree makes a
lot more sense in many cases. Any examples of a tree used to update a
text field? I'd happily turn that to a FormComponentPanel if none is
available.


It really needs some cleanup and improvements but in case anyone needs 
to see an example:


http://code.google.com/p/calipso/source/browse/trunk/calipso-war/src/main/java/gr/abiss/calipso/wicket/components/formfields/TreeChoice.java

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Tree selection form component? (was: Re: Component for chained/dependent drop downs?)

2011-12-06 Thread Emmanouil Batsis (Manos)


On 11/19/2011 05:09 PM, Emmanouil Batsis (Manos) wrote:
 I was wondering if anyone has implemented a reusable component for
 handling hierarchical/dependent dropdowns as I'm thinking of having a go
 at it... I hijacked the thread as it seems relevant.

At first I was after a component that adds an arbitrary number of 
chained selects (the example bellow was just that), but a tree makes a 
lot more sense in many cases. Any examples of a tree used to update a 
text field? I'd happily turn that to a FormComponentPanel if none is 
available.


Manos



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Component for chained/dependent drop downs? (was: Re: Chained dropdowns)

2011-11-19 Thread Emmanouil Batsis (Manos)



On Fri, Nov 18, 2011 at 1:36 PM, Titonjyt...@gmail.com  wrote:


Hi, I'm trying to connect three drowpdowns.

For example.

combo1: Country
combo2: Province
combo3: City

I'm updating dropdowns by Ajax with
AjaxFormComponentUpdatingBehavior(onChange) and it works ok.
But if you choose a Country, then a Province, then a City and after that
you change the Country, the Province changes but not the city.

I'm doing everything with models and adding all dropdowns to
AjaxRequestTarget.



I was wondering if anyone has implemented a reusable component for 
handling hierarchical/dependent dropdowns as I'm thinking of having a go 
at it... I hijacked the thread as it seems relevant.


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Make a Palette option mandatory?

2010-10-27 Thread Emmanouil Batsis (Manos)


I'm probably missing the obvious so any help would be appreciated.

Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Job opportunity in Tahiti

2010-09-24 Thread Emmanouil Batsis (Manos)

On 09/24/2010 10:35 PM, Gabriel Landon wrote:

Our client wants a CMS, so we have chosen to use Liferay.
Liferay is a java portal, so we need to use portlets with it.
That as simple as that.

When we don't need a CMS, we just do simple wicket application.


Not that it's any of my business, but it's nice to have options. For 
example, I might go with BRIX or whatnot if the developers under 
consideration had serious experience with it ;-)


Just my 0.2.
--
Manos Batsis, Chief Technologist

 ___
   _/ /_  (_)_  __
 / __ `/ __ \/ / ___/ ___// __ `/ ___/
/ /_/ / /_/ / (__  |__  )/ /_/ / /
\__,_/_.___/_//(_)__, /_/
//
http://www.Abiss.gr
19, Kalvou Street,
14231, Nea Ionia,
Athens, Greece

Tel: +30 211-1027-900
Fax: +30 211-1027-999

http://gr.linkedin.com/in/manosbatsis


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Message resources in database?

2010-09-18 Thread Emmanouil Batsis (Manos)


How would you implement runtime translation and/or addition of messages 
by users? Couldn't find any RDBMS-based IStringResourceLoaders to look 
at or extend :-/


Manos

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Looking for inspiration/suggestions

2010-09-16 Thread Emmanouil Batsis (Manos)


Consider the task of building a wicket-based UI that allows users to map 
properties between entities (e.g. a mapping between InventoryAsset to 
SupportTicket properties), how would you do it? Some considerations are 
datatype mappings but that may or may not be relevant to the wicket 
layer. The UI will probably produce an XML file as a serialization of 
the mapping between the two entities.


I'm new to wicket and just looking on suggestions on components to use 
etc. Wouldn't say no to any time saver :-)


--
Manos Batsis, Chief Technologist

 ___
   _/ /_  (_)_  __
 / __ `/ __ \/ / ___/ ___// __ `/ ___/
/ /_/ / /_/ / (__  |__  )/ /_/ / /
\__,_/_.___/_//(_)__, /_/
//
http://www.Abiss.gr
19, Kalvou Street,
14231, Nea Ionia,
Athens, Greece

Tel: +30 211-1027-900
Fax: +30 211-1027-999

http://gr.linkedin.com/in/manosbatsis


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org