#10431
15 Nov 2026 Processing3 items Rp 1.145.000
English
Past orders with the status, the items, and actions such as buy again
Lists the orders of a buyer on an account page. For where one order is now, use the shipment tracker.
<template>
<BlessOrderHistory
:orders
currency="IDR"
locale="id-ID"
style="max-width: 560px"
@again="(id) => (again = id)"
/>
<p v-if="again" style="margin-top: 12px">Buy again: {{ again }}</p>
</template>
<script setup lang="ts">
import { ref } from "vue";
import { BlessOrderHistory, type BlessPastOrder } from "blessing-ui";
import { art } from "./_data";
const mic = { name: "USB microphone", quantity: 1, image: art("🎙️", "f3e1e7") };
const foam = { name: "Foam panels", quantity: 2, image: art("🧱", "e6e6e6") };
const cable = { name: "XLR cable", quantity: 3, image: art("🔌", "e8f3df") };
const stand = { name: "Desk stand", quantity: 1, image: art("🗜️", "efe6d8") };
const filter = { name: "Pop filter", quantity: 1, image: art("⭕", "e3e0f3") };
const orders: BlessPastOrder[] = [
{
id: "o3",
number: "#10431",
date: "15 Nov 2026",
status: "processing",
total: 1145000,
items: [mic, foam],
href: "#o3",
},
{
id: "o2",
number: "#10388",
date: "2 Nov 2026",
status: "shipped",
total: 255000,
items: [cable],
href: "#o2",
},
{
id: "o1",
number: "#10204",
date: "12 Oct 2026",
status: "delivered",
total: 1530000,
items: [mic, cable, stand, filter, foam],
href: "#o1",
},
{
id: "o0",
number: "#10150",
date: "1 Oct 2026",
status: "cancelled",
total: 85000,
items: [filter],
},
];
const again = ref<string>();
</script>orders is a list of orders. Each order has an id, a number, a date as text, a status, a total, and items. It can also have an href to its page.processing, shipped, delivered, or cancelled. It shows as a mark and a word, such as "✓ Delivered".name, a quantity, and an optional image. Up to three pictures show, then a count of the rest, such as "+2". Screen readers hear the list of items in place of the pictures.href, a "View order" link shows. Every order that is not in progress has a "Buy again" button that emits again with the id. Both have the order number in their name.currency is an ISO 4217 code (default USD), and locale sets the format.labels or a label pack: title, the four statuses, again, view, and the functions items and more.import { BlessOrderHistory } from "blessing-ui";| Name | Type | Default | Description |
|---|---|---|---|
orders* | BlessPastOrder[] | — | |
currency | string | "USD" | |
locale | string | "en" | |
labels | Partial<Record<BlessOrderStatus, string> & { title: string; again: string; view: string; items: (count: number) => string; more: (count: number) => string; }> | — |
| Name | Payload | Description |
|---|---|---|
again | [id: string] |