Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pdf upload #34

Open
openHBP opened this issue Jan 19, 2018 · 6 comments
Open

pdf upload #34

openHBP opened this issue Jan 19, 2018 · 6 comments

Comments

@openHBP
Copy link

openHBP commented Jan 19, 2018

Extremely nice package. I find it very usefull when we use Django CMS using Filer for Document management. I've implemented your package to be able to use the same for image selection at frontend but I'm facing a problem for pdf and document management.
Are you planning to implement it? Or do you have a simple alternative?
Regards

@yakky
Copy link
Member

yakky commented Jan 19, 2018

Thanks :)
What's the issue with PDF? It should work out of the box

@openHBP
Copy link
Author

openHBP commented Jan 19, 2018

I'm with django 1.8 with last version of your package and Pillow 5.0.0.
When I select a pdf file on the filerImageDialog, the canonical URL is not comming back in the URL field of the the Image Property window.
imagepropertyurl

@openHBP
Copy link
Author

openHBP commented Jan 19, 2018

The error I get is the same as the one mentionned on issue 28.

File "C:\venvpy\vvcp\lib\site-packages\ckeditor_filebrowser_filer\views.py", line 101, in url_image
'width': image.width,
AttributeError: 'File' object has no attribute 'width'

When I comment the 2 lines:

    data = {
        'url': url,
#         'width': image.width,
#         'height': image.height,
    }

The canonical URL is well written into URL field but the Image Property Windows mention : "No file selected" (see PrintScreen in French)
image

And I get the folowwing error:

[19/Jan/2018 15:05:49] "GET /fr/favicon.ico/ HTTP/1.1" 404 12127
[19/Jan/2018 15:05:51] "GET /filebrowser_filer/url_image/355/ HTTP/1.1" 200 43
[19/Jan/2018 15:05:51] "GET /filer/canonical/1516272478/355/ HTTP/1.1" 302 0
[19/Jan/2018 15:05:52] "GET /media/filer_public/d2/3b/d23b167e-eab4-42b2-b583-6ff5f50df0f1/rapport_final_de_projet_rqd_cp_complet.pdf HTTP/1.1" 200 73728
Traceback (most recent call last):
File "c:\python35\Lib\wsgiref\handlers.py", line 138, in run
self.finish_response()
File "c:\python35\Lib\wsgiref\handlers.py", line 180, in finish_response
self.write(data)
File "c:\python35\Lib\wsgiref\handlers.py", line 279, in write
self._write(data)
File "c:\python35\Lib\wsgiref\handlers.py", line 453, in _write
result = self.stdout.write(data)
File "c:\python35\Lib\socket.py", line 593, in write
return self._sock.send(b)
ConnectionAbortedError: [WinError 10053] Une connexion établie a été abandonnée par un logiciel de votre ordinateur hôte
[19/Jan/2018 15:05:52] "GET /media/filer_public/d2/3b/d23b167e-eab4-42b2-b583-6ff5f50df0f1/rapport_final_de_projet_rqd_cp_complet.pdf HTTP/1.1" 500 59

Exception happened during processing of request from ('127.0.0.1', 53384)

@yakky
Copy link
Member

yakky commented Jan 19, 2018

Thanks for the detailed report, we will investigate on the issue

@tehfink
Copy link

tehfink commented Sep 13, 2018

Any update on this?

@openHBP
Copy link
Author

openHBP commented Jul 29, 2020

Hello yakky, I'm still stuck with this issue. The only thing I would like to do is to access filer files (images & documents) from a "CKEditor like" window. Is it now feasible with cms.models.fields.PlaceholderField? I've tried to implement without any success. Would you please take a look to my question on stackoverflow?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants