Skip to content

Commit 3fccdc1

Browse files
authored
Merge pull request #70 from teacoder-team/dev
chore(payment): enable Robokassa payments
2 parents 6169299 + 524bdd2 commit 3fccdc1

2 files changed

Lines changed: 21 additions & 21 deletions

File tree

src/api/payment/payment.service.ts

Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -85,34 +85,33 @@ export class PaymentService {
8585
// icon: YoomoneyIcon,
8686
// isAvailable: true
8787
// },
88-
// {
89-
// id: PaymentMethod.CRYPTO,
90-
// name: 'Криптовалюта',
91-
// description: 'Оплата с помощью BTC, USDT, TON',
92-
// isAvailable: true
93-
// },
88+
{
89+
id: PaymentMethod.CRYPTO,
90+
name: 'Криптовалюта',
91+
description: 'Оплата с помощью BTC, USDT, TON',
92+
isAvailable: true
93+
},
9494
{
9595
id: PaymentMethod.INTERNATIONAL_CARD,
9696
name: 'Международные карты',
9797
description: 'Оплата картой зарубежных банков',
98-
isAvailable: false
99-
},
100-
{
101-
id: PaymentMethod.TELEGRAM_STARS,
102-
name: 'Telegram Stars',
103-
description: 'Оплата подписки через звёзды Telegram',
104-
isAvailable: false
98+
isAvailable: true
10599
}
100+
// {
101+
// id: PaymentMethod.TELEGRAM_STARS,
102+
// name: 'Telegram Stars',
103+
// description: 'Оплата подписки через звёзды Telegram',
104+
// isAvailable: false
105+
// }
106106
]
107107

108-
// return methods.filter(
109-
// m =>
110-
// !(
111-
// m.id === PaymentMethod.CRYPTO &&
112-
// this.CRYPTO_BLOCKED_COUNTRIES.includes(countryCode)
113-
// )
114-
// )
115-
return methods
108+
return methods.filter(
109+
m =>
110+
!(
111+
m.id === PaymentMethod.CRYPTO &&
112+
this.CRYPTO_BLOCKED_COUNTRIES.includes(countryCode)
113+
)
114+
)
116115
}
117116

118117
public async create(dto: InitPaymentRequest, user: User) {

src/api/payment/webhook/webhook.service.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,6 +226,7 @@ export class WebhookService {
226226
userId: payment.user.id
227227
},
228228
update: {
229+
startedAt: now,
229230
expiresAt,
230231
isActive: true
231232
},

0 commit comments

Comments
 (0)