Give ReferenceSetProxy model attr #23

Closed
wants to merge 5 commits into
from
@@ -18,6 +18,7 @@
class SkeletonOptions(usage.Options):
optParameters = (
("siteDir", "d", ".", "Base directory of the warp site"),
+ ("config", "c", "warpconfig", "Default config module")
)
class NodeOptions(usage.Options):
@@ -67,7 +68,11 @@ def makeService(self, options):
from warp.tools import skeleton
skeleton.createSkeleton(siteDir)
raise SystemExit
+<<<<<<< HEAD
+
+=======
+>>>>>>> brendon-master/master
configModule = reflect.namedModule(options['config'])
config = configModule.config
runtime.config.update(config)
@@ -418,6 +418,8 @@ def render_edit(self, request):
refClass = reference._relation.remote_cls
crudClass = getCrudClass(refClass)
+ print "xxxx ", noEdit
+
if self.col in noEdit or idCol in noEdit:
obj = request.store.get(refClass, objID)
return '<input type="hidden" name="warpform-%s" value="%s" />%s' % (
@@ -481,6 +483,7 @@ class ReferenceSetProxy(BaseProxy):
allowCreate = True
+
def render_view(self, request):
refset = self.obj.__class__.__dict__[self.col]
@@ -37,10 +37,11 @@ def __init__(self):
output_encoding="utf-8")
handle_login = config.get('loginHandler', self.handle_login)
+ handle_logout = config.get('logoutHandler', self.handle_logout)
self.dispatch = {
'__login__': handle_login,
- '__logout__': self.handle_logout,
+ '__logout__': handle_logout,
'_comet': self.handle_comet,
'_warp': self.handle_warpstatic,
'': self.handle_default,