[Eva] B2.1: /next создаёт строку прогресса (in-progress)
This commit is contained in:
@@ -122,6 +122,13 @@ async def get_next_sentence(request: Request):
|
|||||||
if not row:
|
if not row:
|
||||||
return {"completed": True, "message": "All sentences completed!"}
|
return {"completed": True, "message": "All sentences completed!"}
|
||||||
|
|
||||||
|
# 🔧 НОВОЕ (16.10.2026): строка прогресса (in-progress) для счётчика list_opened.
|
||||||
|
await conn.execute("""
|
||||||
|
INSERT INTO sentence_progress (user_id, sentence_id, list_opened, completion_time)
|
||||||
|
VALUES ($1, $2, 0, 0)
|
||||||
|
ON CONFLICT (user_id, sentence_id) DO NOTHING
|
||||||
|
""", telegram_id, row["id"])
|
||||||
|
|
||||||
# Оригинальные слова (для проверки)
|
# Оригинальные слова (для проверки)
|
||||||
correct_words = row["sentence_pl"].split()
|
correct_words = row["sentence_pl"].split()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user