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

Where is route file ? #24

Closed
arirah opened this issue Apr 14, 2018 · 1 comment
Closed

Where is route file ? #24

arirah opened this issue Apr 14, 2018 · 1 comment

Comments

@arirah
Copy link

arirah commented Apr 14, 2018

Where is route files ? If i need more routes from where i can set it ?

@andrey900
Copy link
Owner

andrey900 commented Apr 14, 2018

you must create your own module, in method registerRoute(), register the necessary paths, install the module later.
class must be:
const MODULE_NAME = 'ModuleName';
and
protected static $loaded = false;

The module should be located in the modules/ModuleName folder.
Required files: Module.php -> extends App\Source\BaseModule,
info.json: https://github.com/andrey900/SlimCMS/blob/master/modules/Sections/info.json
config.json: https://github.com/andrey900/SlimCMS/blob/master/modules/Sections/config.json

You can use the module generator, it will create the necessary structure, and files, you will have to fill the registerRoute method only to install it. You can do this by enabled the options in the system: developersMode

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

No branches or pull requests

2 participants