fix(onboarding): generic example, numbered rooms, catch-all change prompt
- Example text: 'Projektraum = Entwicklung, Code-Reviews, ...' (not project-specific) - Onboarding prompt: numbered list (1. Raum, 2. Raum, ...) - After completion: shows all rooms with Catch-All marker, asks if change wanted
This commit is contained in:
+21
-4
@@ -680,11 +680,11 @@ class RocketChatAdapter(BasePlatformAdapter):
|
||||
lines = ["Folgende Räume fehlen in der Raum-Map.",
|
||||
"Wofür ist jeder Raum da? Antworte pro Raum mit: `Name = Thema`",
|
||||
""]
|
||||
for room in missing_rooms:
|
||||
for i, room in enumerate(missing_rooms, 1):
|
||||
clean_name = room['name'].lstrip("#")
|
||||
lines.append(f"{clean_name} = ")
|
||||
lines.append(f"{i}. {clean_name} = ")
|
||||
lines.append("")
|
||||
lines.append("Beispiel: `BAT-Team = Trading, Bot Agent Team, Projekt BAT, Austausch und Status`")
|
||||
lines.append("Beispiel: `Projektraum = Entwicklung, Code-Reviews, Austausch und Status zum Projekt`")
|
||||
text = "\n".join(lines)
|
||||
|
||||
# Nachricht senden
|
||||
@@ -779,7 +779,24 @@ class RocketChatAdapter(BasePlatformAdapter):
|
||||
|
||||
if remaining_missing == 0:
|
||||
self.archivar._stats["onboarding_active"] = False
|
||||
confirmation_text = f"✅ Alle {processed_count} Räume zur Map hinzugefügt. Onboarding abgeschlossen."
|
||||
# Baue nummerierte Raumliste für Catch-All-Frage
|
||||
all_rooms = []
|
||||
for rid, entry in self.archivar._room_map.rooms.items():
|
||||
if rid in self.archivar._room_map._excluded_room_ids:
|
||||
continue
|
||||
all_rooms.append((rid, entry.name, entry.catch_all))
|
||||
# Sortiere: catch_all zuerst, dann alphabetisch
|
||||
all_rooms.sort(key=lambda x: (not x[2], x[1]))
|
||||
|
||||
lines = [f"✅ Alle {processed_count} Räume zur Map hinzugefügt."]
|
||||
lines.append("")
|
||||
lines.append("**Aktuelle Raum-Übersicht:**")
|
||||
for i, (rid, name, is_catch) in enumerate(all_rooms, 1):
|
||||
marker = " 🎯 (Catch-All)" if is_catch else ""
|
||||
lines.append(f"{i}. {name}{marker}")
|
||||
lines.append("")
|
||||
lines.append("Möchtest du den Catch-All-Raum ändern? Antworte mit der Raumnummer, oder **überspringen** zum Behalten.")
|
||||
confirmation_text = "\n".join(lines)
|
||||
self.rest.post_message(room_id, confirmation_text)
|
||||
logger.info("[rocketchat] Onboarding abgeschlossen: Alle Räume wurden hinzugefügt")
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user