added notif 2
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
export function zarinStatusLabel(status?: string, zarinId?: string | null): string {
|
||||
if (zarinId) return 'موفق'
|
||||
if (status === 'failed') return 'ناموفق'
|
||||
if (status === 'success') return 'موفق'
|
||||
// pending = ردیف محلی ساخته شده ولی هنوز در نرمافزار زرین ثبت نشده (نه «در صف»)
|
||||
return 'ارسال نشده'
|
||||
}
|
||||
|
||||
export function canRetryZarin(record: { zarin_id?: string | null; sync_status?: string }): boolean {
|
||||
return !record.zarin_id || record.sync_status === 'failed'
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user