@@ -301,7 +301,8 @@ function zoneJsonClearNetworkTab() {
301301 $thisTab . find ( "#vlan_container" ) . empty ( ) ;
302302}
303303
304- function vlanJsonToTemplate ( jsonObj , $template1 , isNetwork ) {
304+ function vlanJsonToTemplate ( jsonObj , $template1 , isNetwork ) {
305+ $template1 . attr ( "id" , "network" + jsonObj . id ) ;
305306 $template1 . data ( "jsonObj" , jsonObj ) ;
306307 $template1 . find ( "#vlan_id" ) . text ( jsonObj . vlan ) ;
307308 var ipRange = jsonObj . startip ;
@@ -341,7 +342,7 @@ function vlanJsonToTemplate(jsonObj, $template1, isNetwork) {
341342 var $container = $infoDropdown . find ( "#network_name_container" ) . show ( ) ;
342343 $container . find ( "#network_name" ) . text ( fromdb ( jsonObj . name ) ) ;
343344 $container = $infoDropdown . find ( "#network_desc_container" ) . show ( ) ;
344- $container . find ( "#network_desc" ) . text ( fromdb ( jsonObj . diplaytext ) ) ;
345+ $container . find ( "#network_desc" ) . text ( fromdb ( jsonObj . displaytext ) ) ;
345346 }
346347 $infoDropdown . show ( ) ;
347348 break ;
@@ -503,7 +504,7 @@ function initAddVLANButton($button, $leftmenuItem1) {
503504 $template1 . find ( "#vlan_type_icon" ) . removeClass ( "direct" ) . addClass ( "virtual" ) ;
504505
505506 var item = json . createvlaniprangeresponse . vlan ;
506- vlanJsonToTemplate ( item , $template1 ) ;
507+ vlanJsonToTemplate ( item , $template1 , false ) ;
507508 $vlanContainer . prepend ( $template1 ) ;
508509 $template1 . fadeIn ( "slow" ) ;
509510 } ,
@@ -538,7 +539,7 @@ function initAddVLANButton($button, $leftmenuItem1) {
538539 $template1 . find ( "#vlan_type_icon" ) . removeClass ( "virtual" ) . addClass ( "direct" ) ;
539540
540541 var item = json . createnetworkresponse . network ;
541- vlanJsonToTemplate ( item , $template1 ) ;
542+ vlanJsonToTemplate ( item , $template1 , true ) ;
542543 $vlanContainer . prepend ( $template1 ) ;
543544 $template1 . fadeIn ( "slow" ) ;
544545 } ,
0 commit comments