Log message #4200285

# At Username Text
# Aug 29th 2019, 07:21 alexdd55976 yes. need to attach related userdata
# Aug 29th 2019, 07:20 javier.villanueva do you need ad data for more than authorization?
# Aug 29th 2019, 07:19 alexdd55976 Authenticate alsways wants to do stuff against users table, which... of course.. does not anything
# Aug 29th 2019, 07:18 alexdd55976 i authenticate against AD, which is fine so far, but need to use authentication component to use this data
# Aug 29th 2019, 07:18 javier.villanueva wich problem you have?
# Aug 29th 2019, 07:14 alexdd55976 anyone can help with authentication + ldap/ad data?
# Aug 29th 2019, 06:39 javier.villanueva Is it a good practice to use constants related to an entity in the global configuration file app.php? (for example entity states)
# Aug 29th 2019, 06:20 javier.villanueva solved, thanks
# Aug 29th 2019, 06:02 alexdd55976 Morning
# Aug 29th 2019, 06:01 javier.villanueva isValidCompany or similar...
# Aug 29th 2019, 06:01 javier.villanueva with a custom rule I suppose
# Aug 29th 2019, 06:00 admad yes you need build rules
# Aug 29th 2019, 05:54 javier.villanueva I am trying to create a validator rule for the next case: An entity has this fields "company_id", "state_id". And the states are ("open", "in_process", "closed") The rule should check that only we can create entities with duplicate company_id if the others have "closed" state. Do I need to use buildRules? I cant use the isUnique rule for the "closed" exception...
# Aug 29th 2019, 05:16 javier.villanueva are you tried testing your api from postman (or similar) to discard a problem in the Angular side?
# Aug 29th 2019, 05:14 javier.villanueva @ashish_onmobile check your chrome inspector to find errors?
# Aug 29th 2019, 05:13 conehead morning!
# Aug 29th 2019, 05:12 javier.villanueva morning all
# Aug 29th 2019, 04:11 kailas @challgren that was the issue! I was using the wrong template. thanks for the help!
# Aug 29th 2019, 03:18 ashish_onmobile but POST is not working.
# Aug 29th 2019, 03:18 ashish_onmobile GET Method work from browser to access api at port 80
# Aug 29th 2019, 03:17 ashish_onmobile 4200*
# Aug 29th 2019, 03:17 ashish_onmobile I am working on angular project which run over port 42000
# Aug 29th 2019, 03:17 kailas @challgren yes. I have a permissions.php file in the config directory. I felt like the changes I was making to it were working. let me poke at that a bit more
# Aug 29th 2019, 03:17 ashish_onmobile I tried this
# Aug 29th 2019, 03:17 ashish_onmobile ashish_onmobile [12:43 PM] public function beforeFilter(Event $event) { parent::beforeFilter($event); $this->response= $this->response->cors($this->request) ->allowOrigin([‘*’]) ->allowMethods([‘GET’, ‘POST’,‘PUT’,‘OPTIONS’]) ->allowHeaders([‘X-CSRF-Token’]) ->allowCredentials() ->exposeHeaders([‘Link’]) ->maxAge(300)
# Aug 29th 2019, 03:16 challgren @kailas that doesnt look right are you editing the permissions.php in your config dir?
# Aug 29th 2019, 03:15 challgren @ashish_onmobile best to ask your question a lot of people lurk and maybe to answer if they know the question
# Aug 29th 2019, 03:14 ashish_onmobile is there anyone who can help for CORS issue
# Aug 29th 2019, 03:13 kailas for permissions, i’m returning: [ ‘Users.SimpleRbac.permissions’ => [….. I’m using CakeDC/Auth.SimpleRbac so I believe that’s the right way to do it. is it not?
# Aug 29th 2019, 03:11 kailas yeah, i used that as my template
# Aug 29th 2019, 03:11 challgren Yeah the permissions.php https://github.com/CakeDC/users/blob/master/config/permissions.php#L64
# Aug 29th 2019, 03:10 kailas yeah, i’ve been looking there. my guess is this is an intersection of permissions issues (which is why it’s redirecting) and configuring auth
# Aug 29th 2019, 03:10 challgren Thats what you want to change in your config
# Aug 29th 2019, 03:10 challgren https://github.com/CakeDC/users/blob/master/config/users.php#L142
# Aug 29th 2019, 03:09 challgren Ohh thats the new middleware one, Im not sure on that. But my guess is in the config under Auth
# Aug 29th 2019, 03:08 kailas 8.4.0 of cakedc/users
# Aug 29th 2019, 03:07 kailas 3.0.4 of cakedc/auth
# Aug 29th 2019, 03:06 challgren yes
# Aug 29th 2019, 03:06 kailas of CakeDC/Users?
# Aug 29th 2019, 03:06 challgren What version you using?
# Aug 29th 2019, 03:05 slackebot2 ‘loginAction’ => [ ‘plugin’ => ‘CakeDC/Users’, ‘controller’ => ‘Users’, ‘action’ => ‘profile’, ‘prefix’ => false ], - shouldn’t it redir to loginAction after successful login? why is it going to / ? - where do i set the logout redirect? seems to be redirecting to /, but then getting stuck in a loop of some type?