Add Print Queue UI and slicer post-processing script
Some checks failed
CI / style (push) Has been cancelled
CI / build-client (push) Has been cancelled
CI / build-amd64 (push) Has been cancelled
CI / build-tester (push) Has been cancelled
CI / test (cockroachdb) (push) Has been cancelled
CI / test (mariadb) (push) Has been cancelled
CI / test (postgres) (push) Has been cancelled
CI / test (sqlite) (push) Has been cancelled
CI / build-arm64 (push) Has been cancelled
CI / build-armv7 (push) Has been cancelled
CI / publish-images (push) Has been cancelled
CI / publish-release (push) Has been cancelled
Some checks failed
CI / style (push) Has been cancelled
CI / build-client (push) Has been cancelled
CI / build-amd64 (push) Has been cancelled
CI / build-tester (push) Has been cancelled
CI / test (cockroachdb) (push) Has been cancelled
CI / test (mariadb) (push) Has been cancelled
CI / test (postgres) (push) Has been cancelled
CI / test (sqlite) (push) Has been cancelled
CI / build-arm64 (push) Has been cancelled
CI / build-armv7 (push) Has been cancelled
CI / publish-images (push) Has been cancelled
CI / publish-release (push) Has been cancelled
- Create Print Queue page showing pending/completed/cancelled jobs - Add needs_weighing filter to spool API for flagged spools - Add IPrintJob interface and needs_weighing to ISpool model - Add slicer_post_process.py for Elegoo/Orca Slicer integration - Add translations for print queue feature - Bump version to 0.23C.3 The workflow: 1. Slicer post-processing script creates pending print job 2. After print, user confirms (deducts filament) or cancels (flags for weighing) 3. Spools needing weigh-in are shown in Print Queue UI Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -264,6 +264,10 @@ async def find(
|
||||
bool,
|
||||
Query(title="Allow Archived", description="Whether to include archived spools in the search results."),
|
||||
] = False,
|
||||
needs_weighing: Annotated[
|
||||
Optional[bool],
|
||||
Query(title="Needs Weighing", description="Filter by spools that need manual weigh-in."),
|
||||
] = None,
|
||||
sort: Annotated[
|
||||
Optional[str],
|
||||
Query(
|
||||
@@ -308,6 +312,7 @@ async def find(
|
||||
location=location,
|
||||
lot_nr=lot_nr,
|
||||
allow_archived=allow_archived,
|
||||
needs_weighing=needs_weighing,
|
||||
sort_by=sort_by,
|
||||
limit=limit,
|
||||
offset=offset,
|
||||
|
||||
@@ -123,6 +123,7 @@ async def find( # noqa: C901, PLR0912
|
||||
location: Optional[str] = None,
|
||||
lot_nr: Optional[str] = None,
|
||||
allow_archived: bool = False,
|
||||
needs_weighing: Optional[bool] = None,
|
||||
sort_by: Optional[dict[str, SortOrder]] = None,
|
||||
limit: Optional[int] = None,
|
||||
offset: int = 0,
|
||||
@@ -158,6 +159,17 @@ async def find( # noqa: C901, PLR0912
|
||||
),
|
||||
)
|
||||
|
||||
if needs_weighing is not None:
|
||||
if needs_weighing:
|
||||
stmt = stmt.where(models.Spool.needs_weighing.is_(True))
|
||||
else:
|
||||
stmt = stmt.where(
|
||||
sqlalchemy.or_(
|
||||
models.Spool.needs_weighing.is_(False),
|
||||
models.Spool.needs_weighing.is_(None),
|
||||
),
|
||||
)
|
||||
|
||||
total_count = None
|
||||
|
||||
if limit is not None:
|
||||
|
||||
Reference in New Issue
Block a user