Revision bf1d3a70 snf-cyclades-app/synnefo/api/management/commands/listnetworks.py
b/snf-cyclades-app/synnefo/api/management/commands/listnetworks.py | ||
---|---|---|
74 | 74 |
if options['public']: |
75 | 75 |
networks = networks.filter(public=True) |
76 | 76 |
|
77 |
labels = ('id', 'name', 'owner', 'state', 'link', 'vms', 'public') |
|
78 |
columns = (3, 12, 20, 7, 14, 4, 6) |
|
77 |
labels = ('id', 'name', 'owner', 'subnet', 'gateway', 'mac_prefix', |
|
78 |
'dhcp', 'state', 'link', 'vms', 'public') |
|
79 |
columns = (3, 12, 30, 14, 14, 14, 8, 10, 12, 4, 6) |
|
79 | 80 |
|
80 | 81 |
if not options['csv']: |
81 | 82 |
line = ' '.join(l.rjust(w) for l, w in zip(labels, columns)) |
... | ... | |
87 | 88 |
fields = (str(network.id), |
88 | 89 |
network.name, |
89 | 90 |
network.userid or '', |
91 |
network.subnet, |
|
92 |
network.gateway or '', |
|
93 |
network.mac_prefix or '', |
|
94 |
str(network.dhcp), |
|
90 | 95 |
network.state, |
91 |
network.link, |
|
96 |
network.link or '',
|
|
92 | 97 |
str(network.machines.count()), |
93 | 98 |
format_bool(network.public)) |
94 | 99 |
|
Also available in: Unified diff