Compare commits
No commits in common. "1bb7d9000f9c58c12533da2b615ccc80aa54c02a" and "374d05a2cada0e42342c0d7bf18bd88349b8edaa" have entirely different histories.
1bb7d9000f
...
374d05a2ca
|
@ -8,5 +8,3 @@ sudo mysql scoutrobot < db.tmp
|
||||||
rm db.tmp
|
rm db.tmp
|
||||||
|
|
||||||
echo 'app(\App\Form\FormSettings::class)->fill(["registerUrl" => "http://stammsilva.test/anmeldung/{slug}/register", "clearCacheUrl" => "http://stammsilva.test/adrema/clear-cache"])->save();' | php artisan tinker
|
echo 'app(\App\Form\FormSettings::class)->fill(["registerUrl" => "http://stammsilva.test/anmeldung/{slug}/register", "clearCacheUrl" => "http://stammsilva.test/adrema/clear-cache"])->save();' | php artisan tinker
|
||||||
|
|
||||||
exit 0
|
|
||||||
|
|
|
@ -39,8 +39,6 @@ class MailgatewayServiceProvider extends ServiceProvider
|
||||||
MailmanType::class,
|
MailmanType::class,
|
||||||
]));
|
]));
|
||||||
|
|
||||||
$this->loadMigrationsFrom(__DIR__ . '/database/migrations');
|
|
||||||
|
|
||||||
View::addNamespace('mailgateway', __DIR__ . '/Components');
|
View::addNamespace('mailgateway', __DIR__ . '/Components');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,32 +0,0 @@
|
||||||
<?php
|
|
||||||
|
|
||||||
use Illuminate\Database\Migrations\Migration;
|
|
||||||
use Illuminate\Database\Schema\Blueprint;
|
|
||||||
use Illuminate\Support\Facades\Schema;
|
|
||||||
use Modules\Mailgateway\Types\MailmanType;
|
|
||||||
|
|
||||||
return new class extends Migration
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the migrations.
|
|
||||||
*/
|
|
||||||
public function up(): void
|
|
||||||
{
|
|
||||||
foreach (DB::table('mailgateways')->get() as $gateway) {
|
|
||||||
$type = json_decode($gateway->type);
|
|
||||||
|
|
||||||
$newType = ['type' => $type->cls, 'data' => $type->params];
|
|
||||||
if (str_contains($type->cls, 'MailmanType')) {
|
|
||||||
$newType['type'] = MailmanType::class;
|
|
||||||
}
|
|
||||||
DB::table('mailgateways')->where('id', $gateway->id)->update(['type' => json_encode($newType)]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reverse the migrations.
|
|
||||||
*/
|
|
||||||
public function down(): void
|
|
||||||
{
|
|
||||||
}
|
|
||||||
};
|
|
Loading…
Reference in New Issue