dev-master
9999999-devStarter for Phalcon micro framework
MIT
The Requires
by langaner
Starter for Phalcon micro framework
A Skeleton project what include jwt token authentication., (*2)
Run composer create-project langaner/phalcon-micro-starter project-directory --prefer-source
or download zip., (*3)
Controllers - all your app controllers, (*4)
Middleware - collection of middleware, (*5)
Models - models folder, (*6)
Presenters - presenters. You can use it by call it from model $this->userRepository->getModel()->getPresenter()->test, (*7)
Providers - all app providers, (*8)
Repositories - all repositoreis. You can use it by call $this->userRepository->test(), (*9)
Services - all app services. You can use it by call $this->userService->test(), (*10)
routes - all routes. You can separate it to files or write all in routes.php, (*11)
http://servarname.server/auth/login - login route. This route provide user auth return his token. All routes protected with AuthMiddleware. Auth settings located in auth config file., (*12)
To use repositories, services, presenters you must register binding in AppProvider to it., (*13)
Examples:, (*14)
Repository - $this->bindRepository('userRepository', UserRepository::class, [new UserModel]);, (*15)
Service - $this->bindService('userService', UserService::class, [$this->getDi()->get('userRepository')]);, (*16)
Presenter - $this->bindRepository('userPresenter', UserPresenter::class, [new UserModel]);, (*17)
Starter for Phalcon micro framework
MIT