Jump to content

Recommended Posts

Posted

Hello,

   I have a custom field that has a regex to validate an IP address.  This works fine when I create a client manually, however, when I run through the checkout flow as a new customer I get this error:

 

Invalid custom field ID.

The custom field is invalid.

 

Any ideas?

 

-CraigA

Posted

I only had that issue when I was on the register page myself, but I seem to get orders so I think somewhere it could be something else. Since you posted it, i'm not the only one so I'll take it there's a bug.

 

The fields was required until I turned them off to no to check if it was something, same with Terms and conditions I unticked that box on the register form as it didn't show it.

 

Video: http://screencast.com/t/4FPqrwt0LPxv

Posted

Can you provide steps to reproduce, including the regex you used, etc?

I'm using this: /^\d{1,2}\-\d{1,2}\-\d{4}$/

 

But when I did the video, I wasn't using any regex  :huh:

Posted

Is there a temporary workaround for this?  My business is dead in the water right now :/

 

Try updating /app/models/clients.php (line 89):

 

                    $this->setCustomField($field->name, $client_id, isset($vars['custom']) && array_key_exists($field->name, $vars['custom']) ? $vars['custom'][$field->name] : null);

 

to:

 

                    $this->setCustomField($field->id, $client_id, isset($vars['custom']) && array_key_exists($field->name, $vars['custom']) ? $vars['custom'][$field->name] : null);
Guest
This topic is now closed to further replies.
×
×
  • Create New...