File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed
Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change 213213 } ) ;
214214 }
215215
216+ if ( args . data . networkLimit != null ) {
217+ $ . ajax ( {
218+ url : createURL ( "updateResourceLimit&domainid=" + args . context . domains [ 0 ] . id + "&resourceType=6&max=" + args . data . networkLimit ) ,
219+ dataType : "json" ,
220+ async : false ,
221+ success : function ( json ) {
222+ domainObj [ "networkLimit" ] = args . data . networkLimit ;
223+ }
224+ } ) ;
225+ }
226+
216227 if ( args . data . primaryStorageLimit != null ) {
217228 $ . ajax ( {
218229 url : createURL ( "updateResourceLimit&domainid=" + args . context . domains [ 0 ] . id + "&resourceType=10&max=" + args . data . primaryStorageLimit ) ,
432443 return true ;
433444 }
434445 } ,
446+ networkLimit : {
447+ label : 'label.network.limits' ,
448+ isEditable : function ( args ) {
449+ if ( args . domains [ 0 ] . id == g_domainid ) //disallow to update the field on the domain you log in as
450+ return false ;
451+ else
452+ return true ;
453+ }
454+ } ,
435455 primaryStorageLimit : {
436456 label : 'label.primary.storage.limits' ,
437457 isEditable : function ( args ) {
560580 case "4" :
561581 domainObj [ "templateLimit" ] = limit . max ;
562582 break ;
583+ case "6" :
584+ domainObj [ "networkLimit" ] = limit . max ;
585+ break ;
563586 case "7" :
564587 domainObj [ "vpcLimit" ] = limit . max ;
565588 break ;
You can’t perform that action at this time.
0 commit comments