bpocallaghan/titan
Composer 安装命令:
composer require bpocallaghan/titan
包简介
Core framework for laravel projects (Laravel Admin Starter).
README 文档
README
A Laravel Website and Admin Framework for your everyday Websites build in Laravel. This project is the core framework for Laravel Starter. Please check this out for the detailed Features list and more.
Test Driven Development
- titan-starter
- I have started from scratch with a new test driven version. The end goal is to focus on TDD, more generic and easier to customize and help speed up your website development.
- User: github@bpocallaghan.ie
- Password: github
Titan is nicely packaged for you so that you only have to do the following;
- install laravel
- composer require titan package
- *create database
- *setup virtual host/ host file
- run titan:setup command
- run titan:install command
- run titan:migrate command (optional)
- *open browser
Then you have your Titan Admin Starter project with all the features ready to start your coding.
Installation
Update your project's composer.json file.
composer require bpocallaghan/titan
php artisan titan:setup
It will do the following:
php artisan titan:publish --files=website- Update
app\User.php - Update
routes\web.php - Update
app\Http\Kernel.php - Update
app\Http\Handler.php - Update
config\app.php
php artisan titan:install
It will do the following:
- Update
.env php artisan migratephp artisan titan:db:seedphp artisan titan:publish --files=auth
php artisan titan:migrate --name=
It will do the following:
- Specify the 'table types' you would like to migrate
blog, documents, faq, locations, news, newsletter_subscribers, photos, testimonials, shop
(Optional) Mail Layout php artisan vendor:publish --tag=laravel-notifications Mail Component php artisan vendor:publish --tag=laravel-mail
It will publish the mail blade files to your project for you to edit.
Installation steps in Detail
php artisan migrate
This will create the 'core/minimum' tables needed (users table will be altered). You can run php artisan migrate --name=blog to include the migration tables.
php artisan titan:db:seed
This will seed the core tables to get started
- roles
- banners
- pages
- navigation_admin
php artisan titan:publish --files=website
This will copy all Website related files to your application.
- views, controllers and database seeds
- webpack.mix.js and packages.json
- resource/assets and public/assets (css, js, fonts, images)
Open routes\web.php and uncomment the home route.
Open app\Http\Kernel.php and add the below to the end of $routeMiddleware list.
'role' => \Bpocallaghan\Titan\Http\Middleware\ValidateRole::class, 'auth.admin' => \Bpocallaghan\Titan\Http\Middleware\AuthenticateAdmin::class,
This is to register the Admin Middlewares
- AuthenticateAdmin - If the user logging in has the
adminrole. - ValidateRole - Admin users can have multiple roles, filter the navigation on those roles.
Commands
The publish commands are used to copy the files from titan to your own application for customization. For example, you need to add or change a field in a table or update text or design in blade files.
php artisan titan:publish --files=app php artisan titan:publish --files=assets php artisan titan:publish --files=auth php artisan titan:publish --files=banner php artisan titan:publish --files=config php artisan titan:publish --files=database php artisan titan:publish --files=events php artisan titan:publish --files=helpers php artisan titan:publish --files=pages php artisan titan:publish --files=public php artisan titan:publish --files=routes php artisan titan:publish --files=website
php artisan titan:publish --files=app
This will copy all Models, Views and Controllers to your application.
This will also copy all routes and RouteServiceProvider to your application.
php artisan titan:publish --files=assets
This will copy all assets (css, js, fonts, images) and webpack.js, package.json to your application.
php artisan titan:publish --files=auth
This will copy all Auth related Models, Views and Controllers to your application.
php artisan titan:publish --files=banner
This will copy all Banner related Models, Views and Controllers to your application.
php artisan titan:publish --files=config
This will copy the config file of titan to your application. You can change the admin skin (blue, red, green, etc)
php artisan titan:publish --files=database
This will copy the database/seeds and database/migrations to your application.
php artisan titan:publish --files=events
This will copy all Events, Listeners, Mails and Notifications to your application.
php artisan titan:publish --files=helpers
This will copy all Helpers, and HelperServiceProvider to your application.
php artisan titan:publish --files=public
This will copy all public (compiled css, js and also fonts and images) to your application.
php artisan titan:publish --files=routes
This will copy all routes, and RouteServiceProvider to your application.
php artisan titan:publish --files=website
This will copy all Website related files to your application (views, controllers, assets).
Note: If you are not going to run php artisan titan:publish --files=routes, remember to add the routes to your application.
TODO
- install command, remove laravel installed files (public/svg)
- create config file (don't load routes, etc)
create new packages for
- *banners
- *activity
- *google analytics
- and more
bpocallaghan/titan 适用场景与选型建议
bpocallaghan/titan 是一款 基于 Blade 开发的 Composer 扩展包,目前已累计 11.25k 次下载、GitHub Stars 达 58, 最近一次更新时间为 2016 年 04 月 07 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「admin」 「controllers」 「helpers」 「cms」 「laravel」 「models」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 bpocallaghan/titan 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 bpocallaghan/titan 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 bpocallaghan/titan 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Opinionated Laravel Controllers extension
2lenet/EasyAdminPlusBundle
A package for generating annotations and drawing SwUi when working with Bitrix controllers.
Bullet development for Laravel Applications
Analysis module for finding problematical shop data.
HTML and form generation
统计信息
- 总下载量: 11.25k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 58
- 点击次数: 23
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-04-07