Release Notes
10 September, 2022
9 September, 2021
https://laravel.com/docs/8.x/releases September 8th, 2020
https://laravel.com/docs/7.x/releases March 3rd, 2020
https://laravel.com/docs/6.x/releases September 3rd, 2019
https://laravel.com/docs/5.8/releases February 26th, 2019
https://laravel.com/docs/5.7/releases September 4th, 2018
https://laravel.com/docs/5.6/releases February 7th, 2018
https://laravel.com/docs/5.5/releases August 30th, 2017
支持数据库 MySQL、PostgreSQL、SQLite、SQL Server,所有版本默认不支持Oracle。不同Laravel版本数据库支持的版本不同。
Laravel 8 开始官方文档都是用Docker部署,且推荐使用Homestead作为开发环境
Issues
- Collections
- Migrations
artisan
查看可用命令
1 | php artisan list |
运行项目
1 | php artisan serve // 启动 |
查看路由列表
1 | php artisan route:list |
生成
1 | php artisan key:generate 生成AppKey |
清楚缓存
1 | php artisan config:clear |
Laravel Mix
Laravel Validation
Introduction
Laravel includes a wide variety of convenient validation rules that you may apply to data, even providing the ability to validate if values are unique in a given database table.
Writing The Validation Logic
1 | $validated = $request->validate([ |
validation rules may be specified as arrays of rules instead of a single |
delimited string
1 | $validatedData = $request->validate([ |
Stopping On First Validation Failure
1 | $request->validate([ |
A Note On Nested Attributes
1 | $request->validate([ |