1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
5 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
6 <title>${self.title()}</title>
7 ${h.stylesheet_link('/css/main.css')}
8 ${h.stylesheet_link('/js/jquery.date_input.css')}
11 <div id="nav" class="block">
24 <a href="${h.url_for(controller='status', action='index', id=None)}">
25 <img src="/icons/dashboard.png" alt="">
26 <span>Dashboard</span>
30 <a href="${h.url_for(controller='spend', action='index', id=None)}">
31 <img src="/icons/spend.png" alt="">
36 <a href="${h.url_for(controller='transfer', action='index', id=None)}">
37 <img src="/icons/transfer.png" alt="">
42 <a href="${h.url_for(controller='history', action='index', id=None)}">
43 <img src="/icons/history.png" alt="">
48 <a href="${h.url_for(controller='user', action='index', id=None)}">
49 <img src="/icons/user.png" alt="">
56 % for message in h.flash.pop_messages():
57 <div class="flash">${message | n}</div>
62 ${h.javascript_link('/js/jquery-1.3.2.js')}
63 ${h.javascript_link('/js/jquery.date_input.js')}
64 ${h.javascript_link('/js/admin.js')}
68 <%def name="title()">BlueChips
74 <%def name="formatUser(user)">
75 % if user == request.environ['user']:
82 <%def name="listExpenditures(es)">
85 <th class="date">Date</th>
86 <th class="user">Spender</th>
87 <th class="description">Description</th>
88 <th class="amount">Amount</th>
89 <th class="share">My Share</th>
90 <th class="editlink"></th>
94 if e.involves(request.environ['user']):
95 klass = 'user-involved'
97 klass = 'user-not-involved'
100 <td class="date">${e.date}</td>
101 <td class="user">${formatUser(e.spender)}</td>
102 <td class="description">${e.description}</td>
103 <td class="amount">${e.amount}</td>
104 <td class="share">${e.share(request.environ['user'])}</td>
105 <td class="editlink">${h.link_to('Edit', h.url_for(controller='spend', action='edit', id=e.id))}</td>
111 <%def name="listTransfers(ts)">
114 <th class="date">Date</th>
115 <th class="user">From</th>
116 <th class="user">To</th>
117 <th class="description">Description</th>
118 <th class="amount">Amount</th>
119 <th class="editlink"></th>
123 if t.involves(request.environ['user']):
124 klass = 'user-involved'
126 klass = 'user-not-involved'
128 <tr class="${klass}">
129 <td class="date">${t.date}</td>
130 <td class="user">${formatUser(t.debtor)}</td>
131 <td class="user">${formatUser(t.creditor)}</td>
132 <td class="description">${t.description}</td>
133 <td class="amount">${t.amount}</td>
134 <td class="editlink">${h.link_to('Edit', h.url_for(controller='transfer', action='edit', id=t.id))}</td>
140 <%def name="expenditureIcon()">
141 ←<span class="dollarsign">→
144 <%def name="transferIcon()">
145 <span class="dollarsign">$</span>→<span class="dollarsign">$</span>