SirNewbie Posted January 2, 2012 Share Posted January 2, 2012 Hi, I'm testing the addition of new accounts. When I try to create a user, I get the following errors. Also, all required fields have been entered. This is with ver. 1.4.6. Has anyone had this problem before? Thanks! There are 2 errors : [/left] id_default_group is required. last_passwd_gen is required. Link to comment Share on other sites More sharing options...
bellini13 Posted January 2, 2012 Share Posted January 2, 2012 do you have any custom modules or themes? have you made any changes to the shop? Link to comment Share on other sites More sharing options...
SirNewbie Posted January 2, 2012 Author Share Posted January 2, 2012 I haven't installed any custom modules or themes. I am using the default theme. The only changes I have made have been options through the admin page. I have disabled several modules that are unnecessary at this point. Link to comment Share on other sites More sharing options...
SirNewbie Posted January 2, 2012 Author Share Posted January 2, 2012 I am new to PHP, but I am trying to reverse engineer where the error is being thrown. So I found that last_passwd_gen is created in Customer.php in the add() function: public function add($autodate = true, $nullValues = true) { $this->birthday = (empty($this->years) ? $this->birthday : (int)($this->years).'-'.(int)($this->months).'-'.(int)($this->days)); $this->secure_key = md5(uniqid(rand(), true)); $this->last_passwd_gen = date('Y-m-d H:i:s', strtotime('-'.Configuration::get('PS_PASSWD_TIME_FRONT').'minutes')); ... However, there is no validation at this point to check if it contains information. I need to find out which other file is trying to read the value and throwing the error. Link to comment Share on other sites More sharing options...
SirNewbie Posted January 3, 2012 Author Share Posted January 3, 2012 Bump! Can anyone tell me what section of code generates and displays the errors from my first post? It looks like when the form is submitted, it calls authentication.php, which then calls AuthController.php, but I still can't find where the error validation is happening on these two variables. Thanks! Link to comment Share on other sites More sharing options...
SirNewbie Posted January 3, 2012 Author Share Posted January 3, 2012 Figured out my problem! Went to: Customers --> then clicked: Set required fields for this section, then unchecked id_default_group, last_passwd_gen. Is there a way for me to mark my own thread as [solved]? Link to comment Share on other sites More sharing options...
bellini13 Posted January 3, 2012 Share Posted January 3, 2012 AuthController extends FrontController, perhaps the validation is being performed there. one other place to check. in the back office, in the Customer section, scroll to the bottom and expand the "Set required fields for this section". are any of them checked? 1 Link to comment Share on other sites More sharing options...
newage Posted May 8, 2017 Share Posted May 8, 2017 Hello! I have the same problem, getting "id_default_group is required." when a customer wants to register. However in the "Set required fields for this section" there is no id_default_group Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now