diff --git a/README.md b/README.md index b2c2ea4..9c15952 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,10 @@ development environment set up, do the following: 1. Setup virtualenv with Python3: cd chez-betty - virtualenv . + # virtualenv . + # Python3.3 or later: + python3 -m venv . + # ^ *not* pyvenv ., that installed python2 in my venv for w/e reason source bin/activate 2. Install the Python3 dependencies: diff --git a/chezbetty/locale/cn/LC_MESSAGES/betty.po b/chezbetty/locale/cn/LC_MESSAGES/betty.po new file mode 100644 index 0000000..bbac767 --- /dev/null +++ b/chezbetty/locale/cn/LC_MESSAGES/betty.po @@ -0,0 +1,602 @@ +# +# Language cn translations for PACKAGE package +# This file is distributed under the same license as the PACKAGE package. +# Pat Pannuto , 2015. +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE 1.0\n" +"POT-Creation-Date: 2015-03-02 14:02-0500\n" +"PO-Revision-Date: 2015-03-11 20:10-0400\n" +"Last-Translator: Ye-Sheng Kuo \n" +"Language-Team: Language cn\n" +"Language: cn\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Generated-By: Lingua 3.9\n" + +#. Default: User is not enabled. Please contact ${email}. +#: chezbetty/views.py:117 +msgid "user-not-enabled" +msgstr "" + +#. Default: Failed to read M-Card. Please try swiping again. +#: chezbetty/views.py:154 +msgid "mcard-error" +msgstr "" + +#: chezbetty/templates/deposit_edit.jinja2:2 +#: chezbetty/templates/deposit_edit.jinja2:3 +msgid "Edit Deposit" +msgstr "" + +#: chezbetty/templates/deposit_edit.jinja2:16 +msgid "New Deposit Amount" +msgstr "" + +#: chezbetty/templates/deposit_edit.jinja2:28 +#: chezbetty/templates/deposit.jinja2:28 +msgid "Deposit To Your Account" +msgstr "" + +#: chezbetty/templates/deposit_edit.jinja2:30 +#: chezbetty/templates/deposit.jinja2:30 +msgid "Deposit To %(pool_name)s Pool" +msgstr "" + +#: chezbetty/templates/deposit_edit.jinja2:35 +msgid "Delete Deposit" +msgstr "" + +#: chezbetty/templates/item_request.jinja2:2 +msgid "Item Request" +msgstr "" + +#: chezbetty/templates/item_request.jinja2:3 +msgid "Request a New Item at Chez Betty" +msgstr "" + +#: chezbetty/templates/item_request.jinja2:10 +#: chezbetty/templates/about.jinja2:13 chezbetty/templates/about.jinja2:105 +#: chezbetty/templates/shame.jinja2:10 chezbetty/templates/items.jinja2:19 +msgid "Home" +msgstr "" + +#: chezbetty/templates/item_request.jinja2:15 +msgid "New Item Request" +msgstr "" + +#: chezbetty/templates/item_request.jinja2:21 +msgid "Submit Request" +msgstr "" + +#: chezbetty/templates/deposit.jinja2:2 chezbetty/templates/deposit.jinja2:3 +#: chezbetty/templates/deposit.jinja2:13 +#: chezbetty/templates/user_info.jinja2:40 +#: chezbetty/templates/deposit_complete.jinja2:12 +msgid "Deposit" +msgstr "" + +#: chezbetty/templates/deposit.jinja2:21 +msgid "Cash" +msgstr "" + +#: chezbetty/templates/deposit.jinja2:22 +msgid "Your Deposit Limit: %(limit)s" +msgstr "" + +#: chezbetty/templates/deposit.jinja2:45 +msgid "Bitcoin" +msgstr "" + +#: chezbetty/templates/deposit.jinja2:56 +msgid "Credit Card" +msgstr "" + +#: chezbetty/templates/deposit.jinja2:57 +msgid "Coming soon." +msgstr "" + +#: chezbetty/templates/purchase.jinja2:2 chezbetty/templates/purchase.jinja2:3 +#: chezbetty/templates/user_info.jinja2:34 +msgid "Purchase" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:17 +#: chezbetty/templates/purchase_complete.jinja2:13 +msgid "Order Summary" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:34 chezbetty/templates/user.jinja2:45 +#: chezbetty/templates/items.jinja2:36 chezbetty/templates/items.jinja2:61 +#: chezbetty/templates/items.jinja2:84 +#: chezbetty/templates/purchase_complete.jinja2:20 +msgid "Item" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:35 chezbetty/templates/user.jinja2:46 +#: chezbetty/templates/purchase_complete.jinja2:21 +msgid "Quantity" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:36 chezbetty/templates/user.jinja2:47 +#: chezbetty/templates/purchase_complete.jinja2:22 +msgid "Item Price" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:37 chezbetty/templates/user.jinja2:48 +#: chezbetty/templates/purchase_complete.jinja2:23 +msgid "Total Price" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:47 +msgid "Order Empty" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:48 +msgid "Scan an item to begin" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:57 chezbetty/templates/user.jinja2:67 +#: chezbetty/templates/purchase_complete.jinja2:42 +msgid "Subtotal" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:61 +msgid "Good Standing Discount" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:67 chezbetty/templates/user.jinja2:76 +#: chezbetty/templates/purchase_complete.jinja2:53 +msgid "Total" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:78 +msgid "Pay With Your User Account" +msgstr "" + +#: chezbetty/templates/purchase.jinja2:80 +msgid "Pay With %(pool_name)s Pool" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:6 +msgid "Customer" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:11 chezbetty/templates/shame.jinja2:23 +msgid "Name" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:14 chezbetty/templates/shame.jinja2:25 +msgid "Account Balance" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:30 +msgid "Links" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:37 +msgid "Account" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:42 +msgid "Logout" +msgstr "" + +#: chezbetty/templates/user_info.jinja2:44 +msgid "Admin" +msgstr "" + +#: chezbetty/templates/base.jinja2:58 chezbetty/templates/base.jinja2:69 +msgid "Hi %(name)s," +msgstr "" + +#: chezbetty/templates/base.jinja2:59 +msgid "You currently owe Betty %(big_debt)s. That's a lot of money!" +msgstr "" + +#: chezbetty/templates/base.jinja2:61 +msgid "" +"We're glad you like Betty. We're happy to extend a small line of credit, but " +"if people owe Betty lots of money, it's hard to keep things in stock. Please " +"try to pay Betty back soon!" +msgstr "" + +#: chezbetty/templates/base.jinja2:70 +msgid "You currently owe Betty %(debt)s." +msgstr "" + +#: chezbetty/templates/base.jinja2:71 +msgid "Please try to pay Betty back soon, thanks!" +msgstr "" + +#: chezbetty/templates/user.jinja2:14 +msgid "Transaction History" +msgstr "" + +#: chezbetty/templates/user.jinja2:32 +msgid "Purchase totaling %(amount)s" +msgstr "" + +#: chezbetty/templates/user.jinja2:33 chezbetty/templates/user.jinja2:93 +#: chezbetty/templates/user.jinja2:102 +msgid "touch to show" +msgstr "" + +#: chezbetty/templates/user.jinja2:34 +msgid "touch to hide" +msgstr "" + +#: chezbetty/templates/user.jinja2:71 +#: chezbetty/templates/purchase_complete.jinja2:46 +msgid "Discounts" +msgstr "" + +#: chezbetty/templates/user.jinja2:86 +msgid "Deposit of %(amount)s" +msgstr "" + +#: chezbetty/templates/user.jinja2:93 +msgid "Adjustment of %(amount)s by %(admin_name)s " +msgstr "" + +#: chezbetty/templates/user.jinja2:102 +msgid "BTC Deposit of %(amount_in_usd)s (%(amount_in_btc)s) " +msgstr "" + +#: chezbetty/templates/user.jinja2:118 +msgid "No transactions." +msgstr "" + +#: chezbetty/templates/user.jinja2:122 +msgid "Show All" +msgstr "" + +#: chezbetty/templates/about.jinja2:2 chezbetty/templates/about.jinja2:3 +msgid "About Chez Betty" +msgstr "" + +#: chezbetty/templates/about.jinja2:8 +msgid "" +"Chez Betty is an honor-system based food cooperative for graduate students, " +"faculty, and staff in Computer Science at the University of Michigan. The " +"name \"Chez Betty\" is an homage to Chez Bob, a similar system at UCSD." +msgstr "" + +#: chezbetty/templates/about.jinja2:16 +msgid "FAQ" +msgstr "" + +#: chezbetty/templates/about.jinja2:18 +msgid "Touch questions to show/hide." +msgstr "" + +#: chezbetty/templates/about.jinja2:22 +msgid "Who are the awesome people who run Chez Betty?" +msgstr "" + +#: chezbetty/templates/about.jinja2:24 +msgid "Chez Betty is run by CSEG, the CSE graduate student group." +msgstr "" + +#: chezbetty/templates/about.jinja2:25 +msgid "" +"Currently, Betty is primarily maintained by Brad Campbell, Pat Pannuto, and " +"Zakir DurumeriƧ" +msgstr "" + +#: chezbetty/templates/about.jinja2:28 +msgid "How to Use Betty like a Pro" +msgstr "" + +#: chezbetty/templates/about.jinja2:30 +msgid "Keep a positive balance." +msgstr "" + +#: chezbetty/templates/about.jinja2:31 +msgid "" +"Tracking down debtors sucks for us and for you. You don't want to end up on " +"the Wall of Shame!" +msgstr "" + +#: chezbetty/templates/about.jinja2:33 +msgid "Take advantage of the Bank of Betty." +msgstr "" + +#: chezbetty/templates/about.jinja2:34 +msgid "" +"Our power users usually deposit $100 once a year or so. Most people deposit " +"$20 to use until that runs out. Remembering cash every time you want to use " +"Betty is no fun." +msgstr "" + +#: chezbetty/templates/about.jinja2:36 +msgid "Help restock." +msgstr "" + +#: chezbetty/templates/about.jinja2:37 +msgid "" +"Betty is run by volunteers who have finite time. If you grab a cold drink, " +"put a warm one in to get cold (though, don't put it in front!). If you " +"finish a box of food, grab a full box and replace it." +msgstr "" + +#: chezbetty/templates/about.jinja2:42 +msgid "How do I buy things from Chez Betty?" +msgstr "" + +#: chezbetty/templates/about.jinja2:45 +msgid "Log in to Chez Betty by swiping your MCard at the terminal." +msgstr "" + +#: chezbetty/templates/about.jinja2:47 +msgid "Accounts are tied to your UMID." +msgstr "" + +#: chezbetty/templates/about.jinja2:48 +msgid "" +"A new account is automatically created for first-time users on the the fly " +"the first time you log in." +msgstr "" + +#: chezbetty/templates/about.jinja2:50 +msgid "Look at your Account Balance. If you're low, deposit some money." +msgstr "" + +#: chezbetty/templates/about.jinja2:52 +msgid "" +"Every user has an account with Chez Betty that keeps track of how much money " +"they've put in." +msgstr "" + +#: chezbetty/templates/about.jinja2:53 +msgid "" +"Betty doesn't make change, instead excess money stays in your account for " +"your next transaction." +msgstr "" + +#: chezbetty/templates/about.jinja2:54 +msgid "You can run into the red, see below." +msgstr "" + +#: chezbetty/templates/about.jinja2:56 +msgid "Grab what you'd like from Chez Betty and scan your items." +msgstr "" + +#: chezbetty/templates/about.jinja2:57 +msgid "Touch \"Submit Purchase\" and you're done!" +msgstr "" + +#: chezbetty/templates/about.jinja2:61 +msgid "Wait... Couldn't people steal from this really easily?" +msgstr "" + +#: chezbetty/templates/about.jinja2:63 +msgid "Yes. (But please don't)." +msgstr "" + +#: chezbetty/templates/about.jinja2:64 +msgid "" +"The idea is to provide a convenient service to members of the UM CSE " +"community. Betty makes a small profit off each sale, some of which will be " +"used to cover the inevitable losses. If too many people take advantage of " +"Betty's trusting nature, the service will have to shut down :(." +msgstr "" + +#: chezbetty/templates/about.jinja2:67 +msgid "Tell me more about my Chez Betty account?" +msgstr "" + +#: chezbetty/templates/about.jinja2:69 +msgid "" +"Chez Betty sells things nearly at-cost (usually about a 15% markup). Since " +"no one likes change and Betty is a self-service operation, it's set up so " +"that each user has an account with Betty. You can put in $20 (or however " +"much) at a time and use that balance until it runs out." +msgstr "" + +#: chezbetty/templates/about.jinja2:75 +msgid "What if I don't have any money / Can my account balance go negative?" +msgstr "" + +#: chezbetty/templates/about.jinja2:77 +msgid "" +"Yes. Chez Betty allows you to spend beyond your immediate means under that " +"assumption that you'll pay Betty back eventually. The idea is to let you " +"grab stuff when you need it and keep track of what owe, instead of " +"incentivizing folks to steal. There is a Wall of Shame for persons who owe Betty more than $5." +msgstr "" + +#: chezbetty/templates/about.jinja2:85 +msgid "How does Betty set prices?" +msgstr "" + +#: chezbetty/templates/about.jinja2:87 +msgid "" +"Betty sells things just above wholesale, usually a 15% markup. If you're " +"interested in the actual algorithm, check out Betty's source code at github." +"com/um-cseg/chez-betty." +msgstr "" + +#: chezbetty/templates/about.jinja2:90 +msgid "" +"Current wholesale and Betty prices are always available on the items page." +msgstr "" + +#: chezbetty/templates/about.jinja2:93 +msgid "What does Betty do with her profits?" +msgstr "" + +#: chezbetty/templates/about.jinja2:95 +msgid "" +"First, Betty has to pay her debts (e.g. any losses incurred from dishonest " +"Chez Betty users). After that, Betty's profits roll into the CSEG general " +"fund. They're used to fund improvements to Betty, buy miscellaneous needs (e." +"g. new ping pong paddles and balls), or to throw events (e.g. bar nights) " +"for CSEG." +msgstr "" + +#: chezbetty/templates/about.jinja2:100 +msgid "" +"If you have more questions / concerns, please feel free to talk to the CSEG " +"officers." +msgstr "" + +#: chezbetty/templates/shame.jinja2:2 chezbetty/templates/shame.jinja2:3 +#: chezbetty/templates/index.jinja2:27 +msgid "Wall of Shame" +msgstr "" + +#: chezbetty/templates/shame.jinja2:13 +msgid "These users owe Chez Betty more than $5." +msgstr "" + +#: chezbetty/templates/shame.jinja2:17 +msgid "Users in Debt" +msgstr "" + +#: chezbetty/templates/shame.jinja2:24 +msgid "uniqname" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:20 +msgid "Old Balance" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:23 +msgid "Deposit Amount" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:26 +msgid "New Balance" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:29 +msgid "Transaction" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:35 +msgid "Thank you!" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:38 +msgid "You successfully deposited %(amount)s into your account" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:41 +msgid "You successfully deposited %(amount)s in the %(pool_name)s Pool" +msgstr "" + +#: chezbetty/templates/deposit_complete.jinja2:50 +msgid "Edit this Deposit" +msgstr "" + +#: chezbetty/templates/items.jinja2:2 chezbetty/templates/items.jinja2:13 +msgid "Items" +msgstr "" + +#: chezbetty/templates/items.jinja2:3 +msgid "Items at Chez Betty" +msgstr "" + +#: chezbetty/templates/items.jinja2:7 +msgid "All that Betty has to offer." +msgstr "" + +#: chezbetty/templates/items.jinja2:20 chezbetty/templates/index.jinja2:25 +msgid "Request an Item" +msgstr "" + +#: chezbetty/templates/items.jinja2:22 +msgid "Touch columns to change sort order." +msgstr "" + +#: chezbetty/templates/items.jinja2:25 +msgid "Top" +msgstr "" + +#: chezbetty/templates/items.jinja2:26 +msgid "Up" +msgstr "" + +#: chezbetty/templates/items.jinja2:27 +msgid "Down" +msgstr "" + +#: chezbetty/templates/items.jinja2:28 +msgid "Bottom" +msgstr "" + +#: chezbetty/templates/items.jinja2:37 +msgid "In Stock" +msgstr "" + +#: chezbetty/templates/items.jinja2:38 +msgid "Wholesale" +msgstr "" + +#: chezbetty/templates/items.jinja2:39 +msgid "Price" +msgstr "" + +#: chezbetty/templates/items.jinja2:56 +msgid "Temporarily Out-of-Stock Items:" +msgstr "" + +#: chezbetty/templates/items.jinja2:75 +msgid "Discontinued Items:" +msgstr "" + +#: chezbetty/templates/items.jinja2:77 +msgid "" +"Betty discontinues items that did not sell well or that wecannot buy any " +"more. If you would like to request the return ofa discontinued item, please " +"e-mail chez-betty@umich.edu." +msgstr "" + +#: chezbetty/templates/purchase_complete.jinja2:2 +#: chezbetty/templates/purchase_complete.jinja2:3 +msgid "Purchase Complete" +msgstr "" + +#: chezbetty/templates/purchase_complete.jinja2:55 +msgid "(Paid with your user account)" +msgstr "" + +#: chezbetty/templates/purchase_complete.jinja2:57 +msgid "(Paid with %(pool_name)s Pool)" +msgstr "" + +#: chezbetty/templates/purchase_complete.jinja2:68 +msgid "If this was a mistake, touch here to undo this transaction." +msgstr "" + +#: chezbetty/templates/index.jinja2:12 +msgid "Welcome to Chez Betty!" +msgstr "" + +#: chezbetty/templates/index.jinja2:13 +msgid "The 24/7 food co-op for all members of the CSE community." +msgstr "" + +#: chezbetty/templates/index.jinja2:18 +msgid "Swipe your M-Card to login" +msgstr "" + +#: chezbetty/templates/index.jinja2:24 +msgid "Item List" +msgstr "" + +#: chezbetty/templates/index.jinja2:26 +msgid "About" +msgstr "" + +#: chezbetty/templates/index.jinja2:30 +msgid "Administration" +msgstr "" + +#: chezbetty/templates/index.jinja2:54 +msgid "Can you help translate Betty? E-mail chez-betty@umich.edu." +msgstr "" diff --git a/chezbetty/templates/base.jinja2 b/chezbetty/templates/base.jinja2 index 9e41f1e..33db480 100644 --- a/chezbetty/templates/base.jinja2 +++ b/chezbetty/templates/base.jinja2 @@ -51,6 +51,7 @@ {% set active_page = active_page|default('index') -%} {#{% include 'navbar.html' %}#} + {% if active_page not in ('deposit', 'deposit_edit') %} {% if user %} {% if user.balance < -50 %} {% endif %} {% endif %} + {% endif %}
{% block alerts %} diff --git a/chezbetty/templates/deposit.jinja2 b/chezbetty/templates/deposit.jinja2 index 3da6dd0..e8da726 100644 --- a/chezbetty/templates/deposit.jinja2 +++ b/chezbetty/templates/deposit.jinja2 @@ -1,11 +1,11 @@ {% extends "base.jinja2" %} +{% set active_page = 'deposit' %} {% block title %}{{ _('Deposit') }}{% endblock %} {% block header %}{{ _('Deposit') }}{% endblock %} {% block content %} -{% set page = 'deposit' %} {% include "user_info.jinja2" %}
diff --git a/chezbetty/templates/deposit_complete.jinja2 b/chezbetty/templates/deposit_complete.jinja2 index 3d52303..10cce69 100644 --- a/chezbetty/templates/deposit_complete.jinja2 +++ b/chezbetty/templates/deposit_complete.jinja2 @@ -1,10 +1,10 @@ {% extends "base.jinja2" %} +{% set active_page = 'deposit_complete' %} {% block title %}Deposit Complete{% endblock %} {% block header %}Deposit Complete{% endblock %} {% block content %} -{% set page = 'deposit' %} {% include "user_info.jinja2" %}
diff --git a/chezbetty/templates/deposit_edit.jinja2 b/chezbetty/templates/deposit_edit.jinja2 index ef9c82d..a55fde3 100644 --- a/chezbetty/templates/deposit_edit.jinja2 +++ b/chezbetty/templates/deposit_edit.jinja2 @@ -1,11 +1,11 @@ {% extends "base.jinja2" %} +{% set active_page = 'deposit_edit' %} {% block title %}{{ _('Edit Deposit') }}{% endblock %} {% block header %}{{ _('Edit Deposit') }}{% endblock %} {% block content %} -{% set page = 'deposit' %} {% include "user_info.jinja2" %} {% set keypad_val = old_deposit.amount %} diff --git a/chezbetty/templates/purchase.jinja2 b/chezbetty/templates/purchase.jinja2 index bea1ba4..1b96ddc 100644 --- a/chezbetty/templates/purchase.jinja2 +++ b/chezbetty/templates/purchase.jinja2 @@ -1,11 +1,11 @@ {% extends "base.jinja2" %} +{% set active_page = 'purchase' %} {% block title %}{{ _('Purchase') }}{% endblock %} {% block header %}{{ _('Purchase') }}{% endblock %} {% block content %} -{% set page = 'purchase' %} {% include "user_info.jinja2" %}
diff --git a/chezbetty/templates/purchase_complete.jinja2 b/chezbetty/templates/purchase_complete.jinja2 index 2ad0674..1346f7b 100644 --- a/chezbetty/templates/purchase_complete.jinja2 +++ b/chezbetty/templates/purchase_complete.jinja2 @@ -1,10 +1,10 @@ {% extends "base.jinja2" %} +{% set active_page = 'purchase_complete' %} {% block title %}{{ _('Purchase Complete') }}{% endblock %} {% block header %}{{ _('Purchase Complete') }}{% endblock %} {% block content %} -{% set page = 'purchase' %} {% include "user_info.jinja2" %} diff --git a/chezbetty/templates/user.jinja2 b/chezbetty/templates/user.jinja2 index 054b96c..6da85ad 100644 --- a/chezbetty/templates/user.jinja2 +++ b/chezbetty/templates/user.jinja2 @@ -1,10 +1,10 @@ {% extends "base.jinja2" %} +{% set active_page = 'account' %} {% block title %}User Information{% endblock %} {% block header %}{{ name }}{% endblock %} {% block content %} -{% set page = 'account' %} {% include "user_info.jinja2" %} {# Display the transaction history list