Commit fbb5e97b authored by mouadh's avatar mouadh

fix response structure

parent 04472a0d
...@@ -322,14 +322,14 @@ class XmlaDiscoverTools(): ...@@ -322,14 +322,14 @@ class XmlaDiscoverTools():
'CUBE_SOURCE', 'CUBE_SOURCE',
'HIERARCHY_VISIBILITY'] 'HIERARCHY_VISIBILITY']
restriction_types = ['string', restriction_types = ['string',
'string', 'string',
'string', 'string',
'string', 'string',
'string', 'string',
'string', 'string',
'unsignedShort', 'unsignedShort',
'unsignedShort', 'unsignedShort',
'unsignedShort'] 'unsignedShort']
xml = xmlwitch.Builder() xml = xmlwitch.Builder()
...@@ -337,21 +337,19 @@ class XmlaDiscoverTools(): ...@@ -337,21 +337,19 @@ class XmlaDiscoverTools():
**{'xmlns:xsd': 'http://www.w3.org/2001/XMLSchema', **{'xmlns:xsd': 'http://www.w3.org/2001/XMLSchema',
'xmlns:xsi': 'http://www.w3.org/2001/XMLSchema-instance'}): 'xmlns:xsi': 'http://www.w3.org/2001/XMLSchema-instance'}):
for idx, restriction in enumerate(restriction_names): with xml.row:
with xml.row: xml.SchemaName('MDSCHEMA_HIERARCHIES')
xml.SchemaName('MDSCHEMA_HIERARCHIES') xml.SchemaGuid('C8B522DA-5CF3-11CE-ADE5-00AA0044773D')
xml.SchemaGuid('C8B522DA-5CF3-11CE-ADE5-00AA0044773D') for idx, restriction in enumerate(restriction_names):
with xml.Restrictions: with xml.Restrictions:
xml.Name(restriction) xml.Name(restriction)
xml.Type(restriction_types[idx]) xml.Type(restriction_types[idx])
# todo fix this xml.RestrictionsMask('511')
# xml.RestrictionsMask('511')
html_parser = HTMLParser.HTMLParser() html_parser = HTMLParser.HTMLParser()
xml = html_parser.unescape(str(xml)) xml = html_parser.unescape(str(xml))
return """ return """
<return> <return>
{0} {0}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment