Add tenant slug to Sparks return url

I'm using miltitenantcy, and Laravel Spark. When viewing the spark billing page, how do I set the url when clicking "Return to..." link? This link returns the user to "/" but I want it to return them to "/tenant-slug" where tenant-slug is the team slug. Any ideas?
7 Replies
ruddy
ruddy3mo ago
Silvan Hagen
Free users with Filament and Laravel Spark
How to handle free users in a multi-tenant Filament app using Laravel Spark and a custom Middleware.
Frank Wiebe
Frank Wiebe3mo ago
That doesn't help me to change the return URL in spark Bumping this.
ruddy
ruddy3mo ago
You can change the Dashabord url from config\spark.php
ruddy
ruddy3mo ago
Hopefully , it is what you want
No description
Frank Wiebe
Frank Wiebe3mo ago
I need it to send them to the team slug, e.g example.com/team-one
ruddy
ruddy3mo ago
This is how Spark operates behind the scenes: This function retrieves the URL specified in the config/spark.php file under dashboard_url and appends it to the default URL, resulting in a complete URL. For example: https://example.com/dashboard_url."
No description
ruddy
ruddy3mo ago
protected function dashboardUrl() { if ($dashboardUrl = config('spark.dashboard_url')) { return $dashboardUrl; } return app('router')->has('dashboard') ? route('dashboard') : '/'; } If you want to explore further, you can take a look at the FrontendState.php file located in the spark directory.