Jeremy Savoy wrote:
I have a model for budget item entries. Each entry contains the total
cost, the amount paid, and the amount due on the item - all are typed
float
I would like for the amount_due to be calculated for the user whenever
there is a change in total cost or amount paid. This change could be
when the item is initially being created or edited at some future
point.
Is this something that I'll just have to implement in javascript/ajax,
or is there already functionality like this built into rapid?
It's certainly easy enough to do server side: You can add a method
called "total" to the container model and then add it to the list of
columns in the view. And then you could use Hobo's Ajax mechanism to
update that view whenever something changes. If you want to try this, I
can give more details
But that seems excessive -- it seems to me that this would best be done
in pure client-side Javascript. It's probably easier and definitely a
lot faster. This only works if the entire budget fits on a single web
page. (You can hide sections of the page if it's too big visually, but
still small enough that it doesn't kill the browser).
Bryan
--
You received this message because you are subscribed to the Google Groups "Hobo
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/hobousers?hl=en.