Merge branch '2.0release' into develop

pull/528/head
winlin 9 years ago
commit 7db7d43aea

@ -622,7 +622,7 @@ class RESTServers(object):
''' '''
get all servers which report to this api-server. get all servers which report to this api-server.
''' '''
def GET(self): def GET(self, id=None):
enable_crossdomain() enable_crossdomain()
try: try:
@ -632,6 +632,7 @@ class RESTServers(object):
data = [] data = []
for node in self.__nodes: for node in self.__nodes:
if id == None or node.id == str(id) or node.device_id == str(id):
data.append(node.json_dump()) data.append(node.json_dump())
return json.dumps(data) return json.dumps(data)

Loading…
Cancel
Save