We are using Aikau framework to integrate to one of our intranet applications, where we have the option to upload files within a directory structure.
The requirement is we want to switch between MODE_SINGLE_UPLOAD & MODE_MULTI_UPLOAD modes in File Uploader depending on the directory structure level the user is currently present in. File Uploader Dialog is shown on click on Upload button.
On Click of Upload button "ALF_SHOW_UPLOADER" topic is published which is listened by "ContentService.js" in "Slingshot/source/web/js/alfresco/services/" directory. The possible solution I can think here is to pass a flag(for SINGLE & MULTI mode) with publish-payload while publishing to the "ALF_SHOW_UPLOADER" topic, based on which "ContentService.js" will pass the respective config from "showUploader: function" to finally call "show()" method to display File-Uploader with appropriate mode(SINGLE_FILE or MULTIPLE FILE).
I want to know if there is an option to override default "ContentService.js" file so that in "showUploader" function I can change the value for "mode" variable dynamically based on the passed flag while publishing to topic. If possible, I would like to know how I can override this file to make the required changes.
I would also appreciate to have #any alternate approach/suggestion to implement this requirement.
Just to add that we are currently using Enterprise Alfresco v5.0.2 with Aikau 1.0.82, in case this information is helpful in suggesting the best way to override the JS file.
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.