Only EN language is available on DEV environment in buildplace inspite of many languages is enabled.
Only EN language is available on DEV environment in buildplace inspite of many languages is enabled.
Hi @InfFilipV
Please note that, the Build Place environments are only available in English language at the moment.
Once you have approved and merged the Pull Request to add the translations to the master branch of the Customer Solution repository, you can can include the language components to the next planned delivery to the Use Place. Once the delivery has been installed, the new languages will be available will be available in the Use Place.
Hi
Please follow the below steps to install translations to build place.
1. To enable new language translations
https://docs.ifs.com/techdocs/21r2/047_lifecycle/070_self_service_options/010_updating_lng/
2. Download the translations from https://download.ifs.cloud/# for different components
https://docs.ifs.com/techdocs/21r2/045_administration_aurena/280_localization/030_import_language_files2/download_and_install_translations_manually/
It's possible to download multiple TRS files from different languages and different components from the site at the same time.
3. As for importing, you can select multiple TRS files and import them at once. Please use Run as Background Job when importing large number of files.
4. As per the problem with extracting multiple zip files. Please refer,
https://community.ifs.com/infrastructure-development-extensibility-iot-cto-office-technology-226/import-translations-13352?postid=50466#post50466
Thank you
Hi
thanks for answers.
So question is:
How I am able to test translations?
In my opinion is quite late to testing modifications’ translation only on UsePlace.
When I exported *.trs and *.lng files to GIT and order TOPIC environment, they wasn’t imported. It looks like, import is disabled:
To check my translations I have to recreate environment and import files manually, but it also does not work.
Until I imported whole cs language, I cannot see my imported translations (new column in Cust layer).
Is planned to add ability to test translations?
Hi
Currently, the "Import Language" feature has been disabled because when the above feature is enabled, it consumes a long time to complete the build execution process. When it comes to the practical scenario, the above execution time is unacceptable from the user's perspective. Therefore, the above importing process needs to be optimized, and the relevant platform team is working on this as of now we can not predict an exact release date for enabling the translations in build place environments. However, once the above feature is enabled, you will be notified through the upcoming release notes.
Cheers!
Hi,
thanks for answer.
In this case, there should be some options to control it in scope of Build Place to specific env. type or setup it while ordering environment.
For example TEST and DEL environments should have all languages imported - to be able to do complex testing.
There should be options for:
- do not import Test Data
- import languages
- select particular languages to import
- import language files from repository
- send notification (on creation / fail / on import data is done)
- prevent deletion by another user without approval (some email with confirmation link)
BR
Filip
Hi,
Do you know when languages other than EN will be handled on Build Place environments? We started Polish translations in one of our local IFS Cloud projects and this process is much more complex than in APP10, and it takes much more time.
Best regards,
Piotr
Hi
I tried to simplify this process by creation TAR script that enable all wanted languages for translation and setup Cust layer as default.
TAR Script:
### Set Cust as default translation layer
```cs
Get BasicDataAdministrationLayerHandling.svc/FndLayerSet(LayerId='Cust') Into layerCust
Modify BasicDataAdministrationLayerHandling.svc/FndLayerSet(LayerId='Cust') Using layerCust When layerCust.UseForDevelopment == false
{
"UseForDevelopment": true
}
```
### Enable en, cs, sk, pl, hu languages for translation
```cs
Get UsedLanguagesHandling.svc/LanguageCodeSet?$filter=((LangCode eq 'en') or (LangCode eq 'cs') or (LangCode eq 'sk') or (LangCode eq 'pl') or (LangCode eq 'hu'))&$select=Status,LangCode Into langs
Modify UsedLanguagesHandling.svc/LanguageCodeSet(LangCode={#langs.value.Items(0).LangCode}) Using langs.value.Items(0) When langs.value.Items(0).Status == false
{
"Status":true
}
Modify UsedLanguagesHandling.svc/LanguageCodeSet(LangCode={#langs.value.Items(1).LangCode}) Using langs.value.Items(1) When langs.value.Items(1).Status == false
{
"Status":true
}
Modify UsedLanguagesHandling.svc/LanguageCodeSet(LangCode={#langs.value.Items(2).LangCode}) Using langs.value.Items(2) When langs.value.Items(2).Status == false
{
"Status":true
}
Modify UsedLanguagesHandling.svc/LanguageCodeSet(LangCode={#langs.value.Items(3).LangCode}) Using langs.value.Items(3) When langs.value.Items(3).Status == false
{
"Status":true
}
Modify UsedLanguagesHandling.svc/LanguageCodeSet(LangCode={#langs.value.Items(4).LangCode}) Using langs.value.Items(4) When langs.value.Items(4).Status == false
{
"Status":true
}
```
### Importing Test Data is done
```cs
Create StreamSubscriptions.svc/FndStreamMessages
{
"FromUser": "IFSAPP",
"ToUser": "IFSAPP",
"Message": "Test Data was imported",
"Header": "Test Data was imported",
"Visible": true,
"StreamType": "General",
"Read": true,
"FollowUpCreated": true
}
```
I’m doing translations in Excel file exported from PL/SQL Developer query bellow, In Excel I generate DB Calls to save translations.
SQL Select for Excel creation
SELECT
attribute_id,
prog_text,
(SELECT ft.field_trans FROM field_translation ft WHERE ft.attribute_id = tf.attribute_id AND ft.lang_code = 'cs') cs,
(SELECT ft.field_trans FROM field_translation ft WHERE ft.attribute_id = tf.attribute_id AND ft.lang_code = 'sk') sk,
path,
module,
layer,
sub_type,
main_type
FROM
translatable_fields tf
WHERE
layer = 'Cust'
AND module = 'GENLED'
-- AND attribute_id >= 145645654
ORDER BY
prog_text
Then convert to table (Format as table) and add columns to generate translation.
Excel Formulas for SQL CMD generation
=IF(I@CS]<>"";"Language_Translation_API.Refresh_("&m@;ATTRIBUTE_ID]]&", 'cs', '"&m@CS]&"', 'O');";"")
=IF((F@SK]&m@CS])<>"";"Language_Translation_API.Refresh_("&m@;ATTRIBUTE_ID]]&", 'sk', '"&IF(I@SK]<>"";"@SK];K@CS])&"', 'O');";"")
Then copy Generated SQL code together and convert to ASCII safe form with UNISTR
Example pre and post unicode escape
Language_Translation_API.Refresh_(1473751, 'cs', 'Datum vzniku', 'O');
Language_Translation_API.Refresh_(1473754, 'cs', 'DIČ', 'O');
==>
Language_Translation_API.Refresh_(1473751, 'cs', 'Datum vzniku', 'O');
Language_Translation_API.Refresh_(1473754, 'cs', TO_CHAR(UNISTR('DI\010C')), 'O');
PowerShell script for conversion
function ConvertToUnistr()
{
add-type -assembly System.Windows.Forms
$form=New-Object System.Windows.Forms.Form
$form.StartPosition='CenterScreen'
$btn=New-Object System.Windows.Forms.Button
$btn.Text='Convert'
$btn.DialogResult='Ok'
$btn.Dock='bottom'
$form.Controls.Add($btn)
$btnCancel=New-Object System.Windows.Forms.Button
$btnCAncel.Text='Cancel'
$btnCancel.DialogResult='Cancel'
$btnCancel.Dock='bottom'
$form.Controls.Add($btnCancel)
$tb=New-Object System.Windows.Forms.Textbox
$tb.Multiline=$true
$tb.Dock = 'fill'
$tb.ScrollBars = 'Both'
$tb.WordWrap =$false
$tb.MaxLength = 1000000000
$form.Controls.Add($tb)
$form.add_load({$tb.Select()})
if($form.ShowDialog() -eq 'Ok'){
$input = $tb.Text
$sb = New-Object Text.StringBuilder
$output = ""
for($i = 0; $i -lt $input.Length; $i++)
{
$ic = cInt16]tchar]$inputn$i]
if ($ic -gt 125)
{
void]$sb.Append("\")
void]$sb.Append(eSystem.Convert]::ToString($ic, 16).ToUpper().PadLeft(4, "0"))
}
else
{
void]$sb.Append($inputn$i])
}
}
$output = $sb.ToString()
$output = tregex]::Replace($output, "',^']*\\]^']*'", "TO_CHAR(UNISTR(`$0))")
Set-Clipboard -Confirm -Value $output
}else{
Write-Host 'Cancelled' -fore red
}
}
Hope it help.
BR
I’m doing translations in Excel file exported from PL/SQL Developer query bellow, In Excel I generate DB Calls to save translations.
Language_Translation_API.Refresh_(1473751, 'cs', 'Datum vzniku', 'O');
Language_Translation_API.Refresh_(1473754, 'cs', 'DIČ', 'O');
==>
Language_Translation_API.Refresh_(1473751, 'cs', 'Datum vzniku', 'O');
Language_Translation_API.Refresh_(1473754, 'cs', TO_CHAR(UNISTR('DI\010C')), 'O');
Hope it help.
BR
Hi
Great work. Is there a corresponding call to Language_Translation_API.Refresh_ which would actually create the translation? I followed your example and there seems to be a second call need to create the translation itself while .Refresh only refreshes?
Thanks,
T.
Hi
if I know, this is enough. Maybe you have only forgotten to commit your script.
And always - do refresh of language cache to make translations work.
BR
Hi
if I know, this is enough. Maybe you have only forgotten to commit your script.
And always - do refresh of language cache to make translations work.
BR
Yeah, that got it. Thanks for the fast reply!!!
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.