There was a bug with the example product defined as:
+smk,matekrat 1.50@+statiegeld "..."
Only the id `+smk` was considered, and no total price was calculated. This
broke the accessible id `matekrat`. The fix is to consider the keys of
the products in the hash, instead of the `id` field.
- Adds price tag calculation. Addons tagged #OPAQUE are excluded from the
price tag.
- BREAKING CHANGE: instead of abusing $product->{price} for a percent,
$product->{percent} is no longer a boolean but the actual percent, so
$product->{price} is the calculated amount.
The total price of a product is now calculated in two places, once when
reading the product list, and once as the result of adding the entry and
its contras when adding the product. Although this involves some
duplication and the sums are calculated in different ways, it hinges on
the existing assertion to make sure that the entry is balanced to ensure
that both sums are the same. Because of that, this code duplication
actually strengthens the integrity.