Uploaded image for project: 'PUBLIC - Liferay Commerce'
  1. PUBLIC - Liferay Commerce
  2. COMMERCE-1732

When a payment option is scoped to a site, it is not localized


    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 2.0.2, 2.0.6
    • Fix Version/s: None
    • Component/s: None
    • Labels:



      We needed to create more payment options than what was provided out of the box. We created modules for check, credit card, and wire, copying all the code for the existing money order payment option and just changing the references. While doing this, we noticed that the names were not being localized but only on the site our options were scoped to. All other sites, the options localized fine.

      While I am attaching one of our payment option modules that can be deployed to test this with, it is faster demonstrated with the groovy script I wrote that adds one of the existing payment options to a site.

      Steps to Reproduce

      1. Make note of the titles of the payment options for the Liferay DXP site
      2. Grab the site id from the the Site Settings for the Liferay DXP site
      3. Set that id in the attached groovy script
      4. Execute the script
      5. Notice now that for the Liferay DXP site, the specified payment option (money-order) is no longer localized



      It seems that https://github.com/liferay/com-liferay-commerce/blob/2.0.2/commerce-payment-web/src/main/java/com/liferay/commerce/payment/web/internal/display/context/CommercePaymentMethodGroupRelsDisplayContext.java#L228 is successfully localizing the names, which only happens for payment methods not scoped to the site.

      https://github.com/liferay/com-liferay-commerce/blob/2.0.2/commerce-payment-web/src/main/resources/META-INF/resources/view.jsp#L88 does not seem to be working.




            • Votes:
              0 Vote for this issue
              0 Start watching this issue


              • Created:


                Version Package