Fix feed username crash and add About page
This commit is contained in:
parent
9db36249a3
commit
2c9301ae14
2 changed files with 33 additions and 3 deletions
|
|
@ -45,7 +45,7 @@ def get_global_feed(
|
|||
type="review",
|
||||
timestamp=r.created_at or datetime.utcnow(), # Handle missing created_at if any
|
||||
data=r,
|
||||
user={"id": user.id, "username": user.username, "avatar": user.avatar} if user else {}
|
||||
user={"id": user.id, "username": user.email.split("@")[0], "avatar": user.avatar} if user else {}
|
||||
))
|
||||
|
||||
for a in attendance:
|
||||
|
|
@ -54,7 +54,7 @@ def get_global_feed(
|
|||
type="attendance",
|
||||
timestamp=a.created_at,
|
||||
data=a,
|
||||
user={"id": user.id, "username": user.username, "avatar": user.avatar} if user else {}
|
||||
user={"id": user.id, "username": user.email.split("@")[0], "avatar": user.avatar} if user else {}
|
||||
))
|
||||
|
||||
for p in posts:
|
||||
|
|
@ -63,7 +63,7 @@ def get_global_feed(
|
|||
type="post",
|
||||
timestamp=p.created_at,
|
||||
data=p,
|
||||
user={"id": user.id, "username": user.username, "avatar": user.avatar} if user else {}
|
||||
user={"id": user.id, "username": user.email.split("@")[0], "avatar": user.avatar} if user else {}
|
||||
))
|
||||
|
||||
# Sort by timestamp desc
|
||||
|
|
|
|||
30
frontend/app/about/page.tsx
Normal file
30
frontend/app/about/page.tsx
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
export default function AboutPage() {
|
||||
return (
|
||||
<div className="container mx-auto px-4 py-8">
|
||||
<h1 className="text-4xl font-bold mb-6 text-brand-500">About Elmeg</h1>
|
||||
<div className="prose dark:prose-invert max-w-none">
|
||||
<p className="text-xl mb-4">
|
||||
Elmeg is the definitive fan archive for <strong>Goose</strong>, built by fans for fans.
|
||||
</p>
|
||||
<p className="mb-4">
|
||||
Our mission is to track every show, every song, and every stat. Whether you're chasing your first <em>Arcadia</em> or looking for that deep cut <em>Factory Fiction</em>, Elmeg has the data you need.
|
||||
</p>
|
||||
|
||||
<div className="bg-zinc-100 dark:bg-zinc-800 p-6 rounded-lg my-8">
|
||||
<h2 className="text-2xl font-bold mb-4">Features</h2>
|
||||
<ul className="list-disc pl-6 space-y-2">
|
||||
<li>Comprehensive Show Archive</li>
|
||||
<li>Detailed Setlists & Song Stats</li>
|
||||
<li>Community Ratings & Reviews</li>
|
||||
<li>Venue Leaderboards</li>
|
||||
<li>Personal Attendance Tracking</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<p className="text-sm text-zinc-500 mt-8">
|
||||
Elmeg is a demo project showcasing advanced full-stack capabilities. Powered by FastAPI, Next.js, and SQLModel.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Loading…
Add table
Reference in a new issue