EMailed label return generation (alpha)

This commit is contained in:
2026-09-02 09:30:19 -05:00
parent 6655b02f4a
commit 826a70bdf6
13 changed files with 603 additions and 5 deletions
+22
View File
@@ -0,0 +1,22 @@
"""
The emailed-return-label SKUs (SH007 for Signify, OK012 for Oak Street)
mark a ticket as a different kind of request entirely: not an outbound
kit, but a return label to be created and emailed to a client who
already has product to send back. See app/services/shipstation_send.py
for the label-creation side of this.
"""
from __future__ import annotations
from app import config
from app.status_rules import parse_status_list
def get_emailed_label_skus() -> set[str]:
return parse_status_list(
config.get("EMAILED_LABEL_SKUS", config.DEFAULT_EMAILED_LABEL_SKUS)
)
def is_emailed_label_order(skus: list[str]) -> bool:
emailed_skus = get_emailed_label_skus()
return any((sku or "").strip().lower() in emailed_skus for sku in skus or [])