[cpif] r397 - in trunk: backend frontend-web

svn at argo.es svn at argo.es
Mon Oct 15 21:10:45 CEST 2007


Author: jcea
Date: Mon Oct 15 21:10:44 2007
New Revision: 397

Log:
El usuario destino tambien debe ser notificado con
los nuevos mensajes en ese hilo.



Modified:
   trunk/backend/database.py
   trunk/backend/upgrade.py
   trunk/frontend-web/url_nuevo_hilo_privado_POST.py

Modified: trunk/backend/database.py
==============================================================================
--- trunk/backend/database.py	(original)
+++ trunk/backend/database.py	Mon Oct 15 21:10:44 2007
@@ -1,7 +1,7 @@
 # $Id$
 
 
-VERSION_DB="2007101502"
+VERSION_DB="2007101504"
 
 import globales
 

Modified: trunk/backend/upgrade.py
==============================================================================
--- trunk/backend/upgrade.py	(original)
+++ trunk/backend/upgrade.py	Mon Oct 15 21:10:44 2007
@@ -431,3 +431,15 @@
 
     conn.commit()
 
+  if root["version del foro"]=="2007101503" :
+    print "Actualizando la base de datos: 2007101503 -> 2007101504"
+    root["version del foro"]="2007101504"
+
+    import database
+    for nick,usuario in root["usuarios"]["usuarios"].items() :
+      metatag_privado=usuario["metatag_privado"]
+      for hilo,dummy in root["metatags"]["metatags"][metatag_privado]["TS2hilo"].values() :
+        database.toggle_monitor_thread(conn,nick,hilo)
+
+    conn.commit()
+

Modified: trunk/frontend-web/url_nuevo_hilo_privado_POST.py
==============================================================================
--- trunk/frontend-web/url_nuevo_hilo_privado_POST.py	(original)
+++ trunk/frontend-web/url_nuevo_hilo_privado_POST.py	Mon Oct 15 21:10:44 2007
@@ -44,5 +44,6 @@
     return (200,{"Content-Type":"text/plain; charset=utf-8"},error)
   num_thread,dummy=database.mensaje_add(conn,texto,texto2,usuario,titulo=titulo,metatags=(u2["metatag_privado"],u["metatag_privado"]))
   database.toggle_monitor_thread(conn,usuario,num_thread)
+  database.toggle_monitor_thread(conn,usuario_pedido_normalizado,num_thread)
   return (302,{"Location":"/indice/%s" %u2["metatag_privado"]},"")
 



More information about the cpif mailing list