feat: Expedição profile, stamp sizes and the Montar folha screen (front 7a.1)

The new Expedição profile and the seller may assemble sheets (capability
assemble). Gestão edits the size table (letter and width). The Montar tab
reads Estampas/<code>-<size>.png or <code>.png from the orders folder,
checks the resolution with the Site's 96/200 DPI ruler, merges repeated
lines and estimates the metres. Montar itself is slice 2.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Cauê Faleiros
2026-11-09 13:34:43 -03:00
parent 4219db8215
commit e9db9dec06
14 changed files with 482 additions and 23 deletions

View File

@@ -1,7 +1,7 @@
"""Who moves which card on the Kanban: Dropstar's flow of 2026-10-23."""
import unittest
from app.core.auth import ROLES, may_move, may_reorder
from app.core.auth import CAPABILITIES, ROLES, may_move, may_reorder
from app.runtime import BACK, STATES, TRANSITIONS
@@ -41,6 +41,17 @@ class MovesTest(unittest.TestCase):
self.assertTrue(may_move('gestao', 'fin', 'rev', back=True))
self.assertFalse(may_move('vendedor', 'tra', 'rec', back=True))
def test_expedicao_moves_nothing(self):
# The new shipping profile assembles sheets (Fase 2, front 7) and reads
# the board; it moves no card and orders no column.
self.assertIn('expedicao', ROLES)
self.assertEqual(moves('expedicao'), set())
self.assertEqual([s for s in STATES if may_reorder('expedicao', s)], [])
def test_the_montador_is_open_to_exactly_five_profiles(self):
self.assertEqual(CAPABILITIES['assemble'],
{'superadmin', 'admin', 'gestao', 'vendedor', 'expedicao'})
def test_a_column_is_ordered_by_whoever_takes_its_cards_forward(self):
self.assertEqual([s for s in STATES if may_reorder('operador', s)], ['tra', 'imp'])
self.assertEqual([s for s in STATES if may_reorder('designer', s)], ['rec', 'cor'])