Repository navigation
feat: SCO-160 group one-row-per-variant product imports by style number - #395
Merged
Merged
Conversation
…mber Exports that list each size and color on its own row imported as one product per row, with the SKU column taking over the style number. Rows now group by style number into one product, and each row's SKU is saved on its variant. Headers map through the scoring mapper the onboarding importer already uses. SCO-160 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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
/productsand brand product pages now groups rows by style number. A file with one row per size and color lands as one product with its variants.SKUcolumn next to a style number column is saved on each variant (product_variants.sku) instead of replacing the style number.mapProductHeaders, the scoring mapper the onboarding importer already uses, in place of per-header greedy matching./api/products/importendpoint accepts optionalvariants: [{ size, color, sku }]per product and inserts exactly those. Drafts without it still cross sizes x colors, so the PDF path and the template are unchanged.Why
SCO-160 asks for long-format files to import as one product per style. Before this, a 3-row file for one tee created 3 products named after their SKUs.
Verification
bun run lintpassesbun run checkpasses (0 errors)bun run test:runpasses (2,046).xlsx(Style Number, Size, Color, SKU, 3 rows) created 1 product with 3 variants carryingXV-201-OAT-S/M/L.xlsxstill created 2 products with 6 and 3 variantsTest plan
Part of SCO-160
🤖 Generated with Claude Code