Firstly my thanks for the very useful pe:triStateCheckbox component.
I make heavy use of the null state of Boolean values in my application.
Because pe:triStateScheckbox uses number Strings "0","1","2" and
because p:inplace seems to use outputText in default display mode,
it is hard to use pe:triStateScheckbox as the editor for a p:inplace.
The inline editing works fine, but after editing it shows a number String.
Would it be possible to instead or additionally use: "null", "true", "false" ?
These would be more compatible with p:inplace, and make sense to users.
And writing a converter for these is just as easy as for the Strings "0","1","2".
Related:
- Forum: Feature suggestion for p:inplace: output component facet
- Issue 4330: Feature suggestion for p:inplace: output component facet
pe:triStateCheckbox incompatible with p:inplace shows number
Primefaces 6.1
JSF Mojarra 2.3.0
(Netbeans 8.2+Glassfish 4.1.1 OR Payara 4.1)
Mac OS X "Yosemite" 10.10.5 / Linux CentOS 6.7
JSF Mojarra 2.3.0
(Netbeans 8.2+Glassfish 4.1.1 OR Payara 4.1)
Mac OS X "Yosemite" 10.10.5 / Linux CentOS 6.7
Hi,
I don't think this is a problem of TriStateCheckbox / TriStateManyCheckbox. The problem is p:inplace because it displays value and not label. If you have e.g.
the itemLabel should be shown and not value. If you have
the text "My Tri State" should be shown and not value.
Does p:inplace not work as expected?
I don't think this is a problem of TriStateCheckbox / TriStateManyCheckbox. The problem is p:inplace because it displays value and not label. If you have e.g.
Code: Select all
<pe:triStateCheckbox value="..." />
<f:selectItem itemValue="..." itemLabel="..."/>
</pe:triStateCheckbox>
Code: Select all
<pe:triStateCheckbox value="..." />
<h:outputText value="My Tri State"/>
</pe:triStateCheckbox>
Does p:inplace not work as expected?
PrimeFaces Cookbook (2. edition): http://ova2.github.io/primefaces-cookbook/ Learning Angular UI Development with PrimeNG: https://github.com/ova2/angular-develop ... th-primeng Blog: https://medium.com/@OlegVaraksin
Thanks Oleg for reply. You wrote:
> Does p:inplace not work as expected?
Well that's what I described, it works "as expected" for the current design of p:inplace, but as I have suggested elsewhere (see forum feature suggestion already given above) there is a need to override the apparent default outputText component of p:inplace.
> I don't think this is a problem of TriStateCheckbox / TriStateManyCheckbox. The problem is p:inplace because it displays value and not label.
But if TriStateCheckbox used "null", "true", "false", instead of "0","1","2" it would work ok with (be compatible with) the current design and implementation of p:inplace. It can't for the sake of implementation make any difference for TriStateCheckbox which strings you use. And since usually only the itemLabel is shown it has no impact on existing users - except on those who have custom converters, and these are easily changed to use "null", "true", "false" strings (which are more descriptive anyway) instead of the rather arbitrary "0", "1", "2".
> Does p:inplace not work as expected?
Well that's what I described, it works "as expected" for the current design of p:inplace, but as I have suggested elsewhere (see forum feature suggestion already given above) there is a need to override the apparent default outputText component of p:inplace.
> I don't think this is a problem of TriStateCheckbox / TriStateManyCheckbox. The problem is p:inplace because it displays value and not label.
But if TriStateCheckbox used "null", "true", "false", instead of "0","1","2" it would work ok with (be compatible with) the current design and implementation of p:inplace. It can't for the sake of implementation make any difference for TriStateCheckbox which strings you use. And since usually only the itemLabel is shown it has no impact on existing users - except on those who have custom converters, and these are easily changed to use "null", "true", "false" strings (which are more descriptive anyway) instead of the rather arbitrary "0", "1", "2".
Primefaces 6.1
JSF Mojarra 2.3.0
(Netbeans 8.2+Glassfish 4.1.1 OR Payara 4.1)
Mac OS X "Yosemite" 10.10.5 / Linux CentOS 6.7
JSF Mojarra 2.3.0
(Netbeans 8.2+Glassfish 4.1.1 OR Payara 4.1)
Mac OS X "Yosemite" 10.10.5 / Linux CentOS 6.7
-
- Information
-
Who is online
Users browsing this forum: No registered users and 20 guests