Form calculation widget not performing correctly