HOCO B2B
Team tasksImad

MRA-07 — Reseller app — account, store, finance & settings

Account hub, store profile and documents, balance and credit, invoices, payments and payment declaration with proof, settings.

FieldDetails
Task codeMRA-07
PhaseP1 — V1 build & integration
Product scopeV1
StatusPlanned
StartWed 18 Nov 2026
DueThu 19 Nov 2026
ResponsibleImad — Mobile developer (Flutter)
Co-responsible—
Effort1.25 person-day(s) planned · 5 from scratch · size S
Area · appReseller app · mobile
Depends onDES-10, DES-09
Unblocks—
Milestones—

Summary

Account hub, store profile and documents, balance and credit, invoices, payments and payment declaration with proof, settings.

Description

The account area is where resellers manage their store record, follow what they owe and declare payments with proof, so finance figures must match the back-office exactly (CRM-01, CRM-10, FIN-01, FIN-03, FIN-05, FIN-10). Scope: account hub RA-27 (store, number, status, read-only customer type), store profile and documents RA-28, balance and credit RA-29, invoices RA-30, payments and payment declaration RA-31, and settings RA-35 (language, notification preferences, sessions, password, sign-out). Per AUTH-11 the customer type is shown but only the back-office changes it; the app offers « Demander un changement » through support. It needs profile.*, finance.summary, invoices.*, payments.*, files.*, notifications.preferences.* and auth.sessions.* (SRV-14, SRV-18, SRV-07) and Akram's DES-09/DES-10 frames. MOB-11 provides the uploads; MRA-08 handles the support request.

Subtasks

#SubtaskOwner
1AccountHubScreen RA-27: store name, REV-000123, account status pill, « Type de client : Demi-gros » (read-only with « Demander un changement » opening a support ticket), assigned delegate contact, linksImad
2StoreProfileScreen RA-28: GET/PATCH /reseller/profile for the editable fields only (others marked « modifiable via le support »), photos, documents list (GET /reseller/documents) and add (MOB-11 upload → POST /reseller/documents with DocumentType RC, NIF, NIS, AI, pièce d'identité)Imad
3BalanceCreditScreen RA-29 on GET /finance/summary: balance due, credit limit, used and available credit, next due dateImad
4InvoicesScreen RA-30: GET /invoices with status filter (« Impayée », « Partiellement payée », « Payée », « En retard », « Annulée »), invoice detail with allocated payments and PDF via signed URLImad
5PaymentsScreen RA-31: GET /payments with PaymentStatus pills (« À vérifier », « Confirmé », « Rejeté » with reason)Imad
6PaymentDeclarationForm: method (BANK_TRANSFER, CCP, BARIDIMOB), amount typed in DA and sent in centimes, payment date, reference, optional invoices, proof photo or PDF (PAYMENT_PROOF) → POST /payments/declarations with an Idempotency-KeyImad
7SettingsScreen RA-35: language (fr; ar/en behind flag), notification preferences (GET/PUT /notification-preferences, transactional categories locked on), active sessions list and revoke (auth.sessions.*), change password, sign-out, app and contract version, legal linksImad
8Pending-account handling: payment declaration and document upload states when ACCOUNT_PENDING_VALIDATION is returnedImad

Deliverables

  • apps/reseller/lib/src/features/account/ (hub, store profile, documents, settings)
  • apps/reseller/lib/src/features/finance/ (balance, invoices, payments, declaration)
  • Widget tests of the declaration form validation and of invoice status pills

Acceptance criteria

  • Balance, credit limit, used and available credit equal the back-office values for the same reseller (FIN-05, FIN-10)
  • Invoices filter by status and open their PDF; each shows the payments allocated to it (FIN-01)
  • A declaration with a proof photo appears immediately as « À vérifier » and is not duplicated by a retry (FIN-03)
  • The customer type is visible but not editable in the app (AUTH-11)
  • Transactional notification categories cannot be disabled; promotional ones can (NOT-06)
  • Revoking another session signs that device out on its next request (AUTH-06)

Requirements covered

RequirementTitleRelease
CRM-01Reseller/prospect record with the minimum data set (store, owner, phone, WhatsApp, email, wilaya, commune, address, GPS, type, potential, delegate, photos, documents, status)V1
CRM-10Store photos and documents (façade, interior, RC, NIF, ID) with protected accessV1
FIN-01Invoices generated from orders with legal mentions and PDF; statuses unpaid, partially paid, paid, overdue, cancelledV1
FIN-03Payment recording in the back-office and payment declaration with proof by the resellerV1
FIN-05Basic credit control: ceiling, used and available credit checked at checkoutV1
FIN-10Reseller finance view: balance, available credit, invoices, paymentsV1
NOT-06Notification preferences (marketing opt-out)V1

Screens

ScreenNameApp
RA-27Account hubRA
RA-28Store profile & documentsRA
RA-29Balance & creditRA
RA-30InvoicesRA
RA-31Payments & payment declarationRA
RA-35SettingsRA

API surface

Test measures

  • Widget tests of the declaration form (amount parsing to centimes, required proof, method list)
  • Integration test: declare payment with proof → appears in the payments list as PENDING_VERIFICATION
  • Golden tests of the finance screens with large amounts and zero balances

Risks

  • Which store fields resellers may edit is not fully settled — drive editability from the profile response (editable flags) rather than hard-coding

KPI

  • Delivered by Thu 19 Nov 2026 within 1.25 person-day(s).
  • Every acceptance criterion above demonstrated before hand-off; linked requirements' acceptance criteria pass.
  • Zero open critical defects, permission gaps or data-integrity regressions at sign-off.

Generated from content/plan/tasks.json by scripts/generate-team-tasks.mjs. Dates are computed by the scheduler (Sunday–Thursday weeks, holidays excluded) — change the plan, not this page.

On this page