send telegram

This commit is contained in:
2026-04-18 18:49:32 +03:00
parent 89907284de
commit cbce559fb4
4 changed files with 5 additions and 2 deletions

View File

@@ -22,7 +22,6 @@ const mobileToggle = document.getElementById('mobileToggle')
const orderSuccess = document.getElementById('orderSuccess')
const contactSuccess = document.getElementById('contactSuccess')
const wooCommerceConfig = window.test1WooCommerce || null
const leadFormConfig = window.test1LeadForm || null
const cartPageUrl = (wooCommerceConfig && wooCommerceConfig.cartUrl) ? wooCommerceConfig.cartUrl : '/cart/'
const checkoutPageUrl = (wooCommerceConfig && wooCommerceConfig.checkoutUrl) ? wooCommerceConfig.checkoutUrl : '/checkout/'
const cartPanel = cartDrawer?.querySelector('.cart-panel')
@@ -147,6 +146,8 @@ const mobileToggle = document.getElementById('mobileToggle')
formElement.addEventListener('submit', async event => {
event.preventDefault()
const leadFormConfig = window.test1LeadForm || null
if (!leadFormConfig?.ajaxUrl || !leadFormConfig?.action || !leadFormConfig?.nonce) {
window.alert('Форма временно недоступна. Обновите страницу и попробуйте снова.')
return