Summarize course revenue
So I have a
Course
model and an Enrollment
model.
each Course
has a fee.
the Course
model has a function that calculates the revenue like so:
and I am displaying that data in my table:
I want to display the sum of all course revenues at the bottom of my table but adding this didn't help:
instead I get this error3 Replies
Haya, have you found a way to solve this yet? Im facing the same issue.
Thanks in advance
This will only work with data directly from your table, not with custom model attributes, I believe
Ok, thanks, ill find another way to deal with this. Thansk anyhow. π