Skip to content

[UI] Import context#11685

Merged
SchrodingersGat merged 5 commits intoinventree:masterfrom
SchrodingersGat:import-context
Apr 7, 2026
Merged

[UI] Import context#11685
SchrodingersGat merged 5 commits intoinventree:masterfrom
SchrodingersGat:import-context

Conversation

@SchrodingersGat
Copy link
Copy Markdown
Member

@SchrodingersGat SchrodingersGat commented Apr 7, 2026

  • Refactors the "data import wizard" into a single globally accessible instance
  • Allows triggering of the wizard using a global state manager
  • Exposes hooks to the plugin context
  • Enables data import by plugins

Example

Using the manufacturing costs plugin

image image

For a full example of how this might be used within the context of a plugin:

SchrodingersGat/inventree-manufacturing-costs#53

@SchrodingersGat SchrodingersGat added this to the 1.3.0 milestone Apr 7, 2026
@SchrodingersGat SchrodingersGat added plugin Plugin ecosystem import / export Data importing, exporting and processing refactor User Interface Related to the frontend / User Interface labels Apr 7, 2026
@netlify
Copy link
Copy Markdown

netlify bot commented Apr 7, 2026

Deploy Preview for inventree-web-pui-preview canceled.

Name Link
🔨 Latest commit a6a7d54
🔍 Latest deploy log https://app.netlify.com/projects/inventree-web-pui-preview/deploys/69d4f439e1efab0008c3e8e4

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 7, 2026

Codecov Report

❌ Patch coverage is 50.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.44%. Comparing base (e91f306) to head (a6a7d54).
⚠️ Report is 3 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #11685      +/-   ##
==========================================
- Coverage   91.44%   91.44%   -0.01%     
==========================================
  Files         964      964              
  Lines       49847    49847              
==========================================
- Hits        45585    45584       -1     
- Misses       4262     4263       +1     
Flag Coverage Δ
backend 89.25% <50.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
Backend Apps 91.71% <33.33%> (-0.01%) ⬇️
Backend General 93.41% <ø> (ø)
Frontend ∅ <ø> (∅)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 7, 2026

Bundle Report

Changes will decrease total bundle size by 2.42kB (-0.03%) ⬇️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
pui_v1-esm 8.83MB -2.42kB (-0.03%) ⬇️

Affected Assets, Files, and Routes:

view changes for bundle: pui_v1-esm

Assets Changed:

Asset Name Size Change Total Size Change (%)
assets/TemplateTable-*.js -43 bytes 612.85kB -0.01%
assets/PartDetail-*.js -136 bytes 479.54kB -0.03%
assets/Filter-*.js -4 bytes 267.36kB -0.0%
assets/Layout-*.js 12.02kB 50.8kB 30.98% ⚠️
assets/InvenTreeTable-*.js 1.19kB 29.39kB 4.21%
assets/UserSettings-*.js -38 bytes 25.19kB -0.15%
assets/PluginUIFeature-*.js 494 bytes 22.83kB 2.21%
assets/StockDetail-*.js -43 bytes 21.66kB -0.2%
assets/BuildDetail-*.js -37 bytes 20.06kB -0.18%
assets/BuildLineTable-*.js -42 bytes 16.82kB -0.25%
assets/MachineManagementPanel-*.js -39 bytes 16.61kB -0.23%
assets/SalesOrderDetail-*.js -86 bytes 16.18kB -0.53%
assets/PurchaseOrderDetail-*.js -186 bytes 13.95kB -1.32%
assets/ImportPartWizard-*.js -1 bytes 12.16kB -0.01%
assets/ReturnOrderDetail-*.js -82 bytes 11.77kB -0.69%
assets/BuildForms-*.js -5 bytes 11.38kB -0.04%
assets/LocationDetail-*.js -82 bytes 10.06kB -0.81%
assets/CategoryDetail-*.js -82 bytes 9.31kB -0.87%
assets/PluginListTable-*.js -38 bytes 8.82kB -0.43%
assets/Login-*.js -5 bytes 8.82kB -0.06%
assets/ColumnRenderers-*.js 1 bytes 8.26kB 0.01%
assets/CompanyDetail-*.js -82 bytes 8.21kB -0.99%
assets/SystemSettings-*.js 1 bytes 7.86kB 0.01%
assets/ParametricDataTable-*.js 1 bytes 7.5kB 0.01%
assets/PartTable-*.js -58 bytes 7.4kB -0.78%
assets/SalesOrderShipmentDetail-*.js -82 bytes 7.32kB -1.11%
assets/SupplierPartDetail-*.js -81 bytes 7.08kB -1.13%
assets/Scan-*.js -38 bytes 6.07kB -0.62%
assets/StockItemTable-*.js 1 bytes 5.98kB 0.02%
assets/PurchasingIndex-*.js -33 bytes 5.68kB -0.58%
assets/ParameterPanel-*.js -43 bytes 5.55kB -0.77%
assets/ManufacturerPartDetail-*.js -82 bytes 5.29kB -1.53%
assets/TaskManagementPanel-*.js -38 bytes 5.01kB -0.75%
assets/SalesOrderAllocationTable-*.js 1 bytes 4.68kB 0.02%
assets/SupplierPartTable-*.js 1 bytes 4.62kB 0.02%
assets/BuildAllocatedStockTable-*.js 1 bytes 4.38kB 0.02%
assets/SalesIndex-*.js -38 bytes 4.36kB -0.86%
assets/HomePanel-*.js -38 bytes 4.28kB -0.88%
assets/SalesOrderTable-*.js 6 bytes 4.17kB 0.14%
assets/EmailManagementPanel-*.js -38 bytes 4.17kB -0.9%
assets/BarcodeScanHistoryTable-*.js -38 bytes 3.9kB -0.96%
assets/Notifications-*.js -38 bytes 3.35kB -1.12%
assets/StockTrackingTable-*.js 1 bytes 3.34kB 0.03%
assets/ParameterTable-*.js -55 bytes 3.03kB -1.78%
assets/ReturnOrderForms-*.js 5 bytes 2.94kB 0.17%
assets/BuildOrderTable-*.js -4 bytes 2.78kB -0.14%
assets/UnitManagementPanel-*.js -38 bytes 2.76kB -1.36%
assets/ErrorTable-*.js -38 bytes 2.61kB -1.44%
assets/BuildIndex-*.js -43 bytes 2.6kB -1.63%
assets/ImportSessionTable-*.js -157 bytes 2.54kB -5.82%
assets/CustomStateTable-*.js -38 bytes 2.49kB -1.51%
assets/PurchaseOrderTable-*.js 5 bytes 2.28kB 0.22%
assets/ManufacturerDetail-*.js -82 bytes 2.2kB -3.59%
assets/SupplierDetail-*.js -82 bytes 2.2kB -3.6%
assets/CustomerDetail-*.js -82 bytes 2.19kB -3.62%
assets/PartCategoryTemplateTable-*.js -38 bytes 2.19kB -1.71%
assets/NavigationTree-*.js -1 bytes 2.18kB -0.05%
assets/GroupDetail-*.js 5 bytes 1.95kB 0.26%
assets/LocationTypesTable-*.js -38 bytes 1.91kB -1.95%
assets/CompanyForms-*.js 1 bytes 1.91kB 0.05%
assets/UserManagementPanel-*.js -43 bytes 1.82kB -2.3%
assets/CurrencyManagementPanel-*.js -38 bytes 1.79kB -2.07%
assets/CoreIndex-*.js -38 bytes 1.71kB -2.18%
assets/ProjectCodeTable-*.js -43 bytes 1.57kB -2.66%
assets/ExportSessionTable-*.js -43 bytes 1.52kB -2.75%
assets/ReportTemplatePanel-*.js -38 bytes 1.41kB -2.63%
assets/LabelTemplatePanel-*.js -38 bytes 1.11kB -3.31%
assets/ScheduledTasksTable-*.js -38 bytes 1.11kB -3.32%
assets/PluginErrorTable-*.js -38 bytes 981 bytes -3.73%
assets/InfoItem-*.js 5 bytes 747 bytes 0.67%
assets/RowExpansionIcon-*.js 4 bytes 350 bytes 1.16%
assets/ImporterForms-*.js -12.08kB 324 bytes -97.39%
assets/IconChevronDown-*.js (Deleted) -1.34kB 0 bytes -100.0% 🗑️

Files in assets/PartDetail-*.js:

  • ./src/tables/bom/BomTable.tsx → Total Size: 20.66kB

Files in assets/Layout-*.js:

  • ./src/components/importer/GlobalImporterDrawer.tsx → Total Size: 414 bytes

  • ./src/components/nav/Layout.tsx → Total Size: 3.48kB

Files in assets/PluginUIFeature-*.js:

  • ./src/components/plugins/PluginContext.tsx → Total Size: 2.0kB

  • ./src/states/ImporterState.tsx → Total Size: 717 bytes

  • ./lib/types/Plugins.tsx → Total Size: 127 bytes

Files in assets/PurchaseOrderDetail-*.js:

  • ./src/tables/purchasing/PurchaseOrderLineItemTable.tsx → Total Size: 10.96kB

Files in assets/PartTable-*.js:

  • ./src/tables/part/PartTable.tsx → Total Size: 16.34kB

Files in assets/ParameterTable-*.js:

  • ./src/tables/general/ParameterTable.tsx → Total Size: 6.12kB

Files in assets/ImportSessionTable-*.js:

  • ./src/tables/settings/ImportSessionTable.tsx → Total Size: 3.99kB

@SchrodingersGat SchrodingersGat merged commit 437dddc into inventree:master Apr 7, 2026
59 checks passed
@SchrodingersGat SchrodingersGat deleted the import-context branch April 7, 2026 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

import / export Data importing, exporting and processing plugin Plugin ecosystem refactor User Interface Related to the frontend / User Interface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant