Youmood: differenze tra le versioni
Da Webmobili Wiki.
| Riga 8: | Riga 8: | ||
<pre> | <pre> | ||
https://www.keliweb.it/ | |||
e7510753@gmail.com | |||
Keliweb777 | |||
CPANEL -> https://www.youmood.it:2083/ | CPANEL -> https://www.youmood.it:2083/ | ||
youmood | youmood | ||
Versione delle 11:12, 6 ago 2025
Info
https://www.youmood.it/ e https://staging.youmood.it
Dobbiamo sostituire il loro plugin per Easy Store con il nostro.
Dati Accesso
https://www.keliweb.it/ e7510753@gmail.com Keliweb777 CPANEL -> https://www.youmood.it:2083/ youmood n72v2p32g3a11as544an4a old - c9ZkJxuo?7Ay WHM -> https://www.youmood.it:2087/ root oEY&b(mOE88f WP-ADMIN: elena n72v2p32g3a11as544an4a staging -> E58K!!K1kkMVI@4Og2G0bh)R
STAGING
Modificare file hosts
# YOUMOOD - hosts per staging 194.76.119.32 staging.youmood.it
Database
Database: PROD -> youmood_db STAGING -> youmood_wp_dhwot
ESW
dati di connessione a ESW
db_connection: 61_SIGI -> PROD db_connection: 61_SIGI_TEST -> TEST codice negozio: 05 codice magazzino: CD_MAG_35 codicevenditore : VEN94050 incassi-codice_causale : 05SLD servizi-codice: T mapping-pagamenti" => ["bacs" => "BON","xpay"=> " POS2"] esw_api-domain => https://easyapi5.eswportal.it X-ApiKey: T1QiKxIUMEqL5BTQ59wc4EJ4YWJHWlY4N1VTTWYwM2NRZUZOSmc= EndPoint listino -> https://easyapi5.eswportal.it/api/v1/61_SIGI_TEST/listini/azienda/05?webgallery=false giacenze -> https://easyapi5.eswportal.it/api/v1/61_SIGI_TEST/giacenze/azienda/05?webgallery=false
ATTRIBUTI WOOCOMMERCE
Erano già presenti degli attributi con valori settati:
WooCommerce Attributi:
Altezza Brand Codice Fornitore Collezione -> vuota Colore Dimensione -> da capire da ESW che campo prende Fornitore Larghezza Lunghezza Modello -> da capire Peso_unit Stile -> CONTEMPORANEO, MODERNO Vari -> loro settaggi tipo Black Week Volume
PASSI
Da fare
- Prendere prodotti listino webgallery true e giacenze di un magazzino.
- Nome prodotto da estrapolare dallo SKU -> N_
- Categoria prodotto da ESW listino categorie ->
- "art_area": "TAVOLI E SEDIE",
- "art_categoria": "TAVOLI ALLUNGABILI",
- "art_sottocategoria": "",
Colori
- C'è un hook che viene chiamato ad ogni cambio di stato di un prodotto (Bozza -> pubblicato o Pubblicato -> cestino).
- Codice eseguito solo in caso di cambio stato del prodotto.
- Viene mandata mail di Debug a info@infocurci.com, con ID prodotto (wordpress) status vecchio + status nuovo.
- Recupera lo SKU del prodotto, ripulito, rimuovendo suffissi tipo -C_qualcosa
- Cerca i prodotti salvati con lo stesso SKU ripulito
SELECT p.ID,tt.term_id, p.ID as post_id, t.name as color_name, p.post_status
FROM wp_posts p
left join wp_term_relationships tr on (tr.object_id=p.ID)
join wp_term_taxonomy tt on (tt.term_taxonomy_id=tr.term_taxonomy_id and tt.taxonomy="pa_colore")
join wp_terms t on (t.term_id=tt.term_id), wp_postmeta pm
WHERE
p.ID = pm.post_id
and p.post_type="product"
and pm.meta_key="_sku_ripulito"
and pm.meta_value = "codice_sku_ripulito"
order by tr.term_order
- Per ciascun prodotto trovato:
- Se lo stato è publish, costruisce un array con:
- post_id
- color_name (nome del termine colore)
- term_id
- Se lo stato è publish, costruisce un array con:
Eventuale immagine associata al colore tramite ACF (get_field('color_image', 'pa_colore_' . $color->term_id)), ridimensionata con nova_resize_thumbnail.
ESEMPIO:
REFPOL-N_SONORA-C_VERDE-D_-V_ REFPOL-N_SONORA-C_CREMA-D_-V_ REFPOL-N_SONORA-C_GRIGIO-D_-V_ OTSALL-N_CLAVIUS-C_GRIGIO-D_180-V_ OTSALL-N_CLAVIUS-C_BIANCO-D_180-V_ OTSALL-N_CLAVIUS-C_BEIGE-D_180-V_