You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by victorTrapiello <vi...@trapiello.net> on 2010/02/01 19:01:36 UTC

Re: (my code palette) how to set default options in object palette

Hello Carlos,

Sorry but I´m new also with Maven, but I got it working, I have downloaded
all the dependencies and now I have my quickstart projects in netbeans ready
to write some code, but my question is once I write the code that I want to
share with you guys how can I share it¿? do you understand me¿? how can you
access to my code.... as I told you I´m new in maven as well ;-) do I need
to package in someway with maven¿?.... thank you very much, I´m learning
alot with you guys!!!!



Carlos Vara wrote:
> 
> Hi Victor,
> 
> a quickstart is a wicket project using this maven archetype:
> 
> http://wicket.apache.org/quickstart.html
> 
> 
> On Sun, Jan 31, 2010 at 7:46 PM, victorTrapiello
> <vi...@trapiello.net>wrote:
> 
>>
>> Thank you very mucv Nino, but what do you mena by a quick start¿? I´m new
>> in
>> this comunity.
>>
>> nino martinez wael wrote:
>> >
>> > Ok Victor next step for you would be to create a quickstart.. So we can
>> > play
>> > with it.. I've sure had this working with wicket 1.2 / 1.3 soo should
>> > still
>> > be the case.
>> >
>> > 2010/1/29 victorTrapiello <vi...@trapiello.net>
>> >
>> >>
>> >> I does not work, I think the key point is my
>> >>
>> >> IChoiceRenderer renderer = new ChoiceRenderer("fullName", "fullName");
>> >>
>> >> i leave it empty and it works for the available subject but not for
>> the
>> >> predefined!
>> >>
>> >> any more thoughts¿?
>> >>
>> >> Thank you very much guys
>> >>
>> >>
>> >>
>> >> nino martinez wael wrote:
>> >> >
>> >> > Form f=new Form("form");
>> >> >     add(f);
>> >> >     List persons = ComponentReferenceApplication.getPersons();;
>> >> >     IChoiceRenderer renderer = new ChoiceRenderer("fullName",
>> >> "fullName");
>> >> >     final Palette palette = new Palette("palette", new
>> >> > ListModel<Person>(new
>> >> > ArrayList<Person>()), new CollectionModel<Person>(
>> >> >       persons), renderer, 10, true);
>> >> > palette.setmodelObject or something like that.
>> >> >
>> >> > 2010/1/29 victorTrapiello <vi...@trapiello.net>
>> >> >
>> >> >>
>> >> >> well I have defined my palette component like this:
>> >> >>
>> >> >> asignString is an string linst with the available subjects (It
>> works
>> >> >> fine,
>> >> >> the palette shows the proper subjects, but it doesn´t show the
>> default
>> >> >> selected one which I save them in the list "lSelected"
>> >> >>
>> >> >>  IChoiceRenderer renderer = new ChoiceRenderer("", "");
>> >> >>  List<String> lSelected=new ArrayList();
>> >> >>        lSelected.add("predefined");
>> >> >>        Model aux=new Model();
>> >> >>        aux.setObject((Serializable) lSelected);
>> >> >>
>> >> >>        final Palette palette = new Palette("palette", aux, new
>> Model(
>> >> >>                (Serializable) asignString), renderer, 10, true);
>> >> >>
>> >> >> Any thought¿?
>> >> >>
>> >> >> thankyou in advance
>> >> >>
>> >> >>
>> >> >> James Carman-3 wrote:
>> >> >> >
>> >> >> > Make sure your model reflects the selected state.  Palette will
>> pick
>> >> >> > that up automatically
>> >> >> >
>> >> >> > On Sat, Jan 23, 2010 at 12:50 PM, victorTrapiello
>> >> >> <vi...@trapiello.net>
>> >> >> > wrote:
>> >> >> >>
>> >> >> >>
>> >> >> >> I use the palette component, to assigne option to a User. but I
>> >> don't
>> >> >> >> find a functionnality, how to set already selected option ?.
>> >> >> >>
>> >> >> >> Exemple : a user selected option, I store it into a database:
>> >> >> >> In the future, the user want to update his option, at the moment
>> he
>> >> >> >> doesn't see his previous selected option.
>> >> >> >>
>> >> >> >>  Do you have a solution.¿?, doe sir make sense¿?
>> >> >> >>
>> >> >> >> cheers!!
>> >> >> >>
>> >> >> >> quote author="MartinM">
>> >> >> >> Well.. you can override newChoicesComponent
>> >> >> >>
>> >> >> >> **
>> >> >> >> Martin
>> >> >> >>
>> >> >> >> 2009/4/28 新希望软件 -- 俞宏伟 <nh...@gmail.com>:
>> >> >> >>> yes, i can setMarkupId for Palette. but now i want to filter
>> for
>> >> >> >>> palette's
>> >> >> >>> choicesComponent.
>> >> >> >>>
>> >> >> >>> there is no public getChoicesComponent() method for
>> >> choicesComponent.
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>> 2009/4/28 Martin Makundi <ma...@koodaripalvelut.com>
>> >> >> >>>
>> >> >> >>>> Why cannot get markupid? You can determine it yourself
>> >> (setMarkupId)
>> >> >> >>>>
>> >> >> >>>> You could also update via ajax using a textfield which sends
>> the
>> >> >> >>>> filtered text to server and server updates the select via
>> ajax...
>> >> >> >>>>
>> >> >> >>>> I wonder if someone has made a select in which the filter is
>> >> >> visually
>> >> >> >>>> built into the select component?
>> >> >> >>>>
>> >> >> >>>> **
>> >> >> >>>> Martin
>> >> >> >>>>
>> >> >> >>>> 2009/4/28 新希望软件 -- 俞宏伟 <nh...@gmail.com>:
>> >> >> >>>> > I want to add a filter for palette choice list, because
>>  choice
>> >> >> list
>> >> >> >>>>  have a
>> >> >> >>>> > very large HTML SELECT list.
>> >> >> >>>> >
>> >> >> >>>> > I found that there is a select filter implement(
>> >> >> >>>> > http://www.barelyfitz.com/projects/filterlist/index.php/1),
>> but
>> >> i
>> >> >> can
>> >> >> >>>> not
>> >> >> >>>> > get select component markupid, so filter can not init.
>> >> >> >>>> >
>> >> >> >>>> > --
>> >> >> >>>> >
>> >> >> >>>> > H. L. Mencken <
>> >> >> >>>> http://www.brainyquote.com/quotes/authors/h/h_l_mencken.html>
>> >> >> >>>> > - "It is even harder for the average ape to believe that he
>> has
>> >> >> >>>> > descended
>> >> >> >>>> > from man."
>> >> >> >>>> >
>> >> >> >>>>
>> >> >> >>>>
>> >> >>
>> ---------------------------------------------------------------------
>> >> >> >>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> >> >>>> For additional commands, e-mail: users-help@wicket.apache.org
>> >> >> >>>>
>> >> >> >>>>
>> >> >> >>>
>> >> >> >>
>> >> >> >>
>> >> ---------------------------------------------------------------------
>> >> >> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> >> >> For additional commands, e-mail: users-help@wicket.apache.org
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> View this message in context:
>> >> >> >>
>> >> >>
>> >>
>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27288282.html
>> >> >> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> ---------------------------------------------------------------------
>> >> >> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> >> >> For additional commands, e-mail: users-help@wicket.apache.org
>> >> >> >>
>> >> >> >>
>> >> >> >
>> >> >> >
>> >> ---------------------------------------------------------------------
>> >> >> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> >> > For additional commands, e-mail: users-help@wicket.apache.org
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >>
>> >> >> --
>> >> >> View this message in context:
>> >> >>
>> >>
>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27374968.html
>> >> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >> >>
>> >> >>
>> >> >>
>> ---------------------------------------------------------------------
>> >> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> >> For additional commands, e-mail: users-help@wicket.apache.org
>> >> >>
>> >> >>
>> >> >
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27378863.html
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> For additional commands, e-mail: users-help@wicket.apache.org
>> >>
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27395876.html
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
> 
> 

-- 
View this message in context: http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27408497.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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


Re: (my code palette) how to set default options in object palette

Posted by victorTrapiello <vi...@trapiello.net>.
Also to say that my code is very basic I only want to add this palette
component to show you that it doesn´t show the default list of subjects:

   List Subjects = new ArrayList();

        Subjects.add("MATHS");
        Subjects.add("ENGLISH");
        List<String> ldefault = new ArrayList();

        ldefault.add("predefined 1");
        ldefault.add("predefined 2");
        Model DefaultSubjects = new Model();

        IChoiceRenderer renderer = new ChoiceRenderer("", "");
        DefaultSubjects.setObject((Serializable) ldefault);



        add(new Palette("palette", new Model(new ArrayList()), new Model(
                (Serializable) Subjects), renderer, 10, true));


Thanks again


victorTrapiello wrote:
> 
> Hello Carlos,
> 
> Sorry but I´m new also with Maven, but I got it working, I have downloaded
> all the dependencies and now I have my quickstart projects in netbeans
> ready to write some code, but my question is once I write the code that I
> want to share with you guys how can I share it¿? do you understand me¿?
> how can you access to my code.... as I told you I´m new in maven as well
> ;-) do I need to package in someway with maven¿?.... thank you very much,
> I´m learning alot with you guys!!!!
> 
> 
> 
> Carlos Vara wrote:
>> 
>> Hi Victor,
>> 
>> a quickstart is a wicket project using this maven archetype:
>> 
>> http://wicket.apache.org/quickstart.html
>> 
>> 
>> On Sun, Jan 31, 2010 at 7:46 PM, victorTrapiello
>> <vi...@trapiello.net>wrote:
>> 
>>>
>>> Thank you very mucv Nino, but what do you mena by a quick start¿? I´m
>>> new
>>> in
>>> this comunity.
>>>
>>> nino martinez wael wrote:
>>> >
>>> > Ok Victor next step for you would be to create a quickstart.. So we
>>> can
>>> > play
>>> > with it.. I've sure had this working with wicket 1.2 / 1.3 soo should
>>> > still
>>> > be the case.
>>> >
>>> > 2010/1/29 victorTrapiello <vi...@trapiello.net>
>>> >
>>> >>
>>> >> I does not work, I think the key point is my
>>> >>
>>> >> IChoiceRenderer renderer = new ChoiceRenderer("fullName",
>>> "fullName");
>>> >>
>>> >> i leave it empty and it works for the available subject but not for
>>> the
>>> >> predefined!
>>> >>
>>> >> any more thoughts¿?
>>> >>
>>> >> Thank you very much guys
>>> >>
>>> >>
>>> >>
>>> >> nino martinez wael wrote:
>>> >> >
>>> >> > Form f=new Form("form");
>>> >> >     add(f);
>>> >> >     List persons = ComponentReferenceApplication.getPersons();;
>>> >> >     IChoiceRenderer renderer = new ChoiceRenderer("fullName",
>>> >> "fullName");
>>> >> >     final Palette palette = new Palette("palette", new
>>> >> > ListModel<Person>(new
>>> >> > ArrayList<Person>()), new CollectionModel<Person>(
>>> >> >       persons), renderer, 10, true);
>>> >> > palette.setmodelObject or something like that.
>>> >> >
>>> >> > 2010/1/29 victorTrapiello <vi...@trapiello.net>
>>> >> >
>>> >> >>
>>> >> >> well I have defined my palette component like this:
>>> >> >>
>>> >> >> asignString is an string linst with the available subjects (It
>>> works
>>> >> >> fine,
>>> >> >> the palette shows the proper subjects, but it doesn´t show the
>>> default
>>> >> >> selected one which I save them in the list "lSelected"
>>> >> >>
>>> >> >>  IChoiceRenderer renderer = new ChoiceRenderer("", "");
>>> >> >>  List<String> lSelected=new ArrayList();
>>> >> >>        lSelected.add("predefined");
>>> >> >>        Model aux=new Model();
>>> >> >>        aux.setObject((Serializable) lSelected);
>>> >> >>
>>> >> >>        final Palette palette = new Palette("palette", aux, new
>>> Model(
>>> >> >>                (Serializable) asignString), renderer, 10, true);
>>> >> >>
>>> >> >> Any thought¿?
>>> >> >>
>>> >> >> thankyou in advance
>>> >> >>
>>> >> >>
>>> >> >> James Carman-3 wrote:
>>> >> >> >
>>> >> >> > Make sure your model reflects the selected state.  Palette will
>>> pick
>>> >> >> > that up automatically
>>> >> >> >
>>> >> >> > On Sat, Jan 23, 2010 at 12:50 PM, victorTrapiello
>>> >> >> <vi...@trapiello.net>
>>> >> >> > wrote:
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> I use the palette component, to assigne option to a User. but I
>>> >> don't
>>> >> >> >> find a functionnality, how to set already selected option ?.
>>> >> >> >>
>>> >> >> >> Exemple : a user selected option, I store it into a database:
>>> >> >> >> In the future, the user want to update his option, at the
>>> moment
>>> he
>>> >> >> >> doesn't see his previous selected option.
>>> >> >> >>
>>> >> >> >>  Do you have a solution.¿?, doe sir make sense¿?
>>> >> >> >>
>>> >> >> >> cheers!!
>>> >> >> >>
>>> >> >> >> quote author="MartinM">
>>> >> >> >> Well.. you can override newChoicesComponent
>>> >> >> >>
>>> >> >> >> **
>>> >> >> >> Martin
>>> >> >> >>
>>> >> >> >> 2009/4/28 新希望软件 -- 俞宏伟 <nh...@gmail.com>:
>>> >> >> >>> yes, i can setMarkupId for Palette. but now i want to filter
>>> for
>>> >> >> >>> palette's
>>> >> >> >>> choicesComponent.
>>> >> >> >>>
>>> >> >> >>> there is no public getChoicesComponent() method for
>>> >> choicesComponent.
>>> >> >> >>>
>>> >> >> >>>
>>> >> >> >>>
>>> >> >> >>> 2009/4/28 Martin Makundi <ma...@koodaripalvelut.com>
>>> >> >> >>>
>>> >> >> >>>> Why cannot get markupid? You can determine it yourself
>>> >> (setMarkupId)
>>> >> >> >>>>
>>> >> >> >>>> You could also update via ajax using a textfield which sends
>>> the
>>> >> >> >>>> filtered text to server and server updates the select via
>>> ajax...
>>> >> >> >>>>
>>> >> >> >>>> I wonder if someone has made a select in which the filter is
>>> >> >> visually
>>> >> >> >>>> built into the select component?
>>> >> >> >>>>
>>> >> >> >>>> **
>>> >> >> >>>> Martin
>>> >> >> >>>>
>>> >> >> >>>> 2009/4/28 新希望软件 -- 俞宏伟 <nh...@gmail.com>:
>>> >> >> >>>> > I want to add a filter for palette choice list, because
>>>  choice
>>> >> >> list
>>> >> >> >>>>  have a
>>> >> >> >>>> > very large HTML SELECT list.
>>> >> >> >>>> >
>>> >> >> >>>> > I found that there is a select filter implement(
>>> >> >> >>>> > http://www.barelyfitz.com/projects/filterlist/index.php/1),
>>> but
>>> >> i
>>> >> >> can
>>> >> >> >>>> not
>>> >> >> >>>> > get select component markupid, so filter can not init.
>>> >> >> >>>> >
>>> >> >> >>>> > --
>>> >> >> >>>> >
>>> >> >> >>>> > H. L. Mencken <
>>> >> >> >>>> http://www.brainyquote.com/quotes/authors/h/h_l_mencken.html>
>>> >> >> >>>> > - "It is even harder for the average ape to believe that he
>>> has
>>> >> >> >>>> > descended
>>> >> >> >>>> > from man."
>>> >> >> >>>> >
>>> >> >> >>>>
>>> >> >> >>>>
>>> >> >>
>>> ---------------------------------------------------------------------
>>> >> >> >>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> >> >> >>>> For additional commands, e-mail: users-help@wicket.apache.org
>>> >> >> >>>>
>>> >> >> >>>>
>>> >> >> >>>
>>> >> >> >>
>>> >> >> >>
>>> >> ---------------------------------------------------------------------
>>> >> >> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> >> >> >> For additional commands, e-mail: users-help@wicket.apache.org
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> --
>>> >> >> >> View this message in context:
>>> >> >> >>
>>> >> >>
>>> >>
>>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27288282.html
>>> >> >> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> ---------------------------------------------------------------------
>>> >> >> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> >> >> >> For additional commands, e-mail: users-help@wicket.apache.org
>>> >> >> >>
>>> >> >> >>
>>> >> >> >
>>> >> >> >
>>> >> ---------------------------------------------------------------------
>>> >> >> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> >> >> > For additional commands, e-mail: users-help@wicket.apache.org
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >>
>>> >> >> --
>>> >> >> View this message in context:
>>> >> >>
>>> >>
>>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27374968.html
>>> >> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>>> >> >>
>>> >> >>
>>> >> >>
>>> ---------------------------------------------------------------------
>>> >> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> >> >> For additional commands, e-mail: users-help@wicket.apache.org
>>> >> >>
>>> >> >>
>>> >> >
>>> >> >
>>> >>
>>> >> --
>>> >> View this message in context:
>>> >>
>>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27378863.html
>>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>>> >>
>>> >>
>>> >> ---------------------------------------------------------------------
>>> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> >> For additional commands, e-mail: users-help@wicket.apache.org
>>> >>
>>> >>
>>> >
>>> >
>>>
>>> --
>>> View this message in context:
>>> http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27395876.html
>>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>>
>> 
>> 
> 
> 

-- 
View this message in context: http://old.nabble.com/how-to-add-filter-for-Palette-choice-tp23269578p27408774.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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