small fix
This commit is contained in:
parent
c3fe1817c3
commit
d38958c089
@ -505,7 +505,7 @@ def general_dashboard(request,dealer_slug):
|
||||
total_revenue_generated = total_revenue_from_cars + total_revenue_from_services
|
||||
# total_expenses=sum([x.amount_paid for x in dealer.entity.get_bills().filter(bill_items__item_role="expense")])
|
||||
total_expenses=dealer.entity.get_bills().filter(bill_items__item_role="expense").aggregate(total=Sum('amount_paid'))['total'] or 0
|
||||
gross_profit = net_profit_from_cars - total_expenses
|
||||
gross_profit = net_profit_from_cars+total_revenue_from_services - total_expenses
|
||||
|
||||
# ----------------------------------------------------
|
||||
# 4. Chart Data Aggregation
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 425 KiB |
Loading…
x
Reference in New Issue
Block a user