Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run aco_sync from controller #114

Closed
LDSign opened this issue Feb 23, 2017 · 2 comments
Closed

Run aco_sync from controller #114

LDSign opened this issue Feb 23, 2017 · 2 comments
Labels

Comments

@LDSign
Copy link

LDSign commented Feb 23, 2017

Hi

Is there a way to run the shell command

"bin\cake acl_extras aco_sync"

from a controllers action?

If so, could you provide an example please?

Thanks,
Frank

@dakota
Copy link
Member

dakota commented Feb 23, 2017

Yes you can. All the shell does is run the methods in the AclExtras class. Take a look at how Croogo does it: https://github.com/croogo/croogo/blob/3.0/Acl/src/Controller/Admin/ActionsController.php#L159-L174

@LDSign
Copy link
Author

LDSign commented Feb 23, 2017

Perfect - works like a charm :) I tried that before... "$AclExtras->startup($this);" was the magic trick :) Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants