Skip to content

Commit

Permalink
Adding translations
Browse files Browse the repository at this point in the history
  • Loading branch information
rbas committed Aug 11, 2013
1 parent b72fb26 commit ebf6901
Show file tree
Hide file tree
Showing 5 changed files with 312 additions and 2 deletions.
2 changes: 1 addition & 1 deletion django_fiobank/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
VERSION = (0, 0, 3)
VERSION = (0, 0, 4)

__author__ = 'rbas'
__version__ = VERSION
Expand Down
135 changes: 135 additions & 0 deletions django_fiobank/locale/cs/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
msgid ""
msgstr ""
"Project-Id-Version: 0.0.4\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2013-08-11 16:04+0200\n"
"PO-Revision-Date: 2013-08-11 15:04+0100\n"
"Last-Translator: Martin Voldrich <rbas.cz@gmail.com>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
"X-Generator: Poedit 1.5.4\n"

#: admin.py:9
msgid "Transaction type"
msgstr "Typ pohybu"

#: admin.py:15
msgid "All"
msgstr "Vše"

#: admin.py:16
msgid "Income"
msgstr "Příchozí"

#: admin.py:17
msgid "Issue"
msgstr "Odchozí"

#: models.py:20
msgid "Name"
msgstr "Název"

#: models.py:21 models.py:40
msgid "Account number"
msgstr "Číslo účtu"

#: models.py:22 models.py:43
msgid "Bank code"
msgstr "Kód banky"

#: models.py:23
msgid "Token"
msgstr "Token"

#: models.py:26 models.py:35
msgid "Account"
msgstr "Účet"

#: models.py:27
msgid "Accounts"
msgstr "Účty"

#: models.py:36
msgid "Transaction id"
msgstr "Id transakce"

#: models.py:37
msgid "Date"
msgstr "Datum"

#: models.py:38
msgid "Amount"
msgstr "Částka"

#: models.py:39
msgid "Currency"
msgstr "Měna"

#: models.py:41
msgid "Account name"
msgstr "Název účtu"

#: models.py:44
msgid "Bic"
msgstr "BIC"

#: models.py:45
msgid "Bank name"
msgstr "Název banky"

#: models.py:46
msgid "Constant symbol"
msgstr "Konstantní symbol"

#: models.py:48
msgid "Variable symbol"
msgstr "Variabilní symbol"

#: models.py:50
msgid "Specific symbol"
msgstr "Specifický symbol"

#: models.py:52
msgid "User identification"
msgstr "Uživatelská identifikace"

#: models.py:55
msgid "Recipient message"
msgstr "Zpráva pro příjemce"

#: models.py:58
msgid "Type"
msgstr "Typ"

#: models.py:59
msgid "Executor"
msgstr "Provedl"

#: models.py:61
msgid "Specification"
msgstr "Upřesnění"

#: models.py:63
msgid "Comment"
msgstr "Komentář"

#: models.py:65
msgid "Instruction id"
msgstr "ID pokynu"

#: models.py:70
msgid "Transaction"
msgstr "Pohyb"

#: models.py:71
msgid "Transactions"
msgstr "Pohyby"
134 changes: 134 additions & 0 deletions django_fiobank/locale/en/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
msgid ""
msgstr ""
"Project-Id-Version: 0.0.4\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2013-08-11 16:04+0200\n"
"PO-Revision-Date: 2013-08-11 14:56+0100\n"
"Last-Translator: Martin Voldrich <rbas.cz@gmail.com>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Poedit 1.5.4\n"

#: admin.py:9
msgid "Transaction type"
msgstr "Transaction type"

#: admin.py:15
msgid "All"
msgstr "All"

#: admin.py:16
msgid "Income"
msgstr "Income"

#: admin.py:17
msgid "Issue"
msgstr "Issue"

#: models.py:20
msgid "Name"
msgstr "Name"

#: models.py:21 models.py:40
msgid "Account number"
msgstr "Account number"

#: models.py:22 models.py:43
msgid "Bank code"
msgstr "Bank code"

#: models.py:23
msgid "Token"
msgstr "Token"

#: models.py:26 models.py:35
msgid "Account"
msgstr "Account"

#: models.py:27
msgid "Accounts"
msgstr "Accounts"

#: models.py:36
msgid "Transaction id"
msgstr "Transaction id"

#: models.py:37
msgid "Date"
msgstr "Date"

#: models.py:38
msgid "Amount"
msgstr "Amount"

#: models.py:39
msgid "Currency"
msgstr "Currency"

#: models.py:41
msgid "Account name"
msgstr "Account name"

#: models.py:44
msgid "Bic"
msgstr "Bic"

#: models.py:45
msgid "Bank name"
msgstr "Bank name"

#: models.py:46
msgid "Constant symbol"
msgstr "Constant symbol"

#: models.py:48
msgid "Variable symbol"
msgstr "Variable symbol"

#: models.py:50
msgid "Specific symbol"
msgstr "Specific symbol"

#: models.py:52
msgid "User identification"
msgstr "User identification"

#: models.py:55
msgid "Recipient message"
msgstr "Recipient message"

#: models.py:58
msgid "Type"
msgstr "Type"

#: models.py:59
msgid "Executor"
msgstr "Executor"

#: models.py:61
msgid "Specification"
msgstr "Specification"

#: models.py:63
msgid "Comment"
msgstr "Comment"

#: models.py:65
msgid "Instruction id"
msgstr "Instruction id"

#: models.py:70
msgid "Transaction"
msgstr "Transaction"

#: models.py:71
msgid "Transactions"
msgstr "Transactions"
2 changes: 1 addition & 1 deletion django_fiobank/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def __unicode__(self):


class Transaction(models.Model):
account = models.ForeignKey(Account)
account = models.ForeignKey(Account, verbose_name=_('Account'))
transaction_id = models.BigIntegerField(_('Transaction id'))
date = models.DateField(_('Date'))
amount = models.FloatField(_('Amount'))
Expand Down
41 changes: 41 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@
except ImportError:
from distutils.core import setup, find_packages # NOQA

from setuptools.command.install_lib import install_lib as _install_lib
from distutils.command.build import build as _build
from distutils.cmd import Command

version = django_fiobank.__versionstr__


Expand All @@ -27,6 +31,39 @@
def read_file(filename):
return open(os.path.join(base_path, filename)).read()


class CompileTranslations(Command):
description = 'compile message catalogs to MO files via django ' \
'compilemessages'
user_options = []

def initialize_options(self):
pass

def finalize_options(self):
pass

def run(self):
import os
import sys
from django.core.management.commands.compilemessages import \
compile_messages

curdir = os.getcwd()
os.chdir(os.path.realpath(os.path.dirname(django_fiobank.__file__)))
compile_messages(stderr=sys.stderr)
os.chdir(curdir)


class Build(_build):
sub_commands = [('compile_translations', None)] + _build.sub_commands


class InstallLib(_install_lib):
def run(self):
self.run_command('compile_translations')
_install_lib.run(self)

setup(
name='django_fiobank',
version=version,
Expand All @@ -39,6 +76,10 @@ def read_file(filename):
packages=find_packages(),
license=read_file('LICENSE'),
install_requires=['fiobank>=0.0.3,<0.1', 'south'],
include_package_data=True,
package_data={'django_fiobank': ['locale/*/LC_MESSAGES/*.mo']},
cmdclass={'build': Build, 'install_lib': InstallLib,
'compile_translations': CompileTranslations},
classifiers=(
'Development Status :: 4 - Beta',
'Intended Audience :: Developers',
Expand Down

0 comments on commit ebf6901

Please sign in to comment.