# |
Aug 30th 2019, 13:43 |
ricksaccous |
what are your url params when you debug them? |
# |
Aug 30th 2019, 13:39 |
yadav.manu36 |
yes |
# |
Aug 30th 2019, 13:37 |
ricksaccous |
this one? Result {#76 ▼ #_status: "FAILURE_OTHER" #_data: null #_errors: array:1 [▼ 0 => "Login URL `http://localhost/admin/admin-user-manager/admin-users/login` did not match `adminUsers` or `login` or `admin` or `AdminUserManager`." ] } (edited) |
# |
Aug 30th 2019, 13:36 |
ricksaccous |
what error are you getting the same one? |
# |
Aug 30th 2019, 13:33 |
yadav.manu36 |
i want just successfully login but not happen i am follow all steps but still not getting cussess |
# |
Aug 30th 2019, 13:28 |
ricksaccous |
and what's happening |
# |
Aug 30th 2019, 13:28 |
ricksaccous |
what are you expecting to happen |
# |
Aug 30th 2019, 13:26 |
yadav.manu36 |
still not working |
# |
Aug 30th 2019, 13:25 |
yadav.manu36 |
->add(new RoutingMiddleware($this)) ->add($authentication); I have used routes middleware before authentication |
# |
Aug 30th 2019, 13:24 |
ricksaccous |
@yadav.manu36 you must load routes middleware before authentication |
# |
Aug 30th 2019, 13:22 |
ricksaccous |
yeah |
# |
Aug 30th 2019, 13:21 |
yadav.manu36 |
this is right? |
# |
Aug 30th 2019, 13:21 |
slackebot2 |
'prefix' => 'admin', "plugin" => 'AdminUserManager' ], 'urlChecker' => CakeRouterUrlChecker::class, ]); |
# |
Aug 30th 2019, 13:21 |
yadav.manu36 |
@ricksaccous $service->loadAuthenticator('Authentication.Form', [ 'fields' => $fields, 'loginUrl' => [ 'controller' => 'AdminUsers', 'action' => 'login', 'prefix' => 'admin', "plugin" => 'AdminUserManager' ], 'logoutRedirect' => [ 'controller' => 'AdminUsers', 'action' => 'logout', |
# |
Aug 30th 2019, 13:18 |
ricksaccous |
@yadav.manu36 you need 'urlChecker' => CakeRouterUrlChecker::class |
# |
Aug 30th 2019, 13:17 |
ricksaccous |
$service->loadAuthenticator( 'Authentication.Form', [ 'fields' => $fields, 'urlChecker' => CakeRouterUrlChecker::class, 'loginUrl' => [ 'plugin' => 'Users', 'prefix' => false, 'controller' => 'Users', 'action' => 'login' ] ] ); |
# |
Aug 30th 2019, 13:17 |
ricksaccous |
because by default it won't recognized the array routes |
# |
Aug 30th 2019, 13:17 |
ricksaccous |
in the form login set up |
# |
Aug 30th 2019, 13:17 |
ricksaccous |
nah he needs to specify a class |
# |
Aug 30th 2019, 13:15 |
javier.villanueva |
'unauthenticatedRedirect' => Router::url([ 'controller' => 'AdminUsers', 'action' = 'login' ]), |
# |
Aug 30th 2019, 13:15 |
javier.villanueva |
in middleware you can try... |
# |
Aug 30th 2019, 13:13 |
yadav.manu36 |
AdminUserManager is my plugin name and i have been used DashedRoute for this |
# |
Aug 30th 2019, 13:13 |
yadav.manu36 |
yes |
# |
Aug 30th 2019, 13:12 |
javier.villanueva |
http://localhost/admin/admin-user-manager/admin-users/login ? |
# |
Aug 30th 2019, 13:12 |
javier.villanueva |
the url is correct? |
# |
Aug 30th 2019, 13:08 |
yadav.manu36 |
yes |
# |
Aug 30th 2019, 13:08 |
javier.villanueva |
same error? |
# |
Aug 30th 2019, 13:08 |
yadav.manu36 |
I am follow this but still not working |
# |
Aug 30th 2019, 12:59 |
javier.villanueva |
but sorry, I dont use this plugin |
# |
Aug 30th 2019, 12:59 |
javier.villanueva |
$service->loadIdentifier('Authentication.Password', [ 'fields' => [ 'username' => 'email', 'password' => 'password', ], 'resolver' => [ 'className' => 'Authentication.Orm', 'finder' => 'active' 'userModel' => 'AdminUsers', ], |
# |
Aug 30th 2019, 12:58 |
javier.villanueva |
I think that you need |
# |
Aug 30th 2019, 12:57 |
yadav.manu36 |
Thanks @javier.villanueva for your effort |
# |
Aug 30th 2019, 12:57 |
yadav.manu36 |
you are right, but table structure already exists so i need this. now i am going to check with ORM Resolver section |
# |
Aug 30th 2019, 12:54 |
javier.villanueva |
and then try to change to your complex config |
# |
Aug 30th 2019, 12:54 |
javier.villanueva |
I think that is better if you check first that plugin works with default config |
# |
Aug 30th 2019, 12:53 |
javier.villanueva |
ORM Resolver section |
# |
Aug 30th 2019, 12:53 |
javier.villanueva |
I think that you need specify your new model in userModel |
# |
Aug 30th 2019, 12:53 |
javier.villanueva |
https://book.cakephp.org/authentication/1.1/en/identifiers.html |
# |
Aug 30th 2019, 12:52 |
yadav.manu36 |
but my controller name is AdminUsersController and my table name is admin_users |
# |
Aug 30th 2019, 12:51 |
yadav.manu36 |
it this? |
# |
Aug 30th 2019, 12:51 |
yadav.manu36 |
'loginUrl' => [ 'controller' => 'adminUsers', |