| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Update Spanish and Catalan translations
And use _ in folder support
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
User can confirm when deleting an image by double checking the
information displayed on this page.
Adds a new optional field in GenericForm: 'ids'. Used when dealing with
ids instead of ips.
|
|
|
|
|
|
|
|
|
|
| |
This commit adds an extra view to ensure users do not reboot clients
accidentally.
ogcp GET /reboot returns the confirmation page and POST /reboot
builds and sends the request to ogServer.
It also includes Spanish translation of the new strings.
|
|
|
|
|
|
|
|
|
|
| |
This commit adds an extra view to ensure users do not power off clients
accidentally.
ogcp GET /poweroff returns the confirmation page and POST /poweroff
builds and sends the request to ogServer.
It also includes Spanish translation of the new strings.
|
|
|
|
|
|
|
| |
This commit adds an extra view to ensure users do not clients
accidentally.
It also includes Spanish translation of the new strings.
|
|
|
|
| |
Otherwise, ogcp redirects to a blank page instead of the scopes view.
|
|
This commits configures and sets up flask-babel and adds Spanish po
file. Flask-babel is already a dependency so this commits no needs to
add it.
Users can edit ogcp.json to choose between English or Spanish. After
changing the language in the configuration file, users must restart ogcp
service.
Instructions to generate translation files, inspired by
https://flask-babel.tkte.ch/:
1. Download ogcp source code.
git clone git://git.soleta.eu/ogCP /path/to/ogcp
2. Create a python virtual environment.
python3 -m venv /path/to/new/venv
3. Activate the virtual environment.
source /path/to/new/venv/bin/activate
4. Install dependencies to the virtual environment.
cd /path/to/ogcp
pip3 install -r requirements.txt
5. Extract ogcp strings.
cd /path/to/ogcp/ogcp
pybabel extract -F babel.cfg -k _l -o messages.pot .
NOTE: "-k _l" is needed to extract strings which use lazy
translations.
6. Create or update translation files.
a. Create translation file. This example creates a french translation
file.
pybabel init -i messages.pot -d translations -l fr
b. Update translation files. You need to do this when ogcp strings
change and want to update current supported languages.
pybabel update -i messages.pot -d translations
7. Edit the translations .po file as needed. Example route:
/path/to/ogcp/ogcp/translations/fr/LC_MESSAGES/messages.po.
8. Compile translations.
pybabel compile -d translations
9. Launch ogcp and check the translations.
cd /path/to/ogcp
pip3 install -r requirements.txt
10. Commit and push .po files with translation changes.
|