if (true) {
Swal.fire("节目发布", "发布完毕", "success");
event.preventDefault();
}
if (false) {
Swal.fire("节目发布", "发布失败", "error");
event.preventDefault();
}
if (true) {
for (var i = 0; i < beta.length; i++) {
NioApp.Toast('<h5>节目发布</h5><p>' + beta[i] + '发布完毕.</p>', 'success');
}
event.preventDefault();
}
if (false) {
NioApp.Toast('<h5>节目发布</h5><p>发布失败.</p>', 'error');
event.preventDefault();
}
@staticmethod
def listAddress():
alpha = {}
network_interfaces = psutil.net_if_addrs()
for interface, addresses in network_interfaces.items():
for address in addresses:
if address.family == socket.AF_INET:
ip = address.address
netType = psutil.net_if_stats()[interface].isup
if netType:
netType = 'UP'
else:
netType = 'DOWN'
if netType not in alpha:
alpha[netType] = []
alpha[netType].append([interface, ip])
return beta
D:\Conda\parading>curl http://127.0.0.1:9000/api/v1.0/system/ip
{
"code": 200,
"data": {
"AddressList": [
[
"VMware Network Adapter VMnet1",
"192.168.71.1"
],
[
"VMware Network Adapter VMnet8",
"192.168.48.1"
],
[
"WLAN",
"192.168.0.100"
],
[
"Loopback Pseudo-Interface 1",
"127.0.0.1"
]
]
},
"msg": "system ip list ok"
}