Skip to content

Commit

Permalink
Fixed the view_filter_map algorithm to correctly generate the URLs if…
Browse files Browse the repository at this point in the history
… using a string or a list of strings
  • Loading branch information
Bryant Howell committed Apr 15, 2019
1 parent 51a14f6 commit de67c7a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion tableau_rest_api/tableau_rest_api_connection_25.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,12 @@ def _query_data_file(self, download_type, view_name_or_luid, high_resolution=Non
final_filter_map = {}
for key in view_filter_map:
new_key = u"vf_{}".format(key)
final_filter_map[new_key] = view_filter_map[key]
# Check if this just a string
if isinstance(view_filter_map[key], basestring):
value = view_filter_map[key]
else:
value = ",".join(map(unicode,view_filter_map[key]))
final_filter_map[new_key] = value

additional_url_params = u"?" + urllib.urlencode(final_filter_map)
if high_resolution is True:
Expand Down

0 comments on commit de67c7a

Please sign in to comment.