lib/gooddata/models/dashboard.rb in gooddata-0.5.13 vs lib/gooddata/models/dashboard.rb in gooddata-0.5.14
- old
+ new
@@ -13,10 +13,10 @@
def export(format, options={})
supported_formats = [:pdf]
fail "Wrong format provied \"#{format}\". Only supports formats #{supported_formats.join(', ')}" unless supported_formats.include?(format)
tab = options[:tab] || ""
- x = GoodData.post("/gdc/projects/lbhjnmbwa07f9g46hnjp3l5c9hphnev9/clientexport", {"clientExport" => {"url" => "https://secure.gooddata.com/dashboard.html#project=#{GoodData.project.uri}&dashboard=#{uri}&tab=#{tab}&export=1", "name" => title}}, :process => false)
+ x = GoodData.post("/gdc/projects/#{GoodData.project.uri}/clientexport", {"clientExport" => {"url" => "https://secure.gooddata.com/dashboard.html#project=#{GoodData.project.uri}&dashboard=#{uri}&tab=#{tab}&export=1", "name" => title}}, :process => false)
while (x.code == 202) do
sleep(1)
uri = JSON.parse(x.body)["asyncTask"]["link"]["poll"]
x = GoodData.get(uri, :process => false)
end