ckan with download button #8198
Team1-epat
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi I am currently using Ckan2.10 and would like to create a Download button in the ckan webpage. After clicked on the Download button, it will call the plugin.py to generate an excel file, but how can I pass the excel file back to the html page so that user is able to download the excel file?
I am trying to upload my excel file (that I have created in the plugin.py) to the api/v3/action/resource_create,
When I execute the above code, ckan will prompt error
NotImplementedError: Streamed bodies and files are mutually exclusive.
I am trying to follow the document, https://docs.ckan.org/en/2.9/maintaining/filestore.html, to create the resource and upload the excel file into the resource then user can download from there. Not sure if this works. Appreciate if someone will enlighten me, thank you very much.
Beta Was this translation helpful? Give feedback.
All reactions