Files
shopdb-flask/plugins/printedparts/api/routes.py
cproudlock f5cfac33b4
Some checks failed
CI / backend (push) Successful in 1m39s
CI / naming (push) Successful in 2s
CI / frontend (push) Successful in 8s
CI / migrations-mysql (push) Failing after 8s
printedparts stage 2: models, real 0001 baseline, tables live
PrintedItem (catalog: code, name, image, cached quantityonhand,
per-item threshold, bin) and PrintedItemTransaction (the ledger:
signed quantity change attributed to a badge-resolved employee).
Both registered in PLUGIN_TABLE_OWNERS; 0001 is a post-cutover real
baseline. The migration-guard test learns the new expected head.
Routes are a placeholder ping until the next stage - the scaffold's
list route imported the deleted scaffold model, which surfaces as an
empty 'Migration error' because the alembic env imports the models
package.
2026-07-16 16:57:21 -04:00

19 lines
592 B
Python

"""Printedparts plugin API routes.
Stage 2 placeholder: the blueprint must import cleanly for plugin discovery
and migrations (the alembic env imports the models package, which pulls in
plugin.py and this module). Real endpoints land in the next stage.
"""
from flask import Blueprint
from shopdb.api import success_response
printedparts_bp = Blueprint('printedparts', __name__)
@printedparts_bp.route('/ping', methods=['GET'])
def ping():
"""Liveness probe for the lab: proves the blueprint is registered."""
return success_response({'plugin': 'printedparts', 'status': 'ok'})