Repository navigation
Release: merge dev into main - #5
Merged
Merged
Conversation
Phase 2-6: fix response types, create model types & mappers, wire services, update views/components for ordering, payment, shipping. - order.response.type: remove nested collections, use decimal totals - payment.response.type: status as number, not string - payment-method/shipping-rate/shipping-method: align with C# spec - model types with display helpers + mappers for all 5 domains - services wrapped to map DTOs → model types - stores use model types; views/components updated for new shapes - removed sections referencing removed nested collections
…, add service layers - Refactor api.client.ts into modular interceptors (auth, camelCase, error-wrapper) - Convert all API repository files from .then() to async/await - Rename PascalCase type/schema files to kebab-case across all features - Add proper service layers between repositories and stores - Remove trivial mapper files (inventory, location, ordering, payment, shipping) - Add model types, shared utils (currency, enums, transform), and handler specs - Simplify AdminUserSummary response type (remove roleNames, lastSignInAtUtc, lastIpAddress) - Clean up UI templates to match updated response types
…lassifications, variant option-values)
- Export OrderLineItem interface from order.api.ts - Add resume, updateLineItem, removeLineItem, listLineItems to orderService - Add resumeOrder, updateLineItem, removeLineItem to orderStore - Add resume button (visible when status is Canceled) to OrderDetail view - Replace placeholder text with DataTable for line items with inline quantity editing - Add i18n keys for resume, line-item update/remove messages - Load line items via listLineItems on mount and after relevant mutations
…ror handling, file upload label
…s layout, menu, components, modules, forms, dashboards
…e to dot-notation names
…-secrets - Remove hardcoded DB password from appsettings.Development.json - Add ConnectionStrings:DefaultConnection to setup-dev-secrets.sh - Add optional Stripe secret key support via env vars - Replace hardcoded password in .env.template with placeholder - Update dev secrets setup comment to reflect all managed secrets
* fix(catalog): fetch variants immediately when productId present
* refactor(catalog): drop unused get import from variant list services
* docs(catalog): reconcile plan with standalone variant routes
* fix(catalog): address final review minors for variant list alignment
* refactor(catalog): flatten feature routes and move parent ids out of paths
Flatten CatalogFeature endpoint constant groups into sibling entity
classes (Admin and Storefront) and relocate nested parent ids from URL
path segments into request bodies for commands and query parameters for
queries, per plan/refactor-catalog-feature-1.md.
- Rewrite CatalogFeature.Admin/Storefront into flat entity-group shape
- Relocate VariantId/ProductId/TaxonId/OptionTypeId parent ids to bodies
and query strings; rename PermissionContext resource descriptors
- Move OptionValues, ProductOptionTypes, VariantOptionValues feature
folders and update all endpoints, smoke tests, and unit/integration tests
* feat(admin): add delWithBody helper for delete-with-body endpoints
* refactor(catalog): flatten taxon service routes and reconcile taxon tree
* refactor(catalog): flatten taxon rule service routes
Rewrite taxonRuleApi.ts against flat api/catalog/taxon-rules base, move
taxonId into create/update bodies, use delWithBody for delete, add
syncRules. Update TaxonRuleFormDialog call sites and taxonRuleApi spec.
* refactor(catalog): flatten product option type service routes
* refactor(catalog): flatten product classification service routes
* refactor(catalog): flatten variant option value routes and add sync
* refactor(catalog): flatten variant price routes and add sync
* refactor(catalog): flatten variant image routes and add blob download
* fix(catalog): use PATCH for product activate and discontinue
* refactor(catalog): add dedicated type and validation files for option types, classifications, prices, images, embeddings
* feat(catalog): add image embedding API service
* feat(catalog): add taxonomy restore and catalog dashboard services
* feat(catalog): add catalog feature composables wrapping usePagedQuery
* test(catalog): add service specs for option types, classifications, embeddings, dashboard and fix flat option-value URLs
* feat(identity): add role and user form validations
* feat(identity): add role, user, and permission types
* feat(identity): add role API service
* feat(identity): add user API service
* feat(identity): add permission API and role/user stores
* feat(identity): add role and user list/detail composables
* test(identity): add role, user, and permission specs
* feat(inventory): add stock item, location, and transfer form validations
* feat(inventory): add stock item, location, movement, reservation, and transfer types
* feat(inventory): add stock item API service
* feat(inventory): add stock location API service
* feat(inventory): add stock movement API service
* feat(inventory): add stock reservation API service
* feat(inventory): add stock transfer API service
* feat(inventory): add inventory dashboard API and stock stores
* feat(inventory): add stock list composables
* test(inventory): add stock service, validation, type, and store specs
* feat(ordering): add order and ordering dashboard types
* feat(ordering): add order form validations
* feat(ordering): add order API service
* feat(ordering): add ordering dashboard API and order store
* feat(ordering): add order list and detail composables
* test(ordering): add order service, validation, type, and store specs
* feat(payment): add payment method and payment types
* feat(payment): add payment method form validations
* feat(payment): add payment method API service
* feat(payment): add payment API and payment method store
* feat(payment): add payment and payment method composables
* test(payment): add payment and payment method specs
* feat(profile): add profile and address form validations
* feat(profile): add profile and address types
* feat(profile): add profile API service
* feat(profile): add address API and profile/address stores
* feat(profile): add profile and address composables
* test(profile): add profile and address specs
* feat(shipping): add shipping method and shipping rate form validations
* feat(shipping): add shipping method and shipping rate types
* feat(shipping): add shipping method and shipping rate API services
* feat(shipping): add shipping method and shipping rate stores
* feat(shipping): add shipping method and shipping rate composables
* test(shipping): add shipping method and shipping rate specs
* feat(location): add country and state by-iso lookups
* feat(dashboard): add dashboard types
* feat(dashboard): add dashboard API and store
* feat(dashboard): add useDashboard composable
* test(dashboard): add dashboard api, type, and store specs
* fix(admin): normalize query consts and filter DSL to camelCase to match client-side validation
* fix(identity): route role name lookup through search fields to match backend filter whitelist
* chore(admin): fix lint errors in shared and auth code to pass quality gate
* chore(admin): replace vi.fn<any>() with typed mocks to pass eslint
* fix(catalog): use flat option-values route in OptionTypeDetail
* docs(plan): mark feature-admin-data-layer-1 complete with task completion dates
* fix(inventory): normalize stock movement and reservation query consts to camelCase
* docs(spec): design remaining 27 admin views across 7 modules
* docs(plan): 8 implementation plans for remaining 27 admin views + cleanup
* feat(dashboard): replace placeholder with stat cards grid
* feat(identity): implement users list view with search, delete, export
* feat(identity): implement user detail view with profile and roles tabs
* feat(identity): implement roles list view with search, delete, export
* feat(identity): implement role detail view with profile and permissions tabs
* feat(identity): implement permissions list view (read-only)
* feat(inventory): implement stock items list view
* feat(inventory): implement stock item detail view
* fix(inventory): ensure current variant always present in stock item dropdown
* feat(inventory): implement stock locations list view
* feat(inventory): implement stock location detail view
* feat(inventory): implement stock reservations list view (read-only)
* feat(inventory): implement stock transfers list view
* feat(inventory): implement stock transfer detail view
* feat(inventory): implement stock movements list view (read-only)
* feat(ordering): implement orders list view with status filter
* feat(ordering): implement order detail view with overview, items, and payments tabs
* feat(payment): implement payments list view (read-only)
* feat(payment): implement payment methods list view
* feat(payment): implement payment method detail view
* feat(profile): implement profiles list view
* feat(profile): implement profile detail view with addresses tab
* fix(payment): harden Stripe webhook endpoint, fix PII leak, add concurrency control
Security fixes:
- Add 64KB request body size limit + webhook rate limiter (DoS prevention)
- Strip encrypted gateway Settings from storefront PaymentMethod response
- Replace raw Stripe payload in error logs with safe metadata (PII leak)
Correctness fixes:
- Add Stripe event ID deduplication via ProcessedStripeEventIds jsonb column
- Add RowVersion optimistic concurrency on PaymentCapture entity
- Add retry-on-concurrency-conflict to admin RefundPayment handler
- Fix StockReservationExpiryMinutes comment (code is 30 min, not 30 days)
- Log ignored webhook event types (requires_action, processing)
Tests:
- Add Inventory integration tests (stock transfer lifecycle, reservation expiry)
- Add Inventory schema to ApiFixture AllSchemas for proper test isolation
Co-Authored-By: Claude <noreply@anthropic.com>
* fix(profile): navigate to profile detail by userId to match detail view contract
* feat(profile): implement addresses list view
* fix(profile): gate addresses list on the baked userId to prevent empty-userId fetches
* feat(profile): implement address detail view
* fix(profile): thread owner userId into address edit links
* feat(shipping): implement shipping methods list view
* feat(shipping): implement shipping method detail view
* feat(shipping): implement shipping rates list view
* feat(shipping): implement shipping rate detail view
* chore(admin): remove unused feature directories (reports, users, error/pages)
* docs(concerns): record admin cross-feature import deviation and pagination follow-up
* refactor(catalog): reorganize variant image get endpoints into Get tree
Move GetById and ListByVariant under a Get/ hierarchy. Rename
ListVariantImages to GetVariantImagePagedOrAll, introduce a Response
record, and drop the default position sort to align with the paged
querying conventions used across the catalog module.
* docs: add CLAUDE.md agent guidance for repo commands
* feat(catalog): update option value endpoints and adjust tags for consistency
* feat(catalog): add fashion attributes to admin product model
Extend the product domain, parameters, and mapping with fashion-specific
fields (style code, season, material, care, fit, department, gender target)
and reorganize shared product models into regions for maintainability.
Also:
- include classifications and their taxons in the paged product query
- surface ClassificationsCount on list items
- drop variant pricing/dimension passthrough from the update request,
deriving the master variant SKU and inventory flag from the entity
- remove the permission requirement from variant image download
- add a dev proxy from the Admin SPA to the API
- trim unused role parameter fields and expose role id/system flag
* feat(catalog): rework product factory signature and wire fashion fields
Reorder ProductMethod.Create to derive the slug from the product name
(overridable via slug:), add region-based parameter organization, and
thread fashion attributes (style code, season, material, care, fit,
department, gender target) through the domain factory, admin mappings,
and demo seeder.
Also:
- seed product FitNotes and parse status from demo JSON
- restore the default position sort in GetVariantImagePagedOrAll
- migrate product tests to named factory arguments, fixing the slug
duplicate, ordering, and rule-evaluator regressions from the reorder
* docs(spec): add admin catalog views corrections design
* docs(plan): add admin catalog views corrections implementation plan
* fix(catalog): return full option-value and image sets to admin
* fix(catalog): full-set paging via empty params and aligned variant services
* feat(catalog): add product status actions and server paging to list
* feat(catalog): wire option types list to server-side paging
* fix(catalog): repair product classification and option type tabs
* docs(plan): record review-driven corrections for getPaged and PickList binding
* feat(catalog): add lazy searchable product options composable
* fix(catalog): reset loading on rejection and guard stale responses
* feat(catalog): refactor variants list with product selector
* fix(catalog): final-review fixes for variants list and product detail
- VariantsList: consolidate product change to one fetch (productId watch
drives reset+fetch; route watcher only syncs from route; drop redundant
setSearch/setPage/refresh); clear stale searchTerm on product change;
gate DataTable behind v-else so error and table are exclusive.
- ProductDetail: gate 'no option types/classifications' empty states on
the loaded flags so failed loads don't show misleading messages.
* docs(spec): storefront MVP - remove USE_MOCK and enable real API
Co-Authored-By: Claude <noreply@anthropic.com>
* docs(plan): storefront MVP - 8 tasks to remove USE_MOCK and hide dropped features
Co-Authored-By: Claude <noreply@anthropic.com>
* fix(storefront): align API repos with backend routes
Apply prior code-review fixes before the USE_MOCK removal plan:
- Fix double-unwrap bug in response interceptor
- Align category, product, similar-products, shipping-rate, search routes
- Add missing cart endpoints (create, delete, checkout details, associate,
validate, shipping-rate select) and fix clearCart to POST /cart/empty
- Add order cancel endpoint
- Wire recommendations, search, and notifications stores to services
- Remove dead code (legacy interceptors, api service, stale router)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): flip catalog services to real API (P1)
Remove USE_MOCK from product, category, and search services.
All three now use only their ApiRepository.
Co-Authored-By: Claude <noreply@anthropic.com>
* fix: correct admin catalog upload, variant option values, paging binding, and filters
- client: clear Content-Type for FormData bodies so axios sends multipart
instead of serializing to JSON (fixes 415 on variant-image/stock-item upload)
- variantApi.getVariants: omit empty productId query param so backend
Guid? binding no longer fails (stock transfer/item variant selection)
- migrations: add processed_stripe_event_ids jsonb + xmin rowversion to
payment_captures (were missing from InitialCreate)
- variant detail: replace checkbox wall with product-scoped MultiSelect
per option type for assigning option values
- lists: add related-select filters (products dept/season/status, option
types filterable, stock items location, transfers source/destination,
orders checkout state)
* fix: user roles, enum strings, UTC dates, antiforgery, variant option rule, select lists, taxon tree
- user roles: only filter isAssigned roles into assignedRoleNames (all
roles were previously checked)
- api: register global JsonStringEnumConverter so enums serialize as
names (product status etc.) instead of numbers
- dates: add formatDateTimeUtc/toUtcIso/fromUtcToDateInput shared utils;
apply local-time display across list/detail views; product
availableOn/discontinueOn now round-trip UTC
- antiforgery: dev env overrides CookieSecurePolicy to SameAsRequest so
uploads over http no longer throw SecurePolicy=Always
- variant option values: enforce exactly one value per option type in
Assign/Sync (backend) + single-select swap in the MultiSelect UI
- select lists: fetchActive stores request full set without paging/sort
- taxon detail: parent picker now a TreeSelect with nested hierarchy
- build: fix pre-existing DateTimeOffset conversion errors in identity
auth + test mocks that blocked compilation
* refactor(catalog): remove taxon tree feature from admin frontend
- delete taxonTreeStore, useTaxonTree composable, and their specs
- remove TaxonApi.getTree and TaxonTreeItem type
- TaxonsList: drop tree view mode (TreeTable + toggle); table only
- TaxonomyDetail: drop taxon TreeTable; keep form + add-taxon button
- TaxonDetail: parent picker back to flat Select from the taxon list
endpoint
* refactor(catalog): rename Paged query slices to PagedOrAll
Rename the GetTaxonomiesPaged and GetOptionValuesPaged feature slices to
GetTaxonomiesPagedOrAll and GetOptionValuesPagedOrAll, moving them from
the Get/Paged directory into Get/PagedOrAll.
The slice captures both a paged and full list retrieval (ToPagedOrAllAsync),
so the Paged name was misleading. Only naming and namespaces change; logic,
routes, permissions, and response contracts are unchanged.
- Move feature files to Get/{Taxonomies|OptionTypes/Values}/Get/PagedOrAll/
- Rename Query/Handler/Parameters/Endpoint types and namespaces
- Update GetTaxonomiesPagedUseCase tests to reference the new slice
* refactor(security): use DateTimeOffset for token and audit timestamps
Replace DateTime with DateTimeOffset across auth token models, the token
blacklist service, token theft detector, refresh token service, user
security audit loggers, and the module dashboard responses (catalog,
dashboard, inventory, ordering).
DateTimeOffset preserves a stable UTC instant and avoids the ambiguity of
naive DateTime in serialized API boundaries. Domain entities already store
timestamps as DateTimeOffset, so response models and loggers now align with
persistence types instead of projecting to DateTime.
- TokenBlacklistService: BlacklistTokenAsync takes DateTimeOffset expiry
- RefreshTokenService: compute sliding max-age as DateTimeOffset
- UserLoggers / TokenTheftDetector: audit timestamps as DateTimeOffset
- Dashboard response models: CreatedAtUtc / Timestamp as DateTimeOffset
- Update unit tests accordingly and correct a stale test DisplayName
* docs(spec): remove forced Pinia stores from admin frontend design
* docs(plan): remove forced Pinia stores from admin frontend implementation plan
* feat(admin): add shared useActiveList composable for fetch-once option lists
* feat(admin): add fetch-active composables for countries, stock locations, taxonomies, users
* feat(catalog): extend useTaxonList with taxonomy scope and add useTaxonDetail composable
* chore(admin): remove dead Pinia stores and empty store barrels
* refactor(admin): rewrite dashboard page on useDashboard and useActiveUsers composables
* refactor(catalog): rewrite taxons list on useTaxonList and useActiveTaxonomies composables
* refactor(catalog): rewrite taxon detail on useTaxonDetail and useActiveTaxonomies composables
* refactor(location): rewrite states views on useActiveCountries composable
* refactor(inventory): rewrite stock item views on useActiveStockLocations composable
* refactor(inventory): rewrite stock transfer views on useActiveStockLocations composable
* chore(admin): remove replaced Pinia stores, keep authStore as the single store
* docs(plan): record approved barrel-prune and vue-tsc --build amendments
* fix(catalog): reset taxon list page when taxonomy scope changes
* docs(plan): correct new composable and spec counts
* rename(store): store -> storefront
* feat(mvp): flip identity services to real API (P2)
Remove USE_MOCK from auth and user services.
Co-Authored-By: Claude <noreply@anthropic.com>
* rename
* feat(mvp): flip cart/order services and align cart API contract
Flip USE_MOCK in cart and order services. Realign add-to-cart to send
{variantId, quantity}, selectShippingRate to send {shippingMethodId},
and cart response types/mapping to the backend CartDetailResponse shape
(itemTotal, itemCount, checkoutState, items with variantId/variantName/sku).
Co-Authored-By: Claude <noreply@anthropic.com>
* test(ordering): update cart unit tests to the variantId add-to-cart contract
cart.service.test.ts now mocks the cart API repo and exercises the new
addToCart(variantId, quantity) signature; cart.repository.test.ts passes
numeric quantities to the mock addItem and asserts the mapped result.
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(ordering): enrich storefront cart items with product name and image
CartItem response now carries ProductName and ProductImageUrl, enriched
from the product entity in GetCart and AddToCart. Enables the storefront
cart page to render product thumbnails and display names.
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): flip payment and shipping services, align payment-intent body
Flip USE_MOCK in payment-intent, payment-method, shipping-method,
shipping-rate. Payment-intent create now sends {amount, currency,
orderId, paymentMethodId} matching the backend contract.
Co-Authored-By: Claude <noreply@anthropic.com>
* docs: demo seeder refactor design — domain-driven single-responsibility pipeline
* feat(mvp): align address, shipping-method, payment-method contracts to backend
Update schemas, response types, and mappings to the real backend shapes:
addresses (address1/zipCode/countryName/stateProvince), shipping methods
(name/calculatorType, no price), payment methods (providerKey, no enum type).
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): flip remaining 7 services to real API (P5)
All 18 services now use real API repositories. Zero USE_MOCK remaining.
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): wire home page handlers to cart store and router
Replace console.log placeholders with real cartStore.addItem(),
router navigation for category/product clicks, and wishlist redirect.
Co-Authored-By: Claude <noreply@anthropic.com>
* docs: demo seeder refactor implementation plan
* docs: fix Task 4 smoke-test embedding copy in seeder plan
* feat(mvp): rewrite CBIR view with real API pipeline and 4-state model
Remove hardcoded Unsplash mock data. Wire searchByImage() from
recommendationsService. Implement Empty->Upload->Loading->Results state
machine. Add similarity score badges, query image sidebar.
Hide You May Also Like (backend returns 501).
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(seed): add domain core modules for demo seed ETL
* fix(storefront): map PagedResult from CBIR search-by-image into Product[]
* refactor(seed): split taxonomy extractor into per-entity scripts
* docs: fix taxon slug allocation order in seeder plan to match old output
* feat(mvp): rewrite checkout with 5-step pipeline and real API data
Replace inline uuidv4 mock data with orderStore.fetchCheckoutData().
Implement 5-step progress indicator (Address→Delivery→Payment→Confirm
→Complete). Load real addresses, shipping methods, payment methods.
Wire place order via orderStore.checkout(). Hide save-payment checkbox.
Co-Authored-By: Claude <noreply@anthropic.com>
* fix(seed): allocate master-category taxon slug before sub-category slugs
* refactor(seed): split product extractor into per-entity scripts with variant cap
* feat(mvp): add forgot password two-step flow view
New ForgotPasswordView with email entry and token-based reset steps.
Backend: POST /api/store/identity/passwords/forgot + /reset.
Route: /forgot-password (guest). Wire login forgot-password link.
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): add session management view
Route: /account/sessions. Shows active sessions with device info,
IP address, last activity. Current session badge. Logout button.
Co-Authored-By: Claude <noreply@anthropic.com>
* refactor(seed): renumber dataset outputs and add invariant verification
* feat(mvp): add wishlists feature with full CRUD and view
New types, API repo, service, Pinia store, WishlistsView.
Backend: /api/store/profiles/wishlists (full CRUD exists).
Route: /account/wishlists. Create/delete wishlists, expand to see items,
remove items. Empty, loading, and error states.
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): add notification preferences view
Toggle grid for per-category email/SMS preferences.
Backend: GET/PUT /api/store/profiles/notification-preferences.
Route: /account/notifications.
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(mvp): hide dropped features from UI
Hide with v-if='false': Google OAuth, reviews, search suggestions,
avatar upload, newsletter form. Fix dead footer links with '#'.
All code preserved — only visibility toggled.
Co-Authored-By: Claude <noreply@anthropic.com>
* chore(mvp): wire cart badge to cartStore and remove counter boilerplate
Co-Authored-By: Claude <noreply@anthropic.com>
* refactor(catalog): split demo seeders into single-entity classes
* refactor(inventory): point seeders at numbered demo datasets
* fix(mvp): resolve demo blockers — ResponseCode, ConfirmationService, AccountNav, cart refresh
C1: Backend StorePaymentDetailResponse + mapping now expose ResponseCode.
Frontend PaymentIntent type + mapping + CheckoutView use responseCode.
C2: ConfirmationService registered in main.ts (Wishlists delete dialog).
M1: AccountNav now links Wishlists, Notifications, Sessions, Profile.
M2: Cart refreshed after shipping-rate select — Confirm step totals accurate.
Co-Authored-By: Claude <noreply@anthropic.com>
* fix(seed): restore embedding-completeness check in verify gate
* feat(admin): migrate catalog DataTables to server-side lazy pagination and sorting
Switch all catalog list views (OptionTypes, Products, Taxonomies, Taxons,
Variants) from client-side filter-display="menu" to server-side lazy mode.
Adds onPage, onRows, onSort handlers wired to usePagedQuery. Clears search
and filter state on filter reset. VariantsList gains variantType filter,
multi-select, and CSV export.
Co-Authored-By: opencode <noreply@opencode.ai>
* feat(admin): migrate inventory/location DataTables to server-side lazy pagination and sorting
Switch CountriesList, StatesList, and StockItemsList from client-side
filter-display="menu" to server-side lazy mode. Adds onPage, onRows, onSort
handlers and computed first offset for server-driven pagination. Clears filter
state on reset for CountriesList, StatesList, and StockItemsList.
Co-Authored-By: opencode <noreply@opencode.ai>
* feat(storefront): add payment intent and transaction mock repositories with tests
Add IPaymentIntentRepository interface, PaymentIntentApiRepository,
MockPaymentIntentRepository with unit tests, and mock payment data.
Add MockTransactionRepository with unit tests for getByOrderId and getById.
Enables isolated storefront development without backend API.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix(storefront): stub TransactionService with empty result for MVP
Drop mock repository dependency in TransactionService and return empty array.
No storefront API for payment transactions exists yet, so the service
returns a successful empty result to avoid runtime errors.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix(api): prefix master variant SKU with MASTER- in demo seeder
Prepend MASTER- to SKU for master variants to distinguish them from style
variants in the catalog demo data. Ensures unique SKUs across master and
style variants during seeding.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix(mvp): wire address creation in checkout, restore deleted mock files
CheckoutView Step 1 now creates addresses via the real
POST /api/store/profiles/addresses endpoint. Removed the
'MVP: dropped' marker — the backend endpoint exists and
was always available. Form fields aligned to the locations
Address schema.
Restored 30 mock repository/data files that were deleted
during earlier commits — these are referenced by existing
unit tests and barrels.
Co-Authored-By: Claude <noreply@anthropic.com>
* chore(storefront): remove unused mock files, clean barrel exports
Deleted 11 mock data/repo files that no production code or test imports.
Cleaned mock exports from 9 repository barrel files.
Wire address creation in CheckoutView via real API endpoint.
Restore 6 mock data files needed by tests from git history.
Build passes, tests unchanged from baseline.
Co-Authored-By: Claude <noreply@anthropic.com>
* chore(storefront): delete remaining unused mock files
Removed mock repos and data files not imported by any test or production code.
Co-Authored-By: Claude <noreply@anthropic.com>
* docs(admin): provision code commenting standard in app/Admin/AGENTS.md
* docs(admin): add template section commenting standard to README
Append the Template Section Commenting Standard section (REQ-005) with the
Section comment format and canonical List-view (PAT-002) / Detail-view
(PAT-003) section orders.
* docs(admin): add View Code-Commenting Rules section
* docs(admin): annotate auth views with code commenting standard
* docs(admin): annotate catalog views with code commenting standard
* docs(admin): fix F8 label in taxons list filter comment
* docs(admin): annotate dashboard view sections
* docs(admin): annotate identity views with code-commenting sections
* docs(admin): annotate inventory views with code-commenting sections
* docs(admin): annotate location views with code-commenting sections
* docs(admin): polish location view comments after review
* docs(admin): annotate ordering views with code-commenting sections
* docs(admin): annotate payment views with code-commenting sections
* docs: tighten wording in AGENTS.md and CLAUDE.md
Condense agent guide and Claude instructions by removing filler words,
contractions, and redundant phrases. No content changes — purely editorial
to improve scan-ability for LLM consumers.
Co-Authored-By: opencode <noreply@opencode.ai>
* docs(admin): fix F8 label in payment method detail load comment
* refactor(api): add idempotent SaveChangesWithIdempotencyAsync to AbstractDataSeeder
Add SaveChangesWithIdempotencyAsync method that catches Postgres unique
constraint (23505) and foreign key (23503) violations, clearing the change
tracker and returning Result.Failure with a typed error. Migrate all 18
seeders across Catalog, Inventory, Location, Ordering, Payment, Profile,
and Shipping modules from raw SaveChangesAsync to the new idempotent method.
Co-Authored-By: opencode <noreply@opencode.ai>
* refactor(api): per-taxonomy slug dedup and conditional slug generation
TaxonSeeder now tracks used slugs per taxonomy instead of globally, so the
same slug can exist across different taxonomies. TaxonMethod.Create and
Update skip slugging when an explicit slug is provided. Add unique index on
(TaxonomyId, Slug) in TaxonConfiguration. Remove global unique slug index
from SluggableConfiguration. VariantSeeder deduplicates SKUs in-memory and
prefixes master variants with MASTER-.
Co-Authored-By: opencode <noreply@opencode.ai>
* refactor(api): simplify DeleteUser and UpdateUser command contracts
Remove DeleteUser.Request record — Command now takes Guid Id directly via
primary constructor. Add [FromRoute] attribute to endpoint parameter. Remove
redundant Id property from UpdateUser.Request since it is already provided
via route.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix(api): map actual Currency in Payment model and handle deleted VariantImage
Use payment.Currency instead of string.Empty in PaymentModelMapping for
both list and detail projections. In EmbeddingOrchestrator, verify the
VariantImage still exists before persisting and catch foreign-key violations
(23503) on SaveChanges to return a typed error. Add warning log event for
the deleted-image race condition.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix: fallback to USD for empty currency in formatCurrency, unique variant SKUs
Admin formatCurrency now trims and falls back to USD when currency is empty
or whitespace, preventing Intl errors. Demo seed variant SKU generator now
appends a 4-char SHA256 digest of the full product name to prevent prefix
collisions (e.g. "Peter England Men …" products). Taxon slug generation in
Python seed script uses per-taxonomy slug sets matching the C# seeder fix.
Add SKU uniqueness verification in output validator.
Co-Authored-By: opencode <noreply@opencode.ai>
* test(api): update unit tests for seeders, taxons, identity, and sluggable config
Add tests for AbstractDataSeeder.SaveChangesWithIdempotencyAsync covering
duplicate-key, foreign-key, and success paths. Add Taxon slug tests verifying
explicit slug preservation and empty-slug fallback. Update DeleteUser and
UpdateUser tests to use simplified Command(Request) and Request-less constructors.
Remove Sluggable unique-index tests since the global index was removed in
favor of per-entity indexes.
Co-Authored-By: opencode <noreply@opencode.ai>
* chore(migrations): regenerate InitialCreate migration for taxonomy slug index
Delete old InitialCreate and AddProcessedStripeEventIds migrations. Add new
InitialCreate migration reflecting the per-taxonomy unique slug index
(ix_taxa_taxonomy_slug). Update ApplicationDbContextModelSnapshot to match.
Co-Authored-By: opencode <noreply@opencode.ai>
* docs(admin): annotate profile views with code-commenting sections
* docs: add variant image embedding management UI design spec
* docs: fix spec self-review ambiguities (MarkPending, CreatePending)
* docs: add variant image embedding management implementation plan (16 tasks)
* docs: fix plan — DeleteEmbedding house pattern + remove invalid Shared.Persistence usings
* feat: add EmbeddingStatus enum and tracking fields to ImageEmbedding domain
* feat: add status transition methods and CreatePending to ImageEmbedding domain
* docs(admin): fix F8 labels in profile detail load comments
* feat: add EmbeddingStatus migration with Status/Error/HangfireJobId/CompletedAtUtc columns
* docs(admin): annotate shipping views with code-commenting sections
* feat: add RunAsync method to embedding orchestrator with status transitions
* fix: guard against empty error lists in RunAsync and strengthen orchestrator tests
* feat: add Status/Error/HangfireJobId/CompletedAtUtc to EmbeddingDetailResponse
* feat: add Get and Delete route constants for variant image embeddings
* feat: add GetEmbedding GET endpoint for variant image embeddings
* feat: convert CreateEmbedding to Hangfire job with Pending-row pattern
* feat: convert RegenerateEmbedding to Hangfire job with MarkPending
* feat: add DeleteEmbedding DELETE endpoint for variant image embeddings
* feat: migrate UploadVariantImage auto-embed to Pending-row + RunAsync pattern
* docs(admin): add Boundary header comments to feature view barrels
* feat: add Status/Error/HangfireJobId/CompletedAtUtc to EmbeddingDetailResponse type
* feat: add get and deleteEmbedding methods to ImageEmbeddingApi
* chore(admin): label remaining API, confirm, and guard sites across views
Close the full-and-necessary audit for all feature views by labeling the
last unlabelled await/confirm.require/validation sites (Load, Call,
Trigger, Validate) with Code Commenting Standard v3.0 labels.
* chore(admin): simplify newly added Call comments to single-action wording
Reword four Task 15 Call labels to keep F8 compliance (one action per
comment) by dropping trailing refresh clauses.
* feat: add useEmbeddingStatus composable with polling
* chore(admin): add missing Call and Validate labels in payment and profile views
* chore(admin): reword two auth Call labels to carry WHY per Task 19 audit
The labels restated the invoked API verbatim (AP-1). Keep the required
Call: label but encode intent the code does not show: email the reset
link only when the account exists; confirm the token before resetting.
* feat: add inline embedding status and management UI to VariantDetail Images tab
* docs(plan): mark process-code-commenting-admin-components-1 all 19 tasks complete
* test(api): update PaymentMapping test to assert actual Currency value
Align ToDetail test assertion with the Payment.Currency mapping fix from
commit 6bcac8a. The test previously expected an empty string, now it
verifies the actual Currency property is mapped through.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix(api): add NotFoundByVariantImage error and save Pending row before Hangfire enqueue
Add dedicated NotFoundByVariantImage error code for embedding lookups by
variant image ID. In Create and Regenerate handlers, persist the Pending
embedding row before enqueueing the Hangfire job so the background worker
never encounters a missing row. Use the specific error in Get and Delete
handlers when no embedding exists for the given variant image.
Co-Authored-By: opencode <noreply@opencode.ai>
* test(api): update embedding tests for NotFoundByVariantImage error code
Align DeleteEmbedding and GetEmbedding tests with the new error code
introduced in commit ba43ef6.
Co-Authored-By: opencode <noreply@opencode.ai>
* fix: make ImageEmbedding.Vector nullable so Pending rows persist (pgvector rejects empty vector)
CreatePending wrote an empty float array into the pgvector column, which
Postgres rejects with '22000: vector must have at least 1 dimension'. A
Pending embedding has no vector yet, so make the column nullable and store
NULL until MarkCompleted writes the real vector. Add migration; null-guard
storefront vector search and orchestrator response mapping.
* feat: restrict embedding management to Search-type images
Only the Search-type image (the AI semantic-search source) should carry an
embedding. Gate the per-card embedding badge/actions and 'Generate All
Missing' to Search-type images, and add an image-type selector to the card
so the admin can designate the search image. Align VectorSearchService to
query Search-type embeddings (was Default), matching the upload auto-embed
trigger, and update the storefront tests accordingly.
* feat: confirm before changing image type to Search or Default
* feat: enforce single Default and single Search image per variant
When an image is set (or uploaded) as Default or Search, demote the prior
image in the same variant holding that type to Thumbnail. Enforced in the
backend Update and Upload handlers so the invariant holds regardless of
client.
* feat(admin): re-enable auth guard with guest-only and post-login redirects
The auth guard was previously disabled behind a TODO after the route
scaffold review. Re-enable it so protected routes require authentication
and guest-only pages (login, forgot-password, reset-password) redirect
authenticated users to the dashboard.
Introduce the guestOnly route meta flag and a resolvePostLoginRedirect
helper that safely validates the redirect query param before resuming the
original destination, falling back to the dashboard when absent or unsafe.
Add unit tests for the guard's redirect logic and the post-login redirect
resolver, plus the feature plan file.
---------
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: opencode <noreply@opencode.ai>
…ts (#3) * feat(billing): auto-place order on checkout.session.completed and void on expired * feat(store): add cancelUrl/checkoutUrl types and payment status API * feat(store): expose checkoutUrl and paymentState from createPaymentIntent * feat(store): payment method selection with Stripe Checkout redirect * fix(store): allow null clientSecret for COD and gate review on payment id * feat(store): add checkout return page that polls payment status * test(billing): cover COD Pending and card checkout-url intents * test(billing): document persistent gateway registration in card intent test * chore(store): fix pre-existing lint errors * chore: fix feature-convention check false positive and acknowledge legacy deviations * chore: update cross-module refs baseline to 33 * docs(billing): correct plan filter and namespace for create-order-from-cart task * fix(billing): store PaymentIntent id after checkout session completes * fix(ordering): verify payment completed before webhook placement * test(billing): cover COD gate and webhook checkout.session handlers * fix(billing): find completed session by PaymentIntent id on webhook retry * fix(store): accept null checkoutUrl/responseCode/state in payment intent response * feat(ordering): allow checkout re-pick and payment retry - Order.RegressCheckoutState: backward transitions (Payment->Delivery, Payment->Address, Delivery->Address) for Draft orders so customers can re-pick address, shipping, or payment before placing the order. - RegressCheckoutStateCommand + handler (cross-module, webhook-driven). - UpdateCheckout regresses Payment->Delivery when the address changes; SelectShippingRate regresses Payment->Delivery when the method changes. - CreatePaymentIntent accepts Delivery or Payment (retry); at Payment it voids stale non-completed captures and re-reserves stock. - checkout.session.expired webhook regresses the cart Payment->Delivery so an abandoned Stripe session no longer leaves the order stuck. - Store SPA watcher clears payment context on any regression out of Payment. * docs(billing): add stripe webhook delivery + return verification plan * docs(billing): revise webhook plan to Option A + diagnostic logging * chore: pin api https port to 5001 * chore: add stripe listen dev script * feat(billing): log stripe webhook receipt and signature validation * feat(billing): log webhook event routing and session outcomes * feat(billing): log payment intent creation paths * feat(ordering): log webhook auto-placement outcomes * feat(store): log checkout return polling to console * docs(billing): correct ILogger generic in webhook plan task 5 * fix(billing): renumber logger event ids to avoid collisions * docs(billing): add aspire-managed stripe listen and dev signature relaxation * feat(aspire): run stripe listen as an orchestrated resource * feat(billing): skip webhook signature in development for stripe listen * docs: make aspire-managed stripe listen the primary flow * test(billing): cover development webhook signature bypass and validation * test(billing): pin dev-with-secret verification and document apphost stripe key requirement * docs(billing): clarify dev webhook signature skip applies only without a secret * feat(aspire): warn when STRIPE_SECRET_KEY is missing so stripe-listen is not a silent no-op * feat(aspire): read stripe key from AppHost user-secrets with env fallback * fix(aspire): resolve stripe webhook forward URL lazily via WithArgs(object[]) * fix(aspire): run stripe listen on host (not container) with lazy URL + --skip-verify * fix(aspire): resolve stripe --forward-to via AllocatedEndpoint in WithArgs callback * docs(billing): refresh setup-dev-secrets comment for AppHost user-secrets flow * chore(billing): bump Stripe.net to 52.3.0 and align webhook API version via CLI --latest * saves * refactor(ordering): add payment/shipment enums, drop string constants, type shipment state * fix(ordering): require shipment state in UpdateOrderShipmentState * refactor(ordering,billing): type checkout state across DTOs/commands and introduce PaymentTimelineState * docs(checkout): add checkout-state spec and five phase plans Spec defines the checkout/payment/shipment state model (enum alignment, Shipment aggregate, value converters) plus architecture-review reliability fixes. Plans: status-value-converters, shipment-aggregate, checkout-spa-enums, webhook-reliability, payment-invariants. * refactor(ordering): add bidirectional value converters for order status enums * refactor(ordering): use static helpers for order status value converters * test(ordering): add round-trip tests for order status value converters * feat(shipping): add Shipment aggregate with lifecycle transitions * feat(shipping): add Shipment EF configuration and schema constant Add the shipping.shipments table mapping (ShipmentConfiguration) and the Shipments table-name constant to ShippingSchema. The AddShipment migration is deferred until the working-tree model changes are committed. * test(shipping): add Shipment lifecycle transition tests * test(shipping): cover Backorder->Canceled transition * refactor(ordering): rename OrderShipmentState to OrderFulfillmentState Rename the order-level status to a derived fulfillment state computed from shipments (not admin-set). Ready/Backorder collapse to Pending in the legacy string converter mapping since they have no order-level equivalent. UpdateOrderShipmentState is retained (removed in a later task). * feat(ordering): add RecordOrderShipmentStateCommand and handler * feat(shipping): add ShipmentMethod.ComputeFulfillmentState Derives order-level OrderFulfillmentState from a collection of ShipmentStatus values. Cross-module reference to Module.Ordering consistent with RecordOrderShipmentStateCommand. Adds 6 unit tests. * feat(shipping): add CreateShipmentCommand and auto-create on checkout Add CreateShipmentCommand handler that creates one Pending shipment from order + shipping method ids. CheckoutPlacementService now sends it best-effort after placement commits; a failure only logs a warning so the placed order is not rolled back. * test(ordering): update CreateOrderFromCart tests for CheckoutPlacementService ISender * fix(ordering): catch exceptions from best-effort shipment auto-create Shipment auto-create must not fail the already-committed placement. Wrap the CreateShipmentCommand send in try/catch and log a warning instead of letting a DbUpdateException or pipeline exception propagate. * feat(shipping): add admin shipment status/list endpoints and fulfillment sync - Add UpdateShipmentStatus PUT endpoint applying domain transitions (Ready/Shipped/Delivered/Backorder/Cancel) and mirroring the derived OrderFulfillmentState to Ordering via RecordOrderShipmentStateCommand - Add ListShipmentsForOrder GET endpoint for an order's shipments - Add ShipmentFulfillmentSyncService (best-effort recompute + mirror) - Register sync service in Shipping module DI - Add ShipmentResult.Errors.NotFound * refactor(ordering): remove superseded UpdateOrderShipmentState feature The Shipping admin shipment endpoints (Task 8/9) supersede Ordering's UpdateOrderShipmentState. Delete the feature, its validator test, the UpdateShipmentState route constant, and the now-unused ShipmentStateUpdated/InvalidShipmentState result members. * feat(admin): add shipment list/status control to order detail Replace the removed Ordering updateShipmentState flow with the new Shipping shipment endpoints: list shipments for an order and update per-shipment status/tracking. Rename the order detail field shipmentState to fulfillmentState and render it as a read-only tag with severity mapping. Includes unit tests for the new listShipments and updateShipmentStatus API methods. * refactor(domain): move OrderFulfillmentState to Shared to fix Shipping->Ordering violation Shipping.Domain.Shipments.ShipmentMethod.ComputeFulfillmentState referenced Module.Ordering.Domain.Orders.OrderFulfillmentState, a cross-module dependency violating module isolation. The enum is now a neutral contract in Shared.Application.Domain.Orders (Shared depends on nothing). Also aligns AllowCancel: partially-shipped and all-shipped orders now share the same cancel rule (drop Shipped from the allowed fulfillment set). Bumps check-cross-module-refs.sh baseline 33 -> 35 (post-fix committed state). * fix(shipping): make CreateShipmentCommand idempotent Return Ok without inserting when a Shipment for the same (OrderId, ShippingMethodId) already exists, so repeated checkout auto-create sends do not duplicate Pending shipments. * fix(admin): render fulfillmentState and gate shipment status transitions OrdersList: Shipment column bound to dead shipmentState field (backend renamed to fulfillmentState) - render the derived fulfillment state with a severity map matching OrderDetail. OrderDetail: restrict the per-row status dropdown to targets reachable from the current status (mirrors ShipmentMethod guards), disable Save when the selection is not a valid transition, and require a tracking number before marking a shipment Shipped. * refactor(store-spa): type checkout/payment/fulfillment states as string unions * fix(store-spa): align order/cart API services with typed state unions * refactor(store-spa): tighten order/cart zod schemas to z.enum states * refactor(store-spa): map checkout steps to renamed PickDeliveryMethod/PickPaymentMethod states * refactor(store-spa): update test fixtures to renamed checkout/fulfillment states Align Store ordering spec fixtures with the typed CheckoutState union ('Payment'->'PickPaymentMethod', 'Delivery'->'PickDeliveryMethod', 'address'->'Address') and the OrderDetail fulfillmentState field. Fixes the checkout-wizard step-mapping fixture failures. * refactor(admin-spa): align order unions to renamed checkout/payment states Rename CheckoutState members Delivery/Payment to PickDeliveryMethod/PickPaymentMethod, add OrderPaymentState union and type paymentState, and drop dead legacy ShipmentState/SHIPMENT_STATE_OPTIONS/UpdateShipmentStateRequest. * refactor(admin-spa): align orders list checkout filter with renamed states * refactor(admin): update checkoutState test fixture to PickPaymentMethod Task 7 of refactor-checkout-spa-enums-1. Align Admin order.spec.ts fixture with the renamed CheckoutState union (Payment -> PickPaymentMethod) so the filter DSL assertion matches the typed value. * fix(store): type checkoutState as CheckoutState in cart and checkout composables Final-review fix: replace string-typed checkoutState with the CheckoutState union in useCart and the CartRef interface in useCheckout. * feat(billing): add Payment.CapturedAmount field and EF config TASK-001 of refactor-payment-invariants-1. Adds CapturedAmount decimal property and HasPrecision mapping. Migration deferred per plan. RIDE-ALONG: includes uncommitted WIP class rename PaymentCapture -> Payment in both files (staged whole per WORKTREE rule). * refactor(billing): enforce capture/refund invariants on partial captures * refactor(billing): capture remaining amount and allow Disputed credit * refactor(billing): route Disputed refunds through CanRefund gate * test(billing): update payment tests for capture/refund invariants Fix the 7 tests broken by partial-capture semantics: - split Capture_ShouldSetStateToCompleted into partial (stays Pending, accumulates CapturedAmount) and full (Completed + CapturedAmount=Amount) - seed CapturedAmount in charge.refunded fixtures so ReconcileRefunded total stays within the captured amount - UncapturedAmount returns 0 only when fully captured - RefundAsync seeds CapturedAmount and asserts accumulation + cap Add coverage: over-capture rejected, over-refund rejected, ReconcileRefunded > CapturedAmount fails, ReconcileRefunded monotonic. Rides along Payment->PaymentCapture alias fixes in PaymentProcessingServiceTests.cs and ProcessStripeWebhookEventJobTests.cs. * fix(billing): set CapturedAmount on Complete and correct partial-capture stamping - Complete() now sets CapturedAmount = Amount (all call sites are full captures), keeping auto-captured payments refundable/reconcilable. - Capture() only stamps CompletedAtUtc when the payment is fully captured, not on partial captures that stay Pending/Processing. - RefundAsync returns AmountExceedsAuthorized (not Completed-transition error) when a Disputed over-refund fails CanRefund. * feat(billing): add WebhookEvent entity and EF config (migration deferred) Persistent idempotent webhook-event log in Billing: WebhookEvent entity, WebhookEventState enum, EF configuration mapping to payment.webhook_events with unique StripeEventId index and string-converted State column. Table migration deferred by human ruling to avoid polluting the EF snapshot. * refactor(billing): persist webhook events and process jobs by event id TASK-002: StripeWebhook.CommandHandler now parses the payload, persists a WebhookEvent (dedupe on the unique StripeEventId, DbUpdateException race returns Ok), and enqueues ProcessStripeWebhookEventJob by event id instead of the raw payload. TASK-003: ProcessStripeWebhookEventJob.ExecuteAsync(Guid eventId) loads and claims the persisted event (Pending->Processing, AttemptCount++), routes the stored payload through the unchanged per-event handlers via RouteEventAsync, and marks Processed/Failed. Only Processed events are skipped; Failed/Processing are re-claimed on Hangfire retry. Tests: job tests seed a WebhookEvent and run by id; added Processed/Failed/ unparseable state-transition coverage. Webhook tests assert persist + enqueue-by-id and duplicate no-op. Ride-along: ProcessStripeWebhookEventJob.cs carries pre-existing WIP PaymentCapture->Payment alias rename in per-event handlers (unchanged behavior). * fix(billing): narrow webhook dedupe race and re-enqueue pending duplicates * feat(billing): wire webhook correlation keys and business timestamps - Payment gains StripeSessionId/StripePaymentIntentId (stable correlation) + ProcessedAtUtc - Webhook job: stable-key lookups, sets StripePaymentIntentId on session completion, stamps business time (Stripe event.Created) on Complete/Fail/Void/Dispute - CreatePaymentIntent records StripeSessionId - Migrations: webhook_events + shipments + fulfillment rename + payment columns (catch-up) and payment correlation columns - Note: CreatePaymentIntent.cs carries WIP Payment alias hunks (ride-along) * refactor(checkout): record payment method on order and confirm-before-charge flow Wire Order.PaymentMethodId end-to-end so ValidateCheckout's PaymentMethodRequired invariant passes: CreatePaymentIntent now carries the selected method through AdvanceCheckoutStateCommand, OrderMethod gains SelectPaymentMethod/ClearPaymentMethod, and RegressCheckoutState invalidates the pick on session expiry. Store SPA: both card and COD paths advance to Review first; the Stripe hosted-checkout redirect now happens only after explicit confirmation on the Review panel (confirm-before-charge). Also lands in-progress orders/payments architecture work: status-value-converter plan revision, checkout-state-enum-alignment plan, architecture review docs, and assorted Billing/Ordering/Shipping/Shared cleanups with matching test updates. * feat: Implement shipping cost applier for authoritative shipping adjustments - Added ShippingCostApplier service to compute and apply shipping costs based on cart weight and selected shipping method. - Refactored CheckoutView to utilize server-computed shipping totals, ensuring consistency across UI components. - Introduced new ShippingAdjustmentSummary DTO to expose detailed shipping adjustment information in cart and order responses. - Updated Cart and Order response contracts to include shipment totals and adjustments, aligning with server-side calculations. - Enhanced UI components in CartView, CheckoutView, and OrderDetailView to reflect server-driven shipping and adjustment data. - Implemented tests to verify correctness of shipping calculations and UI rendering based on new contracts. * refactor(ordering): delegate shipping cost to shared applier in SelectShippingRate * refactor(ordering): delegate shipping cost to shared applier in UpdateCheckout * fix(ordering): apply authoritative shipping cost on admin shipping method change * feat(ordering): expose shipping breakdown and adjustment summary on cart response * feat(ordering): populate shipping breakdown in cart mapping and include adjustments * feat(ordering): expose applied shipping adjustment on order detail * feat(ordering): expose currency and item count on storefront order list * feat(store): mirror cart shipping breakdown in types and schema * feat(store): mirror order shipping adjustment and totals in types and schema * feat(store): add authoritative shipping preview and drop stale orderId rates filter * feat(store): carry server-authoritative cart totals in useCart * feat(store): render server shipping and totals in cart summary * feat(store): show server shipping and total in cart drawer * feat(store): use server shipping totals and preview in checkout * feat(store): show order adjustments, payment and shipping method * feat(store): show item count and currency in order list * feat(admin): show applied shipping adjustment on order detail * test(ordering): cover shipping adjustment mappings and admin method recalc * test(store): cover server-driven cart, checkout and order totals * fix(ordering): preserve shipping adjustments on cart association and checkout * chore(shipping): remove dead storefront shared shipping-method mapping with hardcoded cost * feat(ordering): expose full adjustments and shipping calculation on cart/order responses - ShippingRateCalculator returns the applied rate id - Order persists shipping calculation metadata (TotalWeight, ShippingRateId, IsFreeShipping) - Cart and Order responses expose an Adjustments list plus a ShippingCalculation summary - CalculateShipping preview returns the applied rate id - EF migration AddShippingCalculationMetadata * feat(store): mirror adjustments and shipping calculation in types, schema and order detail * refactor(catalog): align RepositionTaxon namespace and usings with feature path * refactor(billing): wrap ConfirmPayment command payload in Request record Align ConfirmPayment to canonical Admin Option Type pattern (Command(Request)). Rename ConfirmPaymentRequest to Request carrying PaymentId + PaymentMethodId, update handler, endpoint and validator to read command.Request.*, and adapt unit tests. Removes AC-001 inlined-fields violation. Structural only. * refactor: DeleteWishlist wraps Parameters record (AC-001) * refactor(profile): wrap UpdateProfile command in Parameters record Align UpdateProfile to canonical Admin Option Type pattern. Command now wraps a Parameters record carrying UserId, Request, and IsAdminBypass instead of inlining fields. Update handler, storefront and admin endpoints, and unit tests accordingly. Removes the legacy EXCEPTION contract comment. * refactor(catalog): wrap GetSimilarProducts query in Parameters record (AC-001) * refactor(catalog): wrap GetVisualSearchModels query in QueryingParameters * refactor(profile): align DeleteAddress with bare Result delete pattern (AC-002) * refactor(catalog): SetVariantPrice returns bare Result, drop Response * refactor(catalog): RepositionTaxon returns bare Result * refactor(catalog): DeleteVariantImage returns bare Result, drop Response * refactor(Catalog): DeleteEmbedding returns bare Result Convert confirmation command to bare Result per Admin Option Type delete pattern. Command now : ICommand (no Response record); Handler implements ICommandHandler<Command> returning Task<Result>. Delete DeleteEmbedding.Response.cs, update endpoint Produces<Result>(), and drop result.Value.Message assertion from Handle_ShouldDelete test (keeps IsSuccess and deleted.BeNull). * refactor(dashboard): GetDashboard Response inherits DashboardParameters base * refactor(inventory): GetInventoryDashboard Response inherits InventoryDashboardParameters base * refactor(ordering): GetOrderingDashboard Response inherits OrderingDashboardParameters base * refactor(catalog): GetCatalogDashboard Response inherits CatalogDashboardParameters base * refactor(Ordering): GetOrderTracking Response inherits OrderTrackingParameters * refactor(Shipping): reuse ShippingRateDetailResponse base in ListShippingRates Remove AC-002 exception and inline projection; inherit the shared ShippingRateDetailResponse base and use ShippingRateMapping.MapToDetail. * refactor(Shipping): reuse ShippingMethodDetailResponse base in GetShippingMethods Remove AC-002 exception and inline projection; inherit the shared ShippingMethodDetailResponse base and use ShippingMethodMapping.MapToDetail. * refactor(Shipping): declare CalculateShipping mapping with ShippingCalculationParameters base * refactor(Shipping): reuse shared Shipment models and mappings in ListShipmentsForOrder and UpdateShipmentStatus Introduce Shipments/Shared Models (Parameters/Response/Request) and a ShipmentMapping (MapToListItem/MapToDetail) to replace feature-local DTOs with // EXCEPTION markers in the two shipment features. * refactor(Identity): Sync/Revoke/Assign UserRoles Requests inherit RoleCollectionParameters * refactor(Identity): Sync/Revoke/Assign Role and User Permissions Requests inherit PermissionCollectionParameters * refactor(billing): add PaymentActionParameters base for CapturePayment request * refactor(Catalog): add ProductClassificationCollectionParameters base for classification Requests * refactor(Catalog): add ProductOptionTypeCollectionParameters base for OptionType Requests * refactor(Catalog): add VariantOptionValueCollectionParameters base for Assign/Revoke/Sync OptionValue Requests * refactor(Catalog): add price/taxon-rule/search Parameters bases for Request records * refactor(Inventory): add stock Request Parameters bases for Import/Restock/LowStock/Reserve * refactor(Ordering): add shared Request Parameters bases for cart/order actions * refactor(Identity): add shared AuthTokenMapping for storefront auth handlers * refactor(Identity): add shared SessionMapping for storefront GetSession handler * refactor(Identity): add shared PermissionCompositeMapping for GetUserPermissions Extract the inline composite permission tree from GetUserPermissions into a generic MapToPermissionComposite extension, satisfying REQ-006. Add shared PermissionAssignmentItemResponse (Option A) so the generic IsAssigned constraint compiles under warnings-as-errors; both GetUserPermissions and GetRolePermissions nested PermissionItemResponse inherit it. GetRolePermissions handler logic is untouched. * refactor(Identity): use RoleMapping in DeleteRole handler * refactor(Inventory): add shared ImportStockItemsMapping for Import handler * test(Catalog): add VisualSearchModelMapping unit tests * test(catalog): add StoreVariantPrice MapToStoreItem coverage * test(catalog): add StoreVariantImage download mapping tests * refactor(conventions): harden check-feature-conventions.sh, drop exception escape hatches Remove no_exception() helper and AC-002/AC-003 EXCEPTION skip logic; extend AC-003 to catch sealed record Request; guard empty-input loops against spurious FAIL. Give ConfirmPayment.Request a PaymentConfirmationParameters base and drop stale GetVariantOptionValues EXCEPTION comment. * fix(conventions): guard AC-001 loop against empty input * fix(admin): align delete-Result response contracts to bare Result<void> Admin SPA API methods deleteAddress, deleteEmbedding and repositionTaxon declared typed payloads that no longer exist since the backend now returns bare Result. Align return types (and HTTP helper generic) to Promise<Result<void>>, matching the Store SPA pattern. * fix(ordering): remove unsatisfiable PaymentMethodId prerequisite from Place Root cause: commit 8ec6a16 added PaymentMethodId as a hard checkout prerequisite in ValidateCheckoutPrerequisites, but no code in the placement flow (CreateOrderFromCart, CompleteCheckoutForPayment, CheckoutPlacementService, PaymentForCheckoutResponse) ever sets it — so every non-free order placement failed with Order.PaymentMethodRequired, breaking the canonical Place() behavior. Fix the root cause: drop the PaymentMethodId check from Place. Payment selection remains enforced by the separate ValidateCheckout feature (HasPayementMethod), so the prerequisite lives where the data exists, not on domain finalization. Also fix stale ModuleIsolationTests baseline: it asserted 2 known cross-module references, but the pre-existing Order -> Billing.PaymentMethod navigation (same commit 8ec6a16) makes it 3. Update baseline to reflect reality. Resolves 8 pre-existing test failures (OrderMethodTests x2, UpdateOrderStatus, CreateOrderFromCart x5, ModuleIsolationTests). * Revert "fix(ordering): remove unsatisfiable PaymentMethodId prerequisite from Place" This reverts commit 08fb5f9. * fix(ordering): wire payment method onto order before finalization Root cause: Order.Place requires PaymentMethodId (added in 8ec6a16) but no placement path ever set it — PaymentForCheckoutResponse did not expose it, and neither CreateOrderFromCart nor CompleteCheckoutForPayment persisted it onto the order. Every non-free order placement failed with Order.PaymentMethodRequired. Fix: expose PaymentMethodId from the Billing PaymentCapture via PaymentForCheckoutResponse, and have both placement flows persist it onto the order before PlaceAsync. Keep the prerequisite as a genuine invariant — it now has a real data source. Tests: success-path CreateOrderFromCart/Transaction/Stock mocks return a PaymentMethodId; OrderMethodTests and UpdateOrderStatusTests set it in their direct Place()/prerequisite setups. Fix stale ModuleIsolationTests baseline (2 -> 3) to document the pre-existing Order -> Billing.PaymentMethod navigation. Resolves the 8 pre-existing test failures while preserving the payment-method invariant. * feat(ordering): add product references to cart and order line items - Consolidate the four duplicated cart lookup builders into ProductLookupFactory (adds ProductId) - CartItem and LineItemResponse expose productId/productName/productImageUrl for UI navigation - Order mapping gains a lookup-enriched MapToDetailWithLookup used by storefront/admin order detail and checkout - GetOrderTracking reads delivery timestamps from the order's shipment (tracking fields relocated to Shipment) * chore(migrations): squash all migrations into a single InitialCreate * feat(store): show product images and link cart/order items to product details * fix(inventory): stop inflating CountOnHand on reservation release/expiry * feat(inventory): consume order stock by variant lines with re-reserve * fix(billing): release prior cart reservations before intent-time reserve * fix(inventory): cap consume at ordered quantity and release surplus * feat(inventory): write sold stock movement on order consumption * fix(inventory): register reservation expiry scheduler * fix(billing): release reservations by cart token on session expiry * fix(ordering): pass stock consume lines when consuming order reservations Update CheckoutPlacementService to call the three-arg ConsumeForOrderAsync with a StockConsumeLine list built from the cart's line items, matching the signature change to IStockReservationService. * fix(billing): update session-expiry tests for cart-token reservation release The handler now releases reservations keyed by cart token (orderId: null, cartToken: payment.OrderId.ToString()). Update both checkout.session.expired test verifies to the new argument shape. * test(ordering): match 3-arg ConsumeForOrderAsync in checkout tests * fix(billing): don't compensate expired session when a newer capture owns the cart * refactor(conventions): drop cross-module reference rule Modules share one assembly; enforce nothing. Allow cross-module using, EF navigations, and direct service calls. Keep MediatR ISender for behavior with a documented TODO of replacement options plus per-site audited candidates. Delete scripts/check-cross-module-refs.sh, its CI step, PR template checkbox, and ModuleIsolationTests cross-module test. Update AGENTS.md, CLAUDE.md, Directory.Build.targets, and codebase docs. * refactor(module): consolidate shared, restructure vertical slices, add navigations - Fold per-action Request/Response/Validator into vertical-slice files - Delete Features/*/Shared Models/Mappings/Validators trees across all modules - Add EF Core navigations (Order → PaymentCaptures, Shipments, StockReservations) - Split entity configurations into per-type files - Rework ProcessStripeWebhookEventJob placement/regression handling - Add TODO annotations at cross-module ISender dispatch sites - Delete spec/*.md planning docs, squash and reorganize migrations 961 files changed, ~17k lines removed, ~9k added * test(ordering): add CheckoutPlacementService happy-path and branch coverage * test(ordering): add CompleteCheckoutForPayment idempotency and branch coverage * test(shipping): add CreateShipment happy-path and idempotency coverage * test(shipping): add fulfillment-sync and shipment-status branch coverage * test(inventory): add consume happy-path, empty, and multi-location coverage * test(billing): add CreatePaymentIntent offline and compensation branch coverage * docs(spec): stripe checkout paymentintent metadata propagation design * docs(plan): stripe checkout paymentintent metadata propagation * refactor(billing): extract BuildCheckoutSessionOptions from CreateCheckoutSessionAsync * fix(billing): propagate payment_id metadata to checkout PaymentIntent * docs(spec): stripe checkout per-product line items and shipping design * docs(plan): stripe checkout per-product line items and shipping * feat(ordering): project line-item name, unit price, and shipping in GetCartForCheckout * feat(billing): pass per-product line items and shipping to the gateway * feat(billing): emit per-product lines and shipping in Stripe checkout session * fix(billing): guard shipping option behind per-product line items * docs: order timestamps/status/calculation audit + order-details enrichment design * docs(spec): correct listShipments removal scope in order-details enrichment * docs(plan): order details enrichment * feat(ordering): embed payments, shipments, timeline, and timestamps in order detail * fix(ordering): null-safe shipping method name in shipment summary * feat(ordering): load payment captures and shipments in get-order handlers * feat(admin): extend order types and remove listShipments API * feat(admin): render order timeline, payments, and shipments from the payload * feat(store): extend order detail types and validation schema * test(store): add new order detail fields to the detail view fixture * feat(store): render order timeline, shipments, and payments * docs: order cross-module state sync design + plan * feat(ordering): derive payment state from captures * feat(ordering): recompute payment state on payment events * test(ordering): cover failed and checkout recompute paths * fix(billing): mirror processing state on partial capture * feat(billing): recompute order payment state on refund * feat(shipping): sync order fulfillment state on shipment creation * feat(inventory): return consumed stock per location on order cancel * fix(inventory): transactional multi-location stock return * feat(ordering): cancel shipments and return stock on order cancellation * fix(ordering): fail cancel when a shipment cannot be canceled * fix(ordering): recompute payment state on order cancellation * fix(ordering): load payment captures when recomputing payment state on cancel * refactor(billing): type payment DTO state as PaymentRecordState * test(billing): cover setup-intent payment state default * refactor(ordering): type timeline event and dashboard status as enums OrderTimelineEvent.Type is now OrderTimelineEventType (PascalCase members); RecentOrderData.Status is now OrderStatus. Mapping assigns enum values directly (no ToString); global JsonStringEnumConverter still emits member names as JSON strings. RISK-002 (accepted wire change): OrderTimelineEvent.Type wire value changes from lowercase ("created") to PascalCase ("Created"). Verified safe: both SPAs render label, never type. Future consumers must expect PascalCase. RecentOrderData.Status wire value is unchanged. * refactor(inventory): type transfer, reservation, and low-stock statuses as enums * refactor(catalog,dashboard): type variant-image, unit, embedding, and activity statuses as enums VariantImageParameters.Type -> VariantImageType; VariantParameters WeightUnit/DimensionsUnit -> WeightUnit?/DimensionUnit?; EmbeddingDetailResponse.Status -> EmbeddingStatus; ActivityItemData Type/Status -> ActivityType/ActivityStatus. Mappings assign enum values directly (no ToString/TryParse); global JsonStringEnumConverter still emits member names as JSON strings so the wire format is unchanged. GetDashboard.BuildActivities materializes raw OrderStatus first and maps to ActivityStatus in memory because the switch cannot be translated by EF Core inside the Select projection. Note: UpdateVariantImage treats a Default request value as 'not provided' and preserves the existing type per the phase-4 brief. * fix(catalog): make update-image type nullable to restore explicit demote * feat(admin): type payment states, add payment and shipment action buttons * test(admin): cover backorder mark-shipped gate * feat(store): type payment states, add pay-now and cancel-order actions * chore(migrations): rebuild initial create baseline after enum refactor * test: add enum wire-format serialization guards and cover out-of-stock branch * docs(plan): mark status-enum refactor plan completed * fix(ordering): include order detail navigations and guard mapper collections * fix(ordering): populate line-item order/product fields and tracking estimate * fix(billing): populate payment method name and status, set confirm message * test(inventory): cover untested admin handlers and stock-transfer detail * test(inventory): cover storefront reservation release at service level * test(ordering): cover remaining untested handlers and relational include behavior * fix(admin): align inventory and ordering types with backend contract * fix(store): align ordering, payment, and inventory types with backend contract * test(billing,ordering): cover paged payments restructure and shipment method name * docs(plan): mark module mappings-tests plan completed * refactor(ordering): rename terminal checkout state Complete to Placed * feat(ordering): add completed order status and auto-derive from delivery * test(ordering): cover completed order status and delivery auto-completion * fix(spa): align order checkout/status enums with Placed and Completed contract * docs(plan): mark order-status-lifecycle plan completed * fix(ordering): guard cancel on terminal statuses, derive resume completion, map full-refund * fix(ordering): guard cancel handlers, reorder void after shipment guards * fix(ordering): align update-order-status cancel with cancel-order-admin semantics * docs(plan): mark order-state-guards plan completed * feat(ordering): reject unpurchasable variants when adding to cart AddToCart now validates the variant before mutating the cart: it must be published, its product active, carry a non-negative price, and have enough available stock for the requested quantity. Adds IStockItemService to the handler and uses the variant's actual price instead of a zero fallback. Extends the handler test suite with a seeding helper for active products and coverage for the new guard branches. * feat(ordering): validate special instructions length on order update Adds a max-length rule for SpecialInstructions to both the admin UpdateOrderAdmin validator and the storefront UpdateCheckout validator, mirroring the existing email rule pattern. Adds the TestHost package to the unit-test project for future endpoint-level tests. * fix(admin): render order payment/checkout states, editable notes, shipment dropdown - Add Payment State and Checkout State severity Tags to the order overview, replacing the raw checkout-state text. - Add an editable Special Instructions field persisted via OrderApi.updateOrder. - Include the current status in the shipment status dropdown options so the Select renders the actual state (previously blank because the current status is never one of its own reachable targets). Adds matching OrderDetail spec coverage for the dropdown and overview tags. * feat(store): add checkout notes, surface cart errors, fix card quick actions - Add an optional Special Instructions field to the checkout review step, persisted before placing the order and exposed on the checkout composable and UpdateCheckoutRequest. - Surface the server's rejection reason (e.g. out of stock) instead of a generic "Failed to add item" message in the cart and quick-add flows. - Suppress the anchor default on ProductGridCard quick-add / wishlist / quick-view so card navigation no longer fires when clicking the actions. Adds/updates component spec coverage for the card handlers and checkout. * docs: remove obsolete checkout line-items spec, record payment/inventory plan notes The Stripe checkout line-items design was superseded by the implemented per-product lines feature and its plan; the file is removed. The payment-inventory correctness plan gains the Phase 2 completion record and follow-up notes from the recent ordering fixes. * chore: remove committed sdd report artifacts from prior plan workspace phase-1 and phase-2 reports were force-added during an earlier SDD plan; the workspace has since been deleted, so drop the tracked copies. * feat(shipping): implement tracking number updates and validation for shipment statuses * A * docs(thesis): add review remediation artifacts, process spec, and plan
* fix(thesis): regenerate Table 67 from authoritative category-only benchmark
* fix(thesis): regenerate Table 68 and RQ2/§3.7.4 from authoritative efficiency JSON
* fix(thesis): update EN/VI abstract with reconciled benchmark numbers
* fix(thesis): update Part 3 conclusion with reconciled benchmark numbers
* fix(thesis): expand Table 55 to all 11 registered models (CON-001: reject 'six')
* fix(thesis): standardize Fashion-CLIP improvement to authoritative 2.13% in Ch1
Replace three '15 to 20%' occurrences with the oracle-recomputed
Fashion-CLIP vs CLIP-generic mAP difference (2.13%) from the
category-only benchmark (Appendix A.1 / §3.5).
Fix EfficientNet-B0 trade-off from '3.4 percent lower mAP@10' to
'4.65% lower mAP' per the Fashion-CLIP vs EfficientNet-B0 oracle
figure.
* fix(thesis): correct fabricated citations [6],[27] and add DeepFashion co-author
* fix(thesis): correct stale counts and claims in §2.1, §2.3.1, and Part 3 Limitations
- nine bounded contexts → eight (§2.3.1)
- 88 FR / nine modules → 87 FR / eight modules (§2.1 opening + ch2 intro bullets + API caption)
- near-zero P@20 → ~0.30 enriched-label figure (Part 3 Limitations)
* fix(thesis): reconcile CBIR endpoint URL and resolve Variable Vector Dimensions contradiction
Task 13: Update all prose locations to use actual Carter route
api/storefront/catalog/products/images/search and correct the stated
API convention from /api/{module}/{surface}/{resource} to
/api/{surface}/{module}/{resource} to match implemented routes.
Task 14: Reframe the 'Variable Vector Dimensions' bullet in §2.3.4.4
to acknowledge the fixed vector(512) column and document that deploying
other dimensionalities requires schema changes.
Files changed:
- 05-api-design.typ: convention now surface-first
- ml-sidecar.typ: §2.4.4.3 URL corrected (was /api/admin/catalog/storefront/...)
- frontend-ux.typ: §2.4.5.1 URL corrected (was /api/storefront/search-by-image)
- vsa-core.typ: convention mirror updated
- 03-cbir-search.typ: stale duplicate URL corrected
- P2S2.2.4_cbir-search-sequence.puml: diagram URL corrected
- 04-database-design.typ: Variable Vector Dimensions reframed as fixed+future
* fix(thesis): correct phantom section refs, UI state count, and outline TOC
- Task 15: Replace phantom 'Section 2.1.5' with 'Section 1.4.2' in
database-design.typ and data-persistence.typ (HNSW/IVFFlat comparison
lives in Ch1 §1.4.2, not a nonexistent Ch2 §2.1.5).
- Task 16: Change 'five visual search states' to 'four' in
f1-visual-search.typ to match Table 58's four rows (Empty, Upload,
Loading, Results).
- Task 17: Rewrite Part 1 §VI Thesis Outline to reflect the real
three-part TOC structure (no phantom 'Chapter 4', no 'five chapters').
* fix(thesis): reconcile versions, permissions, counts, and unsupported claim (tasks 18-22)
- PostgreSQL 16 → 17 in benchmark hardware table
- pgvector 0.3.2 → 0.7.0 in technology stack table
- Permission format standardized to dot-separated domain.category.resource.action (7 files)
- Storefront use case count corrected from eight to nine
- Accuracy metrics standardized: 3 families (mAP, P@K, R@K) at 3 depths = 7 columns
- Softened unsupported 30% search-abandonment claim in Part 1 and Ch1 background
* fix(thesis): correct Table 70 traceability citations and Appendix B.1 sampling method
Task 23: Fix mis-citations in Requirements Traceability table (Table 70):
- 'Validate pgvector feasibility': Section 2.2.4 → 2.3.4, 2.3.3 → 2.4.3
- 'Set up vector search': Section 2.2.4 → 2.3.4, 2.3.3 → 2.4.3
- RQ3: Section 3.5 → 3.7 (RQ3 answer is in Synthesis section)
- RQ2: Sections 3.3-3.5 → 3.3-3.6 (include efficiency metrics)
- 'Benchmark embedding': Sections 3.2-3.5 → 3.2-3.7 (include synthesis)
- 'Evaluate results': Sections 3.2-3.5 → 3.2-3.7 (include synthesis)
Task 24: Fix Appendix B.1 sampling description:
- Replace 'chosen sequentially' with 'sampled via stratified random sampling'
- Split script uses per-category shuffling with seed 42 (stratified k-fold)
* polish(thesis): TIER 3 fixes (cross-refs, support actors, phantom Chapter 6)
* fix(thesis): address review findings — RQ1 CI over-claim, percentage precision, architecture families
- RQ1 answer (05-retrieval-performance.typ:38): rewrite 'exceeds upper bound of every other model' to acknowledge CLIP-generic CI overlap (0.9173 < 0.9269), separation holds only for CNN models
- ch4-conclusion: standardize percentages to 2-decimal precision (2.1%→2.13%, 4.7%→4.65%, 5.1%→5.10%, 95.5%→95.55%)
- ml-sidecar.typ: 'four architecture families'→'three' to match Table 55's 3-family grouping (CNN/ViT/CLIP)
- ml-sidecar.typ: example inference_ms 92.0→96.8 to match authoritative benchmark
* chore(thesis): commit remediation deliverables and regenerated artifacts
- Makefile: add charts target (make charts regenerates 5 benchmark PNGs)
- 5 PNG charts regenerated from authoritative JSON (mAP, precision, recall, latency, throughput)
- 2 Typst diagram tables updated (thesis_aggregate.typ, thesis_efficiency.typ)
- PlantUML CBIR sequence diagram regenerated (P2S2.2.4)
- main.pdf rebuilt
- thesis/spec/verify_remediation.py (verification oracle)
- thesis/spec/remediation-log.md (full audit trail)
- thesis/spec/regenerate_charts.py (chart regeneration script)
* chore(thesis): add citation-check, revision-roadmap, and literature-review reports
- citation-check-report.md: 37 entries verified, 3 fixes (page numbers, year), 14 orphans, 0 missing
- revision-roadmap.md: 28 findings parsed, all addressed, 14 positive claims catalogued
- literature-review-report.md: search strategy, 20+ annotated sources, literature matrix, research gaps
- bibliography.bib: 3 corrections (zhai2023sigmoid pages, liu2022convnext pages, johnson2019billion year)
* chore(thesis): add peer review report (Phase 6, revision mode)
Weighted total: 7.0/10. 2 critical issues identified:
- C1: 'Statistically meaningful separation' needs caveat about 3-fold underpowering
- C2: Enriched-label evaluation claim has no supporting data
4 important + 5 minor issues documented. Remediation successful.
* fix(thesis): address peer review critical issues C1 and C2
- C1 (05-retrieval-performance.typ:36): add caveat that 3-fold underpowers formal significance testing; non-overlapping bounds presented as indicative
- C2 (ch4-conclusion.typ:37): add explicit reference to Appendix A.2/A.3 for enriched-label evaluation claim (data was present in appendices, just uncited)
* fix(thesis): remove all em dashes from prose and use-case headers
- 2 prose em dashes replaced with commas/parentheses
- 26 use-case table header em dashes replaced with colons (11 files)
- Only remaining em dash: Vietnamese national motto on confirmation page (fixed slogan, not prose)
- typst compile exits 0
* fix(thesis): reduce model count from 11 to 6, restore four architecture families
- Table 55 (ml-sidecar.typ): reduced from 11 rows to 6 (efficientnet-b0, resnet-50, dinov2-vits14, clip-vit-b16, openclip-vit-b-32, fashion-clip)
- 'three architecture families' → 'four' (CNN, ViT, CLIP, Fashion-specific)
- All 6 prose 'eleven'/'11' occurrences → 'six'/'6'
- typst compile exits 0
* feat(benchmarks): seed 6 thesis models with snake_case IDs
- Rename all model registry keys from hyphens to underscores
(fashion-clip -> fashion_clip, clip-b32 -> clip_b32, etc.)
- Add 6 missing YAML model configs (clip_generic, clip_vit_b16,
convnext_tiny, dinov2_vits14, efficientnet_b0, resnet50)
- Update 11_generate_embeddings.py to seed all 11 models with
resume support (incremental writes after each model)
- Expand MODEL_INPUT_SIZES in shared.py for all 11 models
- Update THESIS_MODEL_KEYS, CLI docstrings, and all test files
- Verified: 145/145 unit tests pass, ruff lint clean
* style(thesis): compact DB appendix, formatting fixes, screenshot verification
- d-database.typ: add db-table helper, reduce spacing (2pt), 12pt base
font, 7.5pt table text, 0.3pt strokes, 33 headings renamed to Title Case
- data-persistence.typ: remove backticks from isolation level cell
- ml-sidecar.typ: reformat fashion-clip table row and image path
- P2S2.2.4_cbir-search-sequence.png: regenerate diagram
- remediation-log.md: add S4-1 screenshot remediation row
- verify_remediation.py: add 46-PNG expected list and 6-fabricated check
* fix(catalog): propagate selected embedding model to inference service
Visual search always fell back to fashion_clip because model_name was
sent as a multipart form field, but FastAPI binds plain scalar params
from the query string. The form field was silently ignored, so the
default settings.EMBEDDING_MODEL was used on every request.
- C# client: append model_name as query string on /embeddings/bytes
- Rename Model -> ModelName / model -> model_name across SPA, API,
and Python request schemas so all boundaries use a consistent name
- Store SPA sends modelName (camelCase) which [FromForm] binds to
ModelName; the C# client then sends model_name to the sidecar
* refactor(embedding): align model IDs to snake_case benchmark registry
Rename model identifiers to the snake_case slugs used by the benchmark
registry so C#, the Python sidecar, and the thesis seed data agree:
openclip-vit-b-32 -> clip_b32, fashion-clip -> fashion_clip, etc.
- VariantImageConstant.AIModels: snake_case slugs, drop unregistered
models, add ResNet50/eva_clip/siglip IDs
- clip.py registry registration matches the new slug
- Update unit/integration tests to the renamed identifiers
* feat(catalog): support multiple embedding models with per-model vector indexes
Enable storing embeddings of differing dimensions (fashion_clip=512,
resnet50=2048, etc.) instead of a fixed vector(512) column.
- vector column is now untyped; per-model HNSW expression indexes with
dimension casts are created in DatabaseInitializer after migrations
- VectorSearchService filters by both model name and vector dimension
- Seeder loads per-model JSON files from 012_demo_embeddings/ and
validates dimensions against ImageEmbeddingConstant
- benchmark demo-seed writes per-model files with a --demo mode for the
six thesis models
- consolidate the two prior migrations into a single InitialCreate
* chore: add pgAdmin to Postgres resource and thesis screenshot plan
- Aspire: attach pgAdmin to the Postgres resource for DB inspection
- Add thesis screenshot capture plan; update compiled thesis PDF
* Fix frontend-UX screenshots and capture processes; update remediation log with detailed descriptions for S4-1 to S4-7, ensuring all screenshots are recaptured and relevant parameters adjusted for accurate documentation.
* Refactor code structure for improved readability and maintainability
* Add peer review simulation for thesis and consolidate edit list
- Introduced a new peer review simulation document for the thesis titled "Building a Fashion E-Commerce Application with Recommendation and Image-Based Product Search," providing a comprehensive evaluation from multiple perspectives.
- Created a master edit list that compiles all edits from various rewrite files into a single document for easier navigation and application.
- Removed the chart regeneration script as it is no longer needed.
* docs(thesis): address fresh review round and soften evaluation claims
Revise background, design, evaluation, and conclusion chapters per
2026-08-22 review: correct mAP deltas (95.55%->97.2%, 5.5x->2.67x),
clarify six-of-eleven model scope, estimate RAM from parameter counts,
add dataset-imbalance and scale limitations plus ethical considerations,
and cite ImageBind/BLIP-2. Include new review reports and revision
roadmap; rebuild PDF.
* docs(thesis): trim captions and table prose
Captions exceeded 80 chars and repeated stats already stated in body
text; wordy Goal/Pre-Post/Alternatives cells slowed scanning. Cut to
one identifying phrase, keep scenario steps, IDs, and numbers intact.
* docs(thesis): remove Google OAuth login
Chapter 1 scopes social login out; design chapters still specified
Google OAuth as an in-scope pathway (IDN-FR-03). Drop the requirement,
use-case scenario, C4/deployment integrations, and diagram nodes to
align scope claims with the implemented system.
* docs(thesis): apply page-cut reductions
Page count needed cutting per reviews/2026-08-24-reduction plan:
drop database appendix D (schema already in Section 2.3.4), merge
use-case overview+summary into one combined view, and tighten chapter
framing and prose that restated earlier sections.
* build(thesis): add per-schema ERD rules, rerender diagrams
ERD-core grew too dense at one scale; split into per-context ERDs with
a dedicated 1600px neutral-theme rule. Fix startwbs output rename and
rerender sources changed by the reduction pass.
* docs(thesis): rebuild pdf
* docs(thesis): add reduction-pass review notes
* style: rename csharp code fences to cs
* fix(thesis): align persistence and job details with implementation
Docs described a typed vector(512) column and a single HNSW index on
products; the schema actually stores an untyped vector column with a
model_name filter and per-model partial HNSW indexes. Also correct
Hangfire job cadences, the similarity-threshold wording, and rerender
the ERDs (serif theme, updated schema).
* docs(thesis): group requirements into traceability clusters
87 flat functional requirements made use-case traceability noisy;
regroup them into 27 requirement groups (CAT-GRP-nn, NFR-GRP-nn, ...)
and reference groups instead of individual FR ids from every use case.
* docs(thesis): convert dense limitation and strategy paragraphs to bullets
* docs(thesis): tighten architecture pattern comparison table
* build(thesis): reflow erd make rule and rebuild pdf
Wrap the erd-core mmdc rule in line continuations and rebuild main.pdf
over the requirement-group, persistence-fix, and prose passes.
* docs(thesis): reference requirement groups from admin use cases
* chore: remove coding-agent instruction files
Drop AGENTS.md/CLAUDE.md guides (root, app, benchmarks, thesis) and the
opencode plan artifact; reword the comments in build targets and three
features that pointed readers at AGENTS.md rules.
* docs: scrub agent-guide references
Remove the agent-workflow process doc and strip dangling AGENTS.md /
.harness pointers from codebase docs, scan snapshots, benchmark review
notes, the screenshots plan, PR template, and commenting-guide
citations.
* docs(thesis): remove review working papers
Delete the review-round reports, language audits, rewrite editlists,
and master fixlists under thesis/reviews/ plus the remediation process
spec and plan they were generated from; strip stale AGENTS.md evidence
pointers from the markdown thesis mirrors.
* docs: remove docs/codebase documentation set
* docs(thesis): rebuild pdf
* style(thesis): restyle inline code to match template fonts
The template styled fenced code blocks but not inline raw spans, so
backticked identifiers fell back to Typst's default mono font and
clashed with the Times New Roman body. Render inline raw in Courier New
at 0.9em; rebuild pdf.
* style(thesis): bump inline code size to 12pt
* style(thesis): render inline code terms as emphasis
Replace all 235 inline raw spans with #emph (bracket form for plain
tokens, string form for markup-active characters like angle brackets
and underscores) so identifiers set in italic body text instead of a
clashing mono font; drop the now-unused inline-raw show rule and
rebuild pdf. Fenced code blocks are untouched.
* fix(thesis): apply review remediations
Remove duplicated thesis documentation sets (docs/_thesis/, docs/thesis/), agent instruction files (AGENTS.md, CLAUDE.md at root and subdirectories), feature plans (plan/feature-thesis-screenshots-1.md), and thesis review working papers (thesis/REVIEW.md, thesis/reviews/, thesis/spec/). These files were either superseded by the Typst-based thesis source, generated by coding agents and no longer needed, or contained working scratch material from the review remediation process.
…EADME The docs/codebase/ directory was deleted in the previous commit; remove the Documentation table and Work in Progress section that referenced it.
- Rename FashionCLIP → Fashion-CLIP consistently across all tables and text - Add statistical caveats: 3-fold CV limits power; non-overlapping bounds heuristic is descriptive, not a significance test - Add tbl-retrieval-caveats, tbl-deployment-recommendations, tbl-rq-answers - Restructure limitations into numbered list with per-item justification - Hedge RQ answers: "within measurement uncertainty", "highest observed mean" instead of "demonstrated superiority" - Add footnotes for recall values (category-only ground truth) and RAM estimates (psutil unreliable) - Revise English and Vietnamese abstracts to match cautious tone - Regenerate thesis/main.pdf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Brings
dev(1021 commits, last activity 2026-09-09) intomain(343 commits, last activity 2026-07-11).Diff
~8206 files changed (5279 added, 1198 removed, 1282 modified) — 1756636 insertions, 98737 deletions.
Highlights since the branches diverged
SECURITY.mdTest plan
main(1198, incl. 914 underservice/) are intentionally superseded, not lostmain's recent test commits (mapping unit tests) are present indev's tree