|GoodRelations is a standardized vocabulary for product, price, and company data that can be embedded into existing static and dynamic Web pages.|
Modeling Inventory Levels / Available Quantities
In GoodRelations, that there are two different GoodRelations properties that refer to quantities of items:
gr:amountOfThisGood is attached to gr:TypeAndQuantity nodes and indicates the quantity of the item included in the particular offer. In 80% of the cases, this should be 1.0 (i.e., "1.0"^^xsd.float), because the price etc. is meant for one item. A value other than 1.0 is appropriate when you sell a bundle of items or use units of measurement other than "item/piece", e.g. selling
- 100 tiles,
- 500 g of butter, or
- 1 camera plus 2 memory sticks.
gr:hasInventoryLevel, on the contrary, can be used to indicate inventory levels. Note that while gr:amountOfThisGood is an owl:DatatypeProperty, gr:hasInventoryLevel is an owl:ObjectProperty with a range of gr:QuantitativeValueFloat, because this allows for using arbitrary units and also specifying ranges.
It can only be attached to instances of gr:ProductOrServicesSomeInstancesPlaceholder.
So if you want to indicate inventory levels, use gr:hasInventoryLevel in combination with an instance of gr:QuantitativeValueFloat.
Example: Assume you have 80 pieces of a SCSI controller card on stock. Then, use the following pattern:
Product Name: Personal SCSI 16-bit SCSI Controller
Description: This low-cost, high-performance SCSI controller allows you to connect up to seven professional mass-storage devices to your computer.
EAN/UPC code: 00010363780
<img src="" alt="Product Image"/> 80 items on stock. <span property="gr:hasUnitOfMeasurement" datatype="xsd:string" content="C62"/>
foo:myProduct a gr:ProductOrServicesSomeInstancesPlaceholder; rdfs:label "Personal SCSI 16-bit SCSI Controller"@en ; gr:hasEAN_UCC-13 "00010363780"^^xsd:string ; gr:hasManufacturer <http://www.heppnetz.de/searchmonkey/product.html#heppcomputer> ; rdfs:comment "This low-cost, high-performance SCSI controller allows you to connect up to seven professional mass-storage devices to your computer."@en ; foaf:page <http://www.heppnetz.de/searchmonkey/product.html> ; rdfs:seeAlso <http://www.heppnetz.de/searchmonkey/pscsi.jpg> ; foaf:depiction <http://www.heppnetz.de/searchmonkey/pscsi.jpg> ; gr:hasInventoryLevel [ a gr:QuantitativeValueFloat; gr:hasValueFloat "80"^^xsd:float ; gr:hasUnitOfMeasurement "C62"^^xsd:string ] ; .