Update glmway-workflow.json

This commit is contained in:
2026-07-02 19:12:18 +00:00
parent 4566a2d77c
commit 2db63a0e2b
+93 -125
View File
@@ -1,6 +1,6 @@
{ {
"$json": { "$json": {
"updatedAt": "2026-07-02T17:25:55.366Z", "updatedAt": "2026-07-02T17:58:46.091Z",
"createdAt": "2026-06-08T13:50:12.174Z", "createdAt": "2026-06-08T13:50:12.174Z",
"id": "F1iPg8hktNAebZua", "id": "F1iPg8hktNAebZua",
"name": "GLMWay", "name": "GLMWay",
@@ -1162,7 +1162,7 @@
"parameters": { "parameters": {
"content": "## Recordatorio a nuevo ingreso 24 horas antes de la sesion\n", "content": "## Recordatorio a nuevo ingreso 24 horas antes de la sesion\n",
"height": 464, "height": 464,
"width": 2224, "width": 2080,
"color": 6 "color": 6
}, },
"type": "n8n-nodes-base.stickyNote", "type": "n8n-nodes-base.stickyNote",
@@ -1760,8 +1760,8 @@
"type": "n8n-nodes-base.gmail", "type": "n8n-nodes-base.gmail",
"typeVersion": 2.2, "typeVersion": 2.2,
"position": [ "position": [
1296, 1152,
736 752
], ],
"id": "10b2cb4e-274d-4913-9345-2c024c071f4c", "id": "10b2cb4e-274d-4913-9345-2c024c071f4c",
"name": "Send a message espanol2", "name": "Send a message espanol2",
@@ -1786,8 +1786,8 @@
"type": "n8n-nodes-base.gmail", "type": "n8n-nodes-base.gmail",
"typeVersion": 2.2, "typeVersion": 2.2,
"position": [ "position": [
1296, 1152,
944 960
], ],
"id": "1dc76989-8c58-4ffe-9e1c-5113a59d346c", "id": "1dc76989-8c58-4ffe-9e1c-5113a59d346c",
"name": "Send a message ingles2", "name": "Send a message ingles2",
@@ -1954,8 +1954,8 @@
"type": "n8n-nodes-base.wait", "type": "n8n-nodes-base.wait",
"typeVersion": 1.1, "typeVersion": 1.1,
"position": [ "position": [
1680, 1536,
1072 1088
], ],
"id": "ee5bb9bc-b8cb-493f-8463-ae0a24cf1f0d", "id": "ee5bb9bc-b8cb-493f-8463-ae0a24cf1f0d",
"name": "Wait1", "name": "Wait1",
@@ -2685,8 +2685,8 @@
"type": "n8n-nodes-base.supabase", "type": "n8n-nodes-base.supabase",
"typeVersion": 1, "typeVersion": 1,
"position": [ "position": [
1504, 1360,
848 864
], ],
"id": "ddf0a273-d3bc-44cc-888b-d789ce72ff77", "id": "ddf0a273-d3bc-44cc-888b-d789ce72ff77",
"name": "Actualizar estado a recordado", "name": "Actualizar estado a recordado",
@@ -3366,20 +3366,6 @@
}, },
"disabled": true "disabled": true
}, },
{
"parameters": {
"amount": 2
},
"type": "n8n-nodes-base.wait",
"typeVersion": 1.1,
"position": [
1264,
2272
],
"id": "f6ec4ef9-94a9-4dbb-8c44-0bbd1a6f0f87",
"name": "Wait5",
"webhookId": "09d53dc8-c92a-43d2-a47f-477c0d1317af"
},
{ {
"parameters": { "parameters": {
"operation": "update", "operation": "update",
@@ -3977,7 +3963,7 @@
}, },
{ {
"parameters": { "parameters": {
"sendTo": "={{ $json.session.correo_instructor }}", "sendTo": "=eidan.then14@gmail.com",
"subject": "Entrenamiento #TheGLMWay", "subject": "Entrenamiento #TheGLMWay",
"emailType": "text", "emailType": "text",
"message": "=Hello,\n\nI am writing to inform you that there are no registered participants for today's scheduled activity.\n\nBest regards", "message": "=Hello,\n\nI am writing to inform you that there are no registered participants for today's scheduled activity.\n\nBest regards",
@@ -3999,12 +3985,11 @@
"id": "QWNicjw1khRm5BVI", "id": "QWNicjw1khRm5BVI",
"name": "Eidan - Gmail account" "name": "Eidan - Gmail account"
} }
}, }
"disabled": true
}, },
{ {
"parameters": { "parameters": {
"sendTo": "={{ $json.session.correo_instructor }}", "sendTo": "=eidan.then14@gmail.com",
"subject": "#TheGLMWay Training", "subject": "#TheGLMWay Training",
"emailType": "text", "emailType": "text",
"message": "=Hello,\n\nThis is to inform you that, as of now, there are no people enrolled for today's activity.\n\nBest regards.\n\nThis is an automated message generated by the enrollment management system.", "message": "=Hello,\n\nThis is to inform you that, as of now, there are no people enrolled for today's activity.\n\nBest regards.\n\nThis is an automated message generated by the enrollment management system.",
@@ -4026,8 +4011,7 @@
"id": "QWNicjw1khRm5BVI", "id": "QWNicjw1khRm5BVI",
"name": "Eidan - Gmail account" "name": "Eidan - Gmail account"
} }
}, }
"disabled": true
}, },
{ {
"parameters": { "parameters": {
@@ -4698,8 +4682,8 @@
"type": "n8n-nodes-base.code", "type": "n8n-nodes-base.code",
"typeVersion": 2, "typeVersion": 2,
"position": [ "position": [
1104, 960,
736 752
], ],
"id": "67785f93-1b98-43f4-a72b-c94072ca22e6", "id": "67785f93-1b98-43f4-a72b-c94072ca22e6",
"name": "Cambiar zona horaria4" "name": "Cambiar zona horaria4"
@@ -4711,8 +4695,8 @@
"type": "n8n-nodes-base.code", "type": "n8n-nodes-base.code",
"typeVersion": 2, "typeVersion": 2,
"position": [ "position": [
1104, 960,
944 960
], ],
"id": "b574514b-817a-4798-a44b-2eae1077e118", "id": "b574514b-817a-4798-a44b-2eae1077e118",
"name": "Cambiar zona horaria5" "name": "Cambiar zona horaria5"
@@ -6226,19 +6210,19 @@
"recurrenceRules": [] "recurrenceRules": []
}, },
"node:Comenzo evento ingles": { "node:Comenzo evento ingles": {
"lastTimeChecked": "2026-07-02T17:09:26Z" "lastTimeChecked": "2026-07-02T19:00:13Z"
}, },
"node:Comenzo evento español": { "node:Comenzo evento español": {
"lastTimeChecked": "2026-07-02T17:09:26Z" "lastTimeChecked": "2026-07-02T18:59:34Z"
}, },
"node:Termino evento español": { "node:Termino evento español": {
"lastTimeChecked": "2026-07-02T17:09:26Z" "lastTimeChecked": "2026-07-02T18:59:35Z"
}, },
"node:Termino evento ingles": { "node:Termino evento ingles": {
"lastTimeChecked": "2026-07-02T17:09:26Z" "lastTimeChecked": "2026-07-02T18:59:33Z"
}, },
"node:Prueba": { "node:Prueba": {
"lastTimeChecked": "2026-07-02T17:09:26Z" "lastTimeChecked": "2026-07-02T18:59:59Z"
}, },
"node:Schedule Trigger2": { "node:Schedule Trigger2": {
"recurrenceRules": [] "recurrenceRules": []
@@ -6583,9 +6567,9 @@
} }
] ]
}, },
"versionId": "a0c36c4a-88e6-4aa0-bc8f-d89186085616", "versionId": "fd8d6eab-dabd-462e-a535-455b8571a191",
"activeVersionId": "ed31a19f-9dc8-454f-bf44-dd17635297b2", "activeVersionId": "fd8d6eab-dabd-462e-a535-455b8571a191",
"versionCounter": 3987, "versionCounter": 4008,
"triggerCount": 13, "triggerCount": 13,
"shared": [ "shared": [
{ {
@@ -6608,9 +6592,9 @@
], ],
"tags": [], "tags": [],
"activeVersion": { "activeVersion": {
"updatedAt": "2026-07-02T17:09:27.000Z", "updatedAt": "2026-07-02T17:59:04.000Z",
"createdAt": "2026-07-02T17:02:32.430Z", "createdAt": "2026-07-02T17:58:46.100Z",
"versionId": "ed31a19f-9dc8-454f-bf44-dd17635297b2", "versionId": "fd8d6eab-dabd-462e-a535-455b8571a191",
"workflowId": "F1iPg8hktNAebZua", "workflowId": "F1iPg8hktNAebZua",
"nodes": [ "nodes": [
{ {
@@ -7767,7 +7751,7 @@
"parameters": { "parameters": {
"content": "## Recordatorio a nuevo ingreso 24 horas antes de la sesion\n", "content": "## Recordatorio a nuevo ingreso 24 horas antes de la sesion\n",
"height": 464, "height": 464,
"width": 2224, "width": 2080,
"color": 6 "color": 6
}, },
"type": "n8n-nodes-base.stickyNote", "type": "n8n-nodes-base.stickyNote",
@@ -7815,7 +7799,7 @@
"parameters": { "parameters": {
"content": "## Notificacion inicial\n\nEnvia notificacion de sesion en el primer dia de trabajo del empleado", "content": "## Notificacion inicial\n\nEnvia notificacion de sesion en el primer dia de trabajo del empleado",
"height": 608, "height": 608,
"width": 3008, "width": 3216,
"color": 6 "color": 6
}, },
"type": "n8n-nodes-base.stickyNote", "type": "n8n-nodes-base.stickyNote",
@@ -8357,7 +8341,7 @@
"sendTo": "={{ $('Loop Over Items1').item.json.email }}", "sendTo": "={{ $('Loop Over Items1').item.json.email }}",
"subject": "Entrenamiento #TheGLMWay", "subject": "Entrenamiento #TheGLMWay",
"emailType": "text", "emailType": "text",
"message": "=¡Hola, GLMer!\n\nEste es un recordatorio de tu entrenamiento, donde te transmitiremos nuestra cultura, nuestro ADN y por qué somos diferentes al resto.\n\n¡Te esperamos puntual y con toda la energía para aprender!\n\nÚnete aquí:\n{{ $('Obtener sesion').item.json.enlace_reunion }}", "message": "=¡Hola, GLMer!\n\nEste es un recordatorio de tu entrenamiento, donde te transmitiremos nuestra cultura, nuestro ADN y por qué somos diferentes al resto.\n\n¡Te esperamos puntual y con toda la energía para aprender!\n\nÚnete aquí:\n\n{{ $('Obtener sesion').item.json.enlace_reunion }}",
"options": { "options": {
"appendAttribution": false "appendAttribution": false
} }
@@ -8365,8 +8349,8 @@
"type": "n8n-nodes-base.gmail", "type": "n8n-nodes-base.gmail",
"typeVersion": 2.2, "typeVersion": 2.2,
"position": [ "position": [
1296, 1152,
736 752
], ],
"id": "10b2cb4e-274d-4913-9345-2c024c071f4c", "id": "10b2cb4e-274d-4913-9345-2c024c071f4c",
"name": "Send a message espanol2", "name": "Send a message espanol2",
@@ -8383,7 +8367,7 @@
"sendTo": "={{ $('Loop Over Items1').item.json.email }}", "sendTo": "={{ $('Loop Over Items1').item.json.email }}",
"subject": "#TheGLMWay Training", "subject": "#TheGLMWay Training",
"emailType": "text", "emailType": "text",
"message": "=Hello, GLMer!\n\nThis is a reminder about your training session, where we'll share our culture, our DNA, and what makes us different from the rest.\n\nWe're looking forward to seeing you on time and ready to learn!\n\nJoin here:\n{{ $('Obtener sesion').item.json.enlace_reunion }}", "message": "=Hello, GLMer!\n\nThis is a reminder about your training session, where we'll share our culture, our DNA, and what makes us different from the rest.\n\nWe're looking forward to seeing you on time and ready to learn!\n\nJoin here:\n\n{{ $('Obtener sesion').item.json.enlace_reunion }}",
"options": { "options": {
"appendAttribution": false "appendAttribution": false
} }
@@ -8391,8 +8375,8 @@
"type": "n8n-nodes-base.gmail", "type": "n8n-nodes-base.gmail",
"typeVersion": 2.2, "typeVersion": 2.2,
"position": [ "position": [
1296, 1152,
944 960
], ],
"id": "1dc76989-8c58-4ffe-9e1c-5113a59d346c", "id": "1dc76989-8c58-4ffe-9e1c-5113a59d346c",
"name": "Send a message ingles2", "name": "Send a message ingles2",
@@ -8559,8 +8543,8 @@
"type": "n8n-nodes-base.wait", "type": "n8n-nodes-base.wait",
"typeVersion": 1.1, "typeVersion": 1.1,
"position": [ "position": [
1680, 1536,
1072 1088
], ],
"id": "ee5bb9bc-b8cb-493f-8463-ae0a24cf1f0d", "id": "ee5bb9bc-b8cb-493f-8463-ae0a24cf1f0d",
"name": "Wait1", "name": "Wait1",
@@ -9290,8 +9274,8 @@
"type": "n8n-nodes-base.supabase", "type": "n8n-nodes-base.supabase",
"typeVersion": 1, "typeVersion": 1,
"position": [ "position": [
1504, 1360,
848 864
], ],
"id": "ddf0a273-d3bc-44cc-888b-d789ce72ff77", "id": "ddf0a273-d3bc-44cc-888b-d789ce72ff77",
"name": "Actualizar estado a recordado", "name": "Actualizar estado a recordado",
@@ -9971,20 +9955,6 @@
}, },
"disabled": true "disabled": true
}, },
{
"parameters": {
"amount": 2
},
"type": "n8n-nodes-base.wait",
"typeVersion": 1.1,
"position": [
1264,
2272
],
"id": "f6ec4ef9-94a9-4dbb-8c44-0bbd1a6f0f87",
"name": "Wait5",
"webhookId": "09d53dc8-c92a-43d2-a47f-477c0d1317af"
},
{ {
"parameters": { "parameters": {
"operation": "update", "operation": "update",
@@ -10528,30 +10498,6 @@
} }
} }
}, },
{
"parameters": {
"operation": "getAll",
"tableId": "sesiones_glmway",
"returnAll": true,
"filters": {
"conditions": []
}
},
"type": "n8n-nodes-base.supabase",
"typeVersion": 1,
"position": [
-176,
2144
],
"id": "d34e225b-25bb-4a0a-845c-b9e274529000",
"name": "Get many rows",
"credentials": {
"supabaseApi": {
"id": "2PlsR6rpK7rQTIEn",
"name": "Sofia test - Supabase account"
}
}
},
{ {
"parameters": { "parameters": {
"jsCode": "const months = [\"January\",\"February\",\"March\",\"April\",\"May\",\"June\",\"July\",\"August\",\"September\",\"October\",\"November\",\"December\"];\n\nfunction formatearFecha(dateTimeStr) {\n if (!dateTimeStr) return null;\n const datePart = dateTimeStr.split('T')[0];\n const [year, month, day] = datePart.split('-');\n return `${parseInt(day, 10)} ${months[parseInt(month, 10) - 1]}`;\n}\n\nfunction detectarIdioma(summary) {\n if (!summary) return null;\n if (summary.includes(\"#TheGLMWay Training\")) return \"EN\";\n if (summary.includes(\"Entrenamiento #TheGLMWay\")) return \"ES\";\n return null;\n}\n\nfunction formatearHora(dateTimeStr) {\n if (!dateTimeStr) return null;\n const timePart = dateTimeStr.split('T')[1];\n if (!timePart) return null;\n return timePart.substring(0, 5);\n}\n\nconst output = [];\n\nfor (const item of $input.all()) {\n const event = item.json;\n\n const startRaw = event.start?.dateTime || event.start?.date;\n const endRaw = event.end?.dateTime || event.end?.date;\n const url = event.conferenceData?.entryPoints?.[0]?.uri || null;\n const idioma = detectarIdioma(event.summary);\n\n // Ignorar eventos vacíos o sin datos esenciales\n if (!event.summary || !startRaw) {\n console.log(\"Evento ignorado (vacío):\", JSON.stringify(event));\n continue;\n }\n\n output.push({\n json: {\n id: event.id,\n titulo: event.summary,\n idioma: idioma,\n fecha: formatearFecha(startRaw),\n hora_inicio: formatearHora(startRaw),\n hora_fin: formatearHora(endRaw),\n url: url,\n descripcion: event.description || null\n }\n });\n}\n\nconsole.log(`Sesiones procesadas: ${output.length}`);\nreturn output;\n\n// Agrega esto antes del return output\nconst resumen = output.map(i => ({\n meet_id: i.json.meet_id,\n titulo: i.json.titulo,\n fecha_sesion: i.json.fecha_sesion,\n hora_inicio: i.json.hora_inicio,\n hora_fin: i.json.hora_fin,\n enlace_reunion: i.json.enlace_reunion,\n idioma: i.json.idioma\n}));\nconsole.log(JSON.stringify(resumen));" "jsCode": "const months = [\"January\",\"February\",\"March\",\"April\",\"May\",\"June\",\"July\",\"August\",\"September\",\"October\",\"November\",\"December\"];\n\nfunction formatearFecha(dateTimeStr) {\n if (!dateTimeStr) return null;\n const datePart = dateTimeStr.split('T')[0];\n const [year, month, day] = datePart.split('-');\n return `${parseInt(day, 10)} ${months[parseInt(month, 10) - 1]}`;\n}\n\nfunction detectarIdioma(summary) {\n if (!summary) return null;\n if (summary.includes(\"#TheGLMWay Training\")) return \"EN\";\n if (summary.includes(\"Entrenamiento #TheGLMWay\")) return \"ES\";\n return null;\n}\n\nfunction formatearHora(dateTimeStr) {\n if (!dateTimeStr) return null;\n const timePart = dateTimeStr.split('T')[1];\n if (!timePart) return null;\n return timePart.substring(0, 5);\n}\n\nconst output = [];\n\nfor (const item of $input.all()) {\n const event = item.json;\n\n const startRaw = event.start?.dateTime || event.start?.date;\n const endRaw = event.end?.dateTime || event.end?.date;\n const url = event.conferenceData?.entryPoints?.[0]?.uri || null;\n const idioma = detectarIdioma(event.summary);\n\n // Ignorar eventos vacíos o sin datos esenciales\n if (!event.summary || !startRaw) {\n console.log(\"Evento ignorado (vacío):\", JSON.stringify(event));\n continue;\n }\n\n output.push({\n json: {\n id: event.id,\n titulo: event.summary,\n idioma: idioma,\n fecha: formatearFecha(startRaw),\n hora_inicio: formatearHora(startRaw),\n hora_fin: formatearHora(endRaw),\n url: url,\n descripcion: event.description || null\n }\n });\n}\n\nconsole.log(`Sesiones procesadas: ${output.length}`);\nreturn output;\n\n// Agrega esto antes del return output\nconst resumen = output.map(i => ({\n meet_id: i.json.meet_id,\n titulo: i.json.titulo,\n fecha_sesion: i.json.fecha_sesion,\n hora_inicio: i.json.hora_inicio,\n hora_fin: i.json.hora_fin,\n enlace_reunion: i.json.enlace_reunion,\n idioma: i.json.idioma\n}));\nconsole.log(JSON.stringify(resumen));"
@@ -10606,10 +10552,10 @@
}, },
{ {
"parameters": { "parameters": {
"sendTo": "eidan.then14@gmail.com", "sendTo": "=eidan.then14@gmail.com",
"subject": "Entrenamiento #TheGLMWay", "subject": "Entrenamiento #TheGLMWay",
"emailType": "text", "emailType": "text",
"message": "=Hola,\n\nTe escribo para informarte que, hasta el momento, no hay personas inscritas para la actividad de hoy.\n\nSaludos.\n\nEste es un mensaje automático generado por el sistema de gestión de inscripciones.", "message": "=Hello,\n\nI am writing to inform you that there are no registered participants for today's scheduled activity.\n\nBest regards",
"options": { "options": {
"appendAttribution": false "appendAttribution": false
} }
@@ -10628,12 +10574,11 @@
"id": "QWNicjw1khRm5BVI", "id": "QWNicjw1khRm5BVI",
"name": "Eidan - Gmail account" "name": "Eidan - Gmail account"
} }
}, }
"disabled": true
}, },
{ {
"parameters": { "parameters": {
"sendTo": "eidan.then14@gmail.com", "sendTo": "=eidan.then14@gmail.com",
"subject": "#TheGLMWay Training", "subject": "#TheGLMWay Training",
"emailType": "text", "emailType": "text",
"message": "=Hello,\n\nThis is to inform you that, as of now, there are no people enrolled for today's activity.\n\nBest regards.\n\nThis is an automated message generated by the enrollment management system.", "message": "=Hello,\n\nThis is to inform you that, as of now, there are no people enrolled for today's activity.\n\nBest regards.\n\nThis is an automated message generated by the enrollment management system.",
@@ -10655,8 +10600,7 @@
"id": "QWNicjw1khRm5BVI", "id": "QWNicjw1khRm5BVI",
"name": "Eidan - Gmail account" "name": "Eidan - Gmail account"
} }
}, }
"disabled": true
}, },
{ {
"parameters": { "parameters": {
@@ -10670,7 +10614,7 @@
"conditions": [ "conditions": [
{ {
"id": "df25aa3e-d48f-4e52-ae1f-47678e954d52", "id": "df25aa3e-d48f-4e52-ae1f-47678e954d52",
"leftValue": "={{ $json.session.idioma }}", "leftValue": "={{ $('Obtener sesion1').item.json.idioma }}",
"rightValue": "EN", "rightValue": "EN",
"operator": { "operator": {
"type": "string", "type": "string",
@@ -11182,7 +11126,7 @@
}, },
{ {
"parameters": { "parameters": {
"sendTo": "eidan.then14@gmail.com", "sendTo": "=eidan.then14@gmail.com",
"subject": "Entrenamiento #TheGLMWay", "subject": "Entrenamiento #TheGLMWay",
"emailType": "text", "emailType": "text",
"message": "=<div style=\"font-family: 'Segoe UI', Arial, sans-serif; background-color:#f4f6f8; padding:24px;\">\n <table role=\"presentation\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"max-width:600px;margin:0 auto;background:#ffffff;border-radius:12px;overflow:hidden;box-shadow:0 2px 8px rgba(0,0,0,0.08);\">\n\n <!-- HEADER -->\n <tr>\n <td style=\"background:linear-gradient(135deg,#4f46e5,#7c3aed);padding:28px 32px;\">\n <p style=\"margin:0;color:#e0e7ff;font-size:13px;letter-spacing:1px;text-transform:uppercase;\">Sesión de entrenamiento</p>\n <h1 style=\"margin:6px 0 0;color:#ffffff;font-size:22px;\">{{ $json.session.titulo }}</h1>\n </td>\n </tr>\n\n <!-- INFO SESION -->\n <tr>\n <td style=\"padding:20px 32px;background:#f9fafb;border-bottom:1px solid #eee;\">\n <p style=\"margin:0 0 4px;font-size:14px;color:#374151;\">📅 <strong>{{ $json.session.fecha_sesion }}</strong> &nbsp;|&nbsp; 🕒 {{ $json.session.hora_inicio }} - {{ $json.session.hora_fin }}</p>\n <p style=\"margin:0 0 4px;font-size:14px;color:#374151;\">🎤 Instructor: <strong>{{ $json.session.instructor }}</strong></p>\n <p style=\"margin:0;font-size:14px;\"><a href=\"{{ $json.session.enlace_reunion }}\" style=\"color:#4f46e5;text-decoration:none;font-weight:600;\">🔗 Unirse a la reunión</a></p>\n </td>\n </tr>\n\n <!-- SALUDO -->\n <tr>\n <td style=\"padding:24px 32px 8px;\">\n <p style=\"margin:0;color:#111827;font-size:15px;\">Hola,</p>\n <p style=\"margin:8px 0 0;color:#374151;font-size:15px;\">Aquí tienes el listado de participantes para la sesión de hoy:</p>\n </td>\n </tr>\n\n <!-- LISTADO POR PAIS -->\n <tr>\n <td style=\"padding:8px 32px 24px;\">\n {{ (function(){\n const data = $json.session.participantes || {};\n const colores = ['#4f46e5','#0891b2','#059669','#d97706','#dc2626','#7c3aed','#db2777'];\n let i = 0;\n let html = '';\n\n for (const pais in data) {\n const nombrePais = pais && pais.trim() !== '' ? pais : 'Sin país asignado';\n const color = colores[i % colores.length];\n i++;\n const lista = data[pais];\n\n html += `\n <table role=\"presentation\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"margin-bottom:18px;border:1px solid #e5e7eb;border-radius:10px;overflow:hidden;\">\n <tr>\n <td style=\"background:${color}15;border-left:4px solid ${color};padding:10px 16px;\">\n <span style=\"font-size:14px;font-weight:700;color:${color};\">${nombrePais}</span>\n <span style=\"font-size:12px;color:#6b7280;margin-left:6px;\">(${lista.length} participante${lista.length !== 1 ? 's' : ''})</span>\n </td>\n </tr>`;\n\n lista.forEach((p, idx) => {\n const bg = idx % 2 === 0 ? '#ffffff' : '#fafafa';\n html += `\n <tr>\n <td style=\"padding:10px 16px;background:${bg};border-top:1px solid #f0f0f0;\">\n <p style=\"margin:0;font-size:14px;color:#111827;font-weight:600;\">${p.nombre}</p>\n <p style=\"margin:2px 0 0;font-size:13px;color:#6b7280;\">${p.correo}${p.division ? ' &nbsp;•&nbsp; ' + p.division : ''}${p.departamento ? ' &nbsp;•&nbsp; ' + p.departamento : ''}</p>\n </td>\n </tr>`;\n });\n\n html += `</table>`;\n }\n\n return html || '<p style=\"color:#6b7280;\">No hay participantes registrados.</p>';\n })() }}\n </td>\n </tr>\n\n <!-- FOOTER -->\n <tr>\n <td style=\"padding:20px 32px;background:#f9fafb;border-top:1px solid #eee;\">\n <p style=\"margin:0;font-size:13px;color:#9ca3af;\">Saludos,<br>#TheGLMWay</p>\n </td>\n </tr>\n\n </table>\n</div>", "message": "=<div style=\"font-family: 'Segoe UI', Arial, sans-serif; background-color:#f4f6f8; padding:24px;\">\n <table role=\"presentation\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"max-width:600px;margin:0 auto;background:#ffffff;border-radius:12px;overflow:hidden;box-shadow:0 2px 8px rgba(0,0,0,0.08);\">\n\n <!-- HEADER -->\n <tr>\n <td style=\"background:linear-gradient(135deg,#4f46e5,#7c3aed);padding:28px 32px;\">\n <p style=\"margin:0;color:#e0e7ff;font-size:13px;letter-spacing:1px;text-transform:uppercase;\">Sesión de entrenamiento</p>\n <h1 style=\"margin:6px 0 0;color:#ffffff;font-size:22px;\">{{ $json.session.titulo }}</h1>\n </td>\n </tr>\n\n <!-- INFO SESION -->\n <tr>\n <td style=\"padding:20px 32px;background:#f9fafb;border-bottom:1px solid #eee;\">\n <p style=\"margin:0 0 4px;font-size:14px;color:#374151;\">📅 <strong>{{ $json.session.fecha_sesion }}</strong> &nbsp;|&nbsp; 🕒 {{ $json.session.hora_inicio }} - {{ $json.session.hora_fin }}</p>\n <p style=\"margin:0 0 4px;font-size:14px;color:#374151;\">🎤 Instructor: <strong>{{ $json.session.instructor }}</strong></p>\n <p style=\"margin:0;font-size:14px;\"><a href=\"{{ $json.session.enlace_reunion }}\" style=\"color:#4f46e5;text-decoration:none;font-weight:600;\">🔗 Unirse a la reunión</a></p>\n </td>\n </tr>\n\n <!-- SALUDO -->\n <tr>\n <td style=\"padding:24px 32px 8px;\">\n <p style=\"margin:0;color:#111827;font-size:15px;\">Hola,</p>\n <p style=\"margin:8px 0 0;color:#374151;font-size:15px;\">Aquí tienes el listado de participantes para la sesión de hoy:</p>\n </td>\n </tr>\n\n <!-- LISTADO POR PAIS -->\n <tr>\n <td style=\"padding:8px 32px 24px;\">\n {{ (function(){\n const data = $json.session.participantes || {};\n const colores = ['#4f46e5','#0891b2','#059669','#d97706','#dc2626','#7c3aed','#db2777'];\n let i = 0;\n let html = '';\n\n for (const pais in data) {\n const nombrePais = pais && pais.trim() !== '' ? pais : 'Sin país asignado';\n const color = colores[i % colores.length];\n i++;\n const lista = data[pais];\n\n html += `\n <table role=\"presentation\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"margin-bottom:18px;border:1px solid #e5e7eb;border-radius:10px;overflow:hidden;\">\n <tr>\n <td style=\"background:${color}15;border-left:4px solid ${color};padding:10px 16px;\">\n <span style=\"font-size:14px;font-weight:700;color:${color};\">${nombrePais}</span>\n <span style=\"font-size:12px;color:#6b7280;margin-left:6px;\">(${lista.length} participante${lista.length !== 1 ? 's' : ''})</span>\n </td>\n </tr>`;\n\n lista.forEach((p, idx) => {\n const bg = idx % 2 === 0 ? '#ffffff' : '#fafafa';\n html += `\n <tr>\n <td style=\"padding:10px 16px;background:${bg};border-top:1px solid #f0f0f0;\">\n <p style=\"margin:0;font-size:14px;color:#111827;font-weight:600;\">${p.nombre}</p>\n <p style=\"margin:2px 0 0;font-size:13px;color:#6b7280;\">${p.correo}${p.division ? ' &nbsp;•&nbsp; ' + p.division : ''}${p.departamento ? ' &nbsp;•&nbsp; ' + p.departamento : ''}</p>\n </td>\n </tr>`;\n });\n\n html += `</table>`;\n }\n\n return html || '<p style=\"color:#6b7280;\">No hay participantes registrados.</p>';\n })() }}\n </td>\n </tr>\n\n <!-- FOOTER -->\n <tr>\n <td style=\"padding:20px 32px;background:#f9fafb;border-top:1px solid #eee;\">\n <p style=\"margin:0;font-size:13px;color:#9ca3af;\">Saludos,<br>#TheGLMWay</p>\n </td>\n </tr>\n\n </table>\n</div>",
@@ -11209,7 +11153,7 @@
}, },
{ {
"parameters": { "parameters": {
"sendTo": "eidan.then14@gmail.com", "sendTo": "={{ $json.session.correo_instructor }}",
"subject": "#TheGLMWay Training", "subject": "#TheGLMWay Training",
"emailType": "text", "emailType": "text",
"message": "=Hello,\n\nThis is to inform you that, as of now, there are no people enrolled for today's activity.\n\nBest regards.\n\nThis is an automated message generated by the enrollment management system.", "message": "=Hello,\n\nThis is to inform you that, as of now, there are no people enrolled for today's activity.\n\nBest regards.\n\nThis is an automated message generated by the enrollment management system.",
@@ -11327,8 +11271,8 @@
"type": "n8n-nodes-base.code", "type": "n8n-nodes-base.code",
"typeVersion": 2, "typeVersion": 2,
"position": [ "position": [
1104, 960,
736 752
], ],
"id": "67785f93-1b98-43f4-a72b-c94072ca22e6", "id": "67785f93-1b98-43f4-a72b-c94072ca22e6",
"name": "Cambiar zona horaria4" "name": "Cambiar zona horaria4"
@@ -11340,8 +11284,8 @@
"type": "n8n-nodes-base.code", "type": "n8n-nodes-base.code",
"typeVersion": 2, "typeVersion": 2,
"position": [ "position": [
1104, 960,
944 960
], ],
"id": "b574514b-817a-4798-a44b-2eae1077e118", "id": "b574514b-817a-4798-a44b-2eae1077e118",
"name": "Cambiar zona horaria5" "name": "Cambiar zona horaria5"
@@ -11373,6 +11317,30 @@
"name": "Sofia test - Supabase account" "name": "Sofia test - Supabase account"
} }
} }
},
{
"parameters": {
"operation": "getAll",
"tableId": "sesiones_glmway",
"returnAll": true,
"filters": {
"conditions": []
}
},
"type": "n8n-nodes-base.supabase",
"typeVersion": 1,
"position": [
-176,
2144
],
"id": "d34e225b-25bb-4a0a-845c-b9e274529000",
"name": "Obtener sesion1",
"credentials": {
"supabaseApi": {
"id": "2PlsR6rpK7rQTIEn",
"name": "Sofia test - Supabase account"
}
}
} }
], ],
"connections": { "connections": {
@@ -12453,7 +12421,7 @@
"main": [ "main": [
[ [
{ {
"node": "Get many rows", "node": "Obtener sesion1",
"type": "main", "type": "main",
"index": 0 "index": 0
} }
@@ -12471,17 +12439,6 @@
] ]
] ]
}, },
"Get many rows": {
"main": [
[
{
"node": "Calcular sesion mas cercana4",
"type": "main",
"index": 0
}
]
]
},
"Es espanol o ingles": { "Es espanol o ingles": {
"main": [ "main": [
[ [
@@ -12807,18 +12764,29 @@
} }
] ]
] ]
},
"Obtener sesion1": {
"main": [
[
{
"node": "Calcular sesion mas cercana4",
"type": "main",
"index": 0
}
]
]
} }
}, },
"authors": "Eidan Then", "authors": "Eidan Then",
"name": "Version ed31a19f", "name": "Version fd8d6eab",
"description": "", "description": "",
"autosaved": true, "autosaved": true,
"workflowPublishHistory": [ "workflowPublishHistory": [
{ {
"createdAt": "2026-07-02T17:09:27.085Z", "createdAt": "2026-07-02T17:59:04.569Z",
"id": 2280, "id": 2294,
"workflowId": "F1iPg8hktNAebZua", "workflowId": "F1iPg8hktNAebZua",
"versionId": "ed31a19f-9dc8-454f-bf44-dd17635297b2", "versionId": "fd8d6eab-dabd-462e-a535-455b8571a191",
"event": "activated", "event": "activated",
"userId": "de14e7e5-491b-4983-abb2-f88af42e92fd" "userId": "de14e7e5-491b-4983-abb2-f88af42e92fd"
} }