In working with the module, I found myself wondering about the relation between digital products and inventory.
Some digital products may have a limited availability (e.g. tickets to a theatre). Some may be available in unlimited quantities (e.g. winrar licenses).
As things are, the way this could be handled is by setting the inventory of products in the second category to a very large number, and/or allowing back-order. Since merging in #93, that would leave a label in cart views telling that the product is out of stock, when it really is not.
So I made a few changes, for which I will do a PR momentarily, that allows clearer handling of digital products. Basically, I added a boolean to ProductPart called ConsiderInventory: when checked for a digital product it causes the product to be treated as belonging in the category of theatre tickets. If left unchecked, the digital product is assumed to be in the winrar license category. The flag does nothing for non-digital products.
In working with the module, I found myself wondering about the relation between digital products and inventory.
Some digital products may have a limited availability (e.g. tickets to a theatre). Some may be available in unlimited quantities (e.g. winrar licenses).
As things are, the way this could be handled is by setting the inventory of products in the second category to a very large number, and/or allowing back-order. Since merging in #93, that would leave a label in cart views telling that the product is out of stock, when it really is not.
So I made a few changes, for which I will do a PR momentarily, that allows clearer handling of digital products. Basically, I added a boolean to
ProductPart
calledConsiderInventory
: when checked for a digital product it causes the product to be treated as belonging in the category of theatre tickets. If left unchecked, the digital product is assumed to be in the winrar license category. The flag does nothing for non-digital products.