fix mind map bug (#1934)

### What problem does this PR solve?


### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
Kevin Hu
2024-08-13 19:42:28 +08:00
committed by GitHub
parent 13bcfd7ebd
commit d73a75506e
4 changed files with 15 additions and 9 deletions

View File

@ -46,6 +46,7 @@ class API4ConversationService(CommonService):
@classmethod
@DB.connection_context()
def stats(cls, tenant_id, from_date, to_date, source=None):
if len(to_date) == 10: to_date += " 23:59:59"
return cls.model.select(
cls.model.create_date.truncate("day").alias("dt"),
peewee.fn.COUNT(