Skip to Content

Wago 16mm 3-wire through connector Red

(0 review)
110.00 110.00 (Tax included)

  • Brand
  • Wire Size
Please Log in to see buy options.
Terms and Conditions
 
Shipping: 2-3 Business Days

Internal Reference: 2016-1302

Specifications

Make
Brand Wago
Others
Wire Size 16mm²

Pictures and images  are for demonstration purposes only. The real product appearance may differ from the illustrated image.

// ============================================================================= // Safesun Telegram Chat Button - JavaScript Injection (Option B) // ============================================================================= // This script can be injected via Odoo Website Editor > Custom Code // Works for ALL products - extracts product code from the DOM // // Installation: // 1. Go to Odoo Website > Configuration > Settings // 2. Scroll to "Custom Code" section // 3. Add this code to "Header Code" or "Footer Code" // 4. Save // // Or inject via Website Editor on individual pages // ============================================================================= (function() { 'use strict'; // Bot configuration const BOT_CONFIG = { botName: 'FlameblockBot', botUsername: '@FlameblockBot', defaultFallbackProducts: [ { code: 'FB_2l', name: 'Flameblock 2L', price: 'R2,277' }, { code: 'FB_6l', name: 'Flameblock 6L', price: 'R3,312' }, { code: 'FB_9l', name: 'Flameblock 9L', price: 'R4,781' } ] }; /** * Extract product information from the current page */ function getProductInfo() { const info = { productId: null, defaultCode: null, productName: null, productPrice: null }; // Method 1: Check data attributes const productEl = document.querySelector('[data-product-id]'); if (productEl) { info.productId = productEl.dataset.productId; info.defaultCode = productEl.dataset.productDefaultCode || null; } // Method 2: Check input fields (Odoo often has these) const templateInput = document.querySelector('input[name="product_template_id"]'); if (templateInput && !info.productId) { info.productId = templateInput.value; } // Method 3: Check URL path const urlMatch = window.location.pathname.match(/\/shop\/([^\/]+)-(\d+)/); if (urlMatch && !info.productId) { info.productId = urlMatch[2]; } // Method 4: Extract product name from page const titleEl = document.querySelector('h1[data-oe-expression="product.name"]') || document.querySelector('h1[itemprop="name"]') || document.querySelector('#product_details h1') || document.querySelector('h1'); if (titleEl) { info.productName = titleEl.textContent.trim(); } // Method 5: Extract price const priceEl = document.querySelector('.oe_price') || document.querySelector('[itemprop="price"]') || document.querySelector('.product_price .oe_currency_value'); if (priceEl) { info.productPrice = priceEl.textContent.trim(); } // Build the deep link parameter if (info.defaultCode) { info.deepLinkParam = 'product_' + info.defaultCode; } else if (info.productId) { info.deepLinkParam = 'product_id_' + info.productId; } else { info.deepLinkParam = 'generic_' + encodeURIComponent(window.location.pathname); } return info; } /** * Create and inject the Telegram button */ function injectTelegramButton() { // Check if we're on a product page if (!document.querySelector('.oe_website_sale') && !document.querySelector('#product_details') && !document.querySelector('[data-oe-model="product.template"]')) { return; // Not on a product page } // Check if button already exists if (document.querySelector('.safesun-telegram-chat')) { return; } const product = getProductInfo(); const telegramUrl = 'https://t.me/' + BOT_CONFIG.botName + '?start=' + product.deepLinkParam; // Create button container const container = document.createElement('div'); container.className = 'safesun-telegram-chat mt-3 mb-3'; container.style.cssText = 'border-top: 1px solid #dee2e6; padding-top: 15px;'; // Create the button const button = document.createElement('a'); button.href = telegramUrl; button.target = '_blank'; button.className = 'btn btn-primary btn-lg w-100 d-flex align-items-center justify-content-center'; button.style.cssText = 'background-color: #0088cc; border-color: #0088cc; color: white;'; button.innerHTML = ` 💬 Chat oor ${product.productName || 'hierdie produk'} `; // Add hover effect button.addEventListener('mouseenter', function() { this.style.backgroundColor = '#0077b3'; }); button.addEventListener('mouseleave', function() { this.style.backgroundColor = '#0088cc'; }); // Create subtitle const subtitle = document.createElement('p'); subtitle.className = 'text-muted text-center mt-2 mb-0'; subtitle.style.cssText = 'font-size: 0.85em;'; subtitle.innerHTML = ` Kry hulp en 'n kwotasie via Telegram `; // Add product info if available (for debugging) if (product.productPrice) { const priceInfo = document.createElement('p'); priceInfo.className = 'text-center mt-1 mb-0'; priceInfo.style.cssText = 'font-size: 0.8em; color: #28a745;'; priceInfo.innerHTML = `💰 Prys: ${product.productPrice}`; container.appendChild(priceInfo); } container.appendChild(button); container.appendChild(subtitle); // Find insertion point const insertionPoints = [ document.querySelector('#add_to_cart'), document.querySelector('.css_add_cart'), document.querySelector('.oe_price'), document.querySelector('h1[data-oe-expression="product.name"]'), document.querySelector('#product_details .col-md-6:last-child') ]; for (const point of insertionPoints) { if (point) { point.parentElement.insertBefore(container, point.nextSibling); console.log('[Safesun Telegram] Button injected successfully'); return; } } console.log('[Safesun Telegram] Could not find insertion point'); } /** * Initialize when DOM is ready */ function init() { // Wait for Odoo to be ready if (window.odoo && window.odoo.__DEBUG__) { injectTelegramButton(); } else { // Fallback: run after DOM is loaded if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', injectTelegramButton); } else { injectTelegramButton(); } } // Re-inject on dynamic content changes (for Odoo's SPA navigation) const observer = new MutationObserver(function(mutations) { if (!document.querySelector('.safesun-telegram-chat')) { injectTelegramButton(); } }); observer.observe(document.body, { childList: true, subtree: true }); } // Run initialization init(); // Also run when Odoo finishes loading window.addEventListener('load', function() { setTimeout(injectTelegramButton, 1000); }); })();