Fix quantity not taking into account quantity invoiced.