diff --git a/apps/admin/locales-extra.ts b/apps/admin/locales-extra.ts
index 271fbf8..c2ae98e 100644
--- a/apps/admin/locales-extra.ts
+++ b/apps/admin/locales-extra.ts
@@ -5,6 +5,10 @@ export const enExtra = {
adminHint: "Dev account: admin@vmall.local / admin1234",
wrongRole: "This account does not have platform administrator access.",
},
+ nav: {
+ pointsProducts: "Points products",
+ pointsOrders: "Point redemptions",
+ },
admin: {
dashboardTitle: "Platform overview",
refresh: "Refresh",
@@ -30,6 +34,39 @@ export const enExtra = {
orderManagement: "Order management",
currencyManagement: "Currency management",
pageOf: "Page {page} of {total}",
+ pointsProductManagement: "Points catalog",
+ pointsOrderManagement: "Point redemptions",
+ newPointsProduct: "New points product",
+ editPointsProduct: "Edit points product",
+ pointsNameEn: "Name (English)",
+ pointsNameZh: "Name (中文)",
+ pointsPrice: "Points price",
+ pointsStock: "Stock",
+ pointsImage: "Image URL",
+ pointsPosition: "Sort order",
+ pointsRecommend: "Featured",
+ pointsPublished: "Published",
+ publishedOn: "Published",
+ publishedOff: "Draft",
+ savePointsProduct: "Save points product",
+ pointsProductSaved: "Points product saved.",
+ pointsNameRequired: "Both language names are required.",
+ pointsPriceInvalid: "Points price must be a positive integer.",
+ pointsStockInvalid: "Stock cannot be negative.",
+ redemptionNo: "Redemption no.",
+ redemptionCustomer: "Customer",
+ redemptionReward: "Reward",
+ redemptionPoints: "Points",
+ redemptionStatus: "Status",
+ fulfillRedemption: "Fulfil",
+ cancelRedemption: "Cancel",
+ redemptionFulfilled: "Redemption fulfilled.",
+ redemptionCancelled: "Redemption cancelled.",
+ redemptionStatuses: {
+ pending_fulfillment: "Pending",
+ fulfilled: "Fulfilled",
+ cancelled: "Cancelled",
+ },
},
} as const;
@@ -38,6 +75,10 @@ export const zhExtra = {
adminHint: "开发账号:admin@vmall.local / admin1234",
wrongRole: "此账号没有平台管理员权限。",
},
+ nav: {
+ pointsProducts: "积分商品",
+ pointsOrders: "积分兑换单",
+ },
admin: {
dashboardTitle: "平台概览",
refresh: "刷新",
@@ -63,5 +104,38 @@ export const zhExtra = {
orderManagement: "订单管理",
currencyManagement: "币种管理",
pageOf: "第 {page} 页,共 {total} 页",
+ pointsProductManagement: "积分商品目录",
+ pointsOrderManagement: "积分兑换单",
+ newPointsProduct: "新建积分商品",
+ editPointsProduct: "编辑积分商品",
+ pointsNameEn: "名称(英文)",
+ pointsNameZh: "名称(中文)",
+ pointsPrice: "积分价格",
+ pointsStock: "库存",
+ pointsImage: "图片链接",
+ pointsPosition: "排序",
+ pointsRecommend: "推荐",
+ pointsPublished: "已发布",
+ publishedOn: "已发布",
+ publishedOff: "草稿",
+ savePointsProduct: "保存积分商品",
+ pointsProductSaved: "积分商品已保存。",
+ pointsNameRequired: "中英文名称均为必填项。",
+ pointsPriceInvalid: "积分价格必须为正整数。",
+ pointsStockInvalid: "库存不能为负数。",
+ redemptionNo: "兑换单号",
+ redemptionCustomer: "用户",
+ redemptionReward: "兑换商品",
+ redemptionPoints: "积分",
+ redemptionStatus: "状态",
+ fulfillRedemption: "发货",
+ cancelRedemption: "取消",
+ redemptionFulfilled: "兑换单已发货。",
+ redemptionCancelled: "兑换单已取消。",
+ redemptionStatuses: {
+ pending_fulfillment: "待发货",
+ fulfilled: "已发货",
+ cancelled: "已取消",
+ },
},
} as const;
diff --git a/apps/admin/pages/points-orders.vue b/apps/admin/pages/points-orders.vue
new file mode 100644
index 0000000..7e5a8f2
--- /dev/null
+++ b/apps/admin/pages/points-orders.vue
@@ -0,0 +1,135 @@
+
+
+
+
+
{{ $t("admin.pointsOrderManagement") }}
+
{{ error }}
+
{{ notice }}
+
+
{{ $t("common.loading") }}
+
{{ $t("common.empty") }}
+
+
+
+
+ | {{ $t("admin.redemptionNo") }} |
+ {{ $t("admin.redemptionCustomer") }} |
+ {{ $t("admin.redemptionReward") }} |
+ {{ $t("admin.redemptionPoints") }} |
+ {{ $t("admin.created") }} |
+ {{ $t("admin.redemptionStatus") }} |
+ {{ $t("common.actions") }} |
+
+
+
+
+ | {{ order.order_no }} |
+ {{ order.user_id }} |
+ {{ rewardName(order) }} |
+ {{ order.total_points }} |
+ {{ order.created_at.slice(0, 10) }} |
+
+
+ {{ $t(`admin.redemptionStatuses.${order.status}`) }}
+
+ |
+
+
+
+
+
+ |
+
+
+
+
+
+
+
+
diff --git a/apps/admin/pages/points-products.vue b/apps/admin/pages/points-products.vue
new file mode 100644
index 0000000..4193a09
--- /dev/null
+++ b/apps/admin/pages/points-products.vue
@@ -0,0 +1,267 @@
+
+
+
+
+
{{ $t("admin.pointsProductManagement") }}
+
{{ error }}
+
{{ notice }}
+
+
+
+
{{ $t("common.loading") }}
+
{{ $t("common.empty") }}
+
+
+
+
+ | {{ $t("admin.pointsNameEn") }} |
+ {{ $t("admin.pointsPrice") }} |
+ {{ $t("admin.pointsStock") }} |
+ {{ $t("admin.pointsPosition") }} |
+ {{ $t("admin.pointsRecommend") }} |
+ {{ $t("common.status") }} |
+ {{ $t("common.actions") }} |
+
+
+
+
+ | {{ localizedName(product.name) }} |
+ {{ product.points_price }} |
+ {{ product.stock }} |
+ {{ product.position }} |
+ {{ product.recommend ? $t("common.yes") : $t("common.no") }} |
+
+
+ {{ product.published ? $t("admin.publishedOn") : $t("admin.publishedOff") }}
+
+ |
+
+
+
+ |
+
+
+
+
+
+
+
+