feat: CSV import – default none, Select All/None, and filter + Select Filtered #218

Merged
Copilot merged 2 commits from copilot/add-features-to-csv-import into main 2026-04-14 09:01:36 +00:00
Copilot commented 2026-04-14 07:31:54 +00:00 (Migrated from github.com)

Description

The CSV purchase import preview step lacked selection controls and had no way to filter rows before importing. Rows were auto-selected on load, and there was no bulk deselect or criteria-based selection.

Changes in CsvPurchaseImport.vue

  • Default to none selected — removed auto-select of non-duplicates after upload
  • Select All / Select None buttons — replaced the indeterminate checkbox with two explicit action buttons
  • Filter section (collapsible v-expansion-panel):
    • Text search on description
    • Date range (from / to) — ISO string lexicographic compare
    • Amount range (min / max) — parsed as floats
    • Clear Filters button; Active chip badge when filters are live
  • Select Filtered — bulk-selects non-duplicate rows matching current filters while preserving any existing selection outside the filter; uses a Set for O(1) index lookups
  • Filtered count added to stats row (4 cols: Total / Filtered / Selected / Selected Total); text-secondary when filters are active
  • Table now iterates filteredRows computed property instead of raw previewRows

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactoring (code change that neither fixes a bug nor adds a feature)
  • Performance improvement
  • Test coverage improvement

Testing

  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have tested this manually (if applicable)

Code Quality

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings or errors

CI/CD Checks

  • All automated tests pass
  • Code formatting (Pint) passes
  • JavaScript/TypeScript linting passes
  • Build process completes successfully

Additional Notes

Only CsvPurchaseImport.vue is changed — no backend, routes, or type changes required.

## Description The CSV purchase import preview step lacked selection controls and had no way to filter rows before importing. Rows were auto-selected on load, and there was no bulk deselect or criteria-based selection. ### Changes in `CsvPurchaseImport.vue` - **Default to none selected** — removed auto-select of non-duplicates after upload - **Select All / Select None buttons** — replaced the indeterminate checkbox with two explicit action buttons - **Filter section** (collapsible `v-expansion-panel`): - Text search on description - Date range (from / to) — ISO string lexicographic compare - Amount range (min / max) — parsed as floats - *Clear Filters* button; *Active* chip badge when filters are live - **Select Filtered** — bulk-selects non-duplicate rows matching current filters while preserving any existing selection outside the filter; uses a `Set` for O(1) index lookups - **Filtered count** added to stats row (4 cols: Total / Filtered / Selected / Selected Total); `text-secondary` when filters are active - Table now iterates `filteredRows` computed property instead of raw `previewRows` ## Type of Change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update - [ ] Refactoring (code change that neither fixes a bug nor adds a feature) - [ ] Performance improvement - [ ] Test coverage improvement ## Testing - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [x] I have tested this manually (if applicable) ## Code Quality - [x] My code follows the style guidelines of this project - [x] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings or errors ## CI/CD Checks - [ ] All automated tests pass - [ ] Code formatting (Pint) passes - [ ] JavaScript/TypeScript linting passes - [ ] Build process completes successfully ## Additional Notes Only `CsvPurchaseImport.vue` is changed — no backend, routes, or type changes required.
coderabbitai[bot] commented 2026-04-14 07:32:32 +00:00 (Migrated from github.com)

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Free

Run ID: 08d4740b-2cb9-472e-85d7-a8cefb16f42d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands and usage tips.

<!-- This is an auto-generated comment: summarize by coderabbit.ai --> <!-- This is an auto-generated comment: skip review by coderabbit.ai --> > [!IMPORTANT] > ## Review skipped > > Bot user detected. > > To trigger a single review, invoke the `@coderabbitai review` command. > > <details> > <summary>⚙️ Run configuration</summary> > > **Configuration used**: defaults > > **Review profile**: CHILL > > **Plan**: Free > > **Run ID**: `08d4740b-2cb9-472e-85d7-a8cefb16f42d` > > </details> > > You can disable this status message by setting the `reviews.review_status` to `false` in the CodeRabbit configuration file. > > Use the checkbox below for a quick retry: > - [ ] <!-- {"checkboxId": "e9bb8d72-00e8-4f67-9cb2-caf3b22574fe"} --> 🔍 Trigger review <!-- end of auto-generated comment: skip review by coderabbit.ai --> <!-- tips_start --> --- <sub>Comment `@coderabbitai help` to get the list of available commands and usage tips.</sub> <!-- tips_end -->
Sign in to join this conversation.
No description provided.