HTML Article Galley file upload

I need to upload hundreds of files (images) using HTML Article Galley plugin. For every file I need to select article component. Is it possible for “Image” to be preselected by default? I tried to change in lib/pkp/templates/controllers/wizard/fileUpload/form/fileUploadForm.tpl here:

                {if $showGenreSelector}
                        {fbvFormSection title="submission.upload.fileContents" required=true}
                                {capture assign="defaultLabel"}{translate key="submission.upload.selectComponent"}{/capture}
                                {fbvElement type="select" name="genreId" id="genreId" from=$submissionFileGenres translate=false defaultLabel=$defaultLabel defaultValue="" required="true" selected=$genreId required=true}
                        {/fbvFormSection}

but unsuccessfully.

Hi all,

To add my 2 cents: it would be nice to have the option to upload many images with one step and not one by one… Asking too much?

Best regards, Primož

Hi @primozs,

That’s definitely on the horizon – not planned for the 3.1.2-2 or 3.2 releases, but for one to follow.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

What should I use instead of selected=$genreId in the code above in order to preselect Image?

Hi @Nerijus_Baliunas,

You can see the genre IDs by looking in the “Components” area of the workflow setup. “Components” in the user interface are the same as “genres” in the code, just named differently. If you hover over e.g. an Edit link, the ID will be in the URL.

If your site is a multi-journal site, you’ll need to beware that each journal will have different components, and using a genre ID from one journal will not work for other journals.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

Thank you very much, selected=58 for one journal worked. For others I will either change ID manually in fileUploadForm.tpl, or will make an array depending on journal id, if it is possible.