Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sweepstake
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Arjun Jhukal
sweepstake
Commits
e24faff6
Commit
e24faff6
authored
Oct 30, 2025
by
Arjun Jhukal
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
updated the new fix for payment
parent
f22c11c5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
20 deletions
+21
-20
index.tsx
...erDashboard/buyCoins/buyCoinSinlgeGame/checkout/index.tsx
+19
-18
transaction.ts
src/services/transaction.ts
+1
-1
transaction.ts
src/types/transaction.ts
+1
-1
No files found.
src/components/pages/dashboard/userDashboard/buyCoins/buyCoinSinlgeGame/checkout/index.tsx
View file @
e24faff6
...
@@ -100,24 +100,25 @@ export default function CheckoutPage({ amount, slug, bonus }: {
...
@@ -100,24 +100,25 @@ export default function CheckoutPage({ amount, slug, bonus }: {
<
Button
type=
'submit'
variant=
'contained'
color=
'primary'
className=
'!mt-3'
onClick=
{
async
()
=>
{
<
Button
type=
'submit'
variant=
'contained'
color=
'primary'
className=
'!mt-3'
onClick=
{
async
()
=>
{
try
{
try
{
if
(
currentPaymentMode
===
"crypto"
)
{
const
response
=
await
getPaymentLink
({
const
response
=
await
getPaymentLink
({
id
:
slug
,
id
:
slug
,
amount
,
amount
,
type
:
currentPaymentMode
as
PaymentModeProps
}).
unwrap
();
}).
unwrap
();
router
.
replace
(
response
?.
data
?.
payment_url
)
router
.
replace
(
response
?.
data
?.
payment_url
)
}
// if (currentPaymentMode === "crypto")
{
else
if
(
currentPaymentMode
===
"idem"
)
{
//
}
console
.
log
(
"payment mode is idem"
);
// else if (currentPaymentMode === "idem")
{
}
// console.log("payment mode is idem");
else
{
//
}
dispatch
(
// else
{
showToast
({
// dispatch(
message
:
"Please select prefered mode of payment."
,
// showToast(
{
variant
:
ToastVariant
.
INFO
// message: "Please select prefered mode of payment.",
})
// variant: ToastVariant.INFO
)
//
})
}
// )
//
}
}
}
catch
(
e
:
any
)
{
catch
(
e
:
any
)
{
...
...
src/services/transaction.ts
View file @
e24faff6
...
@@ -10,7 +10,7 @@ export const transactionApi = createApi({
...
@@ -10,7 +10,7 @@ export const transactionApi = createApi({
tagTypes
:
[
"Deposit"
,
"Withdrawl"
],
tagTypes
:
[
"Deposit"
,
"Withdrawl"
],
endpoints
:
(
builder
)
=>
({
endpoints
:
(
builder
)
=>
({
deposit
:
builder
.
mutation
<
DepositResponseProps
,
DepositProps
>
({
deposit
:
builder
.
mutation
<
DepositResponseProps
,
DepositProps
>
({
query
:
({
id
,
amount
,
type
=
"crypto"
})
=>
({
query
:
({
id
,
amount
,
type
})
=>
({
url
:
`/api/payment/
${
id
}
`
,
url
:
`/api/payment/
${
id
}
`
,
method
:
"POST"
,
method
:
"POST"
,
body
:
{
amount
:
amount
,
type
:
type
}
body
:
{
amount
:
amount
,
type
:
type
}
...
...
src/types/transaction.ts
View file @
e24faff6
...
@@ -5,7 +5,7 @@ type TransactionStatus = "SUCCESS" | "UNSUCCESSFUL" | "PENDING";
...
@@ -5,7 +5,7 @@ type TransactionStatus = "SUCCESS" | "UNSUCCESSFUL" | "PENDING";
export
interface
DepositProps
{
export
interface
DepositProps
{
id
:
string
;
id
:
string
;
amount
:
number
;
amount
:
number
;
type
?:
"crypto"
|
"
bank
"
type
?:
"crypto"
|
"
idem
"
}
}
export
interface
DepositUrlProps
{
export
interface
DepositUrlProps
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment