feat: add SHA256 hash attribute to knowledge object on save
Some checks failed
sync2gitee / repo-sync (push) Has been cancelled

This commit is contained in:
CaptainB 2025-05-08 12:34:51 +08:00
parent ab479c422c
commit 9f004defd9

View File

@ -281,6 +281,7 @@ class File(AppModelMixin):
result = select_one("SELECT lo_from_bytea(%s, %s::bytea) as loid", [0, bytea])
self.loid = result['loid']
self.file_size = len(bytea)
self.sha256_hash = sha256_hash
super().save()
def get_bytes(self):