[Users] Radio Button in Sub-nodes (Treeview)...
Andreas Hocevar
ahocevar at opengeo.org
Wed Oct 7 21:02:59 CEST 2009
Hey-
where exactly did you set the checked attribute? Because this is exactly
how it should work.
Note though that a checkbox won't be connected to children's checkboxes
in Ext.
Regards,
Andreas.
Paul james wrote:
> Thanks Andreas!
>
> Jumping to the last question..
> I have that tree configuration :
>
> {
> id: 'Transporte',
> text:
> 'Transporte',
> children:
> [
> {
> id: 'Rodoviario',
> text:
> 'Rodoviario',
> children:
> [
> {
> nodeType: "gx_layer",
> id: "RodoviaFederal",
> layer: "Rodovia Federal",
> isLeaf:
> false,
> loader: {
> param: "LAYERS",
> ...
>
> The checkbox is only generated in last level ( RodoviaFederal and
> sublayers) ... How can I generate checkbox for all levels? Using
> "checked" attribute, it appers, but doest work ... Any idea?
>
> Paul
>
> On Wed, Oct 7, 2009 at 4:09 AM, Andreas Hocevar <ahocevar at opengeo.org
> <mailto:ahocevar at opengeo.org>> wrote:
>
> Paul james wrote:
> > About my other problem (Change sublayer label on treeview) ...
> > I tried with that :
> >
> > tree.on('beforeappend', function(tree, parent, node){
> > node.text = "test";
> > });
> >
> > It only changes the last child... Can you help me on that?
>
> I think so. Because the visual representation of the layer order
> is the
> other way around as the layer stack, nodes are inserted rather than
> appended. Try the following:
>
> function setText(tree, parent, node) {
> node.text = "test";
> }
> tree.on({
> beforeappend: setText,
> beforeinsert: setText
> });
>
> Regards,
> Andreas.
>
> --
> Andreas Hocevar
> OpenGeo - http://opengeo.org/
> Expert service straight from the developers.
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Users mailing list
> Users at geoext.org
> http://www.geoext.org/cgi-bin/mailman/listinfo/users
>
--
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.
More information about the Users
mailing list