Ordered Items

Repeat the purchased product lines from a specific WooCommerce order. Use this for a custom order-detail or Thank you layout, not for a product catalog or the current cart.

Enable and Prepare


  1. Activate WooCommerce and BricksUltimate.
  2. Open Bricks → BricksUltimate → Misc, enable Ultimate Woo Query Builder, and save.
  3. Reopen the Bricks editor so the query options refresh.

Use a WooCommerce order confirmation or authenticated View Order flow with a valid order available. Create a test order containing a simple product, a variation, multiple quantities, and a refunded line if your store supports refunds.

Create the Query Loop


  1. Add an outer Section or Block for the heading and layout. Keep the section heading outside the repeated item.
  2. Add an inner Block for one record and enable Use query loop on that Block.
  3. Choose Ultimate Woo Query Builder as the query Type, then choose Customer Ordered Items under Woo query type.
  4. Enable Disable query merge where offered so the current page's main query does not unexpectedly constrain this custom collection.
  5. Configure the controls below and place the record's dynamic elements inside the repeated Block.
  6. Save and test on the frontend. Builder sample content is not a substitute for the live query result.

Controls and Behavior


ControlHow to use it
Order IDSupply the internal order ID, not a custom display number. Dynamic data is supported. For an order-context layout, use {bu_cust_order_id} where it resolves to the intended order.
Order source precedenceWhen the BU AJAX popup context provides the global orderID, it takes precedence over the configured Order ID. Confirm the actual order when testing popup layouts.
Item typesBy default the provider reads line_item entries. Shipping, fees, and coupon lines are not product rows; another integration can modify the WooCommerce purchase item-types filter.
Product BundlesWhen WooCommerce Product Bundles display integration is present, bundled child lines are filtered out by the current implementation. Test bundle parent and child presentation.
Order access: This query loads the configured order ID without performing an ownership check itself. Use a protected WooCommerce order flow and validate permissions in any custom route. Do not let a public URL parameter choose an arbitrary order.

Purchased Item Dynamic Data

FieldDynamic tag
Purchased name{bu_order_item_name}
Quantity{bu_order_item_quantity}
Formatted line subtotal{bu_order_item_price}
Product SKU{bu_order_item_sku}
Image attachment ID{bu_order_item_featimg_id}
Variation / item metadata{bu_order_item_variable_attributes}

The price tag is a formatted order line subtotal, not necessarily the current product's unit price. It also needs the surrounding order context. Quantity can include refund markup. Use text elements that allow the intended formatted output.

Historical Data Versus Current Product Data

The purchased name comes from the stored order item. SKU and image are read from the linked product, with a parent-image fallback for variations and a placeholder fallback. Deleted products may therefore have a stored name but no usable current SKU or image. The custom-data tag bu_order_item_custom_data reads current product post metadata by key; it is not a general order-item metadata reader. Do not use it as an immutable purchase record.

Nested Order Lists

An outer Customer Orders loop can supply an Order ID to an inner item query, but once inside the inner loop the active object is an order item. Order-level tags, especially the formatted price tag, require a separately resolvable current order. Start with an order-detail page and test nested layouts carefully; do not assume every order tag automatically traverses to an outer loop.

Practical Example


On a protected View Order layout, choose Customer Ordered Items and set Order ID dynamically to the current order ID. Add item image, name, attributes, quantity, and line subtotal inside the repeated Block. Keep order totals and payment details outside this loop.

Scope and Limitations


This provider does not expose item pagination or a per-order item limit. It does not show live cart contents, recalculate historical prices, or add reorder controls automatically. Avoid deeply nested loops and large all-customer order lists for performance.

Troubleshooting and Testing


If the list is blank, check the numeric ID and order access context. If names appear but prices do not, check whether the order is resolvable independently of the item loop. Missing SKU after product deletion is expected. Variation metadata should use the item metadata tag, not a generic product description.

Test the populated and empty states, desktop and mobile layouts, and any relevant AJAX refresh. Keep headings and decorative wrappers from leaving empty gaps when no eligible results exist. If a query type is missing, verify the feature toggle, WooCommerce activation, and editor reload before changing the layout.

Related Documentation