cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1127
Views
0
Helpful
0
Replies

drawing vlanPaths that works with nodeSet

kevinche
Cisco Employee
Cisco Employee

Hi,

I have a topology that uses "Nodeset".  I am drawing paths (for example, VlanPath) on top of the topology when user selects the vlans.

When I collapse the Nodesets, the vlanpaths remain on screen not collapsing with the Nodeset.   Is there a way to make Nodeset aware of the vlanPaths when collapsing/expanding?


FYI, I don't need to draw the vlanPath from node to the nodeset when it is collapsed if that makes my life easier.


The vlanpath is extended like this:

nx.define('IND.VlanPath', nx.graphic.Component, {

properties:{...},

view:{ type: 'nx.graphic.Group',

                content: [{

                    name: 'vlanPath',

                    type: 'nx.graphic.Path',

                    props: {

                        'fill': 'none',

                        'stroke-width': '10px',

                        'stroke-dasharray': '4,0.8'

                    }]

},

methods:{...}

};

I setup a custom layer

nx.define("IND.VlanLayer", nx.graphic.Topology.Layer, {

properties:{...},

methods:{...}

};

I setup the layer like this:

sender.insertLayerAfter("vlan", "IND.VlanLayer", "linkSet");

                    this.view('topo').graph().on("updateVertexCoordinate", function (sender, vertex) {

                        this.view('topo').getLayer("vlan")._draw();

                    }, this);

0 Replies 0
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Recognize Your Peers