mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
Always render physical networks as list view first
This commit is contained in:
parent
464967294b
commit
4a9155df1b
@ -279,39 +279,32 @@
|
||||
response: {
|
||||
success: function(args) {
|
||||
var data = args.data;
|
||||
if (data.length > 1) {
|
||||
// Render list view first
|
||||
$chart.listView({
|
||||
listView: $.extend(true, {}, cloudStack.sections.system.naas.networks.listView, {
|
||||
dataProvider: function(args) {
|
||||
args.response.success({ data: data });
|
||||
},
|
||||
detailView: {
|
||||
tabs: {
|
||||
network: {
|
||||
title: 'Network',
|
||||
custom: function(args) {
|
||||
var $chart = $('<div>').addClass('system-chart network');
|
||||
|
||||
renderChart({
|
||||
$chart: $chart,
|
||||
data: args.context.physicalNetworks[0]
|
||||
});
|
||||
$chart.listView({
|
||||
listView: $.extend(true, {}, cloudStack.sections.system.naas.networks.listView, {
|
||||
dataProvider: function(args) {
|
||||
args.response.success({ data: data });
|
||||
},
|
||||
detailView: {
|
||||
tabs: {
|
||||
network: {
|
||||
title: 'Network',
|
||||
custom: function(args) {
|
||||
var $chart = $('<div>').addClass('system-chart network');
|
||||
|
||||
return $chart;
|
||||
}
|
||||
renderChart({
|
||||
$chart: $chart,
|
||||
data: args.context.physicalNetworks[0]
|
||||
});
|
||||
|
||||
return $chart;
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
});
|
||||
$loading.remove();
|
||||
} else {
|
||||
renderChart({
|
||||
$chart: $chart,
|
||||
data: data[0]
|
||||
});
|
||||
}
|
||||
}
|
||||
})
|
||||
});
|
||||
$loading.remove();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user