Your trade discount line applies an exact discount amount of 178.8852 to a line item of no value (no unit price). A discount from zero is interpreted as zero on the completed transaction, even though an amount was computed on the entry screen. If you are going to enter a line item that is a discount, you must put a negative amount into the Unit price field, not the Discount field.*