mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Bug fix for PurchaseOrder template (#3913)
* Bug fix for PurchaseOrder template - PurchaseOrder.is_pending method did not exist - Thus was evaluating to "false" in the template * UI fixes
This commit is contained in:
parent
57a20be5c3
commit
0bb2dd5c3e
@ -380,6 +380,11 @@ class PurchaseOrder(Order):
|
||||
|
||||
trigger_event('purchaseorder.completed', id=self.pk)
|
||||
|
||||
@property
|
||||
def is_pending(self):
|
||||
"""Return True if the PurchaseOrder is 'pending'"""
|
||||
return self.status == PurchaseOrderStatus.PENDING
|
||||
|
||||
@property
|
||||
def is_overdue(self):
|
||||
"""Returns True if this PurchaseOrder is "overdue".
|
||||
|
@ -58,8 +58,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
{% if order.status == PurchaseOrderStatus.PENDING %}
|
||||
<button type='button' class='btn btn-outline-secondary' id='place-order' title='{% trans "Place order" %}'>
|
||||
<span class='fas fa-paper-plane icon-blue'></span>
|
||||
<button type='button' class='btn btn-primary' id='place-order' title='{% trans "Submit Order" %}'>
|
||||
<span class='fas fa-paper-plane'></span> {% trans "Submit Order" %}
|
||||
</button>
|
||||
{% elif order.status == PurchaseOrderStatus.PLACED %}
|
||||
<button type='button' class='btn btn-primary' id='receive-order' title='{% trans "Receive items" %}'>
|
||||
|
Loading…
Reference in New Issue
Block a user