feat(v2): add multiple extra features from the pdf slides

This commit is contained in:
2026-07-09 01:22:02 +03:30
parent ae240e7ac1
commit 20a43d5c9a
16 changed files with 1003 additions and 239 deletions

View File

@@ -1,4 +1,4 @@
from .models import ImageSession, ProcessingJob
from .models import ImageSession, ImageState, ProcessingJob
def image_session_get(*, session_id):
@@ -7,3 +7,11 @@ def image_session_get(*, session_id):
def processing_job_get(*, job_id):
return ProcessingJob.objects.filter(id=job_id).first()
def image_state_get(*, state_id):
return ImageState.objects.select_related("session", "parent").filter(id=state_id).first()
def image_states_list(*, session_id):
return ImageState.objects.select_related("parent").filter(session_id=session_id).order_by("sequence", "created_at")