File tree Expand file tree Collapse file tree 1 file changed +2
-10
lines changed
Expand file tree Collapse file tree 1 file changed +2
-10
lines changed Original file line number Diff line number Diff line change @@ -411,14 +411,6 @@ def view_check(self):
411411 raise Unauthorised ("view" , self ._classname ,
412412 translator = self ._client .translator )
413413
414- def create_check (self ):
415- ''' Raise the Unauthorised exception if the user's not permitted to
416- create items of this class.
417- '''
418- if not self .is_create_ok ():
419- raise Unauthorised ("create" , self ._classname ,
420- translator = self ._client .translator )
421-
422414 def edit_check (self ):
423415 ''' Raise the Unauthorised exception if the user's not permitted to
424416 edit items of this class.
@@ -455,12 +447,12 @@ def is_view_ok(self):
455447 if self ._db .security .hasPermission ('View' , self ._client .userid ,
456448 self ._classname ):
457449 return 1
458- return self .is_create_ok ()
450+ return self .is_edit_ok ()
459451
460452 def is_only_view_ok (self ):
461453 ''' Is the user only allowed to View (ie. not Create) the current class?
462454 '''
463- return self .is_view_ok () and not self .is_create_ok ()
455+ return self .is_view_ok () and not self .is_edit_ok ()
464456
465457 def __repr__ (self ):
466458 return '<HTMLClass(0x%x) %s>' % (id (self ), self .classname )
You can’t perform that action at this time.
0 commit comments