From 85a34b1947c5e886bd363b57bae557c4fd6021c0 Mon Sep 17 00:00:00 2001 From: Fringg Date: Mon, 4 May 2026 07:18:14 +0300 Subject: [PATCH] feat: add Etoplatezhi payment provider support - Add etoplatezhi to METHOD_LABELS for stats charts - Add PaymentMethodIcon case with green gradient SVG - Add payments_etoplatezhi to admin settings tree - Add i18n keys in all 4 locales (en, ru, zh, fa) --- src/components/PaymentMethodIcon.tsx | 20 ++++++++++++++++++++ src/components/admin/constants.ts | 1 + src/constants/paymentMethods.ts | 1 + src/locales/en.json | 4 ++++ src/locales/fa.json | 4 ++++ src/locales/ru.json | 4 ++++ src/locales/zh.json | 4 ++++ 7 files changed, 38 insertions(+) diff --git a/src/components/PaymentMethodIcon.tsx b/src/components/PaymentMethodIcon.tsx index fafce74..6678333 100644 --- a/src/components/PaymentMethodIcon.tsx +++ b/src/components/PaymentMethodIcon.tsx @@ -295,6 +295,26 @@ export default function PaymentMethodIcon({ ); } + case 'etoplatezhi': { + const etoplatezhiGradId = `${uid}-etoplatezhi`; + return ( + + + + + + + + + + + EP + + + + ); + } + case 'apple_iap': return ( diff --git a/src/components/admin/constants.ts b/src/components/admin/constants.ts index 3f25803..87b1fa8 100644 --- a/src/components/admin/constants.ts +++ b/src/components/admin/constants.ts @@ -55,6 +55,7 @@ export const SETTINGS_TREE: SettingsTreeConfig = { { id: 'payments_paypear', categories: ['PAYPEAR'] }, { id: 'payments_rollypay', categories: ['ROLLYPAY'] }, { id: 'payments_aurapay', categories: ['AURAPAY'] }, + { id: 'payments_etoplatezhi', categories: ['ETOPLATEZHI'] }, { id: 'payments_apple_iap', categories: ['APPLE_IAP'] }, ], }, diff --git a/src/constants/paymentMethods.ts b/src/constants/paymentMethods.ts index 215f8ec..eaa6c0c 100644 --- a/src/constants/paymentMethods.ts +++ b/src/constants/paymentMethods.ts @@ -18,6 +18,7 @@ export const METHOD_LABELS: Record = { paypear: 'PayPear', rollypay: 'RollyPay', aurapay: 'AuraPay', + etoplatezhi: 'Etoplatezhi', apple_iap: 'Apple In-App Purchase', manual: 'Ручное пополнение', }; diff --git a/src/locales/en.json b/src/locales/en.json index 5604370..7640753 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -674,6 +674,9 @@ "aurapay": { "description": "Pay via AuraPay" }, + "etoplatezhi": { + "description": "Pay via Etoplatezhi" + }, "apple_iap": { "description": "Pay via Apple In-App Purchase" } @@ -1998,6 +2001,7 @@ "payments_paypear": "PayPear", "payments_rollypay": "RollyPay", "payments_aurapay": "AuraPay", + "payments_etoplatezhi": "Etoplatezhi", "payments_apple_iap": "Apple IAP", "subs_core": "Core", "subs_trial": "Trial", diff --git a/src/locales/fa.json b/src/locales/fa.json index 026178c..491b9fb 100644 --- a/src/locales/fa.json +++ b/src/locales/fa.json @@ -511,6 +511,9 @@ "severpay": { "description": "پرداخت از طریق SeverPay" }, + "etoplatezhi": { + "description": "پرداخت از طریق Etoplatezhi" + }, "apple_iap": { "description": "پرداخت از طریق Apple In-App Purchase" } @@ -1638,6 +1641,7 @@ "payments_paypear": "PayPear", "payments_rollypay": "RollyPay", "payments_aurapay": "AuraPay", + "payments_etoplatezhi": "Etoplatezhi", "payments_apple_iap": "Apple IAP", "subs_core": "هسته", "subs_trial": "آزمایشی", diff --git a/src/locales/ru.json b/src/locales/ru.json index 2b5d81b..b46c49c 100644 --- a/src/locales/ru.json +++ b/src/locales/ru.json @@ -702,6 +702,9 @@ "aurapay": { "description": "Оплата через AuraPay" }, + "etoplatezhi": { + "description": "Оплата через Etoplatezhi" + }, "apple_iap": { "description": "Оплата через Apple In-App Purchase" } @@ -2014,6 +2017,7 @@ "payments_paypear": "PayPear", "payments_rollypay": "RollyPay", "payments_aurapay": "AuraPay", + "payments_etoplatezhi": "Etoplatezhi", "payments_apple_iap": "Apple IAP", "subs_core": "Основные", "subs_trial": "Пробный период", diff --git a/src/locales/zh.json b/src/locales/zh.json index 919a31a..cc8ddca 100644 --- a/src/locales/zh.json +++ b/src/locales/zh.json @@ -511,6 +511,9 @@ "severpay": { "description": "通过SeverPay支付" }, + "etoplatezhi": { + "description": "通过Etoplatezhi支付" + }, "apple_iap": { "description": "通过Apple应用内购买支付" } @@ -1676,6 +1679,7 @@ "payments_paypear": "PayPear", "payments_rollypay": "RollyPay", "payments_aurapay": "AuraPay", + "payments_etoplatezhi": "Etoplatezhi", "payments_apple_iap": "Apple IAP", "subs_core": "核心", "subs_trial": "试用",