Skip to content

Commit

Permalink
added transaction submitted details to the pop-up window. also change…
Browse files Browse the repository at this point in the history
…d size of window
  • Loading branch information
katriiina committed Mar 27, 2011
1 parent 17aa04b commit d43575c
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 9 deletions.
2 changes: 1 addition & 1 deletion budget/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class Budget(models.Model):
# edited_by = models.ForeignKey(User, related_name="budget_edited")

def __unicode__(self):
return u'%s %s-%s' %(self.name, self.term, self.year)
return u'%s %s-%s' %(self.position.name, self.term, self.year)

class BudgetItem(models.Model):

Expand Down
24 changes: 18 additions & 6 deletions templates/transactions/view_transaction.htm
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,26 @@
{% block body %}
<h1>Details of Transaction</h1>

<table class="summary" cellpadding="3" cellspacing="2" width=350>
<p>
<tr><td><b>Name of Submitter:</b></td><td>{{t.name}}</td></tr>
<tr><td><b>Email Address:</b></td><td>{{t.email}}</td></tr>
<tr><td><b>Cheque Needs to be Mailed?</b></td><td>{{t.mail}}</td></tr>
<tr><td><b>Is Cheque Ready for Pickup?</b></td><td>{{t.cheque_ready}}</td></tr>
<tr><td><b>Has Cheque Been Picked Up?</b></td><td>{{t.cheque_received}}</td></tr>

</p>
</table>
<br><br>

<table class="summary" cellpadding="5" cellspacing="3" width=350>
<p>
<tr><td>Type</td><td>{{t.get_type_display}}</td></tr>
<tr><td>Date</td><td>{{t.date}}</td></tr>
<tr><td>Amount</td><td>{{t.amount|currency}}</td></tr>
<tr><td>Category</td><td>{% ifequal t.type "IN" %}{{t.income_category}}{% else %}{{t.expenditure_category}} {% endifequal %}</td></tr>
<tr><td>Description</td><td>{{t.description}}</td></tr>
<tr><td>Budget</td><td>{{t.budget}}</td></tr>
<tr><td><b>Type</b></td><td>{{t.get_type_display}}</td></tr>
<tr><td><b>Date</b></td><td>{{t.date}}</td></tr>
<tr><td><b>Amount</b></td><td>{{t.amount|currency}}</td></tr>
<tr><td><b>Category</b></td><td>{% ifequal t.type "IN" %}{{t.income_category}}{% else %}{{t.expenditure_category}} {% endifequal %}</td></tr>
<tr><td><b>Description</b></td><td>{{t.description}}</td></tr>
<tr><td><b>Position Name</b></td><td>{{t.position}}</td></tr>

</p>
</table>
Expand Down
4 changes: 2 additions & 2 deletions templates/transactions/view_transactions.htm
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ <h1>View All Transactions</h1>
<td>{{e.description}}</td>
<td>{{e.position}}</td>
<td>{% if user|in_group:"vp_finance,admin" %}<a href="{% url transaction_edit_expenditure id=e.id %}">Edit</a>{% endif %}</td>
<td><a href="{% url transaction_view_transaction id=e.id %}" target="_blank" onclick="window.open(this.href,this.target, 'scrollbar=1, height=300, width=400');return false;">Details</a></td>
<td><a href="{% url transaction_view_transaction id=e.id %}" target="_blank" onclick="window.open(this.href,this.target, 'scrollbar=1, height=500, width=400');return false;">Details</a></td>
<td>{{e.approved}}</td>
</tr>
{% endfor %}
Expand All @@ -75,7 +75,7 @@ <h1>View All Transactions</h1>
<td>{{i.description}}</td>
<td>{{i.position}}</td>
<td>{% if i.approved %}{% if user|in_group:"vp_finance,admin" %}<a href="{% url transaction_edit_income id=i.id %}">Edit</a>{% endif %}{% else %}<a href="{% url transaction_edit_income id=i.id %}">Edit</a> {% endif %}</td>
<td><a href="{% url transaction_view_transaction id=i.id %}" target="_blank" onclick="window.open(this.href,this.target, 'scrollbar=1, height=300, width=400');return false;">Details</a></td>
<td><a href="{% url transaction_view_transaction id=i.id %}" target="_blank" onclick="window.open(this.href,this.target, 'scrollbar=1, height=500, width=400');return false;">Details</a></td>
<td>{{i.approved}}</td>
</tr>
{% endfor %}
Expand Down

0 comments on commit d43575c

Please sign in to comment.