-
Notifications
You must be signed in to change notification settings - Fork 45
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
QUESTION: How to activate attach options? #15
Comments
@nn-dmt Thanks a lot for reporting this.. The plugin doesn't have any dialog. But can you explain the problem in details so I can have a clear understanding of the problem.. Best regards.. |
I tried configuring my web form to include options from attach control to my attach fields - but the front end acted the same. There was no change to the front end form functionality. I even added options to the desk form as well as the web form, to no avail. Can you provide an example configuration of how you would enter the options into the web form? |
I think also, after the attach control was deactivated and removed, that something damaged the form permissions because now only Desk Access level users are allowed to upload media files into front-end web form. I can only imaging its because of the settings i used were incorrect with required file/mime type but that once removing them its still not working. I get 417 error on file uploads now on front end web form from users other than system manager/desk user |
@nn-dmt I'm sorry that you are facing some issues after removing the plugin..
The changes that the plugin make to the system are:
There is nothing in the plugin that changes user permission or do anything related to that..
Can you please post a screenshot of the error and the browser console log. Maybe I will be able to help..
In the field's Options put the config as a JSON string..
You can post your attach field config so I can take a look at it.. I will remove the on install & uninstall code from the plugin and update it Best regards.. |
thank you for the help - i will look into reinstalling it and trying with the formatting you provided. perhaps the permission issue was always there and i just never noticed. I will update you. No worries at all and thanks for your time |
Update: the issue was not with the plugin, but in the handler.py file in the frappe app. the type of files i wanted, audio, needed to be added to approved mimetypes list, it was missing audio in all its formats.
Also needed to change the code down further in the file to the following, since the version that ships with the branch has a bug.
Please note that i don't yet know if this 'fix' causes any security implications, but it seems like frappe themselves have an open PR with a very similar codeblock as the solution, which just has not yet been merged |
@nn-dmt Thanks a lot bro for your update and that is a great discovery..
Even that bug exists in v14..
I can't see anything in the code that might cause a security problem. Even if the security reason that made frappe exclude audio files from the list is the ability to incorporate malicious code into audio files, malicious code can also be incorporated into image files but they still allow images yo be uploaded by guest users.. I will see if I can make the plugin handle the file uploads and allow the modification of the allowed file tyoes list through the plugin, then I will let you know if I found a way.. Best regards.. |
App is installed after i edited field.py to include a comma
but it won't work, the web form attach dialog is the same as before.
The text was updated successfully, but these errors were encountered: