Hey everyone,
I'm having this problem with my user edit form, where I dont want to
edit all the fields, like the password field, so Im using the
$fieldList array to specify the data I want to save, but Im still
getting this sql error and the form do not validate to save.
How do I solve this?
Here's part of the code.
UserController - admin_edit
$this->cleanUpFields();
if ($this->User->save($this->data, true, $fieldList =
array('username', 'email', 'first_name', 'last_name', 'group_id')))
{
$this->Session->setFlash('The User has been
saved');
$this->redirect('/admin/users/index');
}
else
{
$this->Session->setFlash('Please correct errors
below.');
$this->set('groups',
$this->User->Group->generateList(null, null,
null, '{n}.Group.id','{n}.Group.groupname', null));
}
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---