Re: What's the difference between Check and CheckBox
thats because they are not functionally related at all. just because they both represent a checkbox doesnt mean they are functionally equivalent. CheckBox only works with a imodel while CheckGroup/Check can be used to populate a collection with arbitrary items. eg Check uses IModel while CheckGroup uses IModel> each has its own usecase space, and the two spaces do not really overlap -igor On Thu, Oct 23, 2008 at 11:16 PM, Minto van der Sluis <[EMAIL PROTECTED]> wrote: > > Hi igor, > > that's exactly where I discovered the existence of Check ;-) > > Being an almost complete newby I was surprised by the existence of 2 Classes > so closely related. That is functionally related, since as far as I can tell > from the javadoc they are not related in any way. > > regards, > > Minto > > > igor.vaynberg wrote: >> >> javadoc is your friend >> >> -igor >> >> On Wed, Oct 22, 2008 at 11:48 PM, Minto van der Sluis >> <[EMAIL PROTECTED]> wrote: >>> >>> Messing around with unittesting a CheckBox, I discovered Check as well: >>> >>>org.apache.wicket.markup.html.form.Check; >>>org.apache.wicket.markup.html.form.CheckBox; >>> >>> To me it's not very clean what the difference is, since they are both >>> attached to the same markup: >>> >>> >>> >>> Can anyone enlighten me ? >>> >>> regards, >>> >>> Minto van der Sluis >>> -- >>> View this message in context: >>> http://www.nabble.com/What%27s-the-difference-between-Check-and-CheckBox-tp20125256p20125256.html >>> Sent from the Wicket - User mailing list archive at Nabble.com. >>> >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> > > -- > View this message in context: > http://www.nabble.com/What%27s-the-difference-between-Check-and-CheckBox-tp20125256p20144821.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What's the difference between Check and CheckBox
Hi igor, that's exactly where I discovered the existence of Check ;-) Being an almost complete newby I was surprised by the existence of 2 Classes so closely related. That is functionally related, since as far as I can tell from the javadoc they are not related in any way. regards, Minto igor.vaynberg wrote: > > javadoc is your friend > > -igor > > On Wed, Oct 22, 2008 at 11:48 PM, Minto van der Sluis > <[EMAIL PROTECTED]> wrote: >> >> Messing around with unittesting a CheckBox, I discovered Check as well: >> >>org.apache.wicket.markup.html.form.Check; >>org.apache.wicket.markup.html.form.CheckBox; >> >> To me it's not very clean what the difference is, since they are both >> attached to the same markup: >> >> >> >> Can anyone enlighten me ? >> >> regards, >> >> Minto van der Sluis >> -- >> View this message in context: >> http://www.nabble.com/What%27s-the-difference-between-Check-and-CheckBox-tp20125256p20125256.html >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/What%27s-the-difference-between-Check-and-CheckBox-tp20125256p20144821.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Autoscrolling table header
Hi Wicketers, I am newbie to wicket and I want to know whether its possible to implement a DataTable which behaves like a spreadsheet. Its something like ActiveWidget datagrid as in http://www.activewidgets.com/grid/ As you can see , when we scroll , the tableheader also scrolls accordingly. Thanks in advance, umanga - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Trying to create a calendar - need some guidance
I've got an abstract calendar already coded, the only problem is that it's using a DataTable (instead of only a gridview), I have to change the code to use the gridview instead, I'll post the code tomorrow if I've got the time and you're still interested. Edgar Merino John Krasnay escribió: Uh, yeah, that's what I meant to say, just use a GridView :-) jk On Thu, Oct 23, 2008 at 05:14:42PM -0700, Igor Vaynberg wrote: all you need is a gridview. set columns to 7 and generate 30 items... -igor On Thu, Oct 23, 2008 at 1:47 PM, V. Jenks <[EMAIL PROTECTED]> wrote: Hi all. I'm trying to build a component-ized calendar that will be the centerpiece of a new application I'm working on. I built one this morning in JSP and was able to do it with very little code. I kept it simple and I'm hoping I can retro-fit the logic into a wicket page cleanly, without too much trouble. I'm a little stuck because in my JSP, I simply loop through the days and print until Saturday is reached, then I break to a new table row and continue. Doing this in Wicket seems tough because if I use a ListView, I can't be as flexible as far as throwing in a new row while looping and outputting table cells. Here's the rough idea I came up with today in JSP, can someone give me some pointers? <%@ page contentType="text/html" pageEncoding="UTF-8" %> <%@ page import="java.util.*" %> http://www.w3.org/TR/html4/loose.dtd";> <% //get parameters to change date String monthParam = request.getParameter("month"); String yearParam = request.getParameter("year"); //create calendar object Calendar cal = Calendar.getInstance(); cal.setFirstDayOfWeek(Calendar.SUNDAY); //set first day to Sunday if (monthParam != null) cal.set(Calendar.MONTH, (Integer.valueOf(monthParam)-1)); if (yearParam != null) cal.set(Calendar.YEAR, Integer.valueOf(yearParam)); //get total number of days in month int numDaysInMonth = cal.getActualMaximum(Calendar.DAY_OF_MONTH); //get current month name in English String monthName = cal.getDisplayName(Calendar.MONTH, Calendar.LONG, Locale.ENGLISH); //get current year int year = cal.get(Calendar.YEAR); //get array of day names String[] headers = {"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; %> Calendarama! <%= monthName + " " + year %> <% for (int i=0; i<7; i++) { %> <%= headers[i] %> <% } %> <% for (int i=1; i<=numDaysInMonth; i++) { //re-set calendar day in context of loop cal.set(Calendar.DAY_OF_MONTH, i); //get the day number of the week int day = cal.get(Calendar.DAY_OF_WEEK); //days without numbers count int blankDays = 0; //blank days before 1st of month? if (i == 1 && day > 1) { blankDays = day - i; //get count //loop through count and print blank day for (int x=1; x<=blankDays; x++) { %> <% } } %> <%= i %> <% if (day == Calendar.SATURDAY) { %> <% } //blank days after last day of month? if (i == numDaysInMonth && day < 7) { blankDays = 7 - day; //get count //loop through count and print blank day for (int x=1; x<=blankDays; x++) { %> <% } } } %> -- View this message in context: http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20138860.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Page Markup Inheritance Problem...
>From the testing that I have done so far. Yes. This has been such an extra ordinary find for me. It is what I call a HOWZAT!!! wicket moment !! This is such a powerful feature. Hopefully someone can give us the official description of this concept. -Richard Paul Independent Contractor Chicago Area. On Thu, Oct 23, 2008 at 8:29 PM, James Carman <[EMAIL PROTECTED]> wrote: > What if SuperPage is a page that is "concrete"? Can it display itself > without having the elements plugged in? > > On Thu, Oct 23, 2008 at 4:56 PM, Richard Paul <[EMAIL PROTECTED]> wrote: >> I ran into a similar situation last night. Not sure if this is what >> your looking for. >> >> BasePage - My Site Layout >> SuperPage - My Page Layout (e.g. a header area for what I am working with) >> SubPage - Actions ( e.g. forms for adding stuff etc.) >> >> When first navigating to SuperPage I only want to show links that the >> user needs to click on to access the different SubPages. >> >> In this case I used a in my SuperPage. I can still >> navigate to SuperPage even if I am calling the class SuperPage >> directly. >> >> Then each link in SuperPage called my SubPage class, with only the >> extra component added by the SubPage. >> >> Hope this helps. But as Igor said you have to make SuperPage have the >> in its markup. >> >> -Richard >> >> On Thu, Oct 23, 2008 at 3:37 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote: >>> just like in object inheritance your superpage would have to provide a >>> way to plug this extra component in... >>> >>> -igor >>> >>> On Thu, Oct 23, 2008 at 1:30 PM, James Carman >>> <[EMAIL PROTECTED]> wrote: Suppose I have this page hierarchy: BasePage <- SuperPage <- SubPage. In BasePage.html, I've got and in SuperPage.html I've got . Now, in SubPage.html, I can't just "override" the markup of SuperPage.html by using a . Suppose I wanted to just add in an extra component in SubPage.html and then "override" the markup for SuperPage with the markup for SubPage, but still allowing myself to extend from BasePage. I can't do that! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Page Markup Inheritance Problem...
What if SuperPage is a page that is "concrete"? Can it display itself without having the elements plugged in? On Thu, Oct 23, 2008 at 4:56 PM, Richard Paul <[EMAIL PROTECTED]> wrote: > I ran into a similar situation last night. Not sure if this is what > your looking for. > > BasePage - My Site Layout > SuperPage - My Page Layout (e.g. a header area for what I am working with) > SubPage - Actions ( e.g. forms for adding stuff etc.) > > When first navigating to SuperPage I only want to show links that the > user needs to click on to access the different SubPages. > > In this case I used a in my SuperPage. I can still > navigate to SuperPage even if I am calling the class SuperPage > directly. > > Then each link in SuperPage called my SubPage class, with only the > extra component added by the SubPage. > > Hope this helps. But as Igor said you have to make SuperPage have the > in its markup. > > -Richard > > On Thu, Oct 23, 2008 at 3:37 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote: >> just like in object inheritance your superpage would have to provide a >> way to plug this extra component in... >> >> -igor >> >> On Thu, Oct 23, 2008 at 1:30 PM, James Carman >> <[EMAIL PROTECTED]> wrote: >>> Suppose I have this page hierarchy: >>> >>> BasePage <- SuperPage <- SubPage. >>> >>> In BasePage.html, I've got and in SuperPage.html I've >>> got . Now, in SubPage.html, I can't just "override" >>> the markup of SuperPage.html by using a . Suppose I >>> wanted to just add in an extra component in SubPage.html and then >>> "override" the markup for SuperPage with the markup for SubPage, but >>> still allowing myself to extend from BasePage. I can't do that! >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Trying to create a calendar - need some guidance
Uh, yeah, that's what I meant to say, just use a GridView :-) jk On Thu, Oct 23, 2008 at 05:14:42PM -0700, Igor Vaynberg wrote: > all you need is a gridview. set columns to 7 and generate 30 items... > > -igor > > On Thu, Oct 23, 2008 at 1:47 PM, V. Jenks <[EMAIL PROTECTED]> wrote: > > > > Hi all. > > > > I'm trying to build a component-ized calendar that will be the centerpiece > > of a new application I'm working on. I built one this morning in JSP and > > was able to do it with very little code. I kept it simple and I'm hoping I > > can retro-fit the logic into a wicket page cleanly, without too much > > trouble. I'm a little stuck because in my JSP, I simply loop through the > > days and print until Saturday is reached, then I break to a new table row > > and continue. Doing this in Wicket seems tough because if I use a ListView, > > I can't be as flexible as far as throwing in a new row while looping and > > outputting table cells. > > > > Here's the rough idea I came up with today in JSP, can someone give me some > > pointers? > > > > <%@ page contentType="text/html" pageEncoding="UTF-8" %> > > <%@ page import="java.util.*" %> > > > "http://www.w3.org/TR/html4/loose.dtd";> > > <% > > //get parameters to change date > > String monthParam = request.getParameter("month"); > > String yearParam = request.getParameter("year"); > > > > //create calendar object > > Calendar cal = Calendar.getInstance(); > > cal.setFirstDayOfWeek(Calendar.SUNDAY); //set first day to Sunday > > > > if (monthParam != null) > >cal.set(Calendar.MONTH, (Integer.valueOf(monthParam)-1)); > > > > if (yearParam != null) > >cal.set(Calendar.YEAR, Integer.valueOf(yearParam)); > > > > //get total number of days in month > > int numDaysInMonth = cal.getActualMaximum(Calendar.DAY_OF_MONTH); > > > > //get current month name in English > > String monthName = cal.getDisplayName(Calendar.MONTH, Calendar.LONG, > > Locale.ENGLISH); > > > > //get current year > > int year = cal.get(Calendar.YEAR); > > > > //get array of day names > > String[] headers = {"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; > > %> > > > > > > > >Calendarama! > > > > > > > > > > > ><%= monthName + " " + year %> > > > > > > > ><% > > for (int i=0; i<7; i++) > > { > >%> > ><%= headers[i] %> > ><% > > } > >%> > > > > > > > ><% > > for (int i=1; i<=numDaysInMonth; i++) > > { > >//re-set calendar day in context of loop > >cal.set(Calendar.DAY_OF_MONTH, i); > > > >//get the day number of the week > >int day = cal.get(Calendar.DAY_OF_WEEK); > > > >//days without numbers count > >int blankDays = 0; > > > >//blank days before 1st of month? > >if (i == 1 && day > 1) > >{ > > blankDays = day - i; //get count > > > > //loop through count and print blank day > > for (int x=1; x<=blankDays; x++) > > { > >%> > > > ><% > > } > >} > >%> > > <%= i %> > ><% > >if (day == Calendar.SATURDAY) > >{ > >%> > > > > > ><% > >} > > > >//blank days after last day of month? > >if (i == numDaysInMonth && day < 7) > >{ > > blankDays = 7 - day; //get count > > > > //loop through count and print blank day > > for (int x=1; x<=blankDays; x++) > > { > >%> > > > ><% > > } > >} > > } > >%> > > > > > > > > > > > > -- > > View this message in context: > > http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20138860.html > > Sent from the Wicket - User mailing list archive at Nabble.com. > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Trying to create a calendar - need some guidance
all you need is a gridview. set columns to 7 and generate 30 items... -igor On Thu, Oct 23, 2008 at 1:47 PM, V. Jenks <[EMAIL PROTECTED]> wrote: > > Hi all. > > I'm trying to build a component-ized calendar that will be the centerpiece > of a new application I'm working on. I built one this morning in JSP and > was able to do it with very little code. I kept it simple and I'm hoping I > can retro-fit the logic into a wicket page cleanly, without too much > trouble. I'm a little stuck because in my JSP, I simply loop through the > days and print until Saturday is reached, then I break to a new table row > and continue. Doing this in Wicket seems tough because if I use a ListView, > I can't be as flexible as far as throwing in a new row while looping and > outputting table cells. > > Here's the rough idea I came up with today in JSP, can someone give me some > pointers? > > <%@ page contentType="text/html" pageEncoding="UTF-8" %> > <%@ page import="java.util.*" %> > "http://www.w3.org/TR/html4/loose.dtd";> > <% > //get parameters to change date > String monthParam = request.getParameter("month"); > String yearParam = request.getParameter("year"); > > //create calendar object > Calendar cal = Calendar.getInstance(); > cal.setFirstDayOfWeek(Calendar.SUNDAY); //set first day to Sunday > > if (monthParam != null) >cal.set(Calendar.MONTH, (Integer.valueOf(monthParam)-1)); > > if (yearParam != null) >cal.set(Calendar.YEAR, Integer.valueOf(yearParam)); > > //get total number of days in month > int numDaysInMonth = cal.getActualMaximum(Calendar.DAY_OF_MONTH); > > //get current month name in English > String monthName = cal.getDisplayName(Calendar.MONTH, Calendar.LONG, > Locale.ENGLISH); > > //get current year > int year = cal.get(Calendar.YEAR); > > //get array of day names > String[] headers = {"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; > %> > > > >Calendarama! > > > > > ><%= monthName + " " + year %> > > > ><% > for (int i=0; i<7; i++) > { >%> ><%= headers[i] %> ><% > } >%> > > > ><% > for (int i=1; i<=numDaysInMonth; i++) > { >//re-set calendar day in context of loop >cal.set(Calendar.DAY_OF_MONTH, i); > >//get the day number of the week >int day = cal.get(Calendar.DAY_OF_WEEK); > >//days without numbers count >int blankDays = 0; > >//blank days before 1st of month? >if (i == 1 && day > 1) >{ > blankDays = day - i; //get count > > //loop through count and print blank day > for (int x=1; x<=blankDays; x++) > { >%> > ><% > } >} >%> > <%= i %> ><% >if (day == Calendar.SATURDAY) >{ >%> > > ><% >} > >//blank days after last day of month? >if (i == numDaysInMonth && day < 7) >{ > blankDays = 7 - day; //get count > > //loop through count and print blank day > for (int x=1; x<=blankDays; x++) > { >%> > ><% > } >} > } >%> > > > > > > -- > View this message in context: > http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20138860.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Trying to create a calendar - need some guidance
ListView is good if you already have a list of things you want to display. For this kind of iteration you'd be better off with a RepeatingView. Here's how I might tackle it: - create a top-level panel to hold the calendar. The markup would contain your table element, and would have a RepeatingView attached to a tr element - create a panel representing the row, which has a RepeatingView attached to a td element. - create a panel representing a day. - put your loop in the ctor of the top-level panel. Start by creating a row panel and adding it to the first RepeatingView. Then for each day, create a day panel and add it to the repeating view in the row. When you get to the Saturday, just create a new row panel as the "current" one, add it to the first RepeatingView, and continue on your way. Now for the cool part: you could put the part where you create the day panel into an overrideable method. Then you could re-use the component to generate all kinds of different calendars by simply subclassing and returning different kinds of day panels. jk On Thu, Oct 23, 2008 at 01:47:26PM -0700, V. Jenks wrote: > > Hi all. > > I'm trying to build a component-ized calendar that will be the centerpiece > of a new application I'm working on. I built one this morning in JSP and > was able to do it with very little code. I kept it simple and I'm hoping I > can retro-fit the logic into a wicket page cleanly, without too much > trouble. I'm a little stuck because in my JSP, I simply loop through the > days and print until Saturday is reached, then I break to a new table row > and continue. Doing this in Wicket seems tough because if I use a ListView, > I can't be as flexible as far as throwing in a new row while looping and > outputting table cells. > > Here's the rough idea I came up with today in JSP, can someone give me some > pointers? > > <%@ page contentType="text/html" pageEncoding="UTF-8" %> > <%@ page import="java.util.*" %> > "http://www.w3.org/TR/html4/loose.dtd";> > <% > //get parameters to change date > String monthParam = request.getParameter("month"); > String yearParam = request.getParameter("year"); > > //create calendar object > Calendar cal = Calendar.getInstance(); > cal.setFirstDayOfWeek(Calendar.SUNDAY); //set first day to Sunday > > if (monthParam != null) > cal.set(Calendar.MONTH, (Integer.valueOf(monthParam)-1)); > > if (yearParam != null) > cal.set(Calendar.YEAR, Integer.valueOf(yearParam)); > > //get total number of days in month > int numDaysInMonth = cal.getActualMaximum(Calendar.DAY_OF_MONTH); > > //get current month name in English > String monthName = cal.getDisplayName(Calendar.MONTH, Calendar.LONG, > Locale.ENGLISH); > > //get current year > int year = cal.get(Calendar.YEAR); > > //get array of day names > String[] headers = {"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; > %> > > > > Calendarama! > > > > > > <%= monthName + " " + year %> > > > > <% > for (int i=0; i<7; i++) > { > %> > <%= headers[i] %> > <% > } > %> > > > > <% > for (int i=1; i<=numDaysInMonth; i++) > { > //re-set calendar day in context of loop > cal.set(Calendar.DAY_OF_MONTH, i); > > //get the day number of the week > int day = cal.get(Calendar.DAY_OF_WEEK); > > //days without numbers count > int blankDays = 0; > > //blank days before 1st of month? > if (i == 1 && day > 1) > { > blankDays = day - i; //get count > > //loop through count and print blank day > for (int x=1; x<=blankDays; x++) > { > %> > > <% > } > } > %> > <%= i %> > <% > if (day == Calendar.SATURDAY) > { > %> > > > <% > } > > //blank days after last day of month? > if (i == numDaysInMonth && day < 7) > { > blankDays = 7 - day; //get count > > //loop through count and print blank day > for (int x=1; x<=blankDays; x++) > { > %> > > <% > } > } > } > %> > > > > > > -- > View this message in context: > http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20138860.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] >
Re: Proposal: the browser as a desktop client
Johan, I'm not saying you should move *everything* over to the client. I'm saying that most form manipulation can take place without querying the database, especially on a per-request basis. Adding rows and cell validation tend to rely on at most one database lookup (during the initial request). Even if you *do* need to query the database before carrying out some operation (I dare say this is a minority situation) you can issue a web service call to do just that. Wicket's current implementation assumes that by default form manipulation should take place on the server. I am saying that by default it should take place on the client. The same functionality is still possible, it's just your default that changes. And as I mentioned, this approach has many benefits besides performance. Gili Johan Compagner wrote: > > because on the server the business logic runs > Its a complete different paradigm > > if thinks that are now done in onclick() or onsubmit() would run on the > client > what would be possible then? Currently many people just call DAO's there > (spring stuff and so on) > > johan > > > On Thu, Oct 23, 2008 at 11:40 PM, cowwoc <[EMAIL PROTECTED]> wrote: > >> >> GWT generates business logic, HTML and CSS from Java code; as opposed to >> letting you bind business logic written in Java against normal HTML >> files. >> It doesn't have a clean separation of concerns like Wicket. >> >> Ask yourself this, why does the client rely on the server to do dynamic >> form >> manipulation on its behalf? Is it because the server really cares about >> the >> intermediate form states or is it because we don't want to write this >> logic >> in Javascript? >> >> Gili >> >> >> Johan Compagner wrote: >> > >> > use GWT because thats the key difference between wicket and gwt >> > >> > I only see some things like validators that could be precompiled not th >> > complete webapp and all your current page/panel/component/html code >> > >> > >> > On Wed, Oct 22, 2008 at 3:44 PM, cowwoc <[EMAIL PROTECTED]> >> wrote: >> > >> >> >> >> Hi, >> >> >> >> I'd like to propose we leverage existing Java to Javascript compilers >> to >> >> improve Wicket on a couple of fronts. If you think of the web browser >> as >> >> a >> >> desktop client involved in a client-server architecture then it >> becomes >> >> obvious that Wicket is currently asking the server to handle a lot of >> >> logic >> >> on behalf of the client. It does this because it's easier to develop >> in >> >> Java >> >> than in Javascript. In an ideal world, the server should only see HTML >> >> forms >> >> in two states: >> >> >> >> - their initial state (sent to the client) >> >> - their submitted state (merged into the database) >> >> >> >> The client would be able to communicate with web services in between >> to >> >> update the client-side state but most applications won't even need >> this. >> >> The >> >> vast majority of form manipulation (adding rows, data validation) can >> be >> >> handled completely on the client-end. >> >> >> >> I foresee the following benefits: >> >> >> >> - Vastly simplified logic: A lot of resources have been spent building >> >> the >> >> HTML parser and classes related to server-side form manipulation. All >> >> these >> >> are built in for free in JS. For example, interacting with HTML >> elements >> >> and >> >> IDs is far easier than in Java code. >> >> - Improved responsiveness for end-users >> >> - Improved server scalability >> >> - "Nice" URLs, both for humans and for web crawlers. This would also >> open >> >> up >> >> the door for RESTful implementations. >> >> >> >> This would be different from GWT. You would benefit from the >> modularity >> >> of >> >> Wicket, coding HTML and CSS in their native languages. The only >> >> difference >> >> is that you'd now be manipulating dynamic forms on the client-end >> instead >> >> of >> >> the server-end. >> >> >> >> Let me know what you think. >> >> >> >> Gili >> >> -- >> >> View this message in context: >> >> >> http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20111040.html >> >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> >> >> >> - >> >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> >> > >> > >> >> -- >> View this message in context: >> http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20140090.html >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > -- View this message in context: http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20140645.html Sent from the Wicket - User mailing list archive at Nabble.com. -
Re: Proposal: the browser as a desktop client
so write a prototype and present it to the community. we are all eyes. -igor On Thu, Oct 23, 2008 at 2:40 PM, cowwoc <[EMAIL PROTECTED]> wrote: > > GWT generates business logic, HTML and CSS from Java code; as opposed to > letting you bind business logic written in Java against normal HTML files. > It doesn't have a clean separation of concerns like Wicket. > > Ask yourself this, why does the client rely on the server to do dynamic form > manipulation on its behalf? Is it because the server really cares about the > intermediate form states or is it because we don't want to write this logic > in Javascript? > > Gili > > > Johan Compagner wrote: >> >> use GWT because thats the key difference between wicket and gwt >> >> I only see some things like validators that could be precompiled not th >> complete webapp and all your current page/panel/component/html code >> >> >> On Wed, Oct 22, 2008 at 3:44 PM, cowwoc <[EMAIL PROTECTED]> wrote: >> >>> >>> Hi, >>> >>> I'd like to propose we leverage existing Java to Javascript compilers to >>> improve Wicket on a couple of fronts. If you think of the web browser as >>> a >>> desktop client involved in a client-server architecture then it becomes >>> obvious that Wicket is currently asking the server to handle a lot of >>> logic >>> on behalf of the client. It does this because it's easier to develop in >>> Java >>> than in Javascript. In an ideal world, the server should only see HTML >>> forms >>> in two states: >>> >>> - their initial state (sent to the client) >>> - their submitted state (merged into the database) >>> >>> The client would be able to communicate with web services in between to >>> update the client-side state but most applications won't even need this. >>> The >>> vast majority of form manipulation (adding rows, data validation) can be >>> handled completely on the client-end. >>> >>> I foresee the following benefits: >>> >>> - Vastly simplified logic: A lot of resources have been spent building >>> the >>> HTML parser and classes related to server-side form manipulation. All >>> these >>> are built in for free in JS. For example, interacting with HTML elements >>> and >>> IDs is far easier than in Java code. >>> - Improved responsiveness for end-users >>> - Improved server scalability >>> - "Nice" URLs, both for humans and for web crawlers. This would also open >>> up >>> the door for RESTful implementations. >>> >>> This would be different from GWT. You would benefit from the modularity >>> of >>> Wicket, coding HTML and CSS in their native languages. The only >>> difference >>> is that you'd now be manipulating dynamic forms on the client-end instead >>> of >>> the server-end. >>> >>> Let me know what you think. >>> >>> Gili >>> -- >>> View this message in context: >>> http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20111040.html >>> Sent from the Wicket - User mailing list archive at Nabble.com. >>> >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >> >> > > -- > View this message in context: > http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20140090.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Proposal: the browser as a desktop client
because on the server the business logic runs Its a complete different paradigm if thinks that are now done in onclick() or onsubmit() would run on the client what would be possible then? Currently many people just call DAO's there (spring stuff and so on) johan On Thu, Oct 23, 2008 at 11:40 PM, cowwoc <[EMAIL PROTECTED]> wrote: > > GWT generates business logic, HTML and CSS from Java code; as opposed to > letting you bind business logic written in Java against normal HTML files. > It doesn't have a clean separation of concerns like Wicket. > > Ask yourself this, why does the client rely on the server to do dynamic > form > manipulation on its behalf? Is it because the server really cares about the > intermediate form states or is it because we don't want to write this logic > in Javascript? > > Gili > > > Johan Compagner wrote: > > > > use GWT because thats the key difference between wicket and gwt > > > > I only see some things like validators that could be precompiled not th > > complete webapp and all your current page/panel/component/html code > > > > > > On Wed, Oct 22, 2008 at 3:44 PM, cowwoc <[EMAIL PROTECTED]> wrote: > > > >> > >> Hi, > >> > >> I'd like to propose we leverage existing Java to Javascript compilers to > >> improve Wicket on a couple of fronts. If you think of the web browser as > >> a > >> desktop client involved in a client-server architecture then it becomes > >> obvious that Wicket is currently asking the server to handle a lot of > >> logic > >> on behalf of the client. It does this because it's easier to develop in > >> Java > >> than in Javascript. In an ideal world, the server should only see HTML > >> forms > >> in two states: > >> > >> - their initial state (sent to the client) > >> - their submitted state (merged into the database) > >> > >> The client would be able to communicate with web services in between to > >> update the client-side state but most applications won't even need this. > >> The > >> vast majority of form manipulation (adding rows, data validation) can be > >> handled completely on the client-end. > >> > >> I foresee the following benefits: > >> > >> - Vastly simplified logic: A lot of resources have been spent building > >> the > >> HTML parser and classes related to server-side form manipulation. All > >> these > >> are built in for free in JS. For example, interacting with HTML elements > >> and > >> IDs is far easier than in Java code. > >> - Improved responsiveness for end-users > >> - Improved server scalability > >> - "Nice" URLs, both for humans and for web crawlers. This would also > open > >> up > >> the door for RESTful implementations. > >> > >> This would be different from GWT. You would benefit from the modularity > >> of > >> Wicket, coding HTML and CSS in their native languages. The only > >> difference > >> is that you'd now be manipulating dynamic forms on the client-end > instead > >> of > >> the server-end. > >> > >> Let me know what you think. > >> > >> Gili > >> -- > >> View this message in context: > >> > http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20111040.html > >> Sent from the Wicket - User mailing list archive at Nabble.com. > >> > >> > >> - > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > -- > View this message in context: > http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20140090.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: Trying to create a calendar - need some guidance
Yes, of course, but because webical is opensource, you can study the sources and see they are building their calendar. V. Jenks wrote: > > > > adrienleroy wrote: >> >> Hello, >> >> Take a look at the webical project, they are using Wicket : >> http://code.google.com/p/webical/ >> > > Thanks, but it's important that I build my own, given the nature of this > project. It took me 1.5 hrs. to do what I did in JSP so it's not like I'm > trying to accomplish a huge task. > -- View this message in context: http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20140136.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Proposal: the browser as a desktop client
GWT generates business logic, HTML and CSS from Java code; as opposed to letting you bind business logic written in Java against normal HTML files. It doesn't have a clean separation of concerns like Wicket. Ask yourself this, why does the client rely on the server to do dynamic form manipulation on its behalf? Is it because the server really cares about the intermediate form states or is it because we don't want to write this logic in Javascript? Gili Johan Compagner wrote: > > use GWT because thats the key difference between wicket and gwt > > I only see some things like validators that could be precompiled not th > complete webapp and all your current page/panel/component/html code > > > On Wed, Oct 22, 2008 at 3:44 PM, cowwoc <[EMAIL PROTECTED]> wrote: > >> >> Hi, >> >> I'd like to propose we leverage existing Java to Javascript compilers to >> improve Wicket on a couple of fronts. If you think of the web browser as >> a >> desktop client involved in a client-server architecture then it becomes >> obvious that Wicket is currently asking the server to handle a lot of >> logic >> on behalf of the client. It does this because it's easier to develop in >> Java >> than in Javascript. In an ideal world, the server should only see HTML >> forms >> in two states: >> >> - their initial state (sent to the client) >> - their submitted state (merged into the database) >> >> The client would be able to communicate with web services in between to >> update the client-side state but most applications won't even need this. >> The >> vast majority of form manipulation (adding rows, data validation) can be >> handled completely on the client-end. >> >> I foresee the following benefits: >> >> - Vastly simplified logic: A lot of resources have been spent building >> the >> HTML parser and classes related to server-side form manipulation. All >> these >> are built in for free in JS. For example, interacting with HTML elements >> and >> IDs is far easier than in Java code. >> - Improved responsiveness for end-users >> - Improved server scalability >> - "Nice" URLs, both for humans and for web crawlers. This would also open >> up >> the door for RESTful implementations. >> >> This would be different from GWT. You would benefit from the modularity >> of >> Wicket, coding HTML and CSS in their native languages. The only >> difference >> is that you'd now be manipulating dynamic forms on the client-end instead >> of >> the server-end. >> >> Let me know what you think. >> >> Gili >> -- >> View this message in context: >> http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20111040.html >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > -- View this message in context: http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20140090.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Trying to create a calendar - need some guidance
adrienleroy wrote: > > Hello, > > Take a look at the webical project, they are using Wicket : > http://code.google.com/p/webical/ > Thanks, but it's important that I build my own, given the nature of this project. It took me 1.5 hrs. to do what I did in JSP so it's not like I'm trying to accomplish a huge task. -- View this message in context: http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20140032.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Trying to create a calendar - need some guidance
Hello, Take a look at the webical project, they are using Wicket : http://code.google.com/p/webical/ -- View this message in context: http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20139967.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Page Markup Inheritance Problem...
I ran into a similar situation last night. Not sure if this is what your looking for. BasePage - My Site Layout SuperPage - My Page Layout (e.g. a header area for what I am working with) SubPage - Actions ( e.g. forms for adding stuff etc.) When first navigating to SuperPage I only want to show links that the user needs to click on to access the different SubPages. In this case I used a in my SuperPage. I can still navigate to SuperPage even if I am calling the class SuperPage directly. Then each link in SuperPage called my SubPage class, with only the extra component added by the SubPage. Hope this helps. But as Igor said you have to make SuperPage have the in its markup. -Richard On Thu, Oct 23, 2008 at 3:37 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote: > just like in object inheritance your superpage would have to provide a > way to plug this extra component in... > > -igor > > On Thu, Oct 23, 2008 at 1:30 PM, James Carman > <[EMAIL PROTECTED]> wrote: >> Suppose I have this page hierarchy: >> >> BasePage <- SuperPage <- SubPage. >> >> In BasePage.html, I've got and in SuperPage.html I've >> got . Now, in SubPage.html, I can't just "override" >> the markup of SuperPage.html by using a . Suppose I >> wanted to just add in an extra component in SubPage.html and then >> "override" the markup for SuperPage with the markup for SubPage, but >> still allowing myself to extend from BasePage. I can't do that! >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Proposal: the browser as a desktop client
use GWT because thats the key difference between wicket and gwt I only see some things like validators that could be precompiled not th complete webapp and all your current page/panel/component/html code On Wed, Oct 22, 2008 at 3:44 PM, cowwoc <[EMAIL PROTECTED]> wrote: > > Hi, > > I'd like to propose we leverage existing Java to Javascript compilers to > improve Wicket on a couple of fronts. If you think of the web browser as a > desktop client involved in a client-server architecture then it becomes > obvious that Wicket is currently asking the server to handle a lot of logic > on behalf of the client. It does this because it's easier to develop in > Java > than in Javascript. In an ideal world, the server should only see HTML > forms > in two states: > > - their initial state (sent to the client) > - their submitted state (merged into the database) > > The client would be able to communicate with web services in between to > update the client-side state but most applications won't even need this. > The > vast majority of form manipulation (adding rows, data validation) can be > handled completely on the client-end. > > I foresee the following benefits: > > - Vastly simplified logic: A lot of resources have been spent building the > HTML parser and classes related to server-side form manipulation. All these > are built in for free in JS. For example, interacting with HTML elements > and > IDs is far easier than in Java code. > - Improved responsiveness for end-users > - Improved server scalability > - "Nice" URLs, both for humans and for web crawlers. This would also open > up > the door for RESTful implementations. > > This would be different from GWT. You would benefit from the modularity of > Wicket, coding HTML and CSS in their native languages. The only difference > is that you'd now be manipulating dynamic forms on the client-end instead > of > the server-end. > > Let me know what you think. > > Gili > -- > View this message in context: > http://www.nabble.com/Proposal%3A-the-browser-as-a-desktop-client-tp20111040p20111040.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Trying to create a calendar - need some guidance
Hi all. I'm trying to build a component-ized calendar that will be the centerpiece of a new application I'm working on. I built one this morning in JSP and was able to do it with very little code. I kept it simple and I'm hoping I can retro-fit the logic into a wicket page cleanly, without too much trouble. I'm a little stuck because in my JSP, I simply loop through the days and print until Saturday is reached, then I break to a new table row and continue. Doing this in Wicket seems tough because if I use a ListView, I can't be as flexible as far as throwing in a new row while looping and outputting table cells. Here's the rough idea I came up with today in JSP, can someone give me some pointers? <%@ page contentType="text/html" pageEncoding="UTF-8" %> <%@ page import="java.util.*" %> http://www.w3.org/TR/html4/loose.dtd";> <% //get parameters to change date String monthParam = request.getParameter("month"); String yearParam = request.getParameter("year"); //create calendar object Calendar cal = Calendar.getInstance(); cal.setFirstDayOfWeek(Calendar.SUNDAY); //set first day to Sunday if (monthParam != null) cal.set(Calendar.MONTH, (Integer.valueOf(monthParam)-1)); if (yearParam != null) cal.set(Calendar.YEAR, Integer.valueOf(yearParam)); //get total number of days in month int numDaysInMonth = cal.getActualMaximum(Calendar.DAY_OF_MONTH); //get current month name in English String monthName = cal.getDisplayName(Calendar.MONTH, Calendar.LONG, Locale.ENGLISH); //get current year int year = cal.get(Calendar.YEAR); //get array of day names String[] headers = {"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; %> Calendarama! <%= monthName + " " + year %> <% for (int i=0; i<7; i++) { %> <%= headers[i] %> <% } %> <% for (int i=1; i<=numDaysInMonth; i++) { //re-set calendar day in context of loop cal.set(Calendar.DAY_OF_MONTH, i); //get the day number of the week int day = cal.get(Calendar.DAY_OF_WEEK); //days without numbers count int blankDays = 0; //blank days before 1st of month? if (i == 1 && day > 1) { blankDays = day - i; //get count //loop through count and print blank day for (int x=1; x<=blankDays; x++) { %> <% } } %> <%= i %> <% if (day == Calendar.SATURDAY) { %> <% } //blank days after last day of month? if (i == numDaysInMonth && day < 7) { blankDays = 7 - day; //get count //loop through count and print blank day for (int x=1; x<=blankDays; x++) { %> <% } } } %> -- View this message in context: http://www.nabble.com/Trying-to-create-a-calendar---need-some-guidance-tp20138860p20138860.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Page Markup Inheritance Problem...
just like in object inheritance your superpage would have to provide a way to plug this extra component in... -igor On Thu, Oct 23, 2008 at 1:30 PM, James Carman <[EMAIL PROTECTED]> wrote: > Suppose I have this page hierarchy: > > BasePage <- SuperPage <- SubPage. > > In BasePage.html, I've got and in SuperPage.html I've > got . Now, in SubPage.html, I can't just "override" > the markup of SuperPage.html by using a . Suppose I > wanted to just add in an extra component in SubPage.html and then > "override" the markup for SuperPage with the markup for SubPage, but > still allowing myself to extend from BasePage. I can't do that! > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Page Markup Inheritance Problem...
Suppose I have this page hierarchy: BasePage <- SuperPage <- SubPage. In BasePage.html, I've got and in SuperPage.html I've got . Now, in SubPage.html, I can't just "override" the markup of SuperPage.html by using a . Suppose I wanted to just add in an extra component in SubPage.html and then "override" the markup for SuperPage with the markup for SubPage, but still allowing myself to extend from BasePage. I can't do that! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to pass parameters to a BreadCrumbPanel
Hello Wayne, Looks like if I use BreadCrumbPanelLink, i cannot pass the parameters as you mentioned. However I tried to implement the model rather a crude way :) .By persisting the links in a List and saving the same in session. I hope this is ok any experts please advise. //Naveen On Thu, Oct 23, 2008 at 1:53 AM, Wayne Pope < [EMAIL PROTECTED]> wrote: > Hi Naveen, > > I do it something like this: > >TabbedPanel tabbedPanel = new TabbedPanel("tabs", tabs){ >@Override >protected WebMarkupContainer newLink(String linkId, final int > index) { >PageParameters parameters = new PageParameters(); >parameters.put("selected", ((ITab) getTabs().get(index)) >.getTitle().getObject()); >parameters.put("somethingIneedID", somethingIneedID); >return new BookmarkablePageLink(linkId, MyPage.class, >parameters); >} > >}; >if (found) >tabbedPanel.setSelectedTab(selected); > >if (tabSelect != null) >tabbedPanel.setSelectedTab(tabSelect); >add(tabbedPanel); > > you should be able to figue it out from there. > Wayne > > > On Tue, Oct 21, 2008 at 9:06 PM, Nav Che <[EMAIL PROTECTED]> wrote: > > > Hello All, > > > > How do i pass parameters between panels. Basically i have panels in my > > appilcation which use breadcrumb model. > > > > Say on panel A i display list of users and I want the user Id to be a > link > > upon clickin it should show the edit panel ( panel B ) of user and for > > which it shld either pass user object or userid. > > > > Please advise. > > > > Thanks in advance > > > > Regards > > naveen > > >
Re: have anyone tried empire-DB?
On the otherhand if youre really familiar with SQL and know you will not switch database, you could go with ibatis... But then again, I find it's lacking the nice JPA annotations etc.. So you see im still not sure whats the right way..:)( Nino Saturnino Martinez Vazquez Wael wrote: Hi Wayne Im still in reflection mode about Hibernate, Im still a little annoyed about some stuff but I believe its because I do not know enough. And yes hibernates error reporting is not good by a long shot. If i get stuck with hibernate I switch to OpenJPA and get a nicer error message fix it and switch back to hibernate... For now I would say stick with hibernate, and buy the book called http://www.amazon.com/Java-Persistence-Hibernate-Christian-Bauer/dp/1932394885 I havent really looked enough into openjpa etc to say anything about these and performance etc... Wayne Pope wrote: Nino what do you recommend in terms orf DB framework. We're currently using Hibernate and I'm personally finding it a pain - it seems to influence the java code way too much and it create some horrible joins if we're not carefull. Any suggestions that you've used in the real world? On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael < [EMAIL PROTECTED]> wrote: This is interesting: (JaQu) Provide API level compatibility with JPA (so that JaQu can be used as an extension of JPA). But I think something similar are on its way for JPA 2.0..? marco.behler wrote: I gave empireDB a quick look a while ago and it looks interesting. Besides JPersist I also stumbled upon JaQu (http://www.h2database.com/html/jaqu.html), which is still in its infancy. I'm sure there's more LINQ-like clones out there. As far as I'm concerned, I'd really like to have a thorough look at stuff like db4o or couchDB, especially performance wise. I did Hibernate/iBatis in the past and am currently working on a project with iBatis again. Both have advantages and disadvantages and I don't "love" either. I would rather not have to care about tables, objects,the mighty mismatch (and in Hibernate's case the mighty session) anymore, but just shove that damn thing into an object database ;) *hides from enraged DBAs and their optimised queries* Nino.Martinez wrote: Yeah seems to be nice... At WUG DK we discussed. That if using stuff like hibernate, for simple cruds it's nice but if you have a complex object graph it becomes very troublesome to use (if you use cascade all etc.).. Ames, Tim wrote: Looks like it has a lot in common with JPersist. That is what I have been using. No XML, all POJO. -Original Message- From: Nino Saturnino Martinez Vazquez Wael [mailto:[EMAIL PROTECTED] Sent: Thursday, October 16, 2008 11:28 AM To: users@wicket.apache.org Subject: have anyone tried empire-DB? So have you tried it with wicket? http://incubator.apache.org/empire-db/ -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ EMAIL CONFIDENTIALITY NOTICE This Email message, and any attachments, may contain confidential patient health information that is legally protected. This information is intended only for the use of the individual or entity named above. The authorized recipient of this information is prohibited from disclosing this information to any other party unless required to do so by law or regulation and is required to destroy the information after its stated need has been fulfilled. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, or action taken in reliance on the contents of this message is strictly prohibited. If you have received this information in error, please notify the sender immediately by replying to this message and delete the message from your system. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 ---
Re: have anyone tried empire-DB?
Hi Wayne Im still in reflection mode about Hibernate, Im still a little annoyed about some stuff but I believe its because I do not know enough. And yes hibernates error reporting is not good by a long shot. If i get stuck with hibernate I switch to OpenJPA and get a nicer error message fix it and switch back to hibernate... For now I would say stick with hibernate, and buy the book called http://www.amazon.com/Java-Persistence-Hibernate-Christian-Bauer/dp/1932394885 I havent really looked enough into openjpa etc to say anything about these and performance etc... Wayne Pope wrote: Nino what do you recommend in terms orf DB framework. We're currently using Hibernate and I'm personally finding it a pain - it seems to influence the java code way too much and it create some horrible joins if we're not carefull. Any suggestions that you've used in the real world? On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael < [EMAIL PROTECTED]> wrote: This is interesting: (JaQu) Provide API level compatibility with JPA (so that JaQu can be used as an extension of JPA). But I think something similar are on its way for JPA 2.0..? marco.behler wrote: I gave empireDB a quick look a while ago and it looks interesting. Besides JPersist I also stumbled upon JaQu (http://www.h2database.com/html/jaqu.html), which is still in its infancy. I'm sure there's more LINQ-like clones out there. As far as I'm concerned, I'd really like to have a thorough look at stuff like db4o or couchDB, especially performance wise. I did Hibernate/iBatis in the past and am currently working on a project with iBatis again. Both have advantages and disadvantages and I don't "love" either. I would rather not have to care about tables, objects,the mighty mismatch (and in Hibernate's case the mighty session) anymore, but just shove that damn thing into an object database ;) *hides from enraged DBAs and their optimised queries* Nino.Martinez wrote: Yeah seems to be nice... At WUG DK we discussed. That if using stuff like hibernate, for simple cruds it's nice but if you have a complex object graph it becomes very troublesome to use (if you use cascade all etc.).. Ames, Tim wrote: Looks like it has a lot in common with JPersist. That is what I have been using. No XML, all POJO. -Original Message- From: Nino Saturnino Martinez Vazquez Wael [mailto:[EMAIL PROTECTED] Sent: Thursday, October 16, 2008 11:28 AM To: users@wicket.apache.org Subject: have anyone tried empire-DB? So have you tried it with wicket? http://incubator.apache.org/empire-db/ -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ EMAIL CONFIDENTIALITY NOTICE This Email message, and any attachments, may contain confidential patient health information that is legally protected. This information is intended only for the use of the individual or entity named above. The authorized recipient of this information is prohibited from disclosing this information to any other party unless required to do so by law or regulation and is required to destroy the information after its stated need has been fulfilled. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, or action taken in reliance on the contents of this message is strictly prohibited. If you have received this information in error, please notify the sender immediately by replying to this message and delete the message from your system. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
IE6 + load balancer through proxy problem
We are having a very peculiar problem with a website not working properly under very specific conditions. The site is built with wicket and running on Apache + Resin. There are two load balanced servers, and each apache instance points only to the resin instance on the same server. We are using sticky sessions both on the load balancer hardware and in the resin configuration. The client is behind a proxy and they can only use IE6 to access the site. Upon initial page load when they are trying to access the site through the domain name or through the IP address of the load balancer they are getting one of those inscrutable IE6 javascript errors: Line: 2 Char: 1 Error: Invalid character Code: 0 After that almost all of the Ajax controls on the site don't function. There are errors in the logs which look like this: 2008-10-21 11:35:05,906 ERROR [hmux-XXX.XXX.XXX.XXX:6802-13:] org.apache.wicket.RequestCycle - Method onLinkClicked of interface org.apache.wicket.markup.html.link.ILinkListener targeted at component [MarkupContainer [Component id = offerDetailsLink, page = com.aexp.pursuits.wicket.pages.PlayGolf, path = 1:golfForm:offersPanel:offerFragmentPanel:offerDetailsLink.OffersPanel$OfferFragment$1, isVisible = true, isVersioned = true]] threw an exception org.apache.wicket.WicketRuntimeException: Method onLinkClicked of interface org.apache.wicket.markup.html.link.ILinkListener targeted at component [MarkupContainer [Component id = offerDetailsLink, page = com.aexp.pursuits.wicket.pages.PlayGolf, path = 1:golfForm:offersPanel:offerFragmentPanel:offerDetailsLink.OffersPanel$OfferFragment$1, isVisible = true, isVersioned = true]] threw an exception at org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:194) at org.apache.wicket.request.target.component.listener.ListenerInterfaceRequestTarget.processEvents(ListenerInterfaceRequestTarget.java:73) at org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:91) at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1166) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1243) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1331) at org.apache.wicket.RequestCycle.request(RequestCycle.java:493) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:363) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:87) at com.caucho.server.cache.CacheFilterChain.doFilter(CacheFilterChain.java:187) at com.caucho.server.webapp.WebAppFilterChain.doFilter(WebAppFilterChain.java:181) at com.caucho.server.dispatch.ServletInvocation.service(ServletInvocation.java:266) at com.caucho.server.hmux.HmuxRequest.handleRequest(HmuxRequest.java:435) at com.caucho.server.port.TcpConnection.run(TcpConnection.java:603) at com.caucho.util.ThreadPool$Item.runTasks(ThreadPool.java:721) at com.caucho.util.ThreadPool$Item.run(ThreadPool.java:643) at java.lang.Thread.run(Thread.java:595) Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:183) ... 17 more Caused by: java.lang.NullPointerException at com.aexp.pursuits.wicket.panels.OffersPanel$OfferFragment$1.onClick(OffersPanel.java:233) at org.apache.wicket.ajax.markup.html.AjaxFallbackLink.onClick(AjaxFallbackLink.java:98) at org.apache.wicket.markup.html.link.Link.onLinkClicked(Link.java:214) ... 22 more It appears that the AjaxRequestTarget is null. When the client tries to access the site through the IP address of either of the two servers there is no javascript error and the site works. The site also works in Firefox and IE7 at the client. Has anyone seen anything like this before? Do you have any clue what the problem might be? It is very difficult for us to debug this because we are unable to reproduce the problem and have very little access to the client environment to test things out there. Any hints would be appreciated. Thank you, Anna -- View this message in context: http://www.nabble.com/IE6-%2B-load-balancer-through-proxy-problem-tp20137449p20137449.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Override panel markup
2008/10/23 rpaul <[EMAIL PROTECTED]>: > > Not sure this would work. I have not tried it. > > Extend SignInPanel with subclass e.g. MySignInPanel and then create your > matching MySignInPanel.html with the custom content. > > Then use MySignInPanel instead of SignInPanel. just to clear things up, this not only will work but is imho the best practice for custom markup. it also makes clear that you are using customized markup and where to find it by just reading the java code. > > -- > View this message in context: > http://www.nabble.com/Override-panel-markup-tp20135458p20136407.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Override panel markup
you can subclass and let it implement IMarkupResourceStreamProvider and from there do whatever you want...but i wouldnt recommend it. -igor On Thu, Oct 23, 2008 at 11:21 AM, Adriano dos Santos Fernandes <[EMAIL PROTECTED]> wrote: > Yes, thanks. > > And what about overriding direct in the page html (kind of make the panel > not catch its html and use the one from the page), is it possible? (just to > know) > > > Adriano > > > rpaul escreveu: >> >> Not sure this would work. I have not tried it. >> >> Extend SignInPanel with subclass e.g. MySignInPanel and then create your >> matching MySignInPanel.html with the custom content. >> Then use MySignInPanel instead of SignInPanel. >> >> > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Override panel markup
Yes, thanks. And what about overriding direct in the page html (kind of make the panel not catch its html and use the one from the page), is it possible? (just to know) Adriano rpaul escreveu: Not sure this would work. I have not tried it. Extend SignInPanel with subclass e.g. MySignInPanel and then create your matching MySignInPanel.html with the custom content. Then use MySignInPanel instead of SignInPanel. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Override panel markup
that will work. -igor On Thu, Oct 23, 2008 at 10:58 AM, rpaul <[EMAIL PROTECTED]> wrote: > > Not sure this would work. I have not tried it. > > Extend SignInPanel with subclass e.g. MySignInPanel and then create your > matching MySignInPanel.html with the custom content. > > Then use MySignInPanel instead of SignInPanel. > > -- > View this message in context: > http://www.nabble.com/Override-panel-markup-tp20135458p20136407.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: listview produce duplicate value.
which get method are you referring to?? are you using ajax?? -igor On Thu, Oct 23, 2008 at 10:51 AM, overseastars <[EMAIL PROTECTED]> wrote: > > Hi > > My listview is printing duplicate valueswhy?? > > I found that my get method is working well. just printing result is > incorrect??? is it a bug?? > -- > View this message in context: > http://www.nabble.com/listview-produce-duplicate-value.-tp20136280p20136280.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Override panel markup
Not sure this would work. I have not tried it. Extend SignInPanel with subclass e.g. MySignInPanel and then create your matching MySignInPanel.html with the custom content. Then use MySignInPanel instead of SignInPanel. -- View this message in context: http://www.nabble.com/Override-panel-markup-tp20135458p20136407.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
listview produce duplicate value.
Hi My listview is printing duplicate valueswhy?? I found that my get method is working well. just printing result is incorrect??? is it a bug?? -- View this message in context: http://www.nabble.com/listview-produce-duplicate-value.-tp20136280p20136280.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Override panel markup
Hi! I would want to override a panel markup, for instance, I want to add a SignInPanel to my page but don't want to use builtin SignInPanel.html. Is there a way to do it, preferable without creating a specific html file for the new component, i.e., I want to override the content direct on the page if possible? Thanks. Adriano - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: my component ID is being modified and causing errors
Actually, its just the end of the day playing tricks on me, Wicket does this so the generated ID's are unique - it was something unrelated. cheers, Steve On 23 Oct 2008, at 17:55, Steve Swinsburg wrote: I have a simple piece of code which replaces a component with another one when a link is clicked, however the number '4' is being appended to my component ID's. here is the HTML showing 'replaceAjax' as my component ID: replace ajax: replace via ajax wicket:id="replaceAjax">this will be replaced INFO: INFO: Initiating Ajax GET request on ?wicket:interface=: 2:replaceLink::IBehaviorListener:0:&random=0.15276471804827452 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (193 characters) INFO: id="replaceAjax4" > INFO: Response parsed. Now invoking steps... ERROR: Component with id [[replaceAjax4]] a was not found while trying to perform markup update. Make sure you called component.setOutputMarkupId(true) on the component whose markup you are trying to update. INFO: Response processed successfully. INFO: Invoking post-call handler(s)... INFO: last focus id was not set In the above you can see the component ID has been changed to replaceAjax4! Is this a real issue or is the end of the day playing tricks on me? This was on wicket 1.3.0. I then upgraded to wicket 1.3.5 and the 4 turns into an 'e': INFO: Using XMLHttpRequest transport INFO: INFO: Initiating Ajax GET request on ?wicket:interface=: 11:replaceLink::IBehaviorListener:0:&random=0.28145640529692173 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (193 characters) INFO: id="replaceAjaxe" > INFO: Response parsed. Now invoking steps... ERROR: Component with id [[replaceAjaxe]] a was not found while trying to perform markup update. Make sure you called component.setOutputMarkupId(true) on the component whose markup you are trying to update. INFO: Response processed successfully. INFO: Invoking post-call handler(s)... INFO: last focus id was not set What's going on? Thanks, Steve smime.p7s Description: S/MIME cryptographic signature
my component ID is being modified and causing errors
I have a simple piece of code which replaces a component with another one when a link is clicked, however the number '4' is being appended to my component ID's. here is the HTML showing 'replaceAjax' as my component ID: replace ajax: replace via ajax wicket:id="replaceAjax">this will be replaced INFO: INFO: Initiating Ajax GET request on ?wicket:interface=: 2:replaceLink::IBehaviorListener:0:&random=0.15276471804827452 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (193 characters) INFO: id="replaceAjax4" > INFO: Response parsed. Now invoking steps... ERROR: Component with id [[replaceAjax4]] a was not found while trying to perform markup update. Make sure you called component.setOutputMarkupId(true) on the component whose markup you are trying to update. INFO: Response processed successfully. INFO: Invoking post-call handler(s)... INFO: last focus id was not set In the above you can see the component ID has been changed to replaceAjax4! Is this a real issue or is the end of the day playing tricks on me? This was on wicket 1.3.0. I then upgraded to wicket 1.3.5 and the 4 turns into an 'e': INFO: Using XMLHttpRequest transport INFO: INFO: Initiating Ajax GET request on ?wicket:interface=: 11:replaceLink::IBehaviorListener:0:&random=0.28145640529692173 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (193 characters) INFO: id="replaceAjaxe" > INFO: Response parsed. Now invoking steps... ERROR: Component with id [[replaceAjaxe]] a was not found while trying to perform markup update. Make sure you called component.setOutputMarkupId(true) on the component whose markup you are trying to update. INFO: Response processed successfully. INFO: Invoking post-call handler(s)... INFO: last focus id was not set What's going on? Thanks, Steve smime.p7s Description: S/MIME cryptographic signature
Re: GridView adding item after calling populate item
you should not depend on the page being set in the constructor of your components. -igor On Thu, Oct 23, 2008 at 9:08 AM, Job de Noo <[EMAIL PROTECTED]> wrote: > Hi all, > > i hava a question about the behaviour of GridView. > GridView calls the populateItem before adding the item to the rowview. > So all components i add to the gridview don't have the page reference > yet. > > Is this meant to be like this? > > Because it is giving me errors while adding ajax links and getting > their url. Error message i get is: No Page found for component > > Job de Noo > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
GridView adding item after calling populate item
Hi all, i hava a question about the behaviour of GridView. GridView calls the populateItem before adding the item to the rowview. So all components i add to the gridview don't have the page reference yet. Is this meant to be like this? Because it is giving me errors while adding ajax links and getting their url. Error message i get is: No Page found for component Job de Noo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Release 1.3.5 vs 1.4
everything that is fixed in 1.3.x is fixed in 1.4.x and vice-versa where applicable. as far as getting involved, just pick a bug and provde a patch, if you need help here is the best place to ask. -igor On Thu, Oct 23, 2008 at 8:43 AM, rpaul <[EMAIL PROTECTED]> wrote: > > Hi > > I would like some advice on which version of wicket I should be working > with. I am thinking about deploying an app currently using 1.4 to production > by the end of November. > > Are all the bug fixes in 1.3.5 going to be in 1.4 ? > How soon should we expect another release of 1.4 ? > > I also have a question about the best way to get involve. Should I just grab > a bug from the buglist and start investigating it ?, how do I pair up with > someone on the wicket dev team to work on these issues. > > Any recommendations would be helpful. > > Thanks > Richard > -- > View this message in context: > http://www.nabble.com/Release-1.3.5-vs-1.4-tp20133687p20133687.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Wicket and Ext JS integration
Paolo, I think wicket-stuff ( http://wicketstuff.org/confluence/display/STUFFWIKI/Wiki) would be the place to put the code. I would recommend the license be the Apache License, version 2.0. As I understand, that is OK with GPL, version 3 ( http://www.gnu.org/licenses/gpl-faq.html#GPLModuleLicense), which is the license used by ExtJS version 2.1 and up. -Richard On Thu, Oct 23, 2008 at 9:29 AM, Paolo Di Tommaso <[EMAIL PROTECTED] > wrote: > Yes, I'm working for a no-profit organization and it could be an > interesting > option to release it as an OSS. > > Do you have any suggestion where the project could be hosted? Google code? > and any idea about the licence? > > > Thank you, Paolo > > > On Thu, Oct 23, 2008 at 2:19 PM, Richard Allen <[EMAIL PROTECTED] > >wrote: > > > Paolo, > > > > Is this an open source effort? What version of ExtJS are you using? > > > > If we were to choose to go with Wicket, we would be willing to > contribute. > > > > Thanks, > > Richard Allen > > > > On Wed, Oct 22, 2008 at 10:20 AM, Paolo Di Tommaso < > > [EMAIL PROTECTED]> wrote: > > > > > I'm working on a wicket-ext integration project. > > > > > > Until now I've done just really simple stuff, like simple TextField, > > > DateField, TimeField, ComboBox, AutoComplete field and basic (static) > > grid > > > elements. > > > > > > Though my implementation is trivial I would say that is really > promising > > > and > > > I've not found any evident obstacle to a more complete integration. > > > > > > > > > Paolo > > > > > > On Wed, Oct 22, 2008 at 1:53 PM, Richard Allen < > > [EMAIL PROTECTED] > > > >wrote: > > > > > > > We currently use Ext JS 2.2 (http://extjs.com) with Struts 1.x, and > we > > > are > > > > considering migrating to Wicket. I have seen on the mail archive that > > > some > > > > people have integrated Wicket and Ext JS with mixed success. In > > > particular, > > > > I found the wicket-tools-extjs project, > > > > http://www.wickettools.org/index.php/extjs-integrationm, which is > > > version > > > > 0.1.0, published in February 2008. > > > > > > > > Is the wicket-tools-extjs project in active development or was that > > > project > > > > abandoned? Is there any other significant work undergoing to > integrate > > > > Wicket and Ext JS? > > > > > > > > Thanks, > > > > Richard Allen > > > > > > > > > >
Release 1.3.5 vs 1.4
Hi I would like some advice on which version of wicket I should be working with. I am thinking about deploying an app currently using 1.4 to production by the end of November. Are all the bug fixes in 1.3.5 going to be in 1.4 ? How soon should we expect another release of 1.4 ? I also have a question about the best way to get involve. Should I just grab a bug from the buglist and start investigating it ?, how do I pair up with someone on the wicket dev team to work on these issues. Any recommendations would be helpful. Thanks Richard -- View this message in context: http://www.nabble.com/Release-1.3.5-vs-1.4-tp20133687p20133687.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Static injection not working (wicket-guice)
why dont you debug it yourself and see what the problem is. see how the thing actually works and you might find a solution. i dont use guice so i wont be of much help. -igor On Thu, Oct 23, 2008 at 3:30 AM, Edgar Merino <[EMAIL PROTECTED]> wrote: > This one seems to have no answer, I've tried googling and everything stopped > just here, were I started, I hope someone could provide a solution > (different than using salve). > > Edgar Merino > > > > > Edgar Merino escribió: >> >> Anyone for this? >> >> >> Edgar Merino escribió: >>> >>> Hello, >>> >>> I've been trying to inject a service to some classes that are not >>> wicket components, I've asked here and was suggested to use static >>> injection: InjectorHolder.getInjector().inject(this); however this is not >>> working with guice, I always get an illegalstateexception, injectorholder >>> has not been assigned an injector. I've tried ((GuiceInjectorHolder) >>> (RequestCycle.get().getApplication().getMetaData(GuiceInjectorHolder.INJECTOR_KEY))).getInjector().injectMembers(this); >>> however that gives me serialization problems, since wicket is not creating a >>> proxy for my service. I'm on my way to give salve a try but I'm having some >>> problems there too (waiting for a response from the Discussion group), what >>> suggestions can you make? >>> >>> Thanks in advance, >>> Edgar Merino >>> >> >> > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What's the difference between Check and CheckBox
javadoc is your friend -igor On Wed, Oct 22, 2008 at 11:48 PM, Minto van der Sluis <[EMAIL PROTECTED]> wrote: > > Messing around with unittesting a CheckBox, I discovered Check as well: > >org.apache.wicket.markup.html.form.Check; >org.apache.wicket.markup.html.form.CheckBox; > > To me it's not very clean what the difference is, since they are both > attached to the same markup: > > > > Can anyone enlighten me ? > > regards, > > Minto van der Sluis > -- > View this message in context: > http://www.nabble.com/What%27s-the-difference-between-Check-and-CheckBox-tp20125256p20125256.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AjaxFallbackButton: inconsistend submit order
Hi folks, I just stumbled upon a problem with a Form containing a nested Form and two AjaxFallbackButtons (submit and preview). I need to implement different onSubmit() behavior of the nested Form depending on the clicked button. The order of onSubmit() calls is: without JS: - AjaxFallbackButton.onSubmit(AjaxRequestTarget,Form) - OuterForm.onSubmit() // not used - Inner Form.onSubmit() with JS: - Inner Form.onSubmit() - OuterForm.onSubmit() // not used - AjaxFallbackButton.onSubmit(AjaxRequestTarget,Form) With JS, it is therefore not possible to determine which button was clicked from inside a form's onSubmit() method. Is this a (known) bug? - --- Stefan Fußenegger http://talk-on-tech.blogspot.com // looking for a nicer domain ;) -- View this message in context: http://www.nabble.com/AjaxFallbackButton%3A-inconsistend-submit-order-tp20131329p20131329.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
How about just use PropertyListView? On Thu, Oct 23, 2008 at 9:39 AM, pieter claassen <[EMAIL PROTECTED]> wrote: > Guys, thanks for all your feedback. You were right. > > Cheers, > Pieter > > On Oct 23, 2008, at 2:44 PM, Jeremy Thomerson wrote: > >> Johan nailed it... here are your bad lines: >> >> System.out.println("+++"+ >> item.getModelObject().getClass().getName()); >> final QuestionAndAnswer qanda = (QuestionAndAnswer) >> item.getModelObject(); >> setModel(new CompoundPropertyModel(qanda)); >> >> That should just be changed to: >> >> item.setModel(new CompoundPropertyModel(item.getModel()); >> >> if that's what you want. >> >> -- Jeremy Thomerson >> http://www.wickettraining.com >> >> On Thu, Oct 23, 2008 at 6:13 AM, Johan Compagner >> <[EMAIL PROTECTED]>wrote: >> >>> What are you doing there? >>> You get a model object from the listitem >>> And then you are calling setmodel(compound) on the listview itself? >>> Why is that then you are changing the model of the listview inside the >>> loop that it goes over them creating listitems! >>> >>> On 10/23/08, pieter claassen <[EMAIL PROTECTED]> wrote: I am getting a classcast exception in ListView that is stumping me. This is the error message (top few lines) WicketMessage: Error attaching this container for rendering: [MarkupContainer [Component id = questioneditform]] Root cause: java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer at org .apache .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) at org.apache.wicket.Component.getModelObject(Component.java:1558) at com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm $1.populateItem(TemplateEditPage.java:93) This is the code that generates my ListItems: ListView questions = new ListView("questions", >>> >>> template .getQuestions()) { @Override protected void populateItem(ListItem item) >>> >>> { final QuestionAndAnswer qanda = >>> >>> (QuestionAndAnswer) item .getModelObject(); setModel(new >>> >>> CompoundPropertyModel(qanda)); I know for a fact that template.getQuestions() produces an ArrayList. The arraylist works when there is only 1 item in it but when I have more than 1 item, it fails with the ClassCastException. Is this a wicket problem or am I doing something wrong? Regards, Pieter pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> > > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problems with wicket-autocomplete.js
Hi, I have two Problems with the AutoCompleteBehavior in wicket: 1. Type-Conflict in line 287 of wicket-autocomplete.js: function showAutoComplete(){ var position=getPosition(wicketGet(elementId)); var container = getAutocompleteContainer(); var input=wicketGet(elementId); var index=getOffsetParentZIndex(elementId); container.show(); * --> container.style.zIndex=(!isNaN(Number(index))?Number(index)+1:index);* container.style.left=position[0]+'px' container.style.top=(input.offsetHeight+position[1])+'px'; if(cfg.adjustInputWidth) container.style.width=input.offsetWidth+'px'; visible=1; hideShowCovered(); } I believe this was introduced with wicket 1.3.5. In version 1.3.4 this line was: container.style.zIndex=(Number(index)!=Number.NaN?Number(index)+1:index); 2. No Object in line 77: function initialize(){ // Remove the autocompletion menu if still present from // a previous call. This is required to properly register // the mouse event handler again (using the new stateful 'mouseactive' // variable which just gets created) var choiceDiv=document.getElementById(getMenuId()); if (choiceDiv != null) { choiceDiv.parentNode.parentNode.removeChild(choiceDiv.parentNode); } var obj=wicketGet(elementId); --> *objonkeydown=obj.onkeydown;* objonblur=obj.onblur; objonkeyup=obj.onkeyup; objonkeypress=obj.onkeypress; This causes that the autocomplete-List is not shown. But after replacing the autocompleteField with Ajax it works. I think that initJS, wich is called onDomReady (see below), is called to early? This is the AbstractAutoCompleteBehavior.java: public void renderHead(IHeaderResponse response) { super.renderHead(response); response.renderJavascriptReference(AUTOCOMPLETE_JS); final String id = getComponent().getMarkupId(); String initJS = constructInitJS(); response.renderOnDomReadyJavascript(initJS); } I use IE6 and the page with the AutocompleteField is quite big. Has anyone an idea how to get around this? Regards, Benjamin
Re: ListView broken?
Guys, thanks for all your feedback. You were right. Cheers, Pieter On Oct 23, 2008, at 2:44 PM, Jeremy Thomerson wrote: Johan nailed it... here are your bad lines: System.out.println("+++"+ item.getModelObject().getClass().getName()); final QuestionAndAnswer qanda = (QuestionAndAnswer) item.getModelObject(); setModel(new CompoundPropertyModel(qanda)); That should just be changed to: item.setModel(new CompoundPropertyModel(item.getModel()); if that's what you want. -- Jeremy Thomerson http://www.wickettraining.com On Thu, Oct 23, 2008 at 6:13 AM, Johan Compagner <[EMAIL PROTECTED]>wrote: What are you doing there? You get a model object from the listitem And then you are calling setmodel(compound) on the listview itself? Why is that then you are changing the model of the listview inside the loop that it goes over them creating listitems! On 10/23/08, pieter claassen <[EMAIL PROTECTED]> wrote: I am getting a classcast exception in ListView that is stumping me. This is the error message (top few lines) WicketMessage: Error attaching this container for rendering: [MarkupContainer [Component id = questioneditform]] Root cause: java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer at org .apache .wicket .markup.html.list.ListItemModel.getObject(ListItemModel.java:55) at org.apache.wicket.Component.getModelObject(Component.java:1558) at com.musmato.wicket.pages.templates.TemplateEditPage $QuestionEditForm $1.populateItem(TemplateEditPage.java:93) This is the code that generates my ListItems: ListView questions = new ListView("questions", template .getQuestions()) { @Override protected void populateItem(ListItem item) { final QuestionAndAnswer qanda = (QuestionAndAnswer) item .getModelObject (); setModel(new CompoundPropertyModel(qanda)); I know for a fact that template.getQuestions() produces an ArrayList. The arraylist works when there is only 1 item in it but when I have more than 1 item, it fails with the ClassCastException. Is this a wicket problem or am I doing something wrong? Regards, Pieter pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
few (not only) AutoCompleteTextField questions
Hi, First, problem description: Recently I was asked to change DropDownChoice field into AutoCompleteTextField. Everything was ok untill I noticed that old DropDownChoice field has attached OnChangeAjaxBehavior. Ofcourse what works well with DropDownChoice doesnt work as I want with AutoCompleteTextField. The problem is that I want to update a model after user selects one of choices(from autocomplete) not after any change of text field. I found getOnSelectJavascriptExpression method in AbstractAutoCompleteRenderer (since Wicket 1.4 ?) and I thought that it would be a good place to call some JS to update text field model. I looked at http://cwiki.apache.org/WICKET/calling-wicket-from-javascript.html to see how to call server side Wicket code from JavaScript. Next I had the idea to attach to text field AjaxFormComponentUpdatingBehavior and call its getCallbackUrl() from JavaScript returned from mentioned earlier getOnSelectJavascriptExpression(). The problem is that AjaxFormComponentUpdatingBehavior expects event name in constructor - in this case I dont need any onXXX event because I will call its getCallbackUrl() directly from JS. Now few questions: 1)How to update (via Ajax) model of some FormComponents from JavaScript? Do I have to attach AjaxFormComponentUpdatingBehavior to some dummy event and call its getCallbackUrl() directly in JavaScript ? If so, its kind of hacking for me and AjaxFormComponentUpdatingBehavior should provide no-argument constructor. 2)Does JavaScript returned from getOnSelectJavascriptExpression is called after corresponding TextField value has been set ? 3)At Wicket wiki I found description how to work with AutoCompleteTextField and Models: http://cwiki.apache.org/WICKET/autocomplete-using-a-wicket-model.html I dont understand why this problem is not solved by subclassing directly form AutoCompleteTextField and overriding getConverter and provide some custom converter ? Ps. My colegue told me to attach AjaxFormComponentUpdatingBehavior to onBlur event, maybe this is the solution ? (but still, for me better place to update a model is in Javasript from getOnSelectJavascriptExpression() than in onblur event handler...) Best regards Daniel -- View this message in context: http://www.nabble.com/few-%28not-only%29-AutoCompleteTextField-questions-tp20131044p20131044.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Wicket and Ext JS integration
Yes, I'm working for a no-profit organization and it could be an interesting option to release it as an OSS. Do you have any suggestion where the project could be hosted? Google code? and any idea about the licence? Thank you, Paolo On Thu, Oct 23, 2008 at 2:19 PM, Richard Allen <[EMAIL PROTECTED]>wrote: > Paolo, > > Is this an open source effort? What version of ExtJS are you using? > > If we were to choose to go with Wicket, we would be willing to contribute. > > Thanks, > Richard Allen > > On Wed, Oct 22, 2008 at 10:20 AM, Paolo Di Tommaso < > [EMAIL PROTECTED]> wrote: > > > I'm working on a wicket-ext integration project. > > > > Until now I've done just really simple stuff, like simple TextField, > > DateField, TimeField, ComboBox, AutoComplete field and basic (static) > grid > > elements. > > > > Though my implementation is trivial I would say that is really promising > > and > > I've not found any evident obstacle to a more complete integration. > > > > > > Paolo > > > > On Wed, Oct 22, 2008 at 1:53 PM, Richard Allen < > [EMAIL PROTECTED] > > >wrote: > > > > > We currently use Ext JS 2.2 (http://extjs.com) with Struts 1.x, and we > > are > > > considering migrating to Wicket. I have seen on the mail archive that > > some > > > people have integrated Wicket and Ext JS with mixed success. In > > particular, > > > I found the wicket-tools-extjs project, > > > http://www.wickettools.org/index.php/extjs-integrationm, which is > > version > > > 0.1.0, published in February 2008. > > > > > > Is the wicket-tools-extjs project in active development or was that > > project > > > abandoned? Is there any other significant work undergoing to integrate > > > Wicket and Ext JS? > > > > > > Thanks, > > > Richard Allen > > > > > >
Re: How to pass parameters to a BreadCrumbPanel
Hello Wayne, Thanks for your advise, i shall try it out... I was actually planning to write my own breadcrumbs for pages instead of panels. Not sure how successful i would be :) Thanks again //Naveen On Thu, Oct 23, 2008 at 1:53 AM, Wayne Pope < [EMAIL PROTECTED]> wrote: > Hi Naveen, > > I do it something like this: > >TabbedPanel tabbedPanel = new TabbedPanel("tabs", tabs){ >@Override >protected WebMarkupContainer newLink(String linkId, final int > index) { >PageParameters parameters = new PageParameters(); >parameters.put("selected", ((ITab) getTabs().get(index)) >.getTitle().getObject()); >parameters.put("somethingIneedID", somethingIneedID); >return new BookmarkablePageLink(linkId, MyPage.class, >parameters); >} > >}; >if (found) >tabbedPanel.setSelectedTab(selected); > >if (tabSelect != null) >tabbedPanel.setSelectedTab(tabSelect); >add(tabbedPanel); > > you should be able to figue it out from there. > Wayne > > > On Tue, Oct 21, 2008 at 9:06 PM, Nav Che <[EMAIL PROTECTED]> wrote: > > > Hello All, > > > > How do i pass parameters between panels. Basically i have panels in my > > appilcation which use breadcrumb model. > > > > Say on panel A i display list of users and I want the user Id to be a > link > > upon clickin it should show the edit panel ( panel B ) of user and for > > which it shld either pass user object or userid. > > > > Please advise. > > > > Thanks in advance > > > > Regards > > naveen > > >
Re: Possible bug in FormComponent$MessageSource regarding resource string lookups
Done: WICKET-1888 igor.vaynberg wrote: > > request for enhancement. add it to our jria. > > -igor > > -- View this message in context: http://www.nabble.com/Possible-bug-in-FormComponent%24MessageSource-regarding-resource-string-lookups-tp19951394p20130775.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to unittest a checkbox
Since this is not so obvious, we should probably file a request in JIRA to add a checkbox-specific method to FormTester. Care to take care of that, since you found the issue? On Thu, Oct 23, 2008 at 9:15 AM, Minto van der Sluis <[EMAIL PROTECTED]> wrote: > > Thx that did the trick :-) > > For those who that come after me > > formTester.setValue( getCheckboxPath(), "on" ); // check > formTester.setValue( getCheckboxPath(), "off" ); // uncheck > > regards, > > Minto > > -- > View this message in context: > http://www.nabble.com/how-to-unittest-a-checkbox-tp20106917p20130698.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to unittest a checkbox
Thx that did the trick :-) For those who that come after me formTester.setValue( getCheckboxPath(), "on" ); // check formTester.setValue( getCheckboxPath(), "off" ); // uncheck regards, Minto -- View this message in context: http://www.nabble.com/how-to-unittest-a-checkbox-tp20106917p20130698.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RadioGroup set selection from database results
Hi, >From a database I am retrieving two columns, the label for the radio and a boolean value to say whether or not it should be selected. I have written the code below to get the values from the database, the ObjectSelect class contains the object (in this case the string label) and selected which is a boolean value. When the page loads the none of the radio choices are selected. Is it possible to set the default value in this way, if not how can it be done? -CODE //Add query type radio group queryTypes = new LoadableDetachableModel() { @Override protected Object load() { QueryTypeWrapper.setObjects(queryDefDao.getQueryType(queryDefId)); return QueryTypeWrapper.getObjects(); } }; //Generate list of groups with checkboxes final RadioGroup radioGroup = new RadioGroup("radioGroup", queryTypes); f.add(radioGroup); ListView radioList = new ListView("queryTypes", queryTypes) { protected void populateItem(ListItem item) { ObjectSelect os = (ObjectSelect) item.getModelObject(); item.setModel(new CompoundPropertyModel(os)); item.add(new Radio("selected")); item.add(new Label("object")); } }; radioGroup.add(radioList); -CODE Thanks in advanced Ross -- View this message in context: http://www.nabble.com/RadioGroup-set-selection-from-database-results-tp20130427p20130427.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
Johan nailed it... here are your bad lines: System.out.println("+++"+ item.getModelObject().getClass().getName()); final QuestionAndAnswer qanda = (QuestionAndAnswer) item.getModelObject(); setModel(new CompoundPropertyModel(qanda)); That should just be changed to: item.setModel(new CompoundPropertyModel(item.getModel()); if that's what you want. -- Jeremy Thomerson http://www.wickettraining.com On Thu, Oct 23, 2008 at 6:13 AM, Johan Compagner <[EMAIL PROTECTED]>wrote: > What are you doing there? > You get a model object from the listitem > And then you are calling setmodel(compound) on the listview itself? > Why is that then you are changing the model of the listview inside the > loop that it goes over them creating listitems! > > On 10/23/08, pieter claassen <[EMAIL PROTECTED]> wrote: > > I am getting a classcast exception in ListView that is stumping me. > > > > This is the error message (top few lines) > > > > WicketMessage: Error attaching this container for rendering: > > [MarkupContainer [Component id = questioneditform]] > > > > Root cause: > > > > java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer > > at > > org > > .apache > > .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) > > at org.apache.wicket.Component.getModelObject(Component.java:1558) > > at com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm > > $1.populateItem(TemplateEditPage.java:93) > > > > > > This is the code that generates my ListItems: > > > > ListView questions = new ListView("questions", > template > > .getQuestions()) { > > > > > > @Override > > protected void populateItem(ListItem item) > { > > final QuestionAndAnswer qanda = > (QuestionAndAnswer) item > > .getModelObject(); > > setModel(new > CompoundPropertyModel(qanda)); > > > > > > > > I know for a fact that template.getQuestions() produces an ArrayList. > > > > The arraylist works when there is only 1 item in it but when I have > > more than 1 item, it fails with the ClassCastException. Is this a > > wicket problem or am I doing something wrong? > > > > Regards, > > Pieter > > pieter claassen > > [EMAIL PROTECTED] > > > > > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: Wicket and Ext JS integration
Paolo, Is this an open source effort? What version of ExtJS are you using? If we were to choose to go with Wicket, we would be willing to contribute. Thanks, Richard Allen On Wed, Oct 22, 2008 at 10:20 AM, Paolo Di Tommaso < [EMAIL PROTECTED]> wrote: > I'm working on a wicket-ext integration project. > > Until now I've done just really simple stuff, like simple TextField, > DateField, TimeField, ComboBox, AutoComplete field and basic (static) grid > elements. > > Though my implementation is trivial I would say that is really promising > and > I've not found any evident obstacle to a more complete integration. > > > Paolo > > On Wed, Oct 22, 2008 at 1:53 PM, Richard Allen <[EMAIL PROTECTED] > >wrote: > > > We currently use Ext JS 2.2 (http://extjs.com) with Struts 1.x, and we > are > > considering migrating to Wicket. I have seen on the mail archive that > some > > people have integrated Wicket and Ext JS with mixed success. In > particular, > > I found the wicket-tools-extjs project, > > http://www.wickettools.org/index.php/extjs-integrationm, which is > version > > 0.1.0, published in February 2008. > > > > Is the wicket-tools-extjs project in active development or was that > project > > abandoned? Is there any other significant work undergoing to integrate > > Wicket and Ext JS? > > > > Thanks, > > Richard Allen > > >
Re: have anyone tried empire-DB?
Wayne: If you come from a stored procedure heavy usage background and still need to use them, perhaps you can take a look at JPersist. We define two classes for each SP, one is a pojo that reflects the resultset columns (of course this assumes no SP will return different columns in different invocations) and the other is a wrapper for the query or execute operation, and we do this with a code generator which grabs all the metadata from the database. No XML, no mappings, nothing ! Of course it all depends on your needs, we had a lot of legacy DBs and the SP issue was an important one. If you are starting a new project, perhaps the decision criteria would be different. Feels free to contact me if you need some samples. Hope this helps, Daniel Wayne Pope wrote: > > > However my original quesiton still stands - any other db frameworks that > anyone recommends? > > -- View this message in context: http://www.nabble.com/have-anyone-tried-empire-DB--tp20016534p20129739.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Wicket and Ext JS integration
I could be interested to share experience about that, but now I'm really in early stage so I think it would be too early to share the code. Anyway the main idea is to use the Wicket behaviour feature to "attach" an Ext component to the associated Wicket component. This is the easiest part. More complex integration like Data Store could be always done using a Wicket ajax behavior. But I' haven't yet tryed to integrate more complex stuff like editable grids, groups and so on . . Paolo On Thu, Oct 23, 2008 at 1:41 PM, Richard Allen <[EMAIL PROTECTED]>wrote: > The licensing is a pain. We started using ExtJS when it was LGPL, then they > switched to GPL. By then we were already invested, so we bought a > commercial > license -- kind of feel like we got suckered into that one. If I had a > chance to do it again I would just use YUI. We use ExtJS on top of YUI. > However, ExtJS is a good product, even though they made a poor licensing > decision. > > The licensing problem is just a fact that we have to deal with now, so I'm > trying to find out what the easiest path is for integrating ExtJS 2.2 with > Wicket. If someone else has already done the effort or started the effort, > then that would help. The amount of work involved in integrating ExtJS 2.2 > with Wicket is part of our new web framework evaluation criteria. > > Thanks, > Richard Allen > > On Wed, Oct 22, 2008 at 2:05 PM, Nino Saturnino Martinez Vazquez Wael < > [EMAIL PROTECTED]> wrote: > > > I thought there were a licensing issue! Could'nt just remember if it were > > the guy doing the wicket contrib or ext js.. > > > > Martijn Dashorst wrote: > > > >> The GPL licensing of ExtJS is really a brain damage inflicting mess. > >> Personally I would stay very far away from JS libraries that are GPL > >> licensed (it is not clear how the viral aspect infects your server > >> side code, possibly requiring you to ship your server side code to > >> your users—you *are* distributing the GPL licensed code, which is > >> linked to your product) > >> > >> Martijn > >> > >> > >> > > > > -- > > -Wicket for love > > > > Nino Martinez Wael > > Java Specialist @ Jayway DK > > http://www.jayway.dk > > +45 2936 7684 > > > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > >
Re: Wicket and Ext JS integration
The licensing is a pain. We started using ExtJS when it was LGPL, then they switched to GPL. By then we were already invested, so we bought a commercial license -- kind of feel like we got suckered into that one. If I had a chance to do it again I would just use YUI. We use ExtJS on top of YUI. However, ExtJS is a good product, even though they made a poor licensing decision. The licensing problem is just a fact that we have to deal with now, so I'm trying to find out what the easiest path is for integrating ExtJS 2.2 with Wicket. If someone else has already done the effort or started the effort, then that would help. The amount of work involved in integrating ExtJS 2.2 with Wicket is part of our new web framework evaluation criteria. Thanks, Richard Allen On Wed, Oct 22, 2008 at 2:05 PM, Nino Saturnino Martinez Vazquez Wael < [EMAIL PROTECTED]> wrote: > I thought there were a licensing issue! Could'nt just remember if it were > the guy doing the wicket contrib or ext js.. > > Martijn Dashorst wrote: > >> The GPL licensing of ExtJS is really a brain damage inflicting mess. >> Personally I would stay very far away from JS libraries that are GPL >> licensed (it is not clear how the viral aspect infects your server >> side code, possibly requiring you to ship your server side code to >> your users—you *are* distributing the GPL licensed code, which is >> linked to your product) >> >> Martijn >> >> >> > > -- > -Wicket for love > > Nino Martinez Wael > Java Specialist @ Jayway DK > http://www.jayway.dk > +45 2936 7684 > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: Applet Wicket communication
Just use an plain servlet, and talk to it using http + add the WicketSessionFilter in front of it so you can interact with the wicket session http://www.wicket-framework.org/apidocs/wicket/protocol/http/servlet/WicketSessionFilter.html On Thu, Oct 23, 2008 at 1:21 PM, Iqbal Akhtar <[EMAIL PROTECTED]> wrote: > Hi everyone, > > I need help regarding applet to wicket communication. Any help, code, pointer > will be appreciated. > > Thanks and Regards, > Iqbal > > _ > Explore the seven wonders of the world > http://search.msn.com/results.aspx?q=7+wonders+world&mkt=en-US&form=QBRE -- http://www.somatik.be Microsoft gives you windows, Linux gives you the whole house. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Applet Wicket communication
Hi everyone, I need help regarding applet to wicket communication. Any help, code, pointer will be appreciated. Thanks and Regards, Iqbal _ Explore the seven wonders of the world http://search.msn.com/results.aspx?q=7+wonders+world&mkt=en-US&form=QBRE
Re: ListView broken?
What are you doing there? You get a model object from the listitem And then you are calling setmodel(compound) on the listview itself? Why is that then you are changing the model of the listview inside the loop that it goes over them creating listitems! On 10/23/08, pieter claassen <[EMAIL PROTECTED]> wrote: > I am getting a classcast exception in ListView that is stumping me. > > This is the error message (top few lines) > > WicketMessage: Error attaching this container for rendering: > [MarkupContainer [Component id = questioneditform]] > > Root cause: > > java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer > at > org > .apache > .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) > at org.apache.wicket.Component.getModelObject(Component.java:1558) > at com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm > $1.populateItem(TemplateEditPage.java:93) > > > This is the code that generates my ListItems: > > ListView questions = new ListView("questions", template > .getQuestions()) { > > > @Override > protected void populateItem(ListItem item) { > final QuestionAndAnswer qanda = > (QuestionAndAnswer) item > .getModelObject(); > setModel(new > CompoundPropertyModel(qanda)); > > > > I know for a fact that template.getQuestions() produces an ArrayList. > > The arraylist works when there is only 1 item in it but when I have > more than 1 item, it fails with the ClassCastException. Is this a > wicket problem or am I doing something wrong? > > Regards, > Pieter > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
I suspect there may be a strange interaction with compound property models, since the name of your listview is questions and you also have a getQuestions() method in your upper level model object.. I'm just guessing but can you try to change the name of your listview to "questionList" instead of "questions" and try again.. by the way are you sure that you've rebuilt and redeployed your application.. -- View this message in context: http://www.nabble.com/ListView-broken--tp20126952p20128604.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
So, what does it print when you print out the class name? On Thu, Oct 23, 2008 at 6:24 AM, pieter claassen <[EMAIL PROTECTED]> wrote: > Ok, I might be doing something thats not ok but . there are not two > ListViews on this page (there are 3 forms? Is this a problem?) > ClassCastException is throw at System.out.println("") > > > package com.musmato.wicket.pages.templates; > > import java.util.Arrays; > > import org.apache.wicket.markup.html.form.DropDownChoice; > import org.apache.wicket.markup.html.form.Form; > import org.apache.wicket.markup.html.form.RequiredTextField; > import org.apache.wicket.markup.html.form.TextArea; > import org.apache.wicket.markup.html.link.Link; > import org.apache.wicket.markup.html.list.ListItem; > import org.apache.wicket.markup.html.list.ListView; > import org.apache.wicket.model.CompoundPropertyModel; > > import com.musmato.model.QuestionAndAnswer; > import com.musmato.model.Role; > import com.musmato.model.Template; > import com.musmato.model.WebControlType; > import com.musmato.wicket.model.QuestionAndAnswerWebModel; > import com.musmato.wicket.model.TemplateWebModel; > import com.musmato.wicket.pages.AuthPage; > import com.musmato.wicket.util.WicketApplication; > > public class TemplateEditPage extends AuthPage { > >public TemplateEditPage(TemplateWebModel templatemodel) { > >add(new TemplateEditForm("templateeditform", templatemodel)); >add(new QuestionAddForm("questionaddform", templatemodel)); >add(new QuestionEditForm("questioneditform", templatemodel)); >} > >@Override >public Role[] getAllowedRoles() { >// TODO Auto-generated method stub >return null; >} > >private class TemplateEditForm extends Form { >private final Template template; > >public TemplateEditForm(String id, TemplateWebModel > templatemodel) { >super(id); >template = (Template) templatemodel.getObject(); >setModel(new CompoundPropertyModel(templatemodel)); >add(new RequiredTextField("name")); >add(new RequiredTextField("version")); >add(new TextArea("description")); >} > >@Override >public void onSubmit() { > > WicketApplication.get().getTemplateFactory().store(template); >setResponsePage(new TemplateEditPage(new > TemplateWebModel(template))); >} >} > >private class QuestionAddForm extends Form { >private final Template template; > >public QuestionAddForm(String id, TemplateWebModel > templatemodel) { >super(id); >template = (Template) templatemodel.getObject(); >setModel(new CompoundPropertyModel(new > QuestionAndAnswerWebModel( >(Long) null))); >add(new RequiredTextField("question")); >add(new DropDownChoice("type", > Arrays.asList(WebControlType >.values(; >} > >@Override >public void onSubmit() { >QuestionAndAnswer qanda = (QuestionAndAnswer) > getModel() >.getObject(); > >template.addQuestion(qanda); > > WicketApplication.get().getTemplateFactory().store(template); >setResponsePage(new TemplateEditPage(new > TemplateWebModel(template))); >} >} > >private class QuestionEditForm extends Form { >private Template template; > >public QuestionEditForm(String id, TemplateWebModel > templatemodel) { >super(id); >template = (Template) templatemodel.getObject(); >ListView questionlist = new ListView("questions", > template >.getQuestions()) { >@Override >protected void populateItem(ListItem item) { >System.out.println("+++" >+ > item.getModelObject().getClass().getName()); >final QuestionAndAnswer qanda = > (QuestionAndAnswer) item >.getModelObject(); >setModel(new > CompoundPropertyModel(qanda)); >item.add(new > RequiredTextField("question")); >item.add(new DropDownChoice("type", > Arrays > > .asList(WebControlType.values(; >
Re: how to unittest a checkbox
Try: formTester.setValue(getCheckboxPath(), "on"); - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Static injection not working (wicket-guice)
This one seems to have no answer, I've tried googling and everything stopped just here, were I started, I hope someone could provide a solution (different than using salve). Edgar Merino Edgar Merino escribió: Anyone for this? Edgar Merino escribió: Hello, I've been trying to inject a service to some classes that are not wicket components, I've asked here and was suggested to use static injection: InjectorHolder.getInjector().inject(this); however this is not working with guice, I always get an illegalstateexception, injectorholder has not been assigned an injector. I've tried ((GuiceInjectorHolder) (RequestCycle.get().getApplication().getMetaData(GuiceInjectorHolder.INJECTOR_KEY))).getInjector().injectMembers(this); however that gives me serialization problems, since wicket is not creating a proxy for my service. I'm on my way to give salve a try but I'm having some problems there too (waiting for a response from the Discussion group), what suggestions can you make? Thanks in advance, Edgar Merino - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
Ok, I might be doing something thats not ok but . there are not two ListViews on this page (there are 3 forms? Is this a problem?) ClassCastException is throw at System.out.println("") package com.musmato.wicket.pages.templates; import java.util.Arrays; import org.apache.wicket.markup.html.form.DropDownChoice; import org.apache.wicket.markup.html.form.Form; import org.apache.wicket.markup.html.form.RequiredTextField; import org.apache.wicket.markup.html.form.TextArea; import org.apache.wicket.markup.html.link.Link; import org.apache.wicket.markup.html.list.ListItem; import org.apache.wicket.markup.html.list.ListView; import org.apache.wicket.model.CompoundPropertyModel; import com.musmato.model.QuestionAndAnswer; import com.musmato.model.Role; import com.musmato.model.Template; import com.musmato.model.WebControlType; import com.musmato.wicket.model.QuestionAndAnswerWebModel; import com.musmato.wicket.model.TemplateWebModel; import com.musmato.wicket.pages.AuthPage; import com.musmato.wicket.util.WicketApplication; public class TemplateEditPage extends AuthPage { public TemplateEditPage(TemplateWebModel templatemodel) { add(new TemplateEditForm("templateeditform", templatemodel)); add(new QuestionAddForm("questionaddform", templatemodel)); add(new QuestionEditForm("questioneditform", templatemodel)); } @Override public Role[] getAllowedRoles() { // TODO Auto-generated method stub return null; } private class TemplateEditForm extends Form { private final Template template; public TemplateEditForm(String id, TemplateWebModel templatemodel) { super(id); template = (Template) templatemodel.getObject(); setModel(new CompoundPropertyModel(templatemodel)); add(new RequiredTextField("name")); add(new RequiredTextField("version")); add(new TextArea("description")); } @Override public void onSubmit() { WicketApplication.get().getTemplateFactory().store(template); setResponsePage(new TemplateEditPage(new TemplateWebModel(template))); } } private class QuestionAddForm extends Form { private final Template template; public QuestionAddForm(String id, TemplateWebModel templatemodel) { super(id); template = (Template) templatemodel.getObject(); setModel(new CompoundPropertyModel(new QuestionAndAnswerWebModel( (Long) null))); add(new RequiredTextField("question")); add(new DropDownChoice("type", Arrays.asList(WebControlType .values(; } @Override public void onSubmit() { QuestionAndAnswer qanda = (QuestionAndAnswer) getModel() .getObject(); template.addQuestion(qanda); WicketApplication.get().getTemplateFactory().store(template); setResponsePage(new TemplateEditPage(new TemplateWebModel(template))); } } private class QuestionEditForm extends Form { private Template template; public QuestionEditForm(String id, TemplateWebModel templatemodel) { super(id); template = (Template) templatemodel.getObject(); ListView questionlist = new ListView("questions", template .getQuestions()) { @Override protected void populateItem(ListItem item) { System.out.println("+++" + item.getModelObject().getClass().getName()); final QuestionAndAnswer qanda = (QuestionAndAnswer) item .getModelObject(); setModel(new CompoundPropertyModel(qanda)); item.add(new RequiredTextField("question")); item.add(new DropDownChoice("type", Arrays .asList(WebControlType.values(; item.add(new Link("delete") { @Override public void onClick() {
Re: ListView broken?
The classcastexception happens on retrieving the N-th item from the list. The class cast tries to cast the model object of the listview to a List. Apparently the argument to the listview is not a List, but somethign that returns a QuestionAndAnswer. Are you looking at the correct ListView (i.e. are there more ListView s on your page)? Martijn On Thu, Oct 23, 2008 at 11:55 AM, Dipu <[EMAIL PROTECTED]> wrote: > pass , sorry i have no clue > > On Thu, Oct 23, 2008 at 10:37 AM, pieter claassen <[EMAIL PROTECTED]>wrote: > >> Ok, I added; >> >> public class Debug { >>public static void debug(List list) { >>for (Object item : list) { >>System.out.println("++DEBUG++: " + >> item.getClass().toString()); >>} >>} >> >> >> and called debug just before I returned my ArrayList of question: >> >>public ArrayList getQuestions() { >>Debug.debug(questions); >>return questions; >>} >> >> This is what I saw in my console. There are two objects in the list and >> they are both QuestionAndAnswer objects >> >> >> ++DEBUG++: class com.musmato.model.QuestionAndAnswer >> ++DEBUG++: class com.musmato.model.QuestionAndAnswer >> >> Regards, >> Pieter >> >> >> On Oct 23, 2008, at 11:18 AM, Dipu wrote: >> >> can't you check what exactly is being returned by template.getQuestions() >>> and if its a list what are the items in it >>> >>> >>> >>> >>> On Thu, Oct 23, 2008 at 10:10 AM, pieter claassen <[EMAIL PROTECTED] >>> >wrote: >>> >>> Hi Dipu, I tried that but when I do the following: protected void populateItem(ListItem item) { System.out.println("+++" + item.getModelObject().getClass().getName()); final QuestionAndAnswer qanda = (QuestionAndAnswer) item.getModelObject(); I find that I now get the ClassCastException in the System.out.println line. It is clear as mud that the problem is that I am trying to force something into a list which is not a list? Regards, Pieter On Oct 23, 2008, at 10:59 AM, Dipu wrote: looks like template.getQuestions() is returning a list with items in it > which is not of the type QuestionAndAnswer > > try iterating through the list and logging the class name of each item > in > it > > Dipu > > > > On Thu, Oct 23, 2008 at 9:46 AM, pieter claassen <[EMAIL PROTECTED] > >> wrote: >> > > I am getting a classcast exception in ListView that is stumping me. > >> >> This is the error message (top few lines) >> >> WicketMessage: Error attaching this container for rendering: >> [MarkupContainer [Component id = questioneditform]] >> >> Root cause: >> >> java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer >> at >> >> >> org.apache.wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) >> at org.apache.wicket.Component.getModelObject(Component.java:1558) >> at >> >> >> com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm$1.populateItem(TemplateEditPage.java:93) >> >> >> This is the code that generates my ListItems: >> >>ListView questions = new ListView("questions", >> template >>.getQuestions()) { >> >> >>@Override >>protected void populateItem(ListItem item) { >>final QuestionAndAnswer qanda = >> (QuestionAndAnswer) item >>.getModelObject(); >>setModel(new >> CompoundPropertyModel(qanda)); >> >> >> >> I know for a fact that template.getQuestions() produces an ArrayList. >> >> The arraylist works when there is only 1 item in it but when I have >> more >> than 1 item, it fails with the ClassCastException. Is this a wicket >> problem >> or am I doing something wrong? >> >> Regards, >> Pieter >> pieter claassen >> [EMAIL PROTECTED] >> >> >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] >> pieter claassen >> [EMAIL PROTECTED] >> >> >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional
RE: Double clickable rows in AjaxFallbackDefaultDataTable
Hi Igor Thanks for the tip. It work perfectly. I overrode the newRowItem() method of AjaxFallbackDefaultDataTable like this: protected Item newRowItem(String id, int index, IModel model) { Item rowItem = super.newRowItem(id, index, model); AjaxEventBehavior onDoubleClickBehaviour = new AjaxEventBehavior( "ondblclick") { @Override protected void onEvent(AjaxRequestTarget target) { // the code that will execute once a double click occurs target.appendJavascript("alert('ondblclick occurred');"); } }; rowItem.add(onDoubleClickBehaviour); return rowItem; } Regards, Yazeed Isaacs -Original Message- From: Igor Vaynberg [mailto:[EMAIL PROTECTED] Sent: 22 October 2008 05:46 PM To: users@wicket.apache.org Subject: Re: Double clickable rows in AjaxFallbackDefaultDataTable add a behavior to the row item that listens to ondblclick or whatever the event is called. i am not sure that TRs support this, so check in the browser first. to add the behavior to the row item override newrowitem on the table. -igor On Wed, Oct 22, 2008 at 7:58 AM, Yazeed Isaacs <[EMAIL PROTECTED]> wrote: > Hi > > Does anyone know how to implement something that could do this. > > Please point me in the right direction. > > Regards, > Yazeed Isaacs > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
pass , sorry i have no clue On Thu, Oct 23, 2008 at 10:37 AM, pieter claassen <[EMAIL PROTECTED]>wrote: > Ok, I added; > > public class Debug { >public static void debug(List list) { >for (Object item : list) { >System.out.println("++DEBUG++: " + > item.getClass().toString()); >} >} > > > and called debug just before I returned my ArrayList of question: > >public ArrayList getQuestions() { >Debug.debug(questions); >return questions; >} > > This is what I saw in my console. There are two objects in the list and > they are both QuestionAndAnswer objects > > > ++DEBUG++: class com.musmato.model.QuestionAndAnswer > ++DEBUG++: class com.musmato.model.QuestionAndAnswer > > Regards, > Pieter > > > On Oct 23, 2008, at 11:18 AM, Dipu wrote: > > can't you check what exactly is being returned by template.getQuestions() >> and if its a list what are the items in it >> >> >> >> >> On Thu, Oct 23, 2008 at 10:10 AM, pieter claassen <[EMAIL PROTECTED] >> >wrote: >> >> Hi Dipu, >>> >>> I tried that but when I do the following: >>> >>> protected void populateItem(ListItem item) { >>> System.out.println("+++" + >>> item.getModelObject().getClass().getName()); >>> final QuestionAndAnswer qanda = (QuestionAndAnswer) >>> item.getModelObject(); >>> >>> I find that I now get the ClassCastException in the System.out.println >>> line. It is clear as mud that the problem is that I am trying to force >>> something into a list which is not a list? >>> >>> Regards, >>> Pieter >>> >>> >>> >>> On Oct 23, 2008, at 10:59 AM, Dipu wrote: >>> >>> looks like template.getQuestions() is returning a list with items in it >>> which is not of the type QuestionAndAnswer try iterating through the list and logging the class name of each item in it Dipu On Thu, Oct 23, 2008 at 9:46 AM, pieter claassen <[EMAIL PROTECTED] > wrote: > I am getting a classcast exception in ListView that is stumping me. > > This is the error message (top few lines) > > WicketMessage: Error attaching this container for rendering: > [MarkupContainer [Component id = questioneditform]] > > Root cause: > > java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer > at > > > org.apache.wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) > at org.apache.wicket.Component.getModelObject(Component.java:1558) > at > > > com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm$1.populateItem(TemplateEditPage.java:93) > > > This is the code that generates my ListItems: > >ListView questions = new ListView("questions", > template >.getQuestions()) { > > >@Override >protected void populateItem(ListItem item) { >final QuestionAndAnswer qanda = > (QuestionAndAnswer) item >.getModelObject(); >setModel(new > CompoundPropertyModel(qanda)); > > > > I know for a fact that template.getQuestions() produces an ArrayList. > > The arraylist works when there is only 1 item in it but when I have > more > than 1 item, it fails with the ClassCastException. Is this a wicket > problem > or am I doing something wrong? > > Regards, > Pieter > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > pieter claassen >>> [EMAIL PROTECTED] >>> >>> >>> >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >>> > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: ListView broken?
Ok, I added; public class Debug { public static void debug(List list) { for (Object item : list) { System.out.println("++DEBUG++: " + item.getClass().toString()); } } and called debug just before I returned my ArrayList of question: public ArrayList getQuestions() { Debug.debug(questions); return questions; } This is what I saw in my console. There are two objects in the list and they are both QuestionAndAnswer objects ++DEBUG++: class com.musmato.model.QuestionAndAnswer ++DEBUG++: class com.musmato.model.QuestionAndAnswer Regards, Pieter On Oct 23, 2008, at 11:18 AM, Dipu wrote: can't you check what exactly is being returned by template.getQuestions() and if its a list what are the items in it On Thu, Oct 23, 2008 at 10:10 AM, pieter claassen <[EMAIL PROTECTED] >wrote: Hi Dipu, I tried that but when I do the following: protected void populateItem(ListItem item) { System.out.println("+++" + item.getModelObject().getClass().getName()); final QuestionAndAnswer qanda = (QuestionAndAnswer) item.getModelObject(); I find that I now get the ClassCastException in the System.out.println line. It is clear as mud that the problem is that I am trying to force something into a list which is not a list? Regards, Pieter On Oct 23, 2008, at 10:59 AM, Dipu wrote: looks like template.getQuestions() is returning a list with items in it which is not of the type QuestionAndAnswer try iterating through the list and logging the class name of each item in it Dipu On Thu, Oct 23, 2008 at 9:46 AM, pieter claassen <[EMAIL PROTECTED] wrote: I am getting a classcast exception in ListView that is stumping me. This is the error message (top few lines) WicketMessage: Error attaching this container for rendering: [MarkupContainer [Component id = questioneditform]] Root cause: java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer at org .apache .wicket .markup.html.list.ListItemModel.getObject(ListItemModel.java:55) at org.apache.wicket.Component.getModelObject(Component.java:1558) at com.musmato.wicket.pages.templates.TemplateEditPage $QuestionEditForm$1.populateItem(TemplateEditPage.java:93) This is the code that generates my ListItems: ListView questions = new ListView("questions", template .getQuestions()) { @Override protected void populateItem(ListItem item) { final QuestionAndAnswer qanda = (QuestionAndAnswer) item .getModelObject (); setModel(new CompoundPropertyModel(qanda)); I know for a fact that template.getQuestions() produces an ArrayList. The arraylist works when there is only 1 item in it but when I have more than 1 item, it fails with the ClassCastException. Is this a wicket problem or am I doing something wrong? Regards, Pieter pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
can't you check what exactly is being returned by template.getQuestions() and if its a list what are the items in it On Thu, Oct 23, 2008 at 10:10 AM, pieter claassen <[EMAIL PROTECTED]>wrote: > Hi Dipu, > > I tried that but when I do the following: > >protected void populateItem(ListItem item) { >System.out.println("+++" + > item.getModelObject().getClass().getName()); >final QuestionAndAnswer qanda = (QuestionAndAnswer) > item.getModelObject(); > > I find that I now get the ClassCastException in the System.out.println > line. It is clear as mud that the problem is that I am trying to force > something into a list which is not a list? > > Regards, > Pieter > > > > On Oct 23, 2008, at 10:59 AM, Dipu wrote: > > looks like template.getQuestions() is returning a list with items in it >> which is not of the type QuestionAndAnswer >> >> try iterating through the list and logging the class name of each item in >> it >> >> Dipu >> >> >> >> On Thu, Oct 23, 2008 at 9:46 AM, pieter claassen <[EMAIL PROTECTED] >> >wrote: >> >> I am getting a classcast exception in ListView that is stumping me. >>> >>> This is the error message (top few lines) >>> >>> WicketMessage: Error attaching this container for rendering: >>> [MarkupContainer [Component id = questioneditform]] >>> >>> Root cause: >>> >>> java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer >>> at >>> >>> org.apache.wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) >>> at org.apache.wicket.Component.getModelObject(Component.java:1558) >>> at >>> >>> com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm$1.populateItem(TemplateEditPage.java:93) >>> >>> >>> This is the code that generates my ListItems: >>> >>> ListView questions = new ListView("questions", >>> template >>> .getQuestions()) { >>> >>> >>> @Override >>> protected void populateItem(ListItem item) { >>> final QuestionAndAnswer qanda = >>> (QuestionAndAnswer) item >>> .getModelObject(); >>> setModel(new >>> CompoundPropertyModel(qanda)); >>> >>> >>> >>> I know for a fact that template.getQuestions() produces an ArrayList. >>> >>> The arraylist works when there is only 1 item in it but when I have more >>> than 1 item, it fails with the ClassCastException. Is this a wicket >>> problem >>> or am I doing something wrong? >>> >>> Regards, >>> Pieter >>> pieter claassen >>> [EMAIL PROTECTED] >>> >>> >>> >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >>> > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: ListView broken?
Hi Dipu, I tried that but when I do the following: protected void populateItem(ListItem item) { System.out.println("+++" + item.getModelObject().getClass().getName()); final QuestionAndAnswer qanda = (QuestionAndAnswer) item.getModelObject(); I find that I now get the ClassCastException in the System.out.println line. It is clear as mud that the problem is that I am trying to force something into a list which is not a list? Regards, Pieter On Oct 23, 2008, at 10:59 AM, Dipu wrote: looks like template.getQuestions() is returning a list with items in it which is not of the type QuestionAndAnswer try iterating through the list and logging the class name of each item in it Dipu On Thu, Oct 23, 2008 at 9:46 AM, pieter claassen <[EMAIL PROTECTED] >wrote: I am getting a classcast exception in ListView that is stumping me. This is the error message (top few lines) WicketMessage: Error attaching this container for rendering: [MarkupContainer [Component id = questioneditform]] Root cause: java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer at org .apache .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java: 55) at org.apache.wicket.Component.getModelObject(Component.java:1558) at com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm $1.populateItem(TemplateEditPage.java:93) This is the code that generates my ListItems: ListView questions = new ListView("questions", template .getQuestions()) { @Override protected void populateItem(ListItem item) { final QuestionAndAnswer qanda = (QuestionAndAnswer) item .getModelObject (); setModel(new CompoundPropertyModel(qanda)); I know for a fact that template.getQuestions() produces an ArrayList. The arraylist works when there is only 1 item in it but when I have more than 1 item, it fails with the ClassCastException. Is this a wicket problem or am I doing something wrong? Regards, Pieter pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
Comments inline: On Oct 23, 2008, at 10:59 AM, Serkan Camurcuoglu wrote: it seems like template.getQuestions() returns a model which has a QuestionAndAnswer instance instead of a list as its model object.. This is the code in template that returns an arraylist. public ArrayList getQuestions() { return questions; } Is this correct? P The code on the line where the exception is thrown is: return ((List)listView.getModelObject()).get(index); which indicates that your problem is trying to cast a QuestionAndAnswer instance to a List. Everyone is using ListView and it cannot be broken this way :) Pieter Claassen wrote: I am getting a classcast exception in ListView that is stumping me. This is the error message (top few lines) WicketMessage: Error attaching this container for rendering: [MarkupContainer [Component id = questioneditform]] Root cause: java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer at org .apache .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java: 55) at org.apache.wicket.Component.getModelObject(Component.java:1558) at com.musmato.wicket.pages.templates.TemplateEditPage $QuestionEditForm $1.populateItem(TemplateEditPage.java:93) This is the code that generates my ListItems: ListView questions = new ListView("questions", template .getQuestions()) { @Override protected void populateItem(ListItem item) { final QuestionAndAnswer qanda = (QuestionAndAnswer) item .getModelObject(); setModel(new CompoundPropertyModel(qanda)); I know for a fact that template.getQuestions() produces an ArrayList. The arraylist works when there is only 1 item in it but when I have more than 1 item, it fails with the ClassCastException. Is this a wicket problem or am I doing something wrong? Regards, Pieter pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/ListView-broken--tp20126952p20127126.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Scrolling items in a data view
I have a data view area which i populate with a series of records, I limit the items displayed per page to say '4' and i then allow the user to 'page' through the items via two links ie. "view next"/ "view prev" this works fine and im able to see the appropriate page of info on the screen. However what i would like is that instead of the new items replacing the original items on the screen, the items are appended in a dynamic fashion i.e the old items 'roll' off the page and the new items 'roll' on. Has anyone done anything lik ethis before? is it even possible? Cheers -- View this message in context: http://www.nabble.com/Scrolling-items-in-a-data-view-tp20127200p20127200.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problem with a stateless form
Hi, I made a small application to reproduce the problem. You can download it from http://aditsu.net/wickettest.zip Dependencies: jetty 6, wicket 1.4-m3, slf4j, log4j Steps to reproduce: 1. Run the test.Start class 2. Open http://localhost:8080 in a browser 3. Open http://localhost:8080/page2 in a new tab 4. Go to the first tab and click submit Result: WicketRuntimeException: unable to find component with path form on stateless page [Page class = test.Page2, id = 0, version = 0] It looks like the 2 pages are created with the same id in 2 different pagemaps, but when I submit the form, it goes to the second pagemap and finds the second page (with no form on it). Bug? -- View this message in context: http://www.nabble.com/Problem-with-a-stateless-form-tp20127191p20127191.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
it seems like template.getQuestions() returns a model which has a QuestionAndAnswer instance instead of a list as its model object.. The code on the line where the exception is thrown is: return ((List)listView.getModelObject()).get(index); which indicates that your problem is trying to cast a QuestionAndAnswer instance to a List. Everyone is using ListView and it cannot be broken this way :) Pieter Claassen wrote: > > I am getting a classcast exception in ListView that is stumping me. > > This is the error message (top few lines) > > WicketMessage: Error attaching this container for rendering: > [MarkupContainer [Component id = questioneditform]] > > Root cause: > > java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer > at > org > .apache > .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) > at org.apache.wicket.Component.getModelObject(Component.java:1558) > at com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm > $1.populateItem(TemplateEditPage.java:93) > > > This is the code that generates my ListItems: > > ListView questions = new ListView("questions", template > .getQuestions()) { > > > @Override > protected void populateItem(ListItem item) { > final QuestionAndAnswer qanda = > (QuestionAndAnswer) item > .getModelObject(); > setModel(new > CompoundPropertyModel(qanda)); > > > > I know for a fact that template.getQuestions() produces an ArrayList. > > The arraylist works when there is only 1 item in it but when I have > more than 1 item, it fails with the ClassCastException. Is this a > wicket problem or am I doing something wrong? > > Regards, > Pieter > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/ListView-broken--tp20126952p20127126.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ListView broken?
looks like template.getQuestions() is returning a list with items in it which is not of the type QuestionAndAnswer try iterating through the list and logging the class name of each item in it Dipu On Thu, Oct 23, 2008 at 9:46 AM, pieter claassen <[EMAIL PROTECTED]>wrote: > I am getting a classcast exception in ListView that is stumping me. > > This is the error message (top few lines) > > WicketMessage: Error attaching this container for rendering: > [MarkupContainer [Component id = questioneditform]] > > Root cause: > > java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer > at > org.apache.wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) > at org.apache.wicket.Component.getModelObject(Component.java:1558) > at > com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm$1.populateItem(TemplateEditPage.java:93) > > > This is the code that generates my ListItems: > >ListView questions = new ListView("questions", > template >.getQuestions()) { > > >@Override >protected void populateItem(ListItem item) { >final QuestionAndAnswer qanda = > (QuestionAndAnswer) item >.getModelObject(); >setModel(new > CompoundPropertyModel(qanda)); > > > > I know for a fact that template.getQuestions() produces an ArrayList. > > The arraylist works when there is only 1 item in it but when I have more > than 1 item, it fails with the ClassCastException. Is this a wicket problem > or am I doing something wrong? > > Regards, > Pieter > pieter claassen > [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
ListView broken?
I am getting a classcast exception in ListView that is stumping me. This is the error message (top few lines) WicketMessage: Error attaching this container for rendering: [MarkupContainer [Component id = questioneditform]] Root cause: java.lang.ClassCastException: com.musmato.model.QuestionAndAnswer at org .apache .wicket.markup.html.list.ListItemModel.getObject(ListItemModel.java:55) at org.apache.wicket.Component.getModelObject(Component.java:1558) at com.musmato.wicket.pages.templates.TemplateEditPage$QuestionEditForm $1.populateItem(TemplateEditPage.java:93) This is the code that generates my ListItems: ListView questions = new ListView("questions", template .getQuestions()) { @Override protected void populateItem(ListItem item) { final QuestionAndAnswer qanda = (QuestionAndAnswer) item .getModelObject(); setModel(new CompoundPropertyModel(qanda)); I know for a fact that template.getQuestions() produces an ArrayList. The arraylist works when there is only 1 item in it but when I have more than 1 item, it fails with the ClassCastException. Is this a wicket problem or am I doing something wrong? Regards, Pieter pieter claassen [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SortablePalette possible?
And a link to the image I promised: http://img395.imageshack.us/my.php?image=sortablepaletteea0.jpg (may contain some horrible adds) Rommert de Bruijn wrote: Hi all, I'm currently working on a web application that requires Persons to be added/removed to/from a UserGroup. What I have in mind is much like the Palette component, but with added functionality: a) a left hand list with all unselected Persons , a right hand list with selected Persons, and buttons to move Persons from left to right and vice versa, supporting Ctrl/Shift+click behavior to make selections. b) each item in the list shows firstName and lastName, as tabular data. c) up/down sorting behavior on each property that is displayed (in this case: firstName and lastName), for both lists. a) is basically Palette. But b) does not go well with Palette, since the tag in Palette is not allowed (w3c) to take any additional html such as and . To display tabular data, I could use a DataView, which would work nicely with c) using OrderByBorders. But alas: DataView does not support the Ctrl/Shift+click behavior that I need. As they say: pictures say more then 1000 words. So I'll skip the other 800 or so words and attach a screenshot of what I'd like to make :) The image contains some Dutch text, which I'll gladly translate if necessary. My actual questions: - Has anyone tried this before, either successful or unsuccessful? - Which components would you use to create something that does all this? - If this combination of functionality seems impossible to merge into one component, which functionality would you drop to create "the next best thing"? Thanks in advance, Rommert de Bruijn - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Rommert de Bruijn Func. Internet Integration W http://www.func.nl T +31 20 423 F +31 20 4223500 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SortablePalette possible?
Hi all, I'm currently working on a web application that requires Persons to be added/removed to/from a UserGroup. What I have in mind is much like the Palette component, but with added functionality: a) a left hand list with all unselected Persons , a right hand list with selected Persons, and buttons to move Persons from left to right and vice versa, supporting Ctrl/Shift+click behavior to make selections. b) each item in the list shows firstName and lastName, as tabular data. c) up/down sorting behavior on each property that is displayed (in this case: firstName and lastName), for both lists. a) is basically Palette. But b) does not go well with Palette, since the tag in Palette is not allowed (w3c) to take any additional html such as and . To display tabular data, I could use a DataView, which would work nicely with c) using OrderByBorders. But alas: DataView does not support the Ctrl/Shift+click behavior that I need. As they say: pictures say more then 1000 words. So I'll skip the other 800 or so words and attach a screenshot of what I'd like to make :) The image contains some Dutch text, which I'll gladly translate if necessary. My actual questions: - Has anyone tried this before, either successful or unsuccessful? - Which components would you use to create something that does all this? - If this combination of functionality seems impossible to merge into one component, which functionality would you drop to create "the next best thing"? Thanks in advance, Rommert de Bruijn -- Rommert de Bruijn Func. Internet Integration W http://www.func.nl T +31 20 423 F +31 20 4223500 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What's the difference between Check and CheckBox
the main difference is that checks belong to a checkgroup (useful in repeaters) and checkbox is convenient when used alone "check" out http://www.wicketstuff.org/wicket13/forminput/ ;-) regards, Michael Minto van der Sluis wrote: > > Messing around with unittesting a CheckBox, I discovered Check as well: > > org.apache.wicket.markup.html.form.Check; > org.apache.wicket.markup.html.form.CheckBox; > > To me it's not very clean what the difference is, since they are both > attached to the same markup: > > > > Can anyone enlighten me ? > > regards, > > Minto van der Sluis > - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/What%27s-the-difference-between-Check-and-CheckBox-tp20125256p20126224.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: redirect issue on IE causing HTTP 404
Hello Igor, Im still investagating the scenario because in different machine where IE7 and IE6 install it works fine. Im just wandering why here in my machine (IE7) is not working. sorry for the inconvenience. i will just investigate before posting again. Thanks a lot. Cheers. igor.vaynberg wrote: > > create a quickstart that reproduces this and attach it to a jira issue. > > -igor > > On Wed, Oct 22, 2008 at 9:27 PM, freak182 <[EMAIL PROTECTED]> wrote: >> >> Hello Igor, >> >> I have a problem in IE when i redirect wicket pages using javascript >> using >> location.href = '?wicket:interface=:3' . here is the scenario: >> >> public class InitBehavior extends AbstractBehavior >> { >> final IModel params = new AbstractReadOnlyModel() { >> >>@Override >>public Object getObject() >>{ >> >>// redirect url's >>map.put("roamUrl", >> RequestCycle.get().urlFor(NoIdPage.class, >> null)); >>map.put("loginUrl", RequestCycle.get().urlFor(new >> LoginPage())); >>map.put("errorUrl", RequestCycle.get().urlFor(new >> ErrorPage())); >>return map; >>} >> >>}; >> >>component.add(TextTemplateHeaderContributor.forJavaScript( >>InitBehavior.class, "init.js", params)); >>super.bind(component); >>} >> >> ... >> } >> >> and in init.js >> >> function clientReady() { >> >> >>// detect if arcot id exist >>if (!IDExists(strWFUserID)) { >>if (Flag) { >>// >> document.getElementById('divErrPopup').style.display = 'block'; >> >>location.href = '${errorUrl}'; >>} else { >> >> >> location.href = '${roamUrl}'; >>} >>} else { >> >> >>location.href = '${loginUrl}'; >> >>} >> } >> >> this script is executed upon loading of the page. This working fine in >> firefox. im using wicket 1.3.4 i also try the latest release 1.3.5 but it >> still problem in IE(http://localhost:8080/test/undefined). I also, >> mount(new >> QueryStringUrlCodingStrategy("noid", NoIdPage.class)); again this works >> only >> in firefox but not in IE. since our client mostly IE users. i also found >> this bug https://issues.apache.org/jira/browse/WICKET-1449 ... How can i >> solve this problem? Is there a work around to this? >> >> Thanks a lot. >> Cheers. >> >> -- >> View this message in context: >> http://www.nabble.com/redirect-issue-on-IE-causing-HTTP-4040-tp20124228p20124228.html >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/redirect-issue-on-IE-causing-HTTP-404-tp20124228p20125698.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: have anyone tried empire-DB?
>seems to me you just dont grasp how the mappings work. lol yes, I am new to it so lots to grasp. To be fair I did sort out the mappings to use List after a lot of messing about. I just find things take a long time to behave correctly in Hibernate, and thus not very productive - for me it one of the harder frameworks to get up to speed with , especially as I'm using the annotations and most of the doc/knowledge base is around the xml form. Perhaps I should switch. However my original quesiton still stands - any other db frameworks that anyone recommends? On Thu, Oct 23, 2008 at 9:03 AM, Igor Vaynberg <[EMAIL PROTECTED]>wrote: > seems to me you just dont grasp how the mappings work. eg if you use a > @OneToMany with mappedby and let the other side control the > association then nothing is automatically inserted or deleted. > further, even if you do not use mappedby then nothing is deleted > unless you declare the delete orphan cascade. > > the problem here is that List is a specific type of collection where > each element is uniquely identified by its index. that is just the > nature of lists and has nothing to do with hibenrate. this generally > does not map nicely to database collections unless you actually have > an index column in your table, so lists are rarely used when dealing > with databases... > > i will agree with you as far as hibernate's horrible error reporting, > but other then that i find it a good tool and do not see many cases > where the abstraction leaks into actual coding style. some concepts > are very leaky, such as lazy loading, but that cant really be helped. > > -igor > > On Wed, Oct 22, 2008 at 11:56 PM, Wayne Pope > <[EMAIL PROTECTED]> wrote: > > well I'm new to Hibernate, and it seems that you must be extremely > consious > > of how hibernate handles mapping etc. This may also be the same with > other > > object to relational frameworks. An example is the the behaviour of > > OneToMany mappings using List as this uses "bag sematics". Hibernate's > > handling of these relationships is somewhat brute force i.e. it deletes > > existing entries and re-inserts to match the current collection and > > therefore you need to use Set's or use collectionid to create an idbag. > > Therefore straight away I can't use a List (which is all I need) in the > > code. > > > > There seems (to me) many many gotchas with Hibernate that you need to be > > aware of and the error messages don't tell you much compare to say > Wicket. > > > > I come from a world where we used stored proceedures before and you > simply > > provided the straight mapping from the result columns to your pojos. This > > was very flexible as you could change your pojos with no impact to the db > > structure and vice-versa we could completly change the db schema (for > > performance or any reason) with no impact on the code. This seems to work > > well. > > > > On Thu, Oct 23, 2008 at 8:36 AM, Igor Vaynberg <[EMAIL PROTECTED] > >wrote: > > > >> im curious in what way does it influence java code... > >> > >> -igor > >> > >> On Wed, Oct 22, 2008 at 10:59 PM, Wayne Pope > >> <[EMAIL PROTECTED]> wrote: > >> > Nino what do you recommend in terms orf DB framework. We're currently > >> using > >> > Hibernate and I'm personally finding it a pain - it seems to influence > >> the > >> > java code way too much and it create some horrible joins if we're not > >> > carefull. Any suggestions that you've used in the real world? > >> > > >> > On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael > < > >> > [EMAIL PROTECTED]> wrote: > >> > > >> >> This is interesting: > >> >> > >> >> (JaQu) Provide API level compatibility with JPA (so that JaQu can be > >> used > >> >> as an extension of JPA). > >> >> > >> >> But I think something similar are on its way for JPA 2.0..? > >> >> > >> >> > >> >> marco.behler wrote: > >> >> > >> >>> I gave empireDB a quick look a while ago and it looks interesting. > >> Besides > >> >>> JPersist I also stumbled upon JaQu > >> >>> (http://www.h2database.com/html/jaqu.html), which is still in its > >> >>> infancy. > >> >>> I'm sure there's more LINQ-like clones out there. > >> >>> > >> >>> As far as I'm concerned, I'd really like to have a thorough look at > >> stuff > >> >>> like db4o or couchDB, especially performance wise. I did > >> Hibernate/iBatis > >> >>> in > >> >>> the past and am currently working on a project with iBatis again. > Both > >> >>> have > >> >>> advantages and disadvantages and I don't "love" either. I would > rather > >> not > >> >>> have to care about tables, objects,the mighty mismatch (and in > >> Hibernate's > >> >>> case the mighty session) anymore, but just shove that damn thing > into > >> an > >> >>> object database ;) > >> >>> > >> >>> *hides from enraged DBAs and their optimised queries* > >> >>> > >> >>> > >> >>> > >> >>> Nino.Martinez wrote: > >> >>> > >> >>> > >> Yeah seems to be nice... > >> > >> At WUG DK we discussed. That if using stuff like hib
Re: have anyone tried empire-DB?
seems to me you just dont grasp how the mappings work. eg if you use a @OneToMany with mappedby and let the other side control the association then nothing is automatically inserted or deleted. further, even if you do not use mappedby then nothing is deleted unless you declare the delete orphan cascade. the problem here is that List is a specific type of collection where each element is uniquely identified by its index. that is just the nature of lists and has nothing to do with hibenrate. this generally does not map nicely to database collections unless you actually have an index column in your table, so lists are rarely used when dealing with databases... i will agree with you as far as hibernate's horrible error reporting, but other then that i find it a good tool and do not see many cases where the abstraction leaks into actual coding style. some concepts are very leaky, such as lazy loading, but that cant really be helped. -igor On Wed, Oct 22, 2008 at 11:56 PM, Wayne Pope <[EMAIL PROTECTED]> wrote: > well I'm new to Hibernate, and it seems that you must be extremely consious > of how hibernate handles mapping etc. This may also be the same with other > object to relational frameworks. An example is the the behaviour of > OneToMany mappings using List as this uses "bag sematics". Hibernate's > handling of these relationships is somewhat brute force i.e. it deletes > existing entries and re-inserts to match the current collection and > therefore you need to use Set's or use collectionid to create an idbag. > Therefore straight away I can't use a List (which is all I need) in the > code. > > There seems (to me) many many gotchas with Hibernate that you need to be > aware of and the error messages don't tell you much compare to say Wicket. > > I come from a world where we used stored proceedures before and you simply > provided the straight mapping from the result columns to your pojos. This > was very flexible as you could change your pojos with no impact to the db > structure and vice-versa we could completly change the db schema (for > performance or any reason) with no impact on the code. This seems to work > well. > > On Thu, Oct 23, 2008 at 8:36 AM, Igor Vaynberg <[EMAIL PROTECTED]>wrote: > >> im curious in what way does it influence java code... >> >> -igor >> >> On Wed, Oct 22, 2008 at 10:59 PM, Wayne Pope >> <[EMAIL PROTECTED]> wrote: >> > Nino what do you recommend in terms orf DB framework. We're currently >> using >> > Hibernate and I'm personally finding it a pain - it seems to influence >> the >> > java code way too much and it create some horrible joins if we're not >> > carefull. Any suggestions that you've used in the real world? >> > >> > On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael < >> > [EMAIL PROTECTED]> wrote: >> > >> >> This is interesting: >> >> >> >> (JaQu) Provide API level compatibility with JPA (so that JaQu can be >> used >> >> as an extension of JPA). >> >> >> >> But I think something similar are on its way for JPA 2.0..? >> >> >> >> >> >> marco.behler wrote: >> >> >> >>> I gave empireDB a quick look a while ago and it looks interesting. >> Besides >> >>> JPersist I also stumbled upon JaQu >> >>> (http://www.h2database.com/html/jaqu.html), which is still in its >> >>> infancy. >> >>> I'm sure there's more LINQ-like clones out there. >> >>> >> >>> As far as I'm concerned, I'd really like to have a thorough look at >> stuff >> >>> like db4o or couchDB, especially performance wise. I did >> Hibernate/iBatis >> >>> in >> >>> the past and am currently working on a project with iBatis again. Both >> >>> have >> >>> advantages and disadvantages and I don't "love" either. I would rather >> not >> >>> have to care about tables, objects,the mighty mismatch (and in >> Hibernate's >> >>> case the mighty session) anymore, but just shove that damn thing into >> an >> >>> object database ;) >> >>> >> >>> *hides from enraged DBAs and their optimised queries* >> >>> >> >>> >> >>> >> >>> Nino.Martinez wrote: >> >>> >> >>> >> Yeah seems to be nice... >> >> At WUG DK we discussed. That if using stuff like hibernate, for simple >> cruds it's nice but if you have a complex object graph it becomes very >> troublesome to use (if you use cascade all etc.).. >> >> Ames, Tim wrote: >> >> >> > Looks like it has a lot in common with JPersist. That is what I have >> > been using. No XML, all POJO. >> > >> > -Original Message- >> > From: Nino Saturnino Martinez Vazquez Wael >> > [mailto:[EMAIL PROTECTED] >> > Sent: Thursday, October 16, 2008 11:28 AM >> > To: users@wicket.apache.org >> > Subject: have anyone tried empire-DB? >> > >> > So have you tried it with wicket? >> > >> > http://incubator.apache.org/empire-db/ >> > >> > -- >> > -Wicket for love >> > >> > Nino Martinez Wael >> > Java Specialist @ Jayway DK >> > http://www.jayway.dk >>