feat(sms): add WALLET_CHARGED sms trigger for online topup, manual admin credit, refund, and cashback
Deploy Canina / deploy (push) Successful in 43s
E2E Playwright Tests / Run Full E2E & Security Suites (push) Failing after 0s

This commit is contained in:
parsa aghaei committed 2026-09-05 14:06:23 +03:30
1 parent 7093978e27
commit e15c25dae1
5 files changed
+168 -3

No files matched your search

@@ -104,6 +104,19 @@ export const SMS_EVENT_DEFINITIONS: SmsEventDefinition[] = [
{ key: 'date', label: 'تاریخ ارسال', sample: '۱۴۰۳/۰۶/۱۵' },
],
},
{
event: 'WALLET_CHARGED',
label: 'شارژ و افزایش موجودی کیف پول',
description: 'هنگام افزایش موجودی کیف پول کاربر (درگاه آنلاین، پنل مدیریت، کش‌بک یا استرداد)',
variables: [
{ key: 'customerName', label: 'نام مشتری', sample: 'علی محمدی' },
{ key: 'amount', label: 'مبلغ شارژ (تومان)', sample: '۵۰,۰۰۰' },
{ key: 'balance', label: 'موجودی جدید کیف پول (تومان)', sample: '۱۵۰,۰۰۰' },
{ key: 'reason', label: 'علت / نوع شارژ', sample: 'شارژ آنلاین / پاداش خرید (Cashback)' },
{ key: 'customerPhone', label: 'شماره همراه مشتری', sample: '09123456789' },
{ key: 'date', label: 'تاریخ شارژ', sample: '۱۴۰۳/۰۶/۱۵' },
],
},
];
export const DEFAULT_SMS_RULES: SmsRule[] = [
@@ -147,4 +160,14 @@ export const DEFAULT_SMS_RULES: SmsRule[] = [
variables: ['applicantName'],
description: 'پیامک ثبت درخواست متقاضیان عمده‌فروشی',
},
{
id: 'default-wallet-charged-customer',
title: 'اطلاع‌رسانی شارژ کیف پول به کاربر',
event: 'WALLET_CHARGED',
enabled: true,
recipientType: 'customer',
patternId: 0,
variables: ['customerName', 'amount', 'balance'],
description: 'ارسال پیامک افزایش موجودی کیف پول (آنلاین، مدیریت یا کش‌بک)',
},
];