Localization for SXP Employee Edition


First published on: 08/10/2023/6:54 pm

 

 

Users automatically see localization based on the locale of the person logging into the SXP Portal. Local number formats and dates give users a consistent experience based on what the logged-in user is accustomed to in their native locale.

 

Locale is not the same as language, but it can be related (e.g., you can “localize” English to UK English). From an SXP perspective, a user can access an SXP in a language different from their locale. In this case, the user’s experience will be presented in their native locale, but the language will be displayed based on what an administrator configured.

 

That is, what is displayed (the language) is controlled by an admin, while how it’s displayed (locale) is automatically adjusted for the user.

 

When using the default language (English en-us), no further localization is required.

 

To use another language or a localized version of English, update these areas:

  • Menus
  • Reports
  • Application strings

 

Language packs aren't provided, and it's assumed that a single language will be displayed throughout the Portal.

 

Before you can configure menu items and report titles for a specific language, an admin must manually update them. By default, all menus and reports are localized to US English (en-us), and choosing language strings for another locale (e.g., UK English) will replace the previous language strings.

 

Menus currently support only a single language; however, you can translate or localize this language, as described below.

 

To localize a menu:

  1. Go to SXP Manager AddOn > Manage Menu.

  2. Select the desired application and menu.

  3. For each menu entry, ensure the entry’s Name field is translated. This is the link name displayed to the end customer.

  4. For menu entries that are grids, pivots, or charts, open the report link and edit the Query columns associated with that link. Edit the query using the standard SAP Business One query editor. (Always back up queries to a safe location before making edits.)

  5. Recycle the B1WebAPI’s application pool. This will clear the cached language default for all Portals. See 'Recycling Application Pools' for a walkthrough.

  6. Recycle the Portal’s application pool. This will reload the language default from B1WebAPI. See 'Recycling Application Pools' for a walkthrough.

 

Report Localization

You can localize reports in SXP by configuring query column aliases that display to web users. Some queries contain columns that aren't displayed to the web user, and these query aliases must remain intact. A list of query requirements when applying localization is below.

 

You can edit standard queries in SAP Business One's query editor. You must edit 'stored procedure' queries within the stored procedure.

 

Warning: Stored procedure edits require advanced configuration that rely on skills in SQL/Hana. Always back up stored procedures before making edits. When in doubt, contact your B1 consultant.

 

When localizing a report that contains a query link, the query itself is not the source of the column name. These query links may be re-aliased as described in the 'Query Link Localization' section below.

 

Localization Requirements for Queries

Query Description Requirements
B1WebAPI_SU / _OMAN_GET_OPPORTUNITIES_FOR_BOARD

This query is used on the opportunities board and executes a stored procedure ZED_OMAN_GET_OPPORTUNITIES_FOR_BOARD.

 

This stored procedure must be updated.

All fields must remain aliased without changes. Field names aren't displayed to end users.

However, displayed opportunity stage names are based on the default SAP Business One settings.

 

If opportunity stage names must be localized, the value of the 'Name' field can be changed in the stored procedure ZED_OMAN_GET_OPPORTUNITIES_FOR_BOARD.

 

This type of edit requires advanced skills in SQL/Hana query editing.

B1WebAPI_SU / Opportunity Analysis This is a standard pivot report. No special requirements.
B1WebAPI_SU / Opportunity Analysis - All This is a standard pivot report. No special requirements.
B1WebAPI_SU / _OMAN_MYCUSTS This is a standard grid report. Customer alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_QueryPortal / My Sales Orders This is a standard grid report. Customer alias and Ref # aliases are in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.

Other fields have no special requirements.
B1WebAPI_QueryPortal / My Sales Quotes This is a standard grid report. Customer alias and Quote # aliases are in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.

Other fields have no special requirements.
B1WebAPI_SU / _OMAN_GET_MY_OPEN_ACTIVITIES This is a standard grid report. Task Name alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_SU / _OMAN_GET_MY_CLOSED_ACTIVITIES This is a standard grid report. Task Name alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_SU / _OMAN_INVREPORT This is a standard grid report. No special requirements.
B1WebAPI_SU / Last Orders This is a standard pivot report. No special requirements.
B1WebAPI_SU / _OMAN_SALESANALYSIS This is a standard chart report. No special requirements.
B1WebAPI_Expense / RP_ExpRequests This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_ExpRequestDetails This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_ExpClaims This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_ExpClaimDetails This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_MyRequests This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_MyApprovalHistory This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_ApprRequestLinesNotClaimed This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_MyClaims This is a standard grid report. Details alias is in the query link UDT ZEDS_QUERYLINK. See 'Query Link localization' below.
B1WebAPI_Expense / RP_ExpenseAnalysis This is a standard pivot report. No special requirements.

 

When localizing query reports, queries with corresponding query links (i.e., if a web drill-down link has been set up for the report) require localization of the label associated with its drill-down link. This is done within the ZEDS_QUERYLINK UDT (user-defined table).

 

  1. First, open the ZEDS_QUERYLINK UDT under Tools > User-Defined Windows > ZEDS_QUERYLINK - Portal Query Doc Link.

  2. Next, scroll right to the Grid Column Title field. This is the text the end-user will see. Change it to the desired value.

    Edit the 'Grid Column Title' field (1) to change what end-users see.
  3. Update the UDT.

  4. Recycle the B1WebAPI’s application pool when all query links are edited. This will clear the cached query links for all Portals. See 'Recycling Application Pools' for a walkthrough.

  5. Recycle the Portal’s application pool. This will reload changed query links from B1WebAPI. See 'Recycling Application Pools' for a walkthrough.

Application String Localization

You can localize application strings on the web server by updating the values in SXP website’s App_GlobalResources/AppStrings.resx file.

 

Notes to consider before making changes to this file:

  • Back up the AppStrings file.
  • Saving the AppStrings file will restart the website, disrupting web users. The best practice is to update a test site first, confirm the details, then load the changes to production when few users are logged in.
  • Application string files are well-formed XML. Exercise caution when making edits so the XML remains well-formed.

  • When editing application strings for SXP, ensure the value field doesn't contain prohibited XML characters. For a helpful guide, see 'Stack Overflow - What characters do I need to escape in xml documents' and the more technical deep-dive 'W3C - XML'.

  • Included in the application strings file are breadcrumb labels, which begin with the word “Breadcrumb” (e.g., BreadcrumbHome). Replace the value associated with each breadcrumb link to update the breadcrumbs web users see.

 

How to Update Application Strings

1. Open the 'Application Strings' file in an advanced editor such as Visual Studio or a basic text editor.

Warning: When using a text editor to make changes, always create a backup in a safe place. Manual edits to XML files (such as AppStrings.resx) may result in malformed XML, which will prevent the website from working. Backups can be used to restore the website's AppStrings to a previous working state.

2. Find and update the desired label.

In Visual Studio, the 'Name' field contains the identifier for the label and shouldn't be changed, while 'Value' contains its content. Values will be displayed to the end-user and can be updated. Comments sometimes clarify details related to this web label and typically don’t need to be updated (but can be for internal reference).

 

In a text editor, <data name="BreadcrumbHome" xml:space="preserve"> identifies a label (here the label for 'BreadcrumbHome') and shouldn't be changed, while the contents of <value> may be edited to change what’s displayed on the web.

 

 

 

 

Previous

Next


  

Last modified: 01/27/2025/9:58 pm

 

-