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

leafref not displaying in NSO 4.5 webui when used as a list key

ryan-hitch
Level 4
Level 4

I am trying to get the NSO 4.5 webui to display a drop-down list of GigabitEthernet interface names on a Cisco 3560E IOS switch using the simple model listed below. The new NSO 4.5 webui displays a drop-down of available interfaces if I do not use the switch-interface-id as a key, however just displays a blank drop-down list in the popup if switch-interface-id is used as a key. Is there a way to correct this behavior? It is a much more intuitive webui for our end users if we are able to use the "switch-name switch-interface-id" key. Thanks in advance.

list switch {

  key "switch-name switch-interface-id";

  leaf switch-name {

    type leafref {

      path "/ncs:services/ncs:device/ncs:name";

    }

  }

  leaf switch-interface-id {

    type leafref {

      path "deref(../switch-name)/../ncs:config/ios:interface/ios:GigabitEthernet/ios:name";

    }

  }

}

Display using "name switch-interface-id" key

Screenshot (2).png

Display using only "name" type string as a key requires the user to input a unique key when being able to use the "name interface-type-id" would be much more intuitive.

Screenshot (4).png

Screenshot (5).png

1 Accepted Solution

Accepted Solutions

jcederqu
Cisco Employee
Cisco Employee

Ryan. Thank you for pointing this problem out. It occurs due to the internal dependency of the key values.  We are working on a solution and hope to have it ready before the next release later this year..

/Jakob

View solution in original post

2 Replies 2

Jan Lindblad
Cisco Employee
Cisco Employee

jcederqu, did you see this too?

jcederqu
Cisco Employee
Cisco Employee

Ryan. Thank you for pointing this problem out. It occurs due to the internal dependency of the key values.  We are working on a solution and hope to have it ready before the next release later this year..

/Jakob