legacy-knowledge-base
Publicado Jul. 25, 0002

Avoid the categories conversion of the Web Content types during the upgrade to 7.0

written-by

Jose Jimenez

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

legacy-article

learn-legacy-article-disclaimer-text

Description

  • Previous to 7.0, you were able to classify the web content with a type. The types could be specified in the portal-ext.properties, being the next the default types list:
    #
    # Set the list of article types. The display text of each of the article
    # types is set in content/Language.properties.
    #
    journal.article.types=announcements,blogs,general,news,press-release,test
  • In those versions by default the 'general' type was preselected for new web contents in the editor, however the user could change that preselection taking into account that the type was mandatory during the web content creation.

  • As part of a rebuild about how web contents are classified, the types were converted to categories in a new vocabulary in the global scope, named "Type", during the upgrade to 7.0 (see LPS-50764)
  • For some projects the Liferay's assumption of converting web content types in categories could lead into errors, for example for those users using the categories for a specific goal or as part of other feature in where these types do not fit.

Environment

  • Liferay Portal 6.2 and previous versions upgrading to the 7.0 or a newer version.

Resolution

  • The upgrade process do not convert web content types in categories if all the web content in data base were created with the general type. In that case, Liferay asumes that the administrators do not use that feature of classify web content by types and the upgrade process avoid the vocabulary/categories creation, so that, as a workaround you can avoid the new vocabulary and categories simply running this update directly in the portal data base before the upgrade process is executed:
UPDATE JournalArticle set type_ = 'general' WHERE type_ != 'general'

 

  • Note that this update is only valid for a Liferay Portal schema 6.2, or previous versions.
  • If you already have executed the upgrade process and now you are in production with the new version (7.0 or a newer version), the only way to remove that categorization is to remove the category or also to remove the complete Type Vocabulary from global, but take into account that this action can affects to thousands of web contents and it could require a lot of time to be completed.

 

did-this-article-resolve-your-issue

legacy-knowledge-base