3 Apr 02:53
Re: velocity
Maksim Lin <maksim.lin <at> gmail.com>
2006-04-03 00:53:47 GMT
2006-04-03 00:53:47 GMT
Hi Michi, I am using the Velocity extension at the moment, and have run into exactly the same issues and am currently working on fixing them but don't a fix yet, but I'l outline what I've found so far in case others on the list may be able to help. The reason $this.href() works but not $this.account.href() is because $this.account returns a Java object of class: helma.objectmodel.db.Node and NOT of helma.scripting.rhino.HopObject whereas $this DOES return a HopObject object. Now I havn't been able to figure out why? Its seems to happen whenever you get a object from a Helma collection eg. $root.account.get(5) and of course you can't call a helma function like href() on a Node object because its HopObjects that have it and other functions. Now I suspect that there is a way for me to get a hopObject based on a Node object, but so far I have only been able to find that HopObject have an associated Node but not the other way around - any ideas from people familiar with Helmas internals?? And of course once the above issue is solved, you could fix the floats display issue with just an extra method call like: $this.invoiceId.toFixed() Anyways I too am quite eager to test the new&improved JSTemplate from Jürg but I want to stick with Velocity for now because of my familiarity with it and good tool support.(Continue reading)
RSS Feed