diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2019-01-24 14:42:14 +0100 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2019-01-24 14:42:14 +0100 |
commit | 92b45b2f110a98589289cfc3e317670e6ff0a49d (patch) | |
tree | 5cf48370406d7cec50216b9f31367623733e1900 | |
parent | addbc2f7e908a91e76136b39e3e283a09213c448 (diff) | |
download | bank-92b45b2f110a98589289cfc3e317670e6ff0a49d.tar.gz bank-92b45b2f110a98589289cfc3e317670e6ff0a49d.tar.bz2 bank-92b45b2f110a98589289cfc3e317670e6ff0a49d.zip |
Give very big initial amount to Survey account.
-rw-r--r-- | talerbank/app/management/commands/provide_accounts.py | 28 |
1 files changed, 20 insertions, 8 deletions
diff --git a/talerbank/app/management/commands/provide_accounts.py b/talerbank/app/management/commands/provide_accounts.py index 6bf8c53..4a6c545 100644 --- a/talerbank/app/management/commands/provide_accounts.py +++ b/talerbank/app/management/commands/provide_accounts.py @@ -1,16 +1,18 @@ # This file is part of TALER # (C) 2014, 2015, 2106 INRIA # -# TALER is free software; you can redistribute it and/or modify it under the -# terms of the GNU General Public License as published by the Free Software -# Foundation; either version 3, or (at your option) any later version. +# TALER is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 3, or (at your option) any later version. # -# TALER is distributed in the hope that it will be useful, but WITHOUT ANY -# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR -# A PARTICULAR PURPOSE. See the GNU General Public License for more details. +# TALER is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. # -# You should have received a copy of the GNU General Public License along with -# TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/> +# You should have received a copy of the GNU General Public +# License along with TALER; see the file COPYING. If not, +# see <http://www.gnu.org/licenses/> # # @author Marcello Stanisci # @author Florian Dold @@ -22,6 +24,8 @@ from django.db.utils import ProgrammingError, OperationalError from django.core.management.base import BaseCommand from django.conf import settings from ...models import BankAccount +from ...views import wire_transfer +from ...amount import Amount LOGGER = logging.getLogger(__name__) LOGGER.setLevel(logging.INFO) @@ -45,6 +49,14 @@ def make_account(username): exc_info=True) sys.exit(1) + if "Survey" == username: + bank = BankAccount.objects.get(account_no=1) + survey = BankAccount.objects.get(account_no=8) + wire_transfer(Amount(settings.TALER_CURRENCY, 10000000), + bank, + survey, + "Benevolent donation for 'Survey'") + class Command(BaseCommand): help = "Provide initial user accounts" |