We are moving to Git Issues for bug tracking in future releases. During transition, content will be in both tools. If you'd like to file a new bug, please create an issue.

Bug 8169 - Problems with quick submit plugin running nultilanguage OJS instance
Problems with quick submit plugin running nultilanguage OJS instance
Status: RESOLVED FIXED
Product: OJS
Classification: Unclassified
Component: Import/Export
2.4.3
All All
: P3 normal
Assigned To: PKP Support
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-03-18 01:28 PDT by Garant
Modified: 2013-06-10 11:40 PDT (History)
2 users (show)

See Also:
Version Reported In: 2.3.7, 2.3.8
Also Affects:


Attachments
Error Message (92.17 KB, image/png)
2013-03-25 10:19 PDT, Michael Thessel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Garant 2013-03-18 01:28:19 PDT
Hi!
The problem is described here: http://pkp.sfu.ca/support/forum/viewtopic.php?f=8&t=7593#p37856
Also I've described how to reproduce this event
Comment 1 Michael Thessel 2013-03-22 10:08:00 PDT
I looked into that, but having trouble reproducing the issue. What I did so far:

* Set up 2 journals
* Set up 1 issue for each journal
* Set up 2 languages
* Set up those languages as ui, submission and form languages

When I now try to submit a article in a language other than English I get the following errors:

"Please enter the title of your article. (English)" and 
"Please enter the abstract of your article. (English)"

When I then switch back to English, fill those fields and submit the article everything works fine.

I'm running 2.4.1 and not  2.3.4 as the bug report states. Could it be that this has been addressed since? Is there anything wrong with my workflow?
Comment 2 Alec Smecher 2013-03-22 10:14:50 PDT
Michael, Garant is running OJS 2.3.8; we tend to file bugs against the version they are to be fixed in. (Odd, but helpful for our release planning workflow.) In this case the fix will go into 2.4.3.

I'd suggest setting up a 2.3.8 install to see if the issue is different; if you can reproduce it there but not in 2.4.2 then it's a WONTFIX -- the 2.3.x line isn't going to see any more releases unless there's a major security issue.
Comment 3 Michael Thessel 2013-03-25 10:19:04 PDT
Created attachment 3922 [details]
Error Message
Comment 4 Michael Thessel 2013-03-25 10:22:45 PDT
I installed OJS version 2.3.8 and could reproduce the error there.

[Thu Mar 21 18:53:04 2013] [error] [client 192.168.40.1] PHP Fatal error:  Call to a member function getFileId() on a non-object in /src/ojs-2.3.8/classes/submission/editor/EditorAction.inc.php on line 124, referer: http://ojs_stable.vm/index.php/journal1/manager/importexport/plugin/QuickSubmitPlugin

Steps to reproduce:
* Set up journal with 2 languages
* Set up those languages as ui, submission and form languages
* Load quick submit plugin and select language other than default language
* Fill all required fields and upload file
* Submit
* 2 error messages will appear (default language's title and abstract are missing)
* Switch to default language, fill abstract and title
* Submit

This error doesn't happen in the latest development version.

What is strange though, is that you have to fill the abstract and title for the default language. I'm not sure if this is intended. Even if it would be the UI for this is not intuitive. The problem is that in 2.3.8 as well as in 2.4.1, when you don't fill the title and abstract for the default language you will be presented with the error messages mentioned above but the title and abstract fields highlighted are the ones for the selected language. So you get fields marked as containing errors which are actually filled correctly. See attached screenshot.
Comment 5 Alec Smecher 2013-03-25 10:26:06 PDT
Michael, thanks for investigating -- I'm content to mark this a WONTFIX, as the original report doesn't apply to the 2.4.x line. (The 2.3.x line only gets security bugfixes at this point.) The multilingual input tools have been vastly improved in the master branch (for release in OJS 3.0) so I don't think the quirks here are worth fixing.

Garant, I'd suggest upgrading to a 2.4.x release.
Comment 6 Garant 2013-03-25 11:19:47 PDT
Hi, Alec!
Thank you for you advice.
Just wondering, the 2.4.x is a development branch? I mean does it suit for a production server?
Comment 7 Garant 2013-03-25 11:20:28 PDT
Michael, thank you for you help!
Comment 8 Alec Smecher 2013-03-25 11:23:14 PDT
Garant, good question. When we release a new major line (e.g. 2.2.0, 2.3.0, 2.4.0) we will typically have to release a couple of follow-up releases before it becomes stable. For 2.4.x, our candidate is 2.4.2; we released that about 3 weeks ago and only have a few minor issues patched so far (see http://pkp.sfu.ca/wiki/index.php/OJS_2.4.2_Recommended_Patches for a list). I'll be speaking with the team about designating OJS 2.4.2 "stable" later this week, but can't think of any impediments to that. So you're safe to proceed with 2.4.2 and we should be designating it "stable" very soon.
Comment 9 Garant 2013-03-25 11:40:18 PDT
Alec, thank you!
Comment 10 Alec Smecher 2013-06-10 11:39:59 PDT
On further investigation, this does appear to be a problem in 2.4.x. The QuickSubmit plugin does support multiple file uploads for different locales, but if an upload for the primary locale is not included, then a fatal error will occur. Try e.g.:

Primary Locale English; also supports French
- Go to QuickSubmit plugin
- Enter metadata
- Change locale to French
- Upload a file
- Submit the article

...you'll get (OJS 2.4.2)...

[Thu Mar 21 18:53:04 2013] [error] [client 192.168.40.1] PHP Fatal error:  Call to a member function getFileId() on a non-object in /src/ojs-2.3.8/classes/submission/editor/EditorAction.inc.php on line 123

Patch:
https://github.com/pkp/ojs/commit/53ffbd26b4453dd4351938e63b14dad2619be1e1.diff
Comment 11 Alec Smecher 2013-06-10 11:40:02 PDT
Fixed behavior without primary locale included in file uploads
https://github.com/pkp/ojs/commit/53ffbd26b4453dd4351938e63b14dad2619be1e1
Comment 12 Alec Smecher 2013-06-10 11:40:02 PDT
Fixed behavior without primary locale included in file uploads
https://github.com/pkp/ojs/commit/02e1a5027298b6887f729849769b20958c89171c