UI improvements: Leadspeicher, Maps enrichment, exports
- Rename LeadVault → Leadspeicher throughout (sidebar, topbar, page) - SidePanel: full lead detail view with contact, source, tags (read-only), Google Maps link for address - Tags: kontaktiert stored as tag (toggleable), favorit tag toggle - Remove Status column, StatusBadge dropdown, Priority feature - Remove Aktualisieren button from Leadspeicher - Bulk actions: remove status dropdown - Export: LeadVault Excel-only, clean columns, freeze row + autofilter - Export dropdown: click-based (fix overflow-hidden clipping) - ExportButtons: remove CSV, Excel only everywhere - Maps page: post-search Anymailfinder enrichment button - ProgressCard: "Suche läuft..." instead of "Warte auf Anymailfinder-Server..." - Quick SERP renamed to "Schnell neue Suche" - Results page: Excel export, always-enabled download button - Anymailfinder: fix bulk field names, array-of-arrays format - Apify: fix countryCode lowercase - API: sourceTerm search, contacted/favorite tag filters Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -20,6 +20,8 @@ export async function GET(req: NextRequest) {
|
||||
const priorities = searchParams.getAll("priority");
|
||||
const tags = searchParams.getAll("tags");
|
||||
const searchTerms = searchParams.getAll("searchTerm");
|
||||
const contacted = searchParams.get("contacted");
|
||||
const favorite = searchParams.get("favorite");
|
||||
|
||||
const where: Prisma.LeadWhereInput = {};
|
||||
|
||||
@@ -30,6 +32,7 @@ export async function GET(req: NextRequest) {
|
||||
{ contactName: { contains: search } },
|
||||
{ email: { contains: search } },
|
||||
{ notes: { contains: search } },
|
||||
{ sourceTerm: { contains: search } },
|
||||
];
|
||||
}
|
||||
|
||||
@@ -50,6 +53,14 @@ export async function GET(req: NextRequest) {
|
||||
where.sourceTerm = { in: searchTerms };
|
||||
}
|
||||
|
||||
if (contacted === "yes") {
|
||||
where.tags = { contains: "kontaktiert" };
|
||||
}
|
||||
|
||||
if (favorite === "yes") {
|
||||
where.tags = { contains: "favorit" };
|
||||
}
|
||||
|
||||
if (tags.length > 0) {
|
||||
// SQLite JSON contains — search for each tag in the JSON string
|
||||
where.AND = tags.map(tag => ({
|
||||
|
||||
Reference in New Issue
Block a user