modified: main_dc/yalarba/easySite/easySite/app/components/layout/Careers.vue
modified: main_dc/yalarba/easySite/easySite/app/components/layout/default.vue modified: main_dc/yalarba/easySite/easySite/app/composables/useTelegram.ts add telegram bot into vacations page easysite102.ru
This commit is contained in:
@@ -504,6 +504,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
const { sendMessageToTelegram } = useTelegram();
|
||||||
const showContactForm = ref(false)
|
const showContactForm = ref(false)
|
||||||
const loading = ref(false)
|
const loading = ref(false)
|
||||||
const toast = useToast()
|
const toast = useToast()
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
<!-- layouts/default.vue -->
|
<!-- layouts/default.vue -->
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
|
<UToast />
|
||||||
<Notifications position="top-right" />
|
<Notifications position="top-right" />
|
||||||
<slot />
|
<slot />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ export const useTelegram = () => {
|
|||||||
|
|
||||||
const formData = new FormData();
|
const formData = new FormData();
|
||||||
formData.append('chat_id', CHAT_ID);
|
formData.append('chat_id', CHAT_ID);
|
||||||
formData.append('text', `📥 Новое сообщение с сайта ValitovGaziz:\n\n${message}`);
|
formData.append('text', `📥 Новое сообщение:\n\n${message}`);
|
||||||
formData.append('parse_mode', 'HTML');
|
formData.append('parse_mode', 'HTML');
|
||||||
|
|
||||||
const response = await fetch(`https://api.telegram.org/bot${BOT_TOKEN}/sendMessage`, {
|
const response = await fetch(`https://api.telegram.org/bot${BOT_TOKEN}/sendMessage`, {
|
||||||
|
|||||||
Reference in New Issue
Block a user