Laravel 5.0 Documentation
Add use Illuminate\Support\Facades\Route; in the app/Providers/RouteServiceProvider.php in order to continue using the Route Facade. You do not need to move over any of the default Laravel 4.0 AuthenticatableContract, CanResetPasswordContract Include the following traits within the class declaration: use Authenticatable, CanResetPassword; If you used them, remove Illuminate\Auth\Reminders\RemindableTrait RemindableTrait and Illuminate\Auth\UserTrait from your use block and your class declaration. The name of the trait and interface used by Laravel Cashier has changed. Instead of using BillableTrait0 码力 | 242 页 | 1.44 MB | 1 年前3
Learning LaravelCatch all routes 154 Catching all routes except already defined 154 Routes are matched in the order they are declared 155 Case-insensitive routes 155 Chapter 54: Seeding 157 Remarks 157 Examples config/app.php, the service provider: Laravel\Cashier\CashierServiceProvider Databse Setup In order to use cashier we need to configure the databases, if a users table does not already exist we need Laravel\Cashier\Billable; class User extends Authenticatable { use Billable; } Stripe Keys In order to ensure that we ares ending the money to our own Stripe account we have to set it up in the config/services0 码力 | 216 页 | 1.58 MB | 1 年前3
Laravel 3.2 Documentationthough you may jump into any section and start learning, we recommend reading the documentation in order as it allows us to progressively establish concepts that will be used in later documents. Who Will 3.0 Replace your application/start.php file. The default start.php file has been expanded in order to give you more flexibility over the loading of your language, configuration, and view files. To default route which is represented with only a front-slash. Note: Routes are evaluated in the order that they are registered, so register any "catch- all" routes at the bottom of your routes.php file0 码力 | 139 页 | 1.13 MB | 1 年前3
Laravel 5.3 中文文档orders', 'check-status' => 'Check order status', ]); 此外,Passport 还包含了用于验证访问令牌认证请求包含必要令牌域的中间件: Route::get('/orders/{order}/status', function (Order $order) { // Access token has "check-status" $order = new Order; // ... 本文档由 Laravel 学院(LaravelAcademy.org)提供 Laravel 学院致力于提供优质 Laravel 中文学习资源 8 $order->save(); 模型被索引之后,就可以通过模型进行全文搜索了,甚至还可以对搜索结果进行分页: return Order::search('Star Order::search('Star Trek')->get(); return Order::search('Star Trek')->where('user_id', 1)->paginate(); 当然,Scout 还有很多其他特性,具体请查看其文档。 可邮寄对象 注:Laracasts 上有关于该特性的免费视频教程。 Laravel 5.3 支持可邮寄对象,这些对象可以以一个简单对象的形式表示邮件信息,而不再需要在0 码力 | 691 页 | 9.37 MB | 1 年前3
Laravel 5.6 中文文档Broadcast::channel('order.{order}', OrderChannel::class); 最后,可以将频道的授权逻辑放到频道类的 join 方法。join 方法中的代码等同于之前位于频道授权闭包中的处理逻辑。当然,你还可以使用频道模 型绑定: Order; class $user * @param \App\Order $order * @return array|bool */ public function join(User $user, Order $order) { return $user->id === $order->user_id; } } API 控制器生成 = $cache; } /** * 通过 ID 获取订单 * * @param int $id * @return Order */ public function find($id) { if ($this->cache->has($id)) {0 码力 | 377 页 | 14.56 MB | 1 年前3
Laravel 6.0 中文文档cached $cache) { $this->cache = $cache; } /** * 通过 ID 获取订单 * * @param int $id * @return Order */ 本文档由学院君提供 学院君致力于提供优质 Laravel 中文学习资源:https://xueyuanjun.com 156 public function find($id) { priority-sorted list of middleware. * * This forces non-global middleware to always be in t he given order. * * @var array */ protected $middlewarePriority = [ \Illuminate\Session\Middleware\StartSession::clas * * @return array */ public function broadcastOn() { return new PrivateChannel('order.'.$this->update-> order_id); } 授权频道 本文档由学院君提供 学院君致力于提供优质 Laravel 中文学习资源:https://xueyuanjun.com 567 记住,用0 码力 | 1442 页 | 14.66 MB | 1 年前3
Laravel 5.1 中文文档$this->cache = $cache; } /** * 通过 ID 获取订单 * * @param int $id * @return Order */ public function find($id) { if ($this->cache->has($id)) { 本文档由 Laravel 学院(LaravelAcademy.org)提供 201 elixir(function(mix) { mix.babel([ 'order.js', 'product.js' ]);}); 要选择不同的输出路径,只需将目标路径作为第二个参数传递给该方法。处了 Babel 编译 之外,babel 和 mix0 码力 | 307 页 | 3.46 MB | 1 年前3
Laravel 5.2 中文文档resources/assets/js 目录的文件数组,并在 public/js 目录下生成单个 all.js: elixir(function(mix) { mix.babel([ 'order.js', 'product.js' ]); }); 要选择不同的输出路径,只需将目标路径作为第二个参数传递给该方法。处了 Babel 编 译之外,babel 和0 码力 | 377 页 | 4.56 MB | 1 年前3
共 8 条
- 1













