exclude the discount and gift totals if the value is 0, and default titles to codes if there are no titles