Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | Last revision Both sides next revision | ||
tutorial:adm:personalize_localization [2018/12/28 13:20] kotisovam [Personalize localization] |
tutorial:adm:personalize_localization [2018/12/28 13:31] kotisovam [Script run] |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Personalize localization ====== | ||
+ | If you want to personalize some of error, warning, info messages, labels, buttons, etc. you can use the simple shell script (for now, TODO is the script only for Linux systems). | ||
+ | Presently, you can download the script [[http:// | ||
+ | |||
+ | Place the script into the built-in frontend (eq. czechidm-app/ | ||
+ | |||
+ | As **pre-requisites** you must install [[https:// | ||
+ | $ apt-get install jq | ||
+ | |||
+ | Set up a script permission: | ||
+ | $ chmod +x localizationTransform.sh | ||
+ | | ||
+ | Create file '' | ||
+ | |||
+ | < | ||
+ | build.sh | ||
+ | config | ||
+ | czechidm-modules | ||
+ | dist | ||
+ | docs | ||
+ | gulpfile.babel.js | ||
+ | index.html | ||
+ | localizationTransform.sh | ||
+ | node_modules | ||
+ | override_localization.txt | ||
+ | package.json | ||
+ | src | ||
+ | </ | ||
+ | |||
+ | ===== Configuration file ===== | ||
+ | |||
+ | In file '' | ||
+ | |||
+ | < | ||
+ | |||
+ | * **MODULE_ID**: | ||
+ | * **LOCALIZATION**: | ||
+ | * **LOCALIZATION KEY**: key of override message, | ||
+ | * **LOCALIZATION MESSAGE**: new localization message | ||
+ | |||
+ | |||
+ | Examples: | ||
+ | < | ||
+ | core; | ||
+ | core; | ||
+ | core; | ||
+ | core; | ||
+ | acc; | ||
+ | acc; | ||
+ | </ | ||
+ | |||
+ | ===== Script run ===== | ||
+ | $ ./ | ||
+ | |||
+ | On running the script, you get a message displaying the standard output. If some localization key will not be found though, you will receive an error message pointing out the reason for failure: | ||
+ | FAILED key: ' | ||
+ | |||
+ | ===== Example output of script ===== | ||
+ | |||
+ | < | ||
+ | ➜ dist ./ | ||
+ | | ||
+ | / ___|_______ | ||
+ | | | | ||
+ | | |___ / / __/ (__| | | | | | (_| | | | | | ||
+ | \____/ | ||
+ | | ||
+ | | _ )/ __\ \ / / ___ ___| |_ _| |_(_)___ _ _ ___ | ||
+ | | _ \ (__ \ V / (_-</ _ \ | || | _| / _ \ ' \(_-< | ||
+ | |___/\___| \_/ / | ||
+ | Script for transfrom lozalization message from build FE project | ||
+ | |||
+ | JQ installed. | ||
+ | Replace: ' | ||
+ | Replace: ' | ||
+ | Replace: ' | ||
+ | Replace: ' | ||
+ | FAILED key: ' | ||
+ | FAILED key: ' | ||
+ | |||
+ | Localization translation was ended. | ||
+ | |||
+ | </ |