Update app.py
Browse files
app.py
CHANGED
@@ -77,11 +77,11 @@ def guardar_en_airtable(nombre, conceptos):
|
|
77 |
def agregar_aporte(nombre, conceptos):
|
78 |
if not G.has_node(nombre):
|
79 |
G.add_node(nombre, color='gray')
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
|
86 |
guardar_en_airtable(nombre, conceptos)
|
87 |
return visualizar_grafo()
|
|
|
77 |
def agregar_aporte(nombre, conceptos):
|
78 |
if not G.has_node(nombre):
|
79 |
G.add_node(nombre, color='gray')
|
80 |
+
for termino in conceptos.split():
|
81 |
+
if not G.has_node(termino):
|
82 |
+
G.add_node(termino, color='gray')
|
83 |
+
if not G.has_edge(nombre, termino):
|
84 |
+
G.add_edge(nombre, termino)
|
85 |
|
86 |
guardar_en_airtable(nombre, conceptos)
|
87 |
return visualizar_grafo()
|