Re: Modal Window defined in actionpanel

2011-01-17 Thread gnugrf

I figured it out - I was creating the modal window inside the onClick()
method, but it needed to take place outside the method. I was able to put
the markup inside the corresponding action panel html. When the onclick is
called it's just recreating the modal window (because we need to construct
with the appropriate lineitem id).
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Modal-Window-defined-in-actionpanel-tp3221239p3221274.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Modal Window defined in actionpanel

2011-01-17 Thread gnugrf

I'm trying to get a modal window to popup to make edits on line items from a
Listview. I have an actionpanel with an "edit" button and I am having
troubles figuring out where to put the markup -- 
. The actionpanel is an inner class taken from
the repeater examples. I've tried adding the modal window markup to the page
and to the markup for the actionpanel and neither are working. Maybe it is
dumb to create the modal window in onClick() method?
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Modal-Window-defined-in-actionpanel-tp3221239p3221239.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: quick page model question

2011-01-04 Thread gnugrf

Thanks a million man!

I wasn't calling super(model) and after figuring out how to attach sources
(which I hadn't known about), I was able to see that the page model was
being detached and refreshed. The labels on the page aren't updating, but
I'm assuming I need to provide each component with dynamic models e.g
propertymodels referencing the page model. 

You saved me weeks of searching and I can't tell you how much I appreciate
the time you took helping me. 
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/quick-page-model-question-tp3172678p3174289.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: quick page model question

2011-01-04 Thread gnugrf

Jeremy thanks for your patience, I have a couple of questions about your
replies. 

1. If my constructors for the page are 
public ManageClientPage(long id){this(new ClientLDM(id));}
public ManageClientPage(IModel client) { ///code here} 

and the page is being called using ... ManageclientPage(clientId) isn't the
second constructor setting the page model? Previously I was making an
explicit call to setDefaultModel(), but it seemed to have the same
functionality, and I thought setting the model through the constructor
seemed cleaner.

2. How do I set a breakpoint on a method inherited from an abstract class? I
would assume setting it on the detach method in the abstract class. Isnt
this going to make execution stop every time ANY ldm detaches?




-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/quick-page-model-question-tp3172678p3173857.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: quick page model question

2011-01-04 Thread gnugrf

I set a breakpoint within the load() and when the page first gets constructed
I am able to watch the code get executed. When I refresh, the listview on
the page (which uses a different LDM) does get called again, however this
LDM (the model for the page) does not.

I think I probably copied most of this from the examples I've found. I read
detach happens automatically and that I didn't need to override it, is that
true?

public class ClientLDM extends LoadableDetachableModel
{
@SpringBean
ClientService clientService;

private final long id;

public ClientLDM(Client c){this(c.getId());}

public ClientLDM(long id){

InjectorHolder.getInjector().inject(this);
if (id == 0)
{
throw new IllegalArgumentException();
}
this.id = id;
}

@Override
public int hashCode()
{
return Long.valueOf(id).hashCode();
}

@Override
public boolean equals(final Object obj)
{
if (obj == this)
{
return true;
}
else if (obj == null)
{
return false;
}
else if (obj instanceof ClientLDM)
{
ClientLDM other = (ClientLDM)obj;
return other.id == id;
}
return false;
}

@Override
protected Client load()
{

Client client = new Client();
try {
  client = clientService.loadClient("web", id);
} catch (InvalidClientException e) {
e.printStackTrace();
}
return client;
}


}
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/quick-page-model-question-tp3172678p3173721.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: quick page model question

2011-01-03 Thread gnugrf

I'm pretty much a noob, even though I've been slowly working on a project for
about a year so bear with me. I've read "understanding models" a couple
dozen times already and lifecycle, requestcycle, etc. and did a fair amount
of slogging through the mailing list for old posts about "page resfresh"
"page model", etc. and didnt find anything to help me, so forgive my
stupidity..

How would i refresh it in the loadabledetachable model (how would the model
know when the page has been refreshed)

onbeforerender makes sense to me since its an event, i suppose you are
saying to override that method and i could force the page to reload the
model there. i saw in the javadocs it warned to call super.onbeforerender at
the end.

is there any advantage to either direction?

also as a sanity check my constructors are -->

public ManageClientPage(long id){this(new ClientLDM(id));}
public ManageClientPage(IModel client) { ///code here}

and its being called using id.
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/quick-page-model-question-tp3172678p3172797.html
Sent from the Users forum mailing list archive at Nabble.com.

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



quick page model question

2011-01-03 Thread gnugrf

how do you get the page model to refresh when a user presses "reload" or F5?
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/quick-page-model-question-tp3172678p3172678.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: wicket-extensions alive?

2010-08-23 Thread gnugrf

Thank you JT, the day I was working on this when I checked the maven
repository, the first search result returns the older versions of
wicket-extensions based off the groupid = "wicket". It was my mistake, I
didn't realize at the time there was a newer branch based off groupid =
"org.apache.wicket", but your response forced me to do a sanity-check and go
back to the maven repo. Thank You.
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-extensions-alive-tp2324725p2335894.html
Sent from the Wicket - User mailing list archive at Nabble.com.

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



Re: wicket-extensions alive?

2010-08-16 Thread gnugrf

ok, I had read that in a post from several years ago, it just didnt make
sense to me, because I thought "alive and well" would mean that is has some
ability to work with a more current version of wicket. a bit misleading
first response.
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-extensions-alive-tp2324725p2327366.html
Sent from the Wicket - User mailing list archive at Nabble.com.

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



Re: wicket-extensions alive?

2010-08-13 Thread gnugrf

Yeah I noticed that when I checked the maven repo that it required
commons-collections, so I tried adding version 3.2.1. I ended up with the
following error: 

java.lang.ClassCastException: wicket.extensions.Initializer cannot be cast
to org.apache.wicket.IInitializer

The maven repo stated that wicket-extensions required commons-collections
2.1, so I thought maybe it required an older version...same error. I went as
far as checking my local .m2 repo to make sure I didnt have a corrupted .jar
- which has happened to me before. The jar opens, able to see the
LRUmap.class file, so I am at a loss..

Is the dependency right? -->


wicket
wicket-extensions
1.2.7


I noticed that all the other wicket-related stuff is under groupId
org.apache.wicket. Googling around I found someone had this same error
awhile back using inconsistent versions of wicket and wicket-spring, but
that is definitely not the case here.
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-extensions-alive-tp2324725p2324894.html
Sent from the Wicket - User mailing list archive at Nabble.com.

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



wicket-extensions alive?

2010-08-13 Thread gnugrf

I had added wicket-extensions to my pom.xml, because I was planning on making
use of DataTable and DefaultDataTable, however, I hadn't yet added any code
that would require the dependency. Made a couple changes to my project over
the weekend, and went to recompile and tomcat wouldnt start. Checked the
logs and was greeted with:

Invocation of init method failed; nested exception is
java.lang.NoClassDefFoundError: org/apache/commons/collections/map/LRUMap.
After trial and error removing some code...I finally removed the dependency
(needle in a haystack), and all the errors went away.

Q1- Is wicket-extensions alive and well? The wicket docs are still
referencing the library, so I'm guessing yes, even though it seems a couple
years since an update.

Q2- If it is alive, can anybody tell me whats going on with the errors im
having? 
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-extensions-alive-tp2324725p2324725.html
Sent from the Wicket - User mailing list archive at Nabble.com.

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



Re: Debugging in Netbeans - Lists don't load

2010-02-27 Thread gnugrf

Riyad,

Thanks for replying - I may have not been clear enough. The database
connection is fine when I run the application normally. The choices from the
dropdown list are loaded, and I've also put a temporary system.out line to
spit the contents of the list out immediately after loading, so that I can
verify the contents. Everything works UNTIL I run in debug-mode in Netbeans.
At that point, the lists dont get loaded. I don't change anything, other
than running Netbeans in debug.



Riyad Kalla wrote:
> 
> Garrett,
> 
> I would start simple, remove Wicket as much as possible from this
> situation
> first. In your DAO or whatever you are using to do the query and load the
> results from the DB -- just System.out the contents of the list to the
> console.
> 
> Until you get that working, don't bother thinking about Wicket and what is
> going on there -- it will just muddy the water.
> 
> Check your console logs on startup, your persistence framework (Hibernate)
> may be crapping out an error that is scrolling by really quick, like it
> cannot find a driver or your credentials for the DB connection are wrong.
> 
> Also try and check the console when issuing your first query, look for the
> same sort of data.
> 
> Troubleshoot that DB connection first and foremost. At that point, it's
> either a Spring issue or something else, but make sure you get that data
> out
> of the DB first before moving on.
> 
> -R
> 
> On Fri, Feb 26, 2010 at 4:28 PM, Garrett Fry
> wrote:
> 
>>
>> Qualifying information: Im a noob
>>
>> Trying to get a DropDownChoice working. Ive read every post I can find,
>> and
>> slowly losing my mind. I like to solve my own problems if I can, but I
>> can't
>> even debug properly. Everytime I set a breakpoint and step through... the
>> Lists that are loaded via spring/hibernate don't get loaded.
>> They read size(0). Because the lists dont load, I can't even find out
>> whats
>> going wrong in the DropDownChoice. gnu...@sdf.lonestar.org
>> SDF Public Access UNIX System - http://sdf.lonestar.org
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
> 
> 

-- 
View this message in context: 
http://old.nabble.com/Debugging-in-Netbeans---Lists-don%27t-load-tp27724615p27728021.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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