LoginSignup
6
3

More than 3 years have passed since last update.

Laravel7 password_resetsテーブルはどこに消えた?

Last updated at Posted at 2020-03-22

Laravel7がリリースされまして初記事です。

事件発生

事件はLaravel7をインストールした時、起こりました。

$ composer create-project --prefer-dist laravel/laravel .
$ php artisan -V
Laravel Framework 7.2.2

$ ls -1 ./database/migrations
2014_10_12_000000_create_users_table.php
2019_08_19_000000_create_failed_jobs_table.php

password_resets ファアイルが消えた...!?

失踪したファイル

ファイルが削除されてしまっていた...!

転がり込んだファイル

laravel/ui ライブラリに移動されました。

検証

laravel/ui インストール

$ composer require laravel/ui

$ composer show laravel/ui
name     : laravel/ui
descrip. : Laravel UI utilities and presets.
keywords : laravel, ui
versions : * v2.0.1
type     : library
license  : MIT License (MIT) (OSI approved) https://spdx.org/licenses/MIT.html#licenseText
source   : [git] https://github.com/laravel/ui.git 47a0a1dac76f5e73803c86e1f38b2c7e0ae7fa83
dist     : [zip] https://api.github.com/repos/laravel/ui/zipball/47a0a1dac76f5e73803c86e1f38b2c7e0ae7fa83 47a0a1dac76f5e73803c86e1f38b2c7e0ae7fa83
path     : /work/vendor/laravel/ui
names    : laravel/ui
$ php artisan ui vue --auth

$ ls -1 ./database/migrations
2014_10_12_000000_create_users_table.php
2014_10_12_100000_create_password_resets_table.php
2019_08_19_000000_create_failed_jobs_table.php

--auth オプションを付けて実行した際に認証系のファイルが生成されますが、その際に 2014_10_12_100000_create_password_resets_table.php ファイルも生成されました。

謎はすべて解けた!

補足

ui vue で生成されるファイル一覧

$ php artisan ui vue
package.json
resources/js/app.js
resources/js/bootstrap.js
resources/js/components/ExampleComponent.vue
resources/sass/_variables.scss
resources/sass/app.scss
webpack.mix.js

ui vue --auth で生成されるファイル一覧

$ php artisan ui vue --auth
app/Http/Controllers/Auth/ConfirmPasswordController.php
app/Http/Controllers/Auth/ForgotPasswordController.php
app/Http/Controllers/Auth/LoginController.php
app/Http/Controllers/Auth/RegisterController.php
app/Http/Controllers/Auth/ResetPasswordController.php
app/Http/Controllers/Auth/VerificationController.php
app/Http/Controllers/HomeController.php
database/migrations/2014_10_12_100000_create_password_resets_table.php
resources/views/auth/login.blade.php
resources/views/auth/passwords/confirm.blade.php
resources/views/auth/passwords/email.blade.php
resources/views/auth/passwords/reset.blade.php
resources/views/auth/register.blade.php
resources/views/auth/verify.blade.php
resources/views/home.blade.php
resources/views/layouts/app.blade.php
routes/web.php
6
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
3