[open-ils-commits] r8114 - trunk/Open-ILS/src/python/oils/utils

svn at svn.open-ils.org svn at svn.open-ils.org
Mon Nov 26 08:56:24 EST 2007


Author: erickson
Date: 2007-11-26 08:38:02 -0500 (Mon, 26 Nov 2007)
New Revision: 8114

Modified:
   trunk/Open-ILS/src/python/oils/utils/csedit.py
Log:
added a batch retrieve method

Modified: trunk/Open-ILS/src/python/oils/utils/csedit.py
===================================================================
--- trunk/Open-ILS/src/python/oils/utils/csedit.py	2007-11-25 21:11:57 UTC (rev 8113)
+++ trunk/Open-ILS/src/python/oils/utils/csedit.py	2007-11-26 13:38:02 UTC (rev 8114)
@@ -20,7 +20,7 @@
 from oils.const import *
 import re
 
-ACTIONS = ['create', 'retrieve', 'update', 'delete', 'search']
+ACTIONS = ['create', 'retrieve', 'batch_retrieve', 'update', 'delete', 'search']
 
 class CSEditor(object):
     def __init__(self, **args):
@@ -143,6 +143,11 @@
         if action == 'search':
             method = method.replace('$', '.atomic')
 
+        if action == 'batch_retrieve':
+            method = method.replace('batch_retrieve', 'search')
+            method += '.atomic'
+            arg = {'id' : arg}
+
         params = [arg];
         if len(options.keys()):
             params.append(options)



More information about the open-ils-commits mailing list