Closed AndreeaChi closed 1 year ago
To confirm this, I created a SecondRegularUser and added it in a new group called ExtraGroup.
Then, I gave the Edit right to the ExtraGroup at wiki level
and on the Sandbox Page & Children (this second setting is required only if the Edit right is kept for the XWikiRegularUsersGroup).
On a separate browser session, I logged in with the SecondRegularUser and edited TestPage2, added the PDF Viewer macro and the "Upload file" button appears, while the same messages appeared in the console:
If I remove the Edit right from the ExtraGroup at wiki level, the "Upload file" button is again not shown.
The jQuery Migrate warning from the JavaScript console don't affect the feature / end user. They only inform the developer that the code needs to be updated because it uses deprecated / dropped APIs.
This issue was closed as part of CKEditor in here. To apply this fix for the File Manager App, CKEditor needs to be upgraded to 1.64.9 https://jira.xwiki.org/browse/CKEDITOR-499 Note that since CKEditor was merged in the XWiki platform at some point, an upgrade will not be possible for those versions. Check this issue for details on which XWiki versions might still have this problem https://jira.xwiki.org/browse/XWIKI-20491
Steps to reproduce:
On a 14.4.5/13.10.5/14.4.6 XWiki Jetty instance, install PDF Viewer Macro Pro, 2.4. I tested on both Firefox 106.0.5 & Chrome 107.0
Add a standard user (Simple, default hidden pages setting) in a new Group - XWikiRegularUsersGroup
At wiki level, set these rights for the XWikiAdminGroup and leave empty for all the other groups:
At this point, give to the XWikiRegularUsersGroup on the Sandbox Page & Children level Edit rights.
With a user from the XWikiRegularUsersGroup edit Sandbox TestPage1, with no pre-existing PDF attached to the page (no matter the editor type, inline or WYSIWYG) and add the PDF Viewer Macro.
Click in the "Select or upload a PDF file" field
Expected result: a button with "Upload a file" under the "Select or upload a PDF file" field
Actual result: the "Upload a file" button does not appear
In the console, the Source map error: Error: request failed with status 404 Resource URL: null Source Map URL: suggestAttachments.min.js.map appears when inserting the PDF Viewer macro, then when first clicking in the Select or upload a PDF file field, the message JQMIGRATE: jQuery.trim is deprecated; use String.prototype.trim appears.
Also, giving View at wiki level for the group or any right, even Admin on the Sandbox Page & Children level to the group, does not help.