Empty navigation menu in some journals when upgrading from OJS2 to 3.1.1.4

Hi @Dimitris_Efstathiou

I upgraded a large OJS2 installation to OJS3. In some journals the navigation menus were created without any problems, but in others including the index level the labels for the menu items are empty. I mean there is no text available for the items.

What could be the reason for this? I mean I can do an own sql script and just upgrade the labels according to the keys, but maybe this is something that should be fixed in the upgrade script?

Seems that these journals only have the titleLocaleKey setting in the db, so the title setting is missing from the navigation_menu_item_settings table.

@Dimitris_Efstathiou
The problem is related to the journal language settings in OJS2. With some settings (maybe missing) the default labels are not being created.

Hi @ajnyga.

After NavigationMenu Feature - Locales for default NMIs retrieved from key and not database · Issue #3846 · pkp/pkp-lib · GitHub issue applied, we should only have the setting_name="titleLocaleKey" after going from 2.x to 3.x.

The issue there could be that OJS can’t find the titleLocaleKey specified for a certain navigation menu item in the specified UI language setting. Do you get navigation menu items with blank titles or with untranslated title (like ##locale.key##)

I am seeing both title and titleLocaleKey. I used 3.1.1.4 in the upgrade.

03

The problem seemed to be some missing locale settings in OJS2. It seems that settings for the UI, forms and submission language was missing from some journals after they were migrated to OJS3. After I added those settings to the journals, emptied the navigationmenu tables and executed the upgrade process again only with the navigationmenu setup function, all menus appeared.

Not sure yet what is missing from OJS2. What if a OJS2 journal has a default locale that OJS3 does not support? What happens?

Edit: and to answer your question: I got blank items. Label was missing, but the item was there.

Thanks @ajnyga.

Is navigation_menu_item_id=29 fail to show its title? What’s the setting_name=titleLocaleKey value for a navigation_menu_item_id that its title fails to show? Does it have any setting_name=title entry?

Generally, as of the version 3.1.1.4, the setting_name="title" should be getting stored at the db after the first save of a navigation menu item edit form. That lets the user change the default title of the NMI if he want’s…

If there is a setting_name=title for a NMI defined, that value is getting displayed as title. If not, the setting_name=titleLocaleKey is getting translated using the OJS locale-key translation mechanism, and that is getting displayed.

From 3.1.1.4 version on, the default locale of OJS 2.x shouldn’t have any affect on NMI titles, other than the affect that could have on the other OJS installation as well. That’s because, the upgrade/install process only stores the setting_name=titleLocaleKey rows for each NMI, and then lets OJS handle them.

As a test, I could suggest taking the following action:

  • Upgrade from 2.x to 3.1.1.4 → see the status of the navigation_menu_item_settings table.
  • Check setting_name=titleLocaleKey and setting_name=title entries for any NMI that does not get displayed
  • Check if the current language settings “allow” the titleLocaleKey to be displayed (I think that there is no case where OJS displays any locale key as blank though, so that could be an indication that a NMI feature bug exists.)

Hi,

No sorry, that is from the fixed database. After the initial upgrade the title was missing.

After I fixed the supportedSubmissionLocales, supportedFormLocales and supportedLocales values for all journals in journal_settings and executed the upgrade process again, the missing labels appeared.

I have a feeling that the supportedLocales had some strange values in OJS2. I will check that later.