[Erp5-report] r18558 - /erp5/trunk/products/ERP5Type/XMLMatrix.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Sun Dec 30 09:38:51 CET 2007
Author: vincent
Date: Sun Dec 30 09:38:51 2007
New Revision: 18558
URL: http://svn.erp5.org?rev=18558&view=rev
Log:
Revert commit 18557.
Modified:
erp5/trunk/products/ERP5Type/XMLMatrix.py
Modified: erp5/trunk/products/ERP5Type/XMLMatrix.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/XMLMatrix.py?rev=18558&r1=18557&r2=18558&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/XMLMatrix.py (original)
+++ erp5/trunk/products/ERP5Type/XMLMatrix.py Sun Dec 30 09:38:51 2007
@@ -212,22 +212,20 @@
# List all valid cell ids for current base_id.
object_id_list = []
- base_id_len = len(base_id)
- for object_id in self.objectIds():
- object_id_list = object_id.split('_')
- if len(object_id_list) > 1 and object_id_list.pop(0) == base_id:
- try:
- # Check that all '_'-separated fields are of int type (once
- # base_id is poped).
- [int(x) for x in object_id_list]
- self._getOb(object_id) # If the object was created
- # during this transaction,
- # then we do not need to
- # work on it
- except (ValueError, KeyError):
- pass
- else:
- object_id_list.append(object_id)
+ for obj in self.objectValues():
+ object_id = obj.getId()
+ if object_id.find(base_id) == 0:
+ # Check that all '_'-separated fields are of int type.
+ if (object_id) > len(base_id):
+ try:
+ int(object_id[len(base_id)+1:].split('_')[0])
+ test = self._getOb(object_id) # If the object was created
+ # during this transaction,
+ # then we do not need to
+ # work on it
+ object_id_list.append(object_id)
+ except (ValueError, KeyError):
+ pass
# Prepend 'temp_' to all cells, to avoid id conflicts while renaming.
for object_id in object_id_list:
More information about the Erp5-report
mailing list