mirror of
https://github.com/yawaflua/LuckyDiamond.git
synced 2025-12-10 04:09:29 +02:00
Revert "Merge pull request #20 from danilt2000/Swino4ka"
This reverts commit3b06b7ef2d, reversing changes made toc4761cec13.
This commit is contained in:
@@ -116,6 +116,12 @@ button {
|
|||||||
grid-template-rows: auto 0fr repeat(4, 1fr);
|
grid-template-rows: auto 0fr repeat(4, 1fr);
|
||||||
grid-template-areas:
|
grid-template-areas:
|
||||||
"menu header header header header header header"
|
"menu header header header header header header"
|
||||||
|
"menu double double double double double chat"
|
||||||
|
"menu double double double double double chat"
|
||||||
|
"menu double double double double double chat"
|
||||||
|
"menu double double double double double chat"
|
||||||
|
"menu double double double double double chat"
|
||||||
|
"menu double double double double double chat"
|
||||||
"menu jackpot-history jackpot-history jackpot-history jackpot-history jackpot-history chat"
|
"menu jackpot-history jackpot-history jackpot-history jackpot-history jackpot-history chat"
|
||||||
"menu jackpot-history jackpot-history jackpot-history jackpot-history jackpot-history chat"
|
"menu jackpot-history jackpot-history jackpot-history jackpot-history jackpot-history chat"
|
||||||
"menu jackpot-history jackpot-history jackpot-history jackpot-history jackpot-history chat"
|
"menu jackpot-history jackpot-history jackpot-history jackpot-history jackpot-history chat"
|
||||||
|
|||||||
@@ -1,61 +0,0 @@
|
|||||||
import { BackendApiUrl } from '@/properties/Сonfig.js';
|
|
||||||
import { GetCookie } from "@/assets/js/storage/CookieStorage";
|
|
||||||
export async function GetReferralData () {
|
|
||||||
|
|
||||||
const myHeaders = new Headers();
|
|
||||||
myHeaders.append("Content-Type", "application/json");
|
|
||||||
|
|
||||||
const userData = {
|
|
||||||
searchToken: GetCookie("SearchToken"),
|
|
||||||
authtoken: GetCookie("AUTHTOKEN"),
|
|
||||||
};
|
|
||||||
|
|
||||||
const raw = JSON.stringify({
|
|
||||||
"userCredentials": {
|
|
||||||
"searchToken": userData.searchToken,
|
|
||||||
"authtoken": userData.authtoken
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const response = await fetch(`${BackendApiUrl}/PromoCode/GetReferralInfo`, {
|
|
||||||
method: "POST",
|
|
||||||
headers: {
|
|
||||||
"Content-Type": "application/json",
|
|
||||||
},
|
|
||||||
body: raw,
|
|
||||||
redirect: "follow"
|
|
||||||
});
|
|
||||||
|
|
||||||
return await response.json();
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
export async function WithdrawReferralMoney () {
|
|
||||||
const myHeaders = new Headers();
|
|
||||||
myHeaders.append("Content-Type", "application/json");
|
|
||||||
|
|
||||||
const userData = {
|
|
||||||
searchToken: GetCookie("SearchToken"),
|
|
||||||
authtoken: GetCookie("AUTHTOKEN"),
|
|
||||||
};
|
|
||||||
|
|
||||||
const raw = JSON.stringify({
|
|
||||||
"userCredentials": {
|
|
||||||
"searchToken": userData.searchToken,
|
|
||||||
"authtoken": userData.authtoken
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const requestOptions = {
|
|
||||||
method: "POST",
|
|
||||||
headers: myHeaders,
|
|
||||||
body: raw,
|
|
||||||
redirect: "follow"
|
|
||||||
};
|
|
||||||
|
|
||||||
fetch("https://spsystemcore20231122004605.azurewebsites.net/api/PromoCode/TakeMoneyReferral", requestOptions)
|
|
||||||
.then((response) => response.text())
|
|
||||||
.then((result) => console.log(result))
|
|
||||||
.catch((error) => console.error(error));
|
|
||||||
}
|
|
||||||
@@ -1,167 +1,96 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="payment-modal withdraw-modal">
|
<div class="payment-modal withdraw-modal">
|
||||||
<div class="payments-modal__content close-modal__icon text-styles__margin">
|
<div class="payments-modal__content close-modal__icon text-styles__margin">
|
||||||
<h1>Рефералы</h1>
|
<h1>Рефералы</h1>
|
||||||
<img @click="closeModal" src="@/assets/icons-other/icon-payments-modal-close.svg" />
|
<img @click="closeModal" src="@/assets/icons-other/icon-payments-modal-close.svg" />
|
||||||
</div>
|
|
||||||
<div class="payments-modal__deposit">
|
|
||||||
<div class="error-deposit" v-if="errorDeposit">
|
|
||||||
<h2>Ошибка с суммой депозита</h2>
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
class="deposit-input deposit-text referal-icon-diamond deposit-icon__input"
|
|
||||||
>
|
|
||||||
<br>
|
|
||||||
<h3>Ваш реферальный код</h3>
|
|
||||||
<input
|
|
||||||
:class="{ 'animate-start-btn': errorDeposit }"
|
|
||||||
readonly
|
|
||||||
class="deposit-amount__input"
|
|
||||||
v-if="referralData.referralCode"
|
|
||||||
:value="referralData.referralCode"
|
|
||||||
/>
|
|
||||||
<br>
|
|
||||||
<br>
|
|
||||||
<h3>Доступно к выводу</h3>
|
|
||||||
<img src="@/assets/icons-games/saper-game/icon-diamond-ore-saper.png" />
|
|
||||||
<input
|
|
||||||
:class="{ 'animate-start-btn': errorDeposit }"
|
|
||||||
readonly
|
|
||||||
class="deposit-amount__input"
|
|
||||||
v-if="referralData.avalibleAmount !== 0"
|
|
||||||
:value="referralData.avalibleAmount"
|
|
||||||
/>
|
|
||||||
<input
|
|
||||||
:class="{ 'animate-start-btn': errorDeposit }"
|
|
||||||
readonly
|
|
||||||
class="deposit-amount__input"
|
|
||||||
v-else
|
|
||||||
:value="'0'"
|
|
||||||
/>
|
|
||||||
<div class="deposit-btns">
|
|
||||||
<ul class="display-btns btns-style-diamonds">
|
|
||||||
<li v-for="(number, index) in PaymentsModalNumbers" :key="index">
|
|
||||||
<button
|
|
||||||
@click="clickedBtnChoice(index, number.diamonds)"
|
|
||||||
:class="{
|
|
||||||
'btn-click': clickedBtn === index,
|
|
||||||
[number]: clickedBtn === number,
|
|
||||||
}"
|
|
||||||
>
|
|
||||||
{{ number.diamonds }}
|
|
||||||
</button>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="deposit-promocode deposit-promocode__padding--input">
|
<div class="payments-modal__deposit">
|
||||||
<h3>Всего привели рефералов</h3>
|
<div class="error-deposit" v-if="errorDeposit">
|
||||||
<div class="promokods">
|
<h2>Ошибка с суммой депозита</h2>
|
||||||
<input
|
|
||||||
:class="{ 'animate-start-btn': errorDeposit }"
|
|
||||||
readonly
|
|
||||||
class="deposit-amount__input"
|
|
||||||
v-if="referralData.activationsAmount !== 0"
|
|
||||||
:value="referralData.activationsAmount"
|
|
||||||
/>
|
|
||||||
<input
|
|
||||||
:class="{ 'animate-start-btn': errorDeposit }"
|
|
||||||
readonly
|
|
||||||
class="deposit-amount__input"
|
|
||||||
v-else
|
|
||||||
:value="'0'"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="error-checkbox" v-if="errorAgree">
|
|
||||||
<h2>Подтвердите согласие!</h2>
|
|
||||||
</div>
|
|
||||||
<div class="deposit-checkbox checkbox-styles">
|
|
||||||
<input
|
|
||||||
@click="agreeUser = !agreeUser"
|
|
||||||
type="checkbox"
|
|
||||||
:class="{ 'animate-start-btn': errorAgree }"
|
|
||||||
/>
|
|
||||||
<h3>Я согласен с <a href="https://docs.google.com/document/d/1lU_zTWJdD1lcMlIAFDIVz-DlZAoq3a-OFkoO8WBIkzo/edit?usp=sharing">пользовательским соглашением</a></h3>
|
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
class="btn-deposit btn-text-style btn-display-deposit btn-style-payments"
|
class="deposit-input deposit-text referal-icon-diamond deposit-icon__input"
|
||||||
>
|
>
|
||||||
<p>
|
<br>
|
||||||
Вы подтверждаете правильность введенных данных при создании вывода.
|
<h3>Ваш реферальный код</h3>
|
||||||
</p>
|
<input
|
||||||
<button type="submit" @click="handleWithdraw">Вывести</button>
|
:class="{ 'animate-start-btn': errorDeposit }" readonly
|
||||||
<p>
|
class="deposit-amount__input"
|
||||||
Перед пополнение прочитайте политику конфиденциальности и
|
v-model="amount"
|
||||||
пользовательское соглашение.
|
type="number"
|
||||||
</p>
|
/>
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
<h3>Доступно к выводу</h3>
|
||||||
|
<img src="@/assets/icons-games/saper-game/icon-diamond-ore-saper.png" />
|
||||||
|
<input
|
||||||
|
:class="{ 'animate-start-btn': errorDeposit }" readonly
|
||||||
|
class="deposit-amount__input"
|
||||||
|
v-model="amount"
|
||||||
|
type="number"
|
||||||
|
/>
|
||||||
|
<div class="deposit-btns">
|
||||||
|
<ul class="display-btns btns-style-diamonds">
|
||||||
|
<li v-for="(number, index) in PaymentsModalNumbers" :key="index">
|
||||||
|
<button
|
||||||
|
@click="clickedBtnChoice(index, number.diamonds)"
|
||||||
|
:class="{
|
||||||
|
'btn-click': clickedBtn === index,
|
||||||
|
[number]: clickedBtn === number,
|
||||||
|
}"
|
||||||
|
>
|
||||||
|
{{ number.diamonds }}
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="deposit-promocode deposit-promocode__padding--input">
|
||||||
|
<h3>Всего привели рефералов</h3>
|
||||||
|
<div class="promokods">
|
||||||
|
<input
|
||||||
|
:class="{ 'animate-start-btn': errorDeposit }" readonly
|
||||||
|
class="deposit-amount__input"
|
||||||
|
v-model="amount"
|
||||||
|
type="number"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="error-checkbox" v-if="errorAgree">
|
||||||
|
<h2>Подтвердите согласие!</h2>
|
||||||
|
</div>
|
||||||
|
<div class="deposit-checkbox checkbox-styles">
|
||||||
|
<input
|
||||||
|
@click="agreeUser = !agreeUser"
|
||||||
|
type="checkbox"
|
||||||
|
:class="{ 'animate-start-btn': errorAgree }"
|
||||||
|
/>
|
||||||
|
<h3>Я согласен с <a href="https://docs.google.com/document/d/1lU_zTWJdD1lcMlIAFDIVz-DlZAoq3a-OFkoO8WBIkzo/edit?usp=sharing">пользовательским соглашением</a></h3>
|
||||||
|
</div>
|
||||||
|
<div
|
||||||
|
class="btn-deposit btn-text-style btn-display-deposit btn-style-payments"
|
||||||
|
>
|
||||||
|
<p>
|
||||||
|
Вы подтверждаете правильность введенных данных при создании вывода.
|
||||||
|
</p>
|
||||||
|
<button type="submit" @click="RedirectedMethodDep">Вывести</button>
|
||||||
|
<p>
|
||||||
|
Перед пополнение прочитайте политику конфиденциальности и
|
||||||
|
пользовательское соглашение.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</template>
|
||||||
</div>
|
|
||||||
</template>
|
<script>
|
||||||
|
import "@/assets/css/ComponentsStyles/payments-modal.css";
|
||||||
<script>
|
export default {
|
||||||
import "@/assets/css/ComponentsStyles/payments-modal.css";
|
props: ["payments"],
|
||||||
import { GetReferralData } from "@/assets/js/Profile/Referrals";
|
methods: {
|
||||||
import { WithdrawReferralMoney } from "@/assets/js/Profile/Referrals";
|
closeModal() {
|
||||||
import { eventBus } from "@/main";
|
return this.$emit("closemodal");
|
||||||
|
},
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
referralData: {},
|
|
||||||
errorDeposit: false,
|
|
||||||
errorAgree: false,
|
|
||||||
agreeUser: false,
|
|
||||||
amount: 0,
|
|
||||||
PaymentsModalNumbers: [],
|
|
||||||
};
|
|
||||||
},
|
|
||||||
props: ["payments"],
|
|
||||||
async created() {
|
|
||||||
this.referralData = await GetReferralData();
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
avalibleAmountValue() {
|
|
||||||
return this.referralData.avalibleAmount !== 0 ? this.referralData.avalibleAmount : '0';
|
|
||||||
},
|
},
|
||||||
activationsAmountValue() {
|
};
|
||||||
return this.referralData.activationsAmount !== 0 ? this.referralData.activationsAmount : '0';
|
</script>
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async handleWithdraw() {
|
|
||||||
try {
|
|
||||||
if (!this.agreeUser) {
|
|
||||||
this.errorAgree = true;
|
|
||||||
setTimeout(() => {
|
|
||||||
this.errorAgree = false;
|
|
||||||
}, 1500);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (this.referralData.avalibleAmount == 0) {
|
|
||||||
window.alert("У вас нет денег на вывод :(");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
await WithdrawReferralMoney().then(async (response) => {
|
|
||||||
try {
|
|
||||||
console.log("work", response);
|
|
||||||
} catch (e) {
|
|
||||||
console.error(e);
|
|
||||||
}
|
|
||||||
await this.$emit("notifacetionmoney");
|
|
||||||
eventBus.emit("Updatebalance");
|
|
||||||
this.$emit("closemodal");
|
|
||||||
});
|
|
||||||
} catch (error) {
|
|
||||||
console.error("Error withdrawing referral money:", error);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
closeModal() {
|
|
||||||
this.$emit("closemodal");
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
|
||||||
</script>
|
|
||||||
@@ -7,7 +7,7 @@ const SiteOff = {
|
|||||||
<p>We are currently performing maintenance. We will be back shortly!</p>
|
<p>We are currently performing maintenance. We will be back shortly!</p>
|
||||||
</div>`
|
</div>`
|
||||||
};
|
};
|
||||||
const siteIsOff = true;
|
const siteIsOff = false;
|
||||||
|
|
||||||
import router from "@/router/router";
|
import router from "@/router/router";
|
||||||
import mitt from 'mitt'
|
import mitt from 'mitt'
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ export default {
|
|||||||
arrayHistory: [],
|
arrayHistory: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
emits: ['notificationremove'],
|
emits: ['notificationremove'],
|
||||||
mounted() {
|
mounted() {
|
||||||
this.checkWindowSize()
|
this.checkWindowSize()
|
||||||
@@ -100,57 +100,6 @@ export default {
|
|||||||
this.RemoveWindowListener()
|
this.RemoveWindowListener()
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
|
||||||
const myHeaders = new Headers();
|
|
||||||
myHeaders.append("Content-Type", "application/json");
|
|
||||||
myHeaders.append("Cookie", "ARRAffinity=a6e48b9e9d2653435be7b61998d8624b44115214104213d6c8b8c526cc56dc70; ARRAffinitySameSite=a6e48b9e9d2653435be7b61998d8624b44115214104213d6c8b8c526cc56dc70");
|
|
||||||
|
|
||||||
const userData = {
|
|
||||||
searchToken: GetCookie("SearchToken"),
|
|
||||||
authtoken: GetCookie("AUTHTOKEN"),
|
|
||||||
};
|
|
||||||
|
|
||||||
const raw = JSON.stringify({
|
|
||||||
"userCredentials": {
|
|
||||||
"searchToken": userData.searchToken,
|
|
||||||
"authtoken": userData.authtoken
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const requestOptions = {
|
|
||||||
method: "POST",
|
|
||||||
headers: myHeaders,
|
|
||||||
body: raw,
|
|
||||||
redirect: "follow"
|
|
||||||
};
|
|
||||||
|
|
||||||
fetch("https://spsystemcore20231122004605.azurewebsites.net/api/PromoCode/GetReferralInfo", requestOptions)
|
|
||||||
.then((response) => response.text())
|
|
||||||
.then((result) => {
|
|
||||||
console.log(result);
|
|
||||||
if (result == "\"The Referral is not created\"") {
|
|
||||||
const raw = JSON.stringify({
|
|
||||||
"userCredentials": {
|
|
||||||
"searchToken": userData.searchToken,
|
|
||||||
"authtoken": userData.authtoken
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const requestOptions = {
|
|
||||||
method: "POST",
|
|
||||||
headers: myHeaders,
|
|
||||||
body: raw,
|
|
||||||
redirect: "follow"
|
|
||||||
};
|
|
||||||
|
|
||||||
fetch("https://spsystemcore20231122004605.azurewebsites.net/api/PromoCode/CreateReferal", requestOptions)
|
|
||||||
.then((response) => response.text())
|
|
||||||
.then((result) => console.log(result))
|
|
||||||
.catch((error) => console.error(error));
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.catch((error) => console.error(error));
|
|
||||||
|
|
||||||
axios.post('https://spsystemcore20231122004605.azurewebsites.net/api/Payment/GetPaymentHistory', {
|
axios.post('https://spsystemcore20231122004605.azurewebsites.net/api/Payment/GetPaymentHistory', {
|
||||||
searchToken: GetCookie('SearchToken'),
|
searchToken: GetCookie('SearchToken'),
|
||||||
authtoken: GetCookie('AUTHTOKEN')
|
authtoken: GetCookie('AUTHTOKEN')
|
||||||
@@ -191,7 +140,7 @@ export default {
|
|||||||
this.payments = false
|
this.payments = false
|
||||||
this.openRef = false
|
this.openRef = false
|
||||||
},
|
},
|
||||||
referalClick() {
|
referalClick() {
|
||||||
this.openModal = false
|
this.openModal = false
|
||||||
this.openRef = true
|
this.openRef = true
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ import { createRouter, createWebHistory } from "vue-router";
|
|||||||
import HomePage from "../pages/HomePage.vue";
|
import HomePage from "../pages/HomePage.vue";
|
||||||
import ProfilePage from "@/pages/ProfilePage.vue";
|
import ProfilePage from "@/pages/ProfilePage.vue";
|
||||||
import SapergamePage from "@/pages/games-pages/SapergamePage.vue";
|
import SapergamePage from "@/pages/games-pages/SapergamePage.vue";
|
||||||
|
import DoublePage from "@/pages/games-pages/DoublePage.vue";
|
||||||
import SettingsPage from "@/pages/SettingsPage.vue";
|
import SettingsPage from "@/pages/SettingsPage.vue";
|
||||||
import CrashGamePage from "@/pages/games-pages/CrashgamePage.vue";
|
import CrashGamePage from "@/pages/games-pages/CrashgamePage.vue";
|
||||||
import JackpotPage from "@/pages/games-pages/JackpotPage.vue";
|
import JackpotPage from "@/pages/games-pages/JackpotPage.vue";
|
||||||
@@ -16,6 +17,7 @@ export default createRouter({
|
|||||||
{ path: '/', component: HomePage, name: 'home' },
|
{ path: '/', component: HomePage, name: 'home' },
|
||||||
{ path: '/profile', component: ProfilePage, name: 'profile' },
|
{ path: '/profile', component: ProfilePage, name: 'profile' },
|
||||||
{ path: '/game/saper', component: SapergamePage, name: 'saper' },
|
{ path: '/game/saper', component: SapergamePage, name: 'saper' },
|
||||||
|
{ path: '/game/double', component: DoublePage, name: 'double' },
|
||||||
{ path: '/game/crash', component: CrashGamePage, name: 'crash' },
|
{ path: '/game/crash', component: CrashGamePage, name: 'crash' },
|
||||||
{ path: '/game/jackpot', component: JackpotPage, name: 'jackpot' },
|
{ path: '/game/jackpot', component: JackpotPage, name: 'jackpot' },
|
||||||
{ path: '/game/jackpot/history', component: JackopthistoryPage, name: 'jackpot-history' },
|
{ path: '/game/jackpot/history', component: JackopthistoryPage, name: 'jackpot-history' },
|
||||||
|
|||||||
Reference in New Issue
Block a user