When a verdict is found for the plaintiff in an action for the recovery of money, or for the defendant when a setoff for the recovery of money is established beyond the amount of the plaintiff's claim as established, the jury shall also assess the amount of the recovery; they may also, under the direction of the court, assess the amount of the recovery when the court gives judgment for a party on the pleadings.