Skip to content

Commit

Permalink
it works!
Browse files Browse the repository at this point in the history
  • Loading branch information
ciur committed Nov 10, 2024
1 parent cb6ccae commit ebd6b24
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion papermerge/core/features/document/router_pages.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,8 @@ def apply_page_operations(
When `angle` > 0 -> the rotation is clockwise.
When `angle` < 0 -> the rotation is counterclockwise.
"""
new_doc = apply_pages_op(items)
with db.Session() as db_session:
new_doc = apply_pages_op(db_session, items, user_id=user.id)

return schema.Document.model_validate(new_doc)

Expand Down
1 change: 1 addition & 0 deletions tests/core/test_page_ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

pytestmark = pytest.mark.django_db


@patch("papermerge.core.signals.send_ocr_task")
def test_move_pages_one_single_page_strategy_mix(_):
"""Scenario tests moving of one page from
Expand Down

0 comments on commit ebd6b24

Please sign in to comment.