title: Shopify Line Item Properties Identifier
body: <p>We are working on our Rails app so that it takes into account products that use the new "line item properties" on Shopify.</p>
  
  <p>Part of our app looks at a customers orders as a whole and then calculate how many of a particualr product all the orders contain in total.</p>
  
  <p>So you have 3 orders with the same product on it, our app will then show a single product in a list with the total quantity for all 3 orders combined. Nice and easy for picking.</p>
  
  <p>However, I want to seperate the products with line item properties into seperate products in the list, so these can be displayed with the properties.</p>
  
  <p>I can get hold of the properties from the Order object ok, and I know that the same product can be in the order multiple times with different line item properties attached.</p>
  
  <p>BUT what on the order.line_item tells me that this is a "different product"? ie same product but different properties, what tells them appart except for the properties themselves?</p>
  
  <p>Example Line Item:</p>
  
  <pre><code>  "line_items": [
      {
        "fulfillment_service": "manual",
        "fulfillment_status": null,
        "grams": 200,
        "id": 466157049,
        "price": "199.00",
        "product_id": 632910392,
        "quantity": 1,
        "requires_shipping": true,
        "sku": "IPOD2008GREEN",
        "title": "IPod Nano - 8gb",
        "variant_id": 39072856,
        "variant_title": "green",
        "vendor": null,
        "name": "IPod Nano - 8gb - green",
        "variant_inventory_management": "shopify",
        "properties": [
          {
            "name": "Custom Engraving",
            "value": "Happy Birthday"
          }
        ]
      },
  </code></pre>
  
  <p>This is what our code looks like before adding support for line item properties. </p>
  
  <pre><code>def build_products_list(orders)
    products = {}
    orders.each do |order|
      order.line_items.each do |item|
        products[item.name] = {} unless products[item.name]
        products[item.name]['sku'] = item.sku
        products[item.name]['qty'] = (products[item.name]['qty'] ? products[item.name]['qty'] : 0) + item.quantity
      end
    end
    products
  end
  </code></pre>
  
  <p>So i need to change the products[item.name] to something unique for each product, including those that have line item properties so they appear as seperate products.</p>
  
  <p>What to change it to?</p>