mirror of
https://github.com/yawaflua/LuckyDiamond.git
synced 2025-12-10 20:29:35 +02:00
added logic to added money on balance
This commit is contained in:
@@ -88,4 +88,31 @@ export async function ClickCirclePlay(InfoUser, ClickedCell) {
|
||||
catch (error) {
|
||||
console.error('Fetch error')
|
||||
}
|
||||
}
|
||||
|
||||
export async function GetWinningAmount(UserInfo) {
|
||||
const data = {
|
||||
SearchToken: UserInfo.SearchToken,
|
||||
AuthToken: UserInfo.AuthToken
|
||||
}
|
||||
|
||||
try {
|
||||
const response = await fetch(`${BackendApiUrl}/GameMines/TransferMoneyFromGameToWallet`, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(data),
|
||||
redirect: 'follow'
|
||||
})
|
||||
|
||||
if (!response.ok) {
|
||||
console.log('Fetch error:', response.status)
|
||||
}
|
||||
|
||||
return await response.json()
|
||||
}
|
||||
catch (error) {
|
||||
console.log('Fetch error', error)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user