diff --git a/tabellio/pcfdb/sync.py b/tabellio/pcfdb/sync.py index 60d0996..fbf2ccc 100644 --- a/tabellio/pcfdb/sync.py +++ b/tabellio/pcfdb/sync.py @@ -475,6 +475,8 @@ class SyncFromPcfDbView(BrowserView): notify(ObjectModifiedEvent(object)) self.publish(object) + previous_count = count + # currently active deputies cursor.execute('''SELECT t_pers.id, t_pers.nom, prenom, sexe, datenaiss, t_pers.addrpriv, t_pers.addrprof1, t_pers.addrprof2, @@ -490,6 +492,7 @@ class SyncFromPcfDbView(BrowserView): t_parl.arrond = t_arrond.id %s''' % where_ts) + count = 0 polgroup_ids = {} while True: row = cursor.fetchone() @@ -519,7 +522,7 @@ class SyncFromPcfDbView(BrowserView): self.publish(object) cursor.close() - return count + return '%s|%s' % (count, previous_count) def set_person_functions(self, object, pers): cursor = self.db_connection.cursor()