Openbravo Issue Tracking System - POS2
View Issue Details
0049992POS2Corepublic2022-08-12 08:072022-08-12 08:08
jorge-garcia 
Triage Platform Base 
normalmajoralways
newopen 
5
 
 
No
0049992: Messages from some modules are not available in ReactPOS application
Modules can add messages in Backoffice as System Administrator to be used then in ReactPOS application.

Messages from some modules are not available in ReactPOS application once the application is build.

The messages from module are available once the module has as module dependency org.openbravo.retail.posterminal
In an instance of pos2:
In ERP:
  1) Login as Openbravo
  2) Switch role to System Administrator
  3) Go to Module window and put org.openbravo.retail.discounts with In
     Development flag checked
  4) Go to Message window and create a new record for Discounts & Promotions
     Rules for Retail:
       * Search Key: OBDISC_TestLabel
       * Message Type: Information
       * Message Text: Test Label
  5) Save the record

In ubuntu terminal
  1) Navigate to instance folder and go to org.openbravo.core2 module
  2) Execute ant build command and wait until build is successful
  3) Start the server

In ReactPOS Application
  1) Try to use a label OBDISC_TestLabel (using Translate component, useLabel react hook or getLabel function)
  2) Verify the label is not rendered
  3) Verify label is not available in generated POS2-labels-en_US.json file

Repeat the whole process including as a dependant module of org.openbravo.retail.discounts the module org.openbravo.retail.posterminal and verify message are available in ReactPOS app
Reading the code, it seems that the module messages to be taken into account are the ones at 1 level deep from pos2 module.

That is why for example org.openbravo.retail.discounts messages are not available in ReactPOS (it depends only from User Interface Client Kernel module) but messages from module org.openbravo.retail.discounts.bytotal are available (it depends directly from Web POS module)
No tags attached.
Issue History
2022-08-12 08:07jorge-garciaNew Issue
2022-08-12 08:07jorge-garciaAssigned To => Triage Platform Base
2022-08-12 08:07jorge-garciaTriggers an Emergency Pack => No
2022-08-12 08:08jorge-garciaSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=24603#r24603

There are no notes attached to this issue.