feat: implement hybrid address system and premium search logic

- Added centralized, self-learning GeoService (ZIP, City, Street)
- Implemented Hybrid Address Management (Centralized table + Denormalized fields)
- Fixed Gamification logic (PointsLedger field names & filtering)
- Added address autocomplete and two-tier (Free/Premium) search API
- Synchronized UserStats and PointsLedger schemas
This commit is contained in:
2026-02-08 16:26:39 +00:00
parent 4e14d57bf6
commit 451900ae1a
41 changed files with 764 additions and 515 deletions

View File

@@ -2,11 +2,9 @@ import os
from fastapi import FastAPI
from fastapi.middleware.cors import CORSMiddleware
from fastapi.staticfiles import StaticFiles
from app.api.v1.api import api_router
from app.api.v1.api import api_router # Ez már tartalmaz mindent (auth, services, stb.)
from app.core.config import settings
# 1. Könyvtárstruktúra biztosítása (SSD puffer a miniképeknek)
# Ez garantálja, hogy az app elindulásakor létezik a célmappa
os.makedirs("static/previews", exist_ok=True)
app = FastAPI(
@@ -16,24 +14,21 @@ app = FastAPI(
docs_url="/docs"
)
# 2. PONTOS CORS BEÁLLÍTÁS
app.add_middleware(
CORSMiddleware,
allow_origins=[
"http://192.168.100.10:3001", # Frontend portja
"http://192.168.100.10:3001",
"http://localhost:3001",
"https://dev.profibot.hu" # NPM proxy esetén
"https://dev.profibot.hu"
],
allow_credentials=True,
allow_methods=["*"],
allow_headers=["*"],
)
# 3. STATIKUS FÁJLOK KISZOLGÁLÁSA
# Ez teszi lehetővé, hogy a /static eléréssel lekérhetőek legyenek a miniképek
app.mount("/static", StaticFiles(directory="static"), name="static")
# 4. ROUTER BEKÖTÉSE
# CSAK EZT AZ EGYET KELL BEKÖTNI:
app.include_router(api_router, prefix="/api/v1")
@app.get("/")
@@ -41,5 +36,5 @@ async def root():
return {
"status": "online",
"message": "Service Finder Master System v2.0",
"features": ["Document Engine", "Asset Vault", "Org Onboarding"]
"features": ["Document Engine", "Asset Vault", "Org Onboarding", "Service Hunt"]
}