diff --git a/src/pages/salesOrder/SalesOrderList.vue b/src/pages/salesOrder/SalesOrderList.vue index 8d0e8dd..a6eb537 100644 --- a/src/pages/salesOrder/SalesOrderList.vue +++ b/src/pages/salesOrder/SalesOrderList.vue @@ -124,14 +124,14 @@ const actions = computed(() => [ text: "直接产品下单", icon: "task", theme: "primary" as const, - action: toCreate + action: () => router.push("/management/sales-orders/create") }] : []), ...(canCreatePackageOrder.value ? [{ key: "create-package-order", text: "创建客户套餐", icon: "layers", theme: "primary" as const, - action: toCreatePackageOrder + action: () => router.push("/management/customer-packages/create") }] : []) ]); const keyword = ref(""); @@ -153,10 +153,30 @@ const loading = ref(false); const refreshing = ref(false); const noMore = ref(false); const pageSize = 15; -const orderTypeOptions = [{ label: "全部类型", value: "ALL" }, { label: "套餐订单", value: "PACKAGE" }, { label: "直接产品", value: "DIRECT_PRODUCT" }]; -const statusOptions = [{ label: "全部状态", value: "ALL" }, { label: "进行中", value: "ACTIVE" }, { label: "已履约", value: "FULFILLED" }, { label: "已取消", value: "CANCELLED" }]; -const paymentOptions = [{ label: "全部收款", value: "ALL" }, { label: "未收清", value: "PENDING_RECEIVE" }, { label: "未收款", value: "UNPAID" }, { label: "部分收款", value: "PARTIALLY_PAID" }, { label: "已收款", value: "PAID" }]; -const refundOptions = [{ label: "全部退款", value: "ALL" }, { label: "无需退款", value: "NOT_REQUIRED" }, { label: "待退款", value: "PENDING" }, { label: "已退款", value: "REFUNDED" }]; +const orderTypeOptions = [ + { label: "全部类型", value: "ALL" }, + { label: "套餐订单", value: "PACKAGE" }, + { label: "产品订单", value: "DIRECT_PRODUCT" } +]; +const statusOptions = [ + { label: "全部状态", value: "ALL" }, + { label: "进行中", value: "ACTIVE" }, + { label: "已履约", value: "FULFILLED" }, + { label: "已取消", value: "CANCELLED" } +]; +const paymentOptions = [ + { label: "全部收款", value: "ALL" }, + { label: "未收清", value: "PENDING_RECEIVE" }, + { label: "未收款", value: "UNPAID" }, + { label: "部分收款", value: "PARTIALLY_PAID" }, + { label: "已收款", value: "PAID" } +]; +const refundOptions = [ + { label: "全部退款", value: "ALL" }, + { label: "无需退款", value: "NOT_REQUIRED" }, + { label: "待退款", value: "PENDING" }, + { label: "已退款", value: "REFUNDED" } +]; const routeFilterKey = computed(() => [ route.query.customerId, @@ -307,14 +327,6 @@ async function toFulfillment(item: SalesOrder): Promise { if (item.id) await router.push({ path: "/management/order-fulfillments/create", query: { salesOrderId: item.id } }); } -async function toCreate(): Promise { - await router.push("/management/sales-orders/create"); -} - -async function toCreatePackageOrder(): Promise { - await router.push("/management/customer-packages/create"); -} - const search = Toolkit.debounce(async () => { try { await fetchList(true);