xueron / pails
Pails (PhalconRails) is used to create a rails-like PHP app based on Phalcon.
Installs: 1 223
Dependents: 1
Suggesters: 0
Security: 0
Stars: 3
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: >=7.0
- ext-mbstring: *
- ext-openssl: *
- ext-phalcon: ^3.0.0
- ext-redis: *
- aliyuncs/oss-sdk-php: ^2.2
- doctrine/inflector: ^1.1
- guzzlehttp/guzzle: ^6.2
- league/flysystem: ^1.0
- league/fractal: ^0.14
- league/oauth2-client: ^2.2
- league/oauth2-server: ^5.1
- psr/http-message: ^1.0
- robmorgan/phinx: ^0.6|^0.7|^0.8
- symfony/console: ^3.2
- symfony/debug: ^3.2
- xueron/aliyunmns: ^1.0
This package is not auto-updated.
Last update: 2024-11-09 19:33:36 UTC
README
Pails is a PHP framework based on Phalcon.
Install & Run
Composer
The fastest way to install Pails is to add it to your project using Composer (http://getcomposer.org/).
-
Install Composer:
curl -sS https://getcomposer.org/installer | php
-
Create a pails project using Composer:
php composer.phar create-project xueron/pails-seed myapp
基本目录结构
~/app
- Console: 命令行工具
- Commands: 自定义的命令行工具
- Http: web应用
- Controllers: WEB应用控制器
- Models: 数据库模型 -- 扩展 \Phalcon\Mvc\Model
- Services: 业务服务抽象,复杂一点的业务逻辑在这里实现
- Providers: 自定义的服务提供者
~/resources
- views: 视图文件(非PHP代码)
~/config
- database.yml 数据库配置
- app.php
~/db
- migrations: 数据库迁移文件
- seeds: seeds文件,初始化数据
~/log
- 应用程序内日志存放
~/public
- WEB应用的主目录
~/resources
- assets: 资源文件,主要是css和js
- views: 视图文件(非PHP代码)
~/tests
- 单元测试
~/tmp
- cache: 缓存类文件
- volt: volt引擎编译缓存
- pids: 后台程序的pid文件位置(如有)
- sockets: 后台程序的socket文件位置(如有)
~/composer.json PHP的包管理配置
~/package.json npm的包管理配置
~/webpack.mix.js webpack打包工具的配置
~/pails 命令行工具入口
下面两个是动态生成的:
~/node_modules
- npm包的位置,初始运行npm install的时候会生产
~/vendor
- composer的安装位置,执行composer install的时候会生成