integration vom Blog-plugin, hübschere webseite,

This commit is contained in:
Codex Agent
2025-09-26 17:41:17 +02:00
parent 492b9b9fd1
commit 6fc36ebaf4
31 changed files with 22823 additions and 96 deletions

View File

@@ -127,6 +127,34 @@ class MarketingController extends Controller
return view('marketing.success', ['provider' => 'Stripe']);
}
public function blogIndex(Request $request)
{
$locale = $request->get('locale', app()->getLocale());
$posts = \Stephenjude\FilamentBlog\Models\Post::query()
->where('is_published', true)
->whereNotNull('published_at')
->where('published_at', '<=', now())
->whereJsonContains("translations->locale->title->{$locale}", true)
->orderBy('published_at', 'desc')
->paginate(8);
return view('marketing.blog', compact('posts'));
}
public function blogShow($slug)
{
$locale = app()->getLocale();
$post = \Stephenjude\FilamentBlog\Models\Post::query()
->where('slug', $slug)
->where('is_published', true)
->whereNotNull('published_at')
->where('published_at', '<=', now())
->whereJsonContains("translations->locale->title->{$locale}", true)
->firstOrFail();
return view('marketing.blog-show', compact('post'));
}
public function paypalCheckout(Request $request, $package)
{
$packages = [