diff --git a/packages/admin/src/LunarPanelProvider.php b/packages/admin/src/LunarPanelProvider.php index 6e3f4c3412..d7fdc06157 100644 --- a/packages/admin/src/LunarPanelProvider.php +++ b/packages/admin/src/LunarPanelProvider.php @@ -61,7 +61,9 @@ public function register(): void public function boot(): void { - $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + if (! config('lunar.database.disable_migrations', false)) { + $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + } $this->loadViewsFrom(__DIR__.'/../resources/views', 'lunarpanel'); diff --git a/packages/opayo/src/OpayoServiceProvider.php b/packages/opayo/src/OpayoServiceProvider.php index 4c272b698b..ae9f8c1385 100644 --- a/packages/opayo/src/OpayoServiceProvider.php +++ b/packages/opayo/src/OpayoServiceProvider.php @@ -30,7 +30,9 @@ public function boot() $this->loadRoutesFrom(__DIR__.'/../routes/web.php'); - $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + if (! config('lunar.database.disable_migrations', false)) { + $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + } Blade::directive('opayoScripts', function ($incVendor = true) { $url = 'https://sandbox.opayo.eu.elavon.com/api/v1/js/sagepay.js'; diff --git a/packages/stripe/src/StripePaymentsServiceProvider.php b/packages/stripe/src/StripePaymentsServiceProvider.php index 52a5fd4ca6..f8265c2e99 100644 --- a/packages/stripe/src/StripePaymentsServiceProvider.php +++ b/packages/stripe/src/StripePaymentsServiceProvider.php @@ -47,7 +47,11 @@ public function boot() $this->loadViewsFrom(__DIR__.'/../resources/views', 'lunar'); $this->loadRoutesFrom(__DIR__.'/../routes/webhooks.php'); - $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + + if (! config('lunar.database.disable_migrations', false)) { + $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + } + $this->mergeConfigFrom(__DIR__.'/../config/stripe.php', 'lunar.stripe'); $this->publishes([ diff --git a/packages/table-rate-shipping/src/ShippingServiceProvider.php b/packages/table-rate-shipping/src/ShippingServiceProvider.php index a148405820..a054879b6e 100644 --- a/packages/table-rate-shipping/src/ShippingServiceProvider.php +++ b/packages/table-rate-shipping/src/ShippingServiceProvider.php @@ -34,7 +34,9 @@ public function boot(ShippingModifiers $shippingModifiers) $this->loadTranslationsFrom(__DIR__.'/../resources/lang', 'lunarpanel.shipping'); - $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + if (! config('lunar.database.disable_migrations', false)) { + $this->loadMigrationsFrom(__DIR__.'/../database/migrations'); + } $this->loadViewsFrom(__DIR__.'/../resources/views', 'shipping');