-- Migration 051 — TP-LINK product images (direct URL injection)
--
-- Source: tp-link.com og:image (static CDN static.tp-link.com)
-- URL pattern: /upload/image-line/{MODEL}_{REGION}_{HW}_F_large_{TIMESTAMP}.jpg
-- All URLs verified HTTP 200 image/jpeg (2026-04-21).

-- TL-SG3452XP — 48-Port Gigabit PoE+ Smart Switch
UPDATE switches
SET image_url        = 'https://static.tp-link.com/upload/image-line/TL-SG3452XP_UN_1.0_F_large_20211223063015g.jpg',
    product_page_url = COALESCE(product_page_url, 'https://www.tp-link.com/en/business-networking/managed-switch/tl-sg3452xp/'),
    assets_scraped_at = NOW()
WHERE model = 'TL-SG3452XP'
  AND vendor_id = (SELECT id FROM vendors WHERE slug = 'tp-link');

-- TL-SX3016F — 16-Port 10GE SFP+ Smart Switch
UPDATE switches
SET image_url        = 'https://static.tp-link.com/upload/image-line/TL-SX3016F_UN_1.0_01_large_20210924060640m.jpg',
    product_page_url = COALESCE(product_page_url, 'https://www.tp-link.com/en/business-networking/managed-switch/tl-sx3016f/'),
    assets_scraped_at = NOW()
WHERE model = 'TL-SX3016F'
  AND vendor_id = (SELECT id FROM vendors WHERE slug = 'tp-link');
