From 993de3a4cf4deaadfedef03fa3ff1961b111e46d Mon Sep 17 00:00:00 2001 From: adonis Date: Sun, 26 Jul 2026 21:29:10 +0330 Subject: [PATCH] fix bug of pargar 4 --- src/api/pargar.ts | 32 +++++ src/pages/dashboard/index.vue | 12 +- .../components/PargarStuckOutboundAlert.vue | 125 ++++++++++++++++++ src/pages/menuPages/accounting/index.vue | 2 + 4 files changed, 170 insertions(+), 1 deletion(-) create mode 100644 src/pages/menuPages/accounting/components/PargarStuckOutboundAlert.vue diff --git a/src/api/pargar.ts b/src/api/pargar.ts index 56d5074..32a0cf5 100644 --- a/src/api/pargar.ts +++ b/src/api/pargar.ts @@ -85,6 +85,38 @@ export const syncAllWalletsFromPargarChunk = async (params?: { force: params?.force ?? false, }) +export interface StuckOutboundRow { + id: number + export_id: string + type: string + amount: number | null + desc: string + order_id: number | null + withdraw_id: number | null + customer_id: number | null + customer_name?: string | null + customer_mobile?: string | null + pargar_account_id?: string | number | null + created_at?: string | null + waited_minutes: number +} + +export interface StuckOutboundSummary { + count: number + customers: number + waited_minutes: number + oldest_at: string | null + last_confirmed_at: string | null + threshold_minutes: number + rows: StuckOutboundRow[] +} + +/** اسناد پنل که پرگار هنوز تحویل نگرفته — ماندهٔ این مشتری‌ها اعمال نمی‌شود */ +export const getStuckOutbound = async (minutes?: number) => + await useAxios.get('/admin/pargar/stuck-outbound', { + params: minutes === undefined ? undefined : { minutes }, + }) + export interface PanelOnlyCustomer { id: number name: string diff --git a/src/pages/dashboard/index.vue b/src/pages/dashboard/index.vue index c12634c..aa334ed 100644 --- a/src/pages/dashboard/index.vue +++ b/src/pages/dashboard/index.vue @@ -1,6 +1,8 @@