-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve DX using connections. (#159)
* Fix date error on error widget * Improve plus icon alignment * Fix validation for eloquent redirects * Revert "Fix validation for eloquent redirects" This reverts commit dbff7f0. * Do not use redirect connection for eloquent * Small improvements * Revert "Small improvements" This reverts commit 397cce2. * Split connections * Improve alignment plus icon on errors widget as well * Add back right-margins * Clearify migration names and use seperate publish tag * Update documentation for split connections * Allow a `default` config value to use laravel default connection * Fix styling * Fix heading indentation * Make quotes more consistent * Revert "Make quotes more consistent" This reverts commit 17c7365. * Small text improvements * Use correct migration names * Remove outdated informatiion. People can read the up-to-date documentation instead. * Capitalize `Laravel` * Text improvement * Fix typo * Rename database from `errors` to `redirect` if needed * Fix tests * Add backwards compatibility for `connection` configuration * Improve backward compatibility * Fix styling * Use singular version which reads better * Improve readability * Code style fix --------- Co-authored-by: vluijkx <vluijkx@users.noreply.github.com>
- Loading branch information
Showing
11 changed files
with
192 additions
and
110 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 0 additions & 30 deletions
30
database/migrations/create_eloquent_redirect_table.php.stub
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
database/migrations/create_redirect_redirects_table.php.stub
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
|
||
use Illuminate\Database\Migrations\Migration; | ||
use Illuminate\Database\Schema\Blueprint; | ||
use Illuminate\Support\Facades\Schema; | ||
|
||
class CreateRedirectRedirectsTable extends Migration | ||
{ | ||
public function up() | ||
{ | ||
Schema::create('redirects', function (Blueprint $table): void { | ||
$table->uuid('id')->unique()->index(); | ||
$table->string('source')->index(); | ||
$table->string('destination'); | ||
$table->char('match_type', 10); | ||
$table->char('type', 10); | ||
$table->string('site')->index(); | ||
$table->integer('order')->nullable(); | ||
$table->boolean('enabled'); | ||
$table->timestamps(); | ||
}); | ||
} | ||
|
||
public function down() | ||
{ | ||
Schema::dropIfExists('redirects'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.