let presentation do raptor (#2838)

### What problem does this PR solve?

#2837

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
Kevin Hu
2024-10-15 10:11:09 +08:00
committed by GitHub
parent 260d694bbc
commit b540d41cdc
2 changed files with 13 additions and 3 deletions

View File

@ -439,8 +439,9 @@ def change_parser():
else:
return get_json_result(data=True)
if doc.type == FileType.VISUAL or re.search(
r"\.(ppt|pptx|pages)$", doc.name):
if ((doc.type == FileType.VISUAL and req["parser_id"] != "picture")
or (re.search(
r"\.(ppt|pptx|pages)$", doc.name) and req["parser_id"] != "presentation")):
return get_data_error_result(retmsg="Not supported yet!")
e = DocumentService.update_by_id(doc.id,