This commit is contained in:
phaichayon
2026-06-15 16:34:41 +07:00
parent 1d2406483e
commit eae0dee1f2
40 changed files with 9982 additions and 132 deletions

View File

@@ -0,0 +1,117 @@
# Technical Debt
## After Task D
### 1. Database FK
Customer / Contact / Enquiry ยัง enforce relationship ด้วย application logic
Future:
* เพิ่ม FK หลัง schema stable
### 2. Date Input
Form ยังใช้ text input แบบ YYYY-MM-DD
Future:
* เปลี่ยนเป็น Date Picker กลางของระบบ
### 3. Customer Related Enquiries Pagination
หน้า customer detail แสดง related enquiries แล้ว แต่ยังไม่มี pagination
Future:
* เพิ่มเมื่อข้อมูลเริ่มเยอะ
### 4. Follow-up Activity
Activity timeline ยังพึ่ง audit payload
Future:
* ทำ combined activity view/service
---
## After Task E
### 5. Mixed Tax Rollup
Quotation item รองรับ taxRate ต่อรายการแล้ว
Current:
* quotation summary ยังใช้ header tax calculation
Future:
* รองรับ mixed tax per line
* aggregate tax จาก item จริง
Priority:
* Medium
### 6. Attachment Storage
Attachment ยังเป็น metadata-only
Current:
* เก็บเฉพาะ metadata
Future:
* storage provider abstraction
* upload service
* download endpoint
* permission check
Priority:
* High
### 7. Revision Snapshot
Revision copy:
* header
* items
* customers
* topics
Current:
* ไม่ copy follow-ups
* ไม่ copy attachments
Future:
* กำหนด revision snapshot strategy ให้ชัดเจน
Priority:
* Medium
### 8. CRM Foreign Keys
Customer
Contact
Enquiry
Quotation
Current:
* ใช้ organization validation ใน application layer
Future:
* เพิ่ม FK เมื่อ schema stable
* review cascade strategy
Priority:
* High