Demo-Modus entfernt
isDemoMode war nie aktiv: appwrite.js hat immer eine Projekt-ID als Fallback. Weg sind die Demo-Zweige in Anmeldung und Hooks sowie die Beispieldaten aus der alten IT-Welt (Serverausfall, Drucker, Kunde A–E). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
889a2f42eb
commit
b758b1f9a7
11 files changed
+25
-451
No files matched your search
@@ -1,5 +1,5 @@
|
||||
import { useState, useCallback } from 'react'
|
||||
import { databases, DATABASE_ID, COLLECTIONS, Query, isDemoMode } from '../lib/appwrite'
|
||||
import { databases, DATABASE_ID, COLLECTIONS, Query } from '../lib/appwrite'
|
||||
|
||||
export function useWebsiteProjects() {
|
||||
const [projects, setProjects] = useState([])
|
||||
@@ -7,7 +7,6 @@ export function useWebsiteProjects() {
|
||||
const [error, setError] = useState(null)
|
||||
|
||||
const fetchAllProjects = useCallback(async () => {
|
||||
if (isDemoMode) return []
|
||||
setLoading(true)
|
||||
setError(null)
|
||||
try {
|
||||
@@ -26,7 +25,7 @@ export function useWebsiteProjects() {
|
||||
}, [])
|
||||
|
||||
const fetchByTicketId = useCallback(async (ticketId) => {
|
||||
if (!ticketId || isDemoMode) return []
|
||||
if (!ticketId) return []
|
||||
try {
|
||||
const response = await databases.listDocuments(
|
||||
DATABASE_ID, COLLECTIONS.WEBSITE_PROJECTS,
|
||||
|
||||
Reference in new issue
Block a user