1 <%inherit file="/base.mako"/>
3 <form action="${h.url_for(controller='spend', action='update', id=c.expenditure.id)}" method="post">
4 ${h.auth_token_hidden_field()}
7 <th><label for="spender_id">Spender</label></th>
8 <td>${h.select('spender_id', c.expenditure.spender_id, c.users)}</td>
11 <th><label for="amount">Amount</label></th>
12 <td>${h.currency('amount', c.expenditure.amount, size=8)}</td>
15 <th><label for="date">Date</label></th>
16 <td>${h.text('date', c.expenditure.date.strftime('%m/%d/%Y'), size=16, class_='datepicker')}</td>
19 <th><label for="description">Description</label></th>
20 <td>${h.text('description', c.expenditure.description, size=64)}</td>
24 <p>Change how an expenditure is split up. Enter a percentage, or something like a percentage, for each user. They don't have to add to 100.</p>
27 % for ii, user_row in enumerate(c.users):
29 user_id, user = user_row
30 percent = c.values['shares-%d.amount' % ii]
33 <th><label for="shares-${ii}amount">${user.name}</label></th>
35 ${h.text('shares-%d.amount' % ii, percent)}
36 ${h.hidden('shares-%d.user_id' % ii, user.id)}
42 ${h.submit(None, 'Submit', class_="submitbutton")}