You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Thomas Andraschko <zo...@googlemail.com> on 2012/06/25 10:58:27 UTC

Re: [EXTVAL] @Column.lenght -> h:inputText

Hi Gerhard,

i implemented this in my app but without an custom ComponentInitializer.

I just overwritten the AbstractHtmlCoreComponentsComponentInitializer.
If a maxlenght attribute is defined (and greater than 0), ExtVal does not
override it.
Could this be a part of ExtVal?

Regards,
Thomas

2012/4/12 Thomas Andraschko <zo...@googlemail.com>

> Hi,
>
> ok cool - i will try it!
>
> Thanks!
>
>
> 2012/4/12 Gerhard Petracek <ge...@gmail.com>
>
>> hi thomas,
>>
>> that isn't supported by default (intentionally).
>>
>> however, you can provide a custom ComponentInitializer.
>> (implement the interface or extend HtmlCoreComponentsComponentInitializer
>> and override #configureMaxLengthAttribute)
>> -> register it via an extval startup listener.
>>
>> regards,
>> gerhard
>>
>> http://www.irian.at
>>
>> Your JSF/JavaEE powerhouse -
>> JavaEE Consulting, Development and
>> Courses in English and German
>>
>> Professional Support for Apache MyFaces
>>
>>
>>
>> 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
>>
>> > Hi Gerhard,
>> >
>> > yep i could but the value depends on the current logged in user/user
>> > groups. So it can't use a static value -> ValueBinding on maxlenght
>> > attribute would be an easy solution.
>> > Ok, so there is no possiblity to disable this behavior?
>> >
>> > Why ExtVal does override the default attributes? IMO the component
>> > attributes should have a higher prio.
>> >
>> > Thanks!
>> >
>> > Best regards,
>> > Thomas
>> >
>> > 2012/4/12 Gerhard Petracek <ge...@gmail.com>
>> >
>> > > hi thomas,
>> > >
>> > > you can use Column#length with the correct value or a different
>> property
>> > > for your value-binding (without @Column) .
>> > >
>> > > regards,
>> > > gerhard
>> > >
>> > > http://www.irian.at
>> > >
>> > > Your JSF/JavaEE powerhouse -
>> > > JavaEE Consulting, Development and
>> > > Courses in English and German
>> > >
>> > > Professional Support for Apache MyFaces
>> > >
>> > >
>> > >
>> > > 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
>> > >
>> > > > Hi,
>> > > >
>> > > > we have a value binding on an h:inputText. The binded variable has
>> > > @Column
>> > > > and the default value of length is 255.
>> > > > I try to overwrite this via "maxlength" attribute on the h:inputText
>> > but
>> > > > the rendered maxlenght is 255.
>> > > >
>> > > > How can disable this behavior for a single input field?
>> > > >
>> > > > Best regards,
>> > > > Thomas
>> > > >
>> > >
>> >
>>
>
>

Re: [EXTVAL] @Column.lenght -> h:inputText

Posted by Thomas Andraschko <zo...@googlemail.com>.
Hi Gerhard,

created :)

https://issues.apache.org/jira/browse/EXTVAL-144

Regards,
Thomas

2012/6/25 Gerhard Petracek <ge...@gmail.com>

> hi thomas,
>
> +1 for adding it -> please create a jira ticket (improvement).
>
> regards,
> gerhard
>
> http://www.irian.at
>
> Your JSF/JavaEE powerhouse -
> JavaEE Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
>
>
> 2012/6/25 Thomas Andraschko <zo...@googlemail.com>
>
> > Hi Gerhard,
> >
> > i implemented this in my app but without an custom ComponentInitializer.
> >
> > I just overwritten the AbstractHtmlCoreComponentsComponentInitializer.
> > If a maxlenght attribute is defined (and greater than 0), ExtVal does not
> > override it.
> > Could this be a part of ExtVal?
> >
> > Regards,
> > Thomas
> >
> > 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
> >
> > > Hi,
> > >
> > > ok cool - i will try it!
> > >
> > > Thanks!
> > >
> > >
> > > 2012/4/12 Gerhard Petracek <ge...@gmail.com>
> > >
> > >> hi thomas,
> > >>
> > >> that isn't supported by default (intentionally).
> > >>
> > >> however, you can provide a custom ComponentInitializer.
> > >> (implement the interface or extend
> > HtmlCoreComponentsComponentInitializer
> > >> and override #configureMaxLengthAttribute)
> > >> -> register it via an extval startup listener.
> > >>
> > >> regards,
> > >> gerhard
> > >>
> > >> http://www.irian.at
> > >>
> > >> Your JSF/JavaEE powerhouse -
> > >> JavaEE Consulting, Development and
> > >> Courses in English and German
> > >>
> > >> Professional Support for Apache MyFaces
> > >>
> > >>
> > >>
> > >> 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
> > >>
> > >> > Hi Gerhard,
> > >> >
> > >> > yep i could but the value depends on the current logged in user/user
> > >> > groups. So it can't use a static value -> ValueBinding on maxlenght
> > >> > attribute would be an easy solution.
> > >> > Ok, so there is no possiblity to disable this behavior?
> > >> >
> > >> > Why ExtVal does override the default attributes? IMO the component
> > >> > attributes should have a higher prio.
> > >> >
> > >> > Thanks!
> > >> >
> > >> > Best regards,
> > >> > Thomas
> > >> >
> > >> > 2012/4/12 Gerhard Petracek <ge...@gmail.com>
> > >> >
> > >> > > hi thomas,
> > >> > >
> > >> > > you can use Column#length with the correct value or a different
> > >> property
> > >> > > for your value-binding (without @Column) .
> > >> > >
> > >> > > regards,
> > >> > > gerhard
> > >> > >
> > >> > > http://www.irian.at
> > >> > >
> > >> > > Your JSF/JavaEE powerhouse -
> > >> > > JavaEE Consulting, Development and
> > >> > > Courses in English and German
> > >> > >
> > >> > > Professional Support for Apache MyFaces
> > >> > >
> > >> > >
> > >> > >
> > >> > > 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
> > >> > >
> > >> > > > Hi,
> > >> > > >
> > >> > > > we have a value binding on an h:inputText. The binded variable
> has
> > >> > > @Column
> > >> > > > and the default value of length is 255.
> > >> > > > I try to overwrite this via "maxlength" attribute on the
> > h:inputText
> > >> > but
> > >> > > > the rendered maxlenght is 255.
> > >> > > >
> > >> > > > How can disable this behavior for a single input field?
> > >> > > >
> > >> > > > Best regards,
> > >> > > > Thomas
> > >> > > >
> > >> > >
> > >> >
> > >>
> > >
> > >
> >
>

Re: [EXTVAL] @Column.lenght -> h:inputText

Posted by Gerhard Petracek <ge...@gmail.com>.
hi thomas,

+1 for adding it -> please create a jira ticket (improvement).

regards,
gerhard

http://www.irian.at

Your JSF/JavaEE powerhouse -
JavaEE Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2012/6/25 Thomas Andraschko <zo...@googlemail.com>

> Hi Gerhard,
>
> i implemented this in my app but without an custom ComponentInitializer.
>
> I just overwritten the AbstractHtmlCoreComponentsComponentInitializer.
> If a maxlenght attribute is defined (and greater than 0), ExtVal does not
> override it.
> Could this be a part of ExtVal?
>
> Regards,
> Thomas
>
> 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
>
> > Hi,
> >
> > ok cool - i will try it!
> >
> > Thanks!
> >
> >
> > 2012/4/12 Gerhard Petracek <ge...@gmail.com>
> >
> >> hi thomas,
> >>
> >> that isn't supported by default (intentionally).
> >>
> >> however, you can provide a custom ComponentInitializer.
> >> (implement the interface or extend
> HtmlCoreComponentsComponentInitializer
> >> and override #configureMaxLengthAttribute)
> >> -> register it via an extval startup listener.
> >>
> >> regards,
> >> gerhard
> >>
> >> http://www.irian.at
> >>
> >> Your JSF/JavaEE powerhouse -
> >> JavaEE Consulting, Development and
> >> Courses in English and German
> >>
> >> Professional Support for Apache MyFaces
> >>
> >>
> >>
> >> 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
> >>
> >> > Hi Gerhard,
> >> >
> >> > yep i could but the value depends on the current logged in user/user
> >> > groups. So it can't use a static value -> ValueBinding on maxlenght
> >> > attribute would be an easy solution.
> >> > Ok, so there is no possiblity to disable this behavior?
> >> >
> >> > Why ExtVal does override the default attributes? IMO the component
> >> > attributes should have a higher prio.
> >> >
> >> > Thanks!
> >> >
> >> > Best regards,
> >> > Thomas
> >> >
> >> > 2012/4/12 Gerhard Petracek <ge...@gmail.com>
> >> >
> >> > > hi thomas,
> >> > >
> >> > > you can use Column#length with the correct value or a different
> >> property
> >> > > for your value-binding (without @Column) .
> >> > >
> >> > > regards,
> >> > > gerhard
> >> > >
> >> > > http://www.irian.at
> >> > >
> >> > > Your JSF/JavaEE powerhouse -
> >> > > JavaEE Consulting, Development and
> >> > > Courses in English and German
> >> > >
> >> > > Professional Support for Apache MyFaces
> >> > >
> >> > >
> >> > >
> >> > > 2012/4/12 Thomas Andraschko <zo...@googlemail.com>
> >> > >
> >> > > > Hi,
> >> > > >
> >> > > > we have a value binding on an h:inputText. The binded variable has
> >> > > @Column
> >> > > > and the default value of length is 255.
> >> > > > I try to overwrite this via "maxlength" attribute on the
> h:inputText
> >> > but
> >> > > > the rendered maxlenght is 255.
> >> > > >
> >> > > > How can disable this behavior for a single input field?
> >> > > >
> >> > > > Best regards,
> >> > > > Thomas
> >> > > >
> >> > >
> >> >
> >>
> >
> >
>