I want to provide translation to OMS state machine button.

mohammed.shamim
mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet

How can I provide translation to spryker oms machine button.

Comments

  • fsmeier
    fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,051 ⚖️ - Guardians (admin)

    Heyhey @mohammed.shamim ,

    very good question! I just had a look and can give you the following hints:

    1. Make sure to name your event in OMS unique. Example: <event name="oms.event.ship" manual="true"/>
    2. Create a translation file, i.E. src/Pyz/Zed/Translator/data/MyCustomModule/en_US.csv
    3. Map the event name with a translation in that file → "oms.event.ship","Let Santa Clause ship it"
    4. Reload the Back Office translation: docker/sdk console translator:clean-cache && docker/sdk console translator:generate-cache

    Then it could look like this in the order status:

    Small note: The OMS graph (the svg image) does not support this kind of translation.

    Hope this answers your question :)

    All the best,

    Florian

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet

    Thanks, I was following doc for translator part but missing the event name format.

  • fsmeier
    fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,051 ⚖️ - Guardians (admin)

    I also did not find any special rule about that event-naming format, but since it will be translated together with the other translation-strings I thought it makes sense to use a more unique token :)

    Glad I could help 💪