diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 84b1e5e0..8c162216 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -56,6 +56,7 @@ jobs: --exclude=".ci_config_deploy/***" \ --exclude="data/***" \ --exclude="docs/***" \ + --exclude="Customimport/***" \ --exclude="temp/***" \ --exclude="CopyToKeycloak/***" \ --exclude="Umsetzungsanweisung/***" \ @@ -140,6 +141,7 @@ jobs: --exclude="data/***" \ --exclude="docs/***" \ --exclude="temp/***" \ + --exclude="Customimport/***" \ --exclude="CopyToKeycloak/***" \ --exclude="Umsetzungsanweisung/***" \ --exclude="config/staging/***" \ diff --git a/Customimport/salesforcelanguageimport.html b/Customimport/salesforcelanguageimport.html new file mode 100644 index 00000000..72035a3f --- /dev/null +++ b/Customimport/salesforcelanguageimport.html @@ -0,0 +1,993 @@ + + + + + +Salesforce XLIFF Translation Tool + + + + + + + + +

Salesforce XLIFF Translation Tool

+ +
+

How to use this tool

+
    +
  1. Export the required target languages from Salesforce in XLIFF format.
  2. +
  3. Salesforce may provide several language files in a ZIP archive. You can upload the Salesforce ZIP directly or select extracted XLIFF files.
  4. +
  5. Under Salesforce XLIFF export files, select the ZIP or the individual XLIFF files for the languages you want to translate. The tool automatically reads all XLIFF files from a ZIP and detects each file's target-language value.
  6. +
  7. Prepare one Excel or CSV target translation file and upload it under Target translation.
  8. +
  9. Check the language matches, create the preview, and then download the translated files as a ZIP archive.
  10. +
  11. Extract the generated ZIP and import each completed target-language XLIFF file into Salesforce separately. Salesforce accepts one translation file per import.
  12. +
+ +

Required columns: Header names are case-insensitive. The English headers object, field, and target are recommended. The existing German aliases Objekt and Feld also remain supported.

+ + + + + + + + + + + + + + + + + + + + + + + + +
objectfieldtargetlanguage
AccountNameKontonamede
AccountNameNom du comptefr
+ +

The optional language column lets one target translation file contain several languages. Its values must match the XLIFF target-language values, for example de, fr, or de-DE. If the column is omitted and several Salesforce XLIFF files are loaded, select the one target XLIFF file to which the translation data belongs.

+

Important: Each matched target language is exported as a separate XLIFF file inside the generated ZIP. A language file is omitted when no matching translation can be applied. The result contains only changed translation units with a non-empty target value. Rows with an empty target, rows where field and target are identical, and translations identical to the current XLIFF source or target are omitted.

+
+ +
+
+ +
No Salesforce XLIFF export files selected.
+
+ +
+
+ +
No target translation file selected.
+ +
+ +
+
+ +
+ +
+ + +
+ +
+ +
+ + + + + + + + + + + + +
FileLanguageObjectFieldCurrent targetResult target
+
+ + + + + \ No newline at end of file diff --git a/docs/README.md b/docs/README.md index ee1fd737..c1ac1471 100644 --- a/docs/README.md +++ b/docs/README.md @@ -51,6 +51,7 @@ Aktuell wichtig: - der Mining-Checker ist das erste als echtes Desktop-Modul angebundene Modul unter `modules/mining-checker/` - der Waehrungs-Checker ist als zweites echtes Desktop-Modul unter `modules/fx-rates/` angebunden +- der Salesforce Translation Import ist als weitere Desktop-App unter `modules/salesforce-translation-import/` angebunden - Modul-Assets koennen ueber einen gemeinsamen Auslieferungsweg aus dem Modul selbst geladen werden - die API bleibt vorerst auf demselben Host und wird nicht auf `api.desktop.kusche.berlin` ausgelagert - das gemeinsame Admin-Debug-Widget neben der Uhr ist der Standard fuer Live-Debugging in Desktop und Native-Apps diff --git a/modules/salesforce-translation-import/desktop.php b/modules/salesforce-translation-import/desktop.php new file mode 100644 index 00000000..e4e4b837 --- /dev/null +++ b/modules/salesforce-translation-import/desktop.php @@ -0,0 +1,25 @@ + 'salesforce-translation-import', + 'title' => (string) ($manifest['title'] ?? 'Salesforce Translation Import'), + 'icon' => 'SF', + 'entry_route' => '/apps/salesforce-translation-import', + 'window_mode' => 'window', + 'content_mode' => 'iframe', + 'default_width' => 1180, + 'default_height' => 820, + 'supports_widget' => false, + 'supports_tray' => false, + 'module_name' => 'integration', + 'summary' => (string) ($manifest['description'] ?? 'Import-Werkzeug fuer Salesforce-XLIFF-Dateien und Zieluebersetzungen aus Excel oder CSV.'), +]; diff --git a/modules/salesforce-translation-import/docs/README.md b/modules/salesforce-translation-import/docs/README.md new file mode 100644 index 00000000..78f077af --- /dev/null +++ b/modules/salesforce-translation-import/docs/README.md @@ -0,0 +1,14 @@ +# Salesforce Translation Import + +Desktop-App fuer den Import von Salesforce-XLIFF-Dateien mit Zieluebersetzungen aus Excel oder CSV. + +## Einbindung + +- Desktop-App ueber `modules/salesforce-translation-import/desktop.php` +- oeffentlicher App-Einstieg ueber `public/apps/salesforce-translation-import/index.php` +- Darstellung als isolierte Fensterseite per `iframe`, damit die Import-Logik und die Formularstruktur stabil bleiben + +## Hinweis + +- die bestehende HTML-/JS-Logik aus `Customimport/salesforcelanguageimport.html` wurde als App-Seite uebernommen +- vorhandene Inline-CSS bleibt weitgehend erhalten, weil die App in einer isolierten Fensterseite laeuft und dadurch das globale Desktop-UI nicht direkt stoert diff --git a/modules/salesforce-translation-import/module.json b/modules/salesforce-translation-import/module.json new file mode 100644 index 00000000..3a5baede --- /dev/null +++ b/modules/salesforce-translation-import/module.json @@ -0,0 +1,12 @@ +{ + "name": "salesforce-translation-import", + "title": "Salesforce Translation Import", + "version": "0.1.0", + "description": "Import-Werkzeug fuer Salesforce-XLIFF-Dateien und Zieluebersetzungen aus Excel oder CSV.", + "enabled_by_default": true, + "auth": { + "required": true, + "users": [], + "groups": [] + } +} diff --git a/modules/salesforce-translation-import/pages/index.php b/modules/salesforce-translation-import/pages/index.php new file mode 100644 index 00000000..a0861eec --- /dev/null +++ b/modules/salesforce-translation-import/pages/index.php @@ -0,0 +1,1008 @@ + + + + + +Salesforce Translation Import + + + + + + + + +

Salesforce XLIFF Translation Tool

+ +
+

How to use this tool

+
    +
  1. Export the required target languages from Salesforce in XLIFF format.
  2. +
  3. Salesforce may provide several language files in a ZIP archive. You can upload the Salesforce ZIP directly or select extracted XLIFF files.
  4. +
  5. Under Salesforce XLIFF export files, select the ZIP or the individual XLIFF files for the languages you want to translate. The tool automatically reads all XLIFF files from a ZIP and detects each file's target-language value.
  6. +
  7. Prepare one Excel or CSV target translation file and upload it under Target translation.
  8. +
  9. Check the language matches, create the preview, and then download the translated files as a ZIP archive.
  10. +
  11. Extract the generated ZIP and import each completed target-language XLIFF file into Salesforce separately. Salesforce accepts one translation file per import.
  12. +
+ +

Required columns: Header names are case-insensitive. The English headers object, field, and target are recommended. The existing German aliases Objekt and Feld also remain supported.

+ + + + + + + + + + + + + + + + + + + + + + + + +
objectfieldtargetlanguage
AccountNameKontonamede
AccountNameNom du comptefr
+ +

The optional language column lets one target translation file contain several languages. Its values must match the XLIFF target-language values, for example de, fr, or de-DE. If the column is omitted and several Salesforce XLIFF files are loaded, select the one target XLIFF file to which the translation data belongs.

+

Important: Each matched target language is exported as a separate XLIFF file inside the generated ZIP. A language file is omitted when no matching translation can be applied. The result contains only changed translation units with a non-empty target value. Rows with an empty target, rows where field and target are identical, and translations identical to the current XLIFF source or target are omitted.

+
+ +
+
+ +
No Salesforce XLIFF export files selected.
+
+ +
+
+ +
No target translation file selected.
+ +
+ +
+
+ +
+ +
+ + +
+ +
+ +
+ + + + + + + + + + + + +
FileLanguageObjectFieldCurrent targetResult target
+
+ + + + + diff --git a/public/apps/salesforce-translation-import/index.php b/public/apps/salesforce-translation-import/index.php new file mode 100644 index 00000000..9ad5e7b1 --- /dev/null +++ b/public/apps/salesforce-translation-import/index.php @@ -0,0 +1,5 @@ +