This commit is contained in:
phaichayon
2026-06-16 08:43:19 +07:00
parent eae0dee1f2
commit b8f13e36b3
12 changed files with 547 additions and 21 deletions

View File

@@ -0,0 +1,18 @@
Status:
accepted
Context:
Quotation revision was introduced in Task E, but the rules before approval workflow were still ambiguous.
Task E.1 needs a stable rule so Task F can build approval on top without changing quotation lineage again.
Decision:
- Revision is allowed only when the current quotation status is `approved`, `sent`, `accepted`, or `rejected`.
- Revision is not allowed for `draft` or `cancelled`.
- A new revision keeps the same quotation family using `parentQuotationId`.
- A new revision copies header, items, customers, and topics only.
- A new revision is created with the `revised` status when that master option exists.
Consequences:
- Sales can revise commercially meaningful documents without reopening early drafts.
- Approval work can later key off a stable quotation family and revision chain.
- Follow-ups and attachments are still out of the revision snapshot and remain technical debt until explicitly designed.