Hedley,

It works!!!!!

All but one of the error messages have also been taken care of. This
looks like a remember bug?
------
2008-01-09T09:05:24 INFO CMFFormController You have triggered the form
controller action "passwordreset" using a GET REQUEST.  This is a
potential security hazard.  In Plone 3.0 this will FAIL unless you
explicitly enable your form to support GET requests in the ZMI (or using
the .metadata file). 

One final problem. When a user logs in, they are directed to the join
form, and not the home page or some other page. How do I change the page
that the user gets when he/she logs in?

When I log in I get this page:
http://hammerhead:8081/ahs/newspaper/portal_memberdata/portal_factory/AHSMember/ahsmember.2008-01-09.6353804714/reg_form

and these breadcrumbs - 

You are here: Home → Member Profiles → ahsmember.2008-01-09.6353804714

Note: _at_rename_after_creation = True is not working

Are these remember bugs? or does it come from this:

    # Methods
    def view(self, REQUEST):
        """Silly workaround for when we do not use 
                BrowserDefaultMixin or GenericSetup"""
        return self.base_view(REQUEST)

Thanks!

Mark
 

On Wed, 2008-01-09 at 03:47 -0500, Hedley Roos wrote:
> Ok, I had time to investigate.
> 
> Here's your problem. The BooleanWidget offers either a '1' or '0' on
> the
> REQUEST when you post. Your validators catch that correctly.
> 
> Let's look at the isValid guard on auto_pending transitition
> (introduced
> in remember 1.0b1)
> 
> 219     security.declarePublic('isValid')
> 220     def isValid(self):
> 221         """
> 222         Check to make sure a Member object's fields satisfy schema
> 223         constraints
> 224         """
> 225         errors = {}
> 226         # make sure object has required data and metadata
> 227         self.Schema().validate(self, None, errors, 1, 1)
> 228         if errors:
> 229             return 0
> 230         return 1
> 
> When this executes the last time your object has already had those '1'
> values for the BooleanFields correctly converted to True. True and
> False
> are the only valid options for a BooleanField.
> 
> You are not the one at fault. The BooleanWidget uses clever javascript
> to handle checkboxes, but in the process it does not correctly define
> the name of the input as say foo:int. At least that marshalling will
> cause the variable to appear in the request as a 0 or 1 (not strings)
> which in Python can usually be interpreted the same as proper
> booleans.
> 
> To fix this you have to slightly rewrite your validators. Here's one:
> 
> 162     def validate_accept_terms_of_use(self, value):
> 163         LOG("validate_accept_terms_of_use", INFO, "The value=%s" %
> str(value))
> 164         if (value == True) or (value == '1'):
> 165             return None
> 166         return 'You must read and accept the Terms of Use before
> you
> can join the site.'
> 
> Make the other one the same (with a different message naturally).
> 
> Cheers
> H
> 
> 
> 
> 
> _______________________________________________
> Product-Developers mailing list
> [email protected]
> http://lists.plone.org/mailman/listinfo/product-developers
> 
> 

_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers

Reply via email to