19 Commits

Author SHA1 Message Date
masoodafar-web 39590d2cbe docs: Phase 10 — DataMigration + EF Staging + PackagePurchaseDialog + UI Fixes
Updated 8 docs:
- CHANGELOG: Phase 10a-d (DataMigration tool, EF staging migrations, PackagePurchaseDialog, 4 UI fixes)
- PAYMENT-FINANCE: Rial→Toman conversion chain documented, PackagePurchaseDialog status
- TECH-02: Added PackagePurchaseDialog to folder structure + status table
- TECH-04: DataMigration tool features (smart retry, FK handling, fallback tables), EF staging
- PACKAGE-TASKS: Phase 10 graph, NuGet v0.0.189, T4.1+T4.2 marked 
- BIZ-PACKAGE: v6→v7, commits updated, T4.1+T4.2 marked 
- INDEX: Updated last-update + R3 description
- ROADMAP: Progress bars updated, DONE section + NOW section refreshed
2026-02-27 20:56:00 +03:30
masoodafar-web e9f1fb9911 docs: Phase 9 — Q24-Q30 + History Interceptor + Rename + Migration
- CHANGELOG: add Phase 9 (9a-9d) with all new commits (CMS:a1024a3→fdbb91d→10d2ca2, FO:474d364, BO:6939780)
- CHANGELOG: update summary table (279 items, 99%)
- TASKS: add Phase 9 section with detailed descriptions + update commit list (30 total)
- BIZ: update header to 'code complete — Phase 0-9 ' + add Phase 9 commits
- TECH-01: add SP Worker (Q26), History Tracking System (Q27), IHasHistory, Interceptor docs
- TECH-01: add UserWalletHistoryService (renamed from ChangeLog)
- INDEX: update R3/R6 descriptions, update timestamp
2026-02-27 06:35:09 +03:30
masoodafar-web df1affa46e docs: mark T4.2, T4.3, T4.13, F2, F3 as completed — phase 8f
- PACKAGE-TRANSFORMATION-TASKS.md: add phase 8f section, mark T4.2/T4.3/T4.13 complete
- FEATURE-BACKLOG.md: mark F2 (ChangeNetworkParent) + F3 (CalculateOrderPV) complete
- NuGet v0.0.188 | CMS:dcd1135 FO:3bffc13 BO:e020354
2026-02-26 22:10:45 +03:30
masoodafar-web 38aababc1a docs: update for Phase 8e — per-package commission reports
- PACKAGE-TRANSFORMATION-TASKS: mark T4.8-T4.12 completed, add Phase 8e section, update tree diagram, bump to NuGet v0.0.187
- OVERVIEW-03-CHANGELOG: add Phase 8e entry, mark commission per-package items done, update timeline & summary table
2026-02-26 21:13:16 +03:30
masoodafar-web e6d086b559 Docs: Phase 8b-8d — BO CRUD expansion + FO Customer RPCs + Proto cleanup
- PACKAGE-TRANSFORMATION-TASKS.md: Add phases 8b, 8c, 8d with full details
  Updated overview diagram, commit hashes, status to 0-8d complete
- OVERVIEW-03-CHANGELOG.md: Add Phase 8b (BO CRUD) + Phase 8a+8c (FO)
  Updated summary table to 99% (240/241 complete)
2026-02-26 18:04:04 +03:30
masoodafar-web a61a987b57 docs: Add Phase 8a — Checkout wire-up + NuGet plan 2026-02-26 03:36:33 +03:30
masoodafar-web d94b09878a docs: Update TASKS for Phase 7a-c completion (16 commits across 3 repos)
- Phase 7a: Cosmetic cleanup (CMS+FO+BO)
- Phase 7b: FrontOffice RPC migration to Customer* RPCs
- Phase 7c: Delete 4 deprecated CQRS handlers (1125 lines removed)
- Updated overview diagram, commit list, and footer
2026-02-26 03:06:22 +03:30
masoodafar-web 0aa126af1c Docs: Phase 5-6 completion — per-package commission + deprecation cleanup
- CHANGELOG: Phase 5 (per-pkg commission, golden cleanup) + Phase 6 (deprecation, ConfigService MagicWallet)
- ROADMAP: Progress 83%→93%, timeline updated through Phase 6
- TASKS: Mark مرحله ۳ (پورسانت) , add commits 607f791→7176fe4→d19c569
2026-02-26 01:14:51 +03:30
masoodafar-web 37330a3e45 docs: update all documentation for Package-Based Transformation Phase 0-4
- OVERVIEW-03-CHANGELOG: Add complete Package-Based section (Phase 0-4) with
  commit references, add summary table row, update timeline
- OVERVIEW-05-ROADMAP: Add Package-Based progress bar (83%), update DONE/NOW
  sections with Phase 0-4 complete and Phase 5-6 pending
- OVERVIEW-02-INDEX: Add 4 new roadmap files to index, update file counts
- BIZ-PACKAGE-BASED-SYSTEM: Status → 'در حال پیاده‌سازی — فاز 0-4 تکمیل'
  with all 7 commit hashes
- PACKAGE-TRANSFORMATION-TASKS: Mark Phase 0/1/2 as complete with commit refs,
  update overview diagram with completion markers
2026-02-26 00:32:33 +03:30
masoodafar-web 33d5ae9305 docs: BIZ-PACKAGE-BASED-SYSTEM v3 — per-package commission deep analysis
Major v3 changes:
- Q12-Q18: MaxWeeklyBalancesPerLeg, MaxNetworkLevel, MagicWalletMaxDeposit,
  MagicWalletMaxCredit all become per-package (not global SystemConstants)
- NetworkWeeklyBalance gets PackageId + Unique(UserId,WeekId,PackageId)
- SP changes: @MaxBalancesPerLeg and @MaxNetworkLevel as dynamic params
  (removing hardcoded 300/15)
- SpCommissionCalculationStrategy: pass package settings to SPs
- Carryover per-package: week-shifting only for same PackageId records
- commission.proto: package_id+package_title in 4 message types,
  new CustomerCommissionPackageSummary message, package filter in requests
- FrontOffice: commission dashboard with per-package summary cards
- BackOffice: package filter dropdown in all commission reports + CSV
- Package Create/Edit: Quick Access checkboxes for features inline
- Seed data: silver MaxBalancesPerLeg=30, MagicWalletMax=100M/250M
- Migration: NetworkWeeklyBalances existing records get base PackageId
- Impact Analysis: 39 -> 48+ changes across 6 layers
- Timeline: 14 -> 17 days critical path (+3 days for per-package work)

Updated docs:
- business/BIZ-PACKAGE-BASED-SYSTEM.md (v2 -> v3)
- roadmap/PACKAGE-TRANSFORMATION-TASKS.md (synced with v3)
2026-02-24 23:48:09 +03:30
masoodafar-web 01244f426e docs: package-based transformation — complete roadmap + UX impact + feature backlog
New documents:
- roadmap/FEATURE-BACKLOG.md: 12 kept RPCs → feature tasks with priority,
  target pages, and time estimates (F1-F12)
- roadmap/PACKAGE-TRANSFORMATION-UX.md: UX impact analysis —
  before/after wireframes for 19 pages (10 FO + 9 BO),
  customer + admin experience changes, future needs prediction
- roadmap/PACKAGE-TRANSFORMATION-TASKS.md: step-by-step implementation
  plan (6 phases, ~13 day critical path), atomic tasks with
  code diffs, dependency graph, test checklist

Updated:
- cms/GRPC-SERVICES-AUDIT.md: cross-references to new docs

Total: 998 lines of documentation covering:
- 12 RPC feature tasks prioritized by package-based relevance
- 19 page wireframes (before/after comparison)
- 39 transformation tasks broken into 6 phases
- 10 predicted future requirements (N1-N10)
- Risk analysis + rollback plan + calendar
2026-02-24 23:18:50 +03:30
masoodafar-web f5173a4def docs: فعال‌سازی درگاه ZarinPal + مرج پروداکشن + بهبود UI ادمین
- CHANGELOG: اضافه Phase 18 BackOffice + فعال‌سازی درگاه FO + تنظیمات محیطی CMS + مرج پروداکشن
- PAYMENT-FINANCE: MerchantId واقعی + تنظیمات محیطی Staging/Production + Magic فاز 6 کامل
- ROADMAP: بروزرسانی درصدها + Magic 100% + Payment 97% + DONE section
- TECH-02: ساختار فولدر + UserAutoComplete + WalletManagement + دکمه‌های درگاه
- BUSINESS-01: Magic Wallet فاز 1-6 کامل
- TECH-04: Migration پروداکشن ExpandDiscountProductFullInformation + حذف u21 تکراری
- TECH-03: جزئیات مرج پروداکشن + تنظیمات appsettings.Production.json
- MAGIC-WALLET-PLAN: وضعیت کامل
- INDEX: بروزرسانی تاریخ
2026-02-22 23:26:36 +03:30
masoodafar-web 6b6173e2be docs: rename 'تخفیفی' to 'اعتباری' across all documentation
- 9 files updated: BUSINESS-01/02/03/04, TECH-02, OVERVIEW-01/03/04, MAGIC-WALLET-SPEC
- فروشگاه تخفیفی → فروشگاه اعتباری
- کیف‌پول تخفیفی → کیف‌پول اعتباری
- Consistent naming with FrontOffice UI
2026-02-22 20:57:05 +03:30
masoodafar-web c14bea6a06 docs: update MAGIC-WALLET-PLAN checklist - all items complete
- Mark migrations as completed (u21 applied + 74 rows seeded)
- Mark ChargeDiscountWallet as fully implemented
- Update status from pending to done with details
2026-02-22 20:41:29 +03:30
masoodafar-web 421a651975 docs: Magic Wallet + VAT 10% documentation update
- All 14 totalDoc files updated with Magic Wallet additions
- MAGIC-WALLET-PLAN.md: Phase 1-6 checklist fully marked complete
- Business docs: Magic Wallet section, commission filter, new entities
- Payment docs: VAT 9%→10%, TransactionType 14+15, ZarinPal 4th usage
- Technical docs: UserWallet fields, ClubMembershipCycle, gRPC RPCs
- Overview docs: Magic flowchart, ER diagram, changelog, glossary, roadmap
2026-02-22 20:09:01 +03:30
masoodafar-web 0e61513b0e docs: add ClubMembershipCycle table to preserve activation date
Problem: ActivateClubMembership overwrites ActivatedAt on re-purchase,
losing the original club activation date. Commission check uses
ActivatedAt to determine 'new member this week'.

Solution: New ClubMembershipCycle table
- Each package purchase creates a new cycle record
- ClubMembership.ActivatedAt = first-time only (never overwritten)
- Commission uses Cycle.PackagePurchasedAt instead of ActivatedAt
- IsCurrentCycle flag tracks active cycle
- Full history preserved for all purchase cycles

Also updated:
- SPEC: section 7.5 (entity), 7.6 (migration), 8.2 (SP change), 8.3 (handler)
- PLAN: phase 1 (entity), phase 2 (activate handler), phase 4 (date query)
- Checklist: added 4 new items
2026-02-19 02:58:14 +03:30
masoodafar-web b1dd69b31f docs: fix Magic Mode exit condition — BOTH Balance=0 AND cap reached
- Exit requires BOTH simultaneously: Balance==0 AND TotalDeposited>=100M
- If Balance=0 but cap not reached → still Magic (can charge more)
- If cap reached but Balance>0 → still Magic (can spend more)
- Added examples: partial deposit (50M/100M) stays in Magic
- Fixed handler 8.1 pseudo-code
- Updated test scenarios in PLAN (7 scenarios covering edge cases)
2026-02-19 02:32:04 +03:30
masoodafar-web 2f0d43aa81 docs: clarify Magic Wallet cap is per-cycle, not lifetime
- Cap resets every time user buys a new 56M package and re-enters Magic
- MagicTotalDeposited & MagicTotalCredited reset to 0 on each new cycle
- Added multi-cycle example (cycle 1, 2, 3... ∞)
- Added section 4.3: reset behavior on re-entry
- Added test scenarios for cycle reset
- PurchaseCycleCount tracks cycles but has no limit
2026-02-19 02:17:10 +03:30
masoodafar-web a94d0dbe95 docs: add Magic Wallet spec & implementation plan
- New folder: roadmap/ for upcoming features
- MAGIC-WALLET-SPEC: full business rules, state machine, x2.5 multiplier,
  100M deposit cap, API flow, data model changes, transaction logging
- MAGIC-WALLET-PLAN: 6-phase implementation, checklist, time estimates
- Note: ChargeDiscountWallet completion is independent (not Magic Wallet)
- Note: WalletChangeLog is mandatory (not optional)
- Updated master index with roadmap section
2026-02-19 02:08:28 +03:30