from sdcBePy.common.helpers import check_arguments_not_none
-
def get_url(ip, port, protocol):
return "%s://%s:%s" % (protocol, ip, port)
def get_normatives(self):
return self.con.get("/sdc2/rest/v1/screen", with_buffer=True)
+ def get_model_list(self):
+ return self.con.get("/sdc2/rest/v1/catalog/model", with_buffer=True)
+
def post_file(self, path, multi_part_form_data, buffer=None):
return self.con.post_file(path, multi_part_form_data, buffer)
self.con.buffer.seek(0)
response = value.decode(self.CHARTSET).split(self.BODY_SEPARATOR)
- return response[1] if len(response) == 2 else response[0]
-
+ return response[len(response) - 1] if len(response) > 1 else response[0]
class CurlConnector:
CONTENT_TYPE_HEADER = "Content-Type: application/json"