Re: [Zope3-Users] How to allow one user to access only his object

2005-10-21 Thread TAHARA Yusei
On Thu, 20 Oct 2005 22:19:58 -0700 Naotoshi Seo [EMAIL PROTECTED] wrote: This is easy problem in normal web application. Scripts which receive POST just print out new html (in this case Classname.post). However, I would like to use browser:editview and I have only idea, redirecting, to show

Re: [Zope3-Users] How to allow one user to access only his object

2005-10-21 Thread Naotoshi Seo
Hi. class MessageTraverser: implements(IPublishTraverse) __used_for__ = IMessage def publishTraverse(self, request, name): if name == 'edit.html': # verify password and return a message or raise NotFoundError. How do I pass POSTed value to publishTraverse's

Re: [Zope3-Users] How to allow one user to access only his object

2005-10-21 Thread TAHARA Yusei
Hi. On Fri, 21 Oct 2005 05:06:32 -0700 Naotoshi Seo [EMAIL PROTECTED] wrote: At this post method, do I redirect to a URL like ./edit.html?field.passwd=KDJFKJA ? It is not cool. Are there any ways? Why you don't post to edit.html from password.html? Furthermore, returning object in

Re: [Zope3-Users] Re: Interface tests: NotImplemented or NotImplementedError

2005-10-21 Thread Chris Withers
Fred Drake wrote: On 10/20/05, Chris Withers [EMAIL PROTECTED] wrote: What an unfortunate name, I'd have called it Uncomparable on some such... While the current name is unfortunate, and Uncomparable would make the two easier to distinguish, Uncomparable would also be wrong. (If a

Re: [Zope3-Users] Re: Compound Form Elements

2005-10-21 Thread Duncan McGreggor
On Oct 21, 2005, at 12:16 PM, James Allwyn wrote: Following Christian's tweaks to the browser.py file (creating a CustomSequenceWidget), I've got this working well in isolation - I can add a ContactData object on its own no problem. However, I've hit a brick wall about how to use the

Re: [Zope3-Users] How to allow one user to access only his object

2005-10-21 Thread Naotoshi Seo
Hi. At this post method, do I redirect to a URL like ./edit.html?field.passwd=KDJFKJA ? It is not cool. Are there any ways? Why you don't post to edit.html from password.html? Yes, it worked. It seems I was being confused. zapi.queryView has been deprecated. You should use

Re: [Zope3-Users] How to allow one user to access only his object

2005-10-21 Thread Naotoshi Seo
Sorry, this code did not make sense. This code trys to traverse 'messageboardobject/messageobject/edit.html' also. I could access directly. I tried to reject only this by replacing else: to elif string.find(name, 'editmine.html') == -1: But, name value receives only 'messageobject' in this

Re: [Zope3-Users] How to allow one user to access only his object

2005-10-21 Thread Naotoshi Seo
Hi. I made a traverser for Message objects also, and I prohibited access to editview.html at there. It worked. Thank you, TAHARA. from zope.publisher.interfaces import NotFound from zope.app import zapi from zope.app.container.traversal import ContainerTraverser from