[open-ils-commits] r1306 - servres/trunk/conifer/syrup/views (gfawcett)

svn at svn.open-ils.org svn at svn.open-ils.org
Sat Apr 2 21:08:47 EDT 2011


Author: gfawcett
Date: 2011-04-02 21:08:46 -0400 (Sat, 02 Apr 2011)
New Revision: 1306

Modified:
   servres/trunk/conifer/syrup/views/items.py
Log:
fix bug; could not save phys item if you do not have OPENSRF_STAFF_USERID defined.

Modified: servres/trunk/conifer/syrup/views/items.py
===================================================================
--- servres/trunk/conifer/syrup/views/items.py	2011-04-03 01:08:43 UTC (rev 1305)
+++ servres/trunk/conifer/syrup/views/items.py	2011-04-03 01:08:46 UTC (rev 1306)
@@ -378,7 +378,7 @@
                     del data['author2']
             [setattr(item, k, v) for (k,v) in data.items()]
 
-            if item.item_type == 'PHYS':
+            if item.item_type == 'PHYS' and hasattr(settings, 'OPENSRF_STAFF_USERID'): # TODO: we need an explicit 'we do updates' flag
                 update_option = request.POST.get('update_option')
                 location_option = request.POST.get('location_option')
                 modifier_option = request.POST.get('modifier_option')



More information about the open-ils-commits mailing list