On 12/6/2011 5:08 PM, Paul McNett wrote:
> There are potentially two things going on here. First, you mentioned a grid. 
> Grids
> get the values to display by calling biz.getFieldVal(fld, row), IOW they send 
> the row
> number to getFieldVal. By default, getFieldVal() won't update the children in 
> this
> case, so the grid will show the wrong calculated value if the calculation 
> relies on
> the children. To override this, you change your VirtualField definition from 
> this:
>
> class MyBiz(...):
>     def initProperties(...):
>       self.VirtualFields["myfield"] = self.getMyField
>
> to:
>
>       self.VirtualFields["myfield"] = {"func": self.getMyField, 
> "requery_children": True}
>
> The second thing could be an unintended consequence of recent changes, so if 
> you try
> the above and see no improvement, please let us know.

The change in the virtual field did it.  I was using the grid as you 
said and the orders object would also automatically update the total, 
but would grab the orderline subtotals using getDataSet(), which I 
assume has the same update issue as getFieldVal().  It would also make 
sense that when I opened my edit forms the bizobj would requery as normal.

Thanks for the help.

Regards,

Nate
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[email protected]

Reply via email to