X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=bluechips%2Ftemplates%2Fmobile%2Fstatus%2Findex.mako;h=060d0b80d2c69fe5e005354f527f35e84e30894a;hb=378c8f2731ace02f1d2f1491e46eeca28f194462;hp=08069e1b67bf341297fbfcbe8deb3ee3f86dbdb1;hpb=28c9c65bb98e6981a516a64850744335bf36f81b;p=bluechips.git diff --git a/bluechips/templates/mobile/status/index.mako b/bluechips/templates/mobile/status/index.mako index 08069e1..060d0b8 100644 --- a/bluechips/templates/mobile/status/index.mako +++ b/bluechips/templates/mobile/status/index.mako @@ -1,29 +1,8 @@ <%inherit file="/mobile/base.mako"/> -<%! - from datetime import date -%> - -
- - - Dashboard - - - - Expense - - - - Transfer - -
+${self.tabs('status')}
- % for message in h.flash.pop_messages(): -
${message | n}
- % endfor - % if len(c.settle) == 0:

No need! The books are balanced!

% else: @@ -39,92 +18,11 @@ ${transfer[0].name} ${transfer[1].name} - ${transfer[2]} + ${transfer[2]} % endfor % endif
- -
-
- ${h.auth_token_hidden_field()} - - - - - - - - - - - - - - - - - -
${h.select('spender_id', [request.environ['user'].id], c.users)}
${h.currency('amount', 0, size=8)}
${h.text('date', date.today().strftime('%m/%d/%Y'), size=16)}
${h.text('description')}
- -

Change how an expenditure is split up.

- - - % for ii, user_row in enumerate(c.users): - <% - user_id, user = user_row - if user.resident: - percent = 1 - else: - percent = 0 - %> - - - - - % endfor - - - -
- ${h.text('shares-%d.amount' % ii, percent)} - ${h.hidden('shares-%d.user_id' % ii, user.id)} -
- ${h.submit(None, 'Submit', class_="submitbutton")} -
-
-
- -
-
- ${h.auth_token_hidden_field()} - - - - - - - - - - - - - - - - - - - - - - - - -
${h.select('debtor_id', request.environ['user'].id, c.users)}
${h.select('creditor_id', None, c.users)}
${h.currency('amount', 0, size=8)}
${h.text('date', date.today().strftime('%m/%d/%Y'), size=16)}
${h.text('description')}
- -
-
-
+${self.spendForm()} +${self.transferForm()}