Commit Graph
608 Commits
Author SHA1 Message Date
Oliver 19dfb81bfb [docs] Zensical docs (#13253)
* add zensical workflow

* rebuild schema dynamically

* load in new module

* Use zensical for docs invoke tasks

* modern

* improved carousel layout

* Increased content width

* fix for app icons

* Ensure schema dir exists

* remove unused requirement

* update readthedocs process

* fix polar.sh link

* adjust link checker pattern

* Revert some of the original style

* remove legacy mkdocs requirements

* fix for ready.py

* reduce db warnings during schema generation

* Adjust padding

* fix index issues

* fix page title

* fix pages with broken or missing headers

* split data import API schema

* cleanup old carousel

* remove djlint link
2026-11-14 22:34:18 +11:00
OliverandCopilot Autofix powered by AI 12c16000d9 MFA workflow fixes (#13241)
* MFA workflow fixes

- Fixes https://github.com/inventree/InvenTree/issues/13238
- Verify email on successful password reset
- Invalidate password on account creation
- Fix MFA workflows
- Add regression tests

* Update docs

* Update OTP secret expectation to use exact match

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Attempt to fix flaky test

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-11-14 13:34:57 +11:00
OliverandMatthias Mair 790112013b Added generic MPN barcode scanning (#13266)
* Added generic MPN barcode scanning

- Provides generic lookup against MPN
- Runs with lower priority (fallback only)
- Barcode plugins are now ordered by decreasing priority

* Apply suggestion from @matmair

* Bump internal priority

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2026-11-13 21:53:35 +11:00
Matthias Mair 7e57196d76 Add import linter (#13248)
* add import-linter

* move machine imports to plugin space

* clean up samples

* extend scope

* extend checks

* move plugin internals into a seperat folder

* remove unneeded re-export

* adjust import

* update import checker

* update src ref

* fix mocks
2026-11-12 18:41:59 +11:00
Matthias Mair a8a867400d feat(backend): enable disabling of basic authentication (#13169)
* !feat(backend): disable basic authentication by default

* align PR

* add PR number

* fix schema creation/discovery

* mask basic auth

* fix error code

* reduce diff

* adjust changelog message

* fix test (needs basic auth which is now off by default)

* switch to default on; retain warning

* update test for new default

* fix assertation
2026-11-10 13:32:38 +11:00
Matthias Mair c54c69c1bc update logging setup to respect json setting (#13216)
* fix json_log to ensure we really only log json

* also control gunicorn

* reduce noise in action
2026-11-07 16:02:41 +11:00
Oliver d8f09fa078 Token fixes (#13175)
* Prevent junk token from bypassing MFA

* updated docs

* Fix read-only token fields

* Fix API version ref
2026-11-03 23:05:23 +11:00
Matthias Mair 4121d9a8a5 Merge commit from fork
* fix basic auth without mfa

* refactor order to use new basic auth class

* remove session auth taht would bybpass mfa (mfa thing fixed in another session)

* allign with other PRs

prep for merge with https://github.com/inventree/InvenTree/pull/13169/

* fix schema generation
2026-11-03 20:23:32 +11:00
Matthias Mair 16fa2ee5cd Merge commit from fork
* fix oauth scopes

* fix typing
2026-11-03 20:20:10 +11:00
Oliver 62d363a99d [UI] Context details for plugin actions (#13172)
* [UI] Context details for plugin actions

Adds additional target instance context when registering custom UI actions

* Add CHANGELOG entry

* Improve test
2026-11-03 17:22:26 +11:00
Oliver 461186bee9 [UI] Launch forms directly from plugin (#13174)
* [UI] Launch forms directly from plugin

Provide ability for plugins to dynamically launch modal forms, without specifying the underlying react components.

This allows (for example) a primary action on a detail page to launch a new native API form

* Add CHANGELOG entry
2026-11-03 16:41:33 +11:00
Oliver c3948f56ed Implement stock adjust barcode actions (#13170) 2026-11-03 12:03:33 +11:00
Matthias Mair b2c2f926e7 Fix doc links / setup (#13140)
* fix various doc links

* update generated start page

* switch to properdocs

* bump deps

* pin mkdocs before 2.0 so deps dont break

* fix link
2026-11-01 08:34:25 +11:00
Oliver 60db8a924e Updates for AutoCreateBuildPlugin (#13118) 2026-10-28 10:42:44 +11:00
OliverandCopilot Autofix powered by AI 3e55d413ec [report] Harden data access for reports (#13111)
* [report] Harden data access for reports

- Exclude sensitive data
- Prevent database writes during report generation

* Fix typo

* Add regression test against model traversal

* Add webhook endpoint and message to imports

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Remove some models from BLOCKED_MODELS

* Revert READ_ONLY requirement

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-10-28 01:06:45 +11:00
Oliver c4280c2a03 [Refactor] Stock tracking audit (#13101)
* Add "event_type" and "notes" support to AuditLog model

* Register history entries for stock items

* record stock edited events as normal updates

* Remove legacy tracking entry generation code

* Updated unit tests for all stock event types

* remove legacy endpoints

* remove legacy tables from UI

* Updated docs

* Data migration

* Remove old models

* Update docs

* Updated playwright tests

* Fix broken links

* Update CHANGELOG.md

* Cache CID value

* Fix migration tests

* Increase query threshold for unit test

* Fix bug and add regression test

* mark migration as one-way

* flush events in the correct order

* improve prefetch

* Adjust row rendering
2026-10-27 15:14:15 +11:00
Oliver 6c65d96ece Export escape fix (#13110)
* Allow numeric values to be exported unescapted

* Updated docs

* Explicit regression tests
2026-10-27 11:55:24 +11:00
Oliver c475e9bfcf [Feature] Changelog / Edit History (#13069)
* Initial app scaffolding

* Skeleton for AuditLogTable

* Add UI table

* Add audit history panel to admin center

* Add auditing for models in the 'company' app

* Gate API access of user staff status

* Display item history in UI

* Track 'attachment' history

* Track 'parameter' changes

* Audit support for "common" models

* Track changed for "build" models

* Track history for "order" models:

- PurchaseOrder
- SalesOrder
- SalesOrderShipment
- ReturnOrder

Also track changes against LineItem and ExtraLineItem objects

* Register custom admin class

* Support Part history

* BomItem changes

* Fix for BulkCreateMixin

* Tweak unit tests

* Use Viewset

* Adjust error code behavior

* Setting to keep summary entries

* Refactor helper for middlewares

* Tweak unit tests

* Fixes for ModelInformationDict

* Track pricing changes

* Add model type filter for auditlog table

* Specify filter field type

* Hide HistoryPanel if auding is disabled

* add docs

* Add "--summary" option to export_records task

* Playwright tests

* Track task responsible for data changes

* Updated unit tests

* record changes to global settings

* Update docs

* Ensure values are stringified

* Fix for globalsetting

* Patch unit test

* Tweak playwright tests

* playwright test fix

* use main branch for demo data

* Update CHANGELOG
2026-10-25 12:36:13 +11:00
Oliver 43956b9324 [bug] Can build fix (#13090)
* Fix 'can_build' calculation

- Take 'piece_count' into consideration
- Update queryset annotations
- Update quantity calculation call sites

* Updated docs
2026-10-24 17:28:07 +11:00
Oliver e57ee86c35 Cache config fix (#13080)
* Fix docs

* Adjust config template

* Tweak cache config code
2026-10-24 12:19:47 +11:00
Matthias Mair 5bd0036ee1 feat(backend): add a way to proof instance id without sharing id / making id available (#13030)
* add a way to proof instance identification without publicly sharing id

* fix test
2026-10-24 08:25:46 +11:00
OliverandMatthias Mair 4c948cda1b Pricing role (#13034)
* add 'pricing' role

* Create new 'pricing' app

- migrate existing pricing models

* bug fixes

* Move API endpoints to /api/pricing/

* Adjust target branch for playwright tests

* Fix permission checks for nested OptionalField entries

* Migrate existing background tasks

* Point to master branch demo data

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2026-10-21 15:00:50 +11:00
96d1d20b73 feat: Add Delivery Address field to Purchase Orders (#9768)
* Add delivery address to purchase order; migrate address field to Supplier Address (#9303)

* update model related_name and remove migrate file

* regenerate migration

* Fix migration ordering

* Bump API version

* add 'receiving_company' field

* UI updates

* Add regression tests

---------

Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
Co-authored-by: Matthias Mair <code@mjmair.com>
2026-10-17 08:13:26 +11:00
Oliver 839cd571f4 Supplier price note (#13027)
* add extra information to form

* Updated documentation

* Updated UI

* Fix broken link
2026-10-17 08:11:56 +11:00
Oliver 529a41f1fd override default value display (#13028) 2026-10-16 23:09:33 +11:00
Oliver c74523dcff Control backup count (#13025)
Enable control of how many historical backup entries to keep when running invoke backup --clean
2026-10-16 19:22:33 +11:00
OliverandMatthias Mair 9b8fdeb06d Internal company support (#13017)
* Add internal company flag

* Unit tests

* Add changelog entry and update API version

* add global company table

* Expose model_filters for internal settings

* Update API version

* Update CHANGELOG

* update assert

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2026-10-15 11:20:59 +11:00
Oliver 720ba157bb Shipment contact info (#13016)
* Add 'contact' field to SalesOrderShipment model

* add unit test

* Update shipment table

* improve UI form

* Add 'phone' and 'email' fields to Address model

* Bump API version

* Update CHANGELOG

* Updated docs
2026-10-14 19:33:33 +11:00
Oliver 99893f3453 [UI] Nested bom (#12952)
* [UI] Replace BOM subassembly table

- Do not render as a separate table
- Dynamically load and insert subassembly data
- Retains single table layout
- Observe same column setup

* Adjust alignment of icons

* Hide certain icons for nested rows

* Display subassembly quantity chain

* Display full multiplication chain

* Add nested pricing multipliers

* Display the multiplied "can-build" quantity

* Updated BOM docs

* Playwright tests

* Handle case where can_build is zero

* Refresh nested BOM when underlying records change

* Remove trunc for display

* fix playwright test
2026-10-13 22:59:51 +11:00
Oliver 788b291a21 Plugin reload limitations (#13007)
* Improve auto-reload of plugin

Ensure entire module is reloaded

* Add regression tests

* Updated docs

* Detect plugin reload loop - and report error
2026-10-13 20:46:02 +11:00
Oliver 55ad065a60 Add docs for font loading (#12998) 2026-10-13 13:01:20 +11:00
Matthias Mair 600dc1a75b feat(frontend): optional nav tree sidebyside (#12974)
* disable restriction (for now)

* add option for a permanent navigation tree

* revert unintended change

* adjust search text to be less confusing when pinned
2026-10-13 09:26:57 +11:00
Petr Ledvina 967f7a55d1 Add raise_error template tag (#12940) 2026-09-28 07:04:49 +10:00
d33d77d679 feat: add plugin support for custom page integration (#12900)
* Added plugin UI route functionality.

* Updated Sample UI plugin with route example.

* Added UI route tests.

* Plugin name added to UI Route URL.

* Updated docs.

* Docs fix.

* Updated sample_route text.

* Update src/backend/InvenTree/plugin/base/ui/mixins.py

Co-authored-by: Matthias Mair <code@mjmair.com>

* Fixed nav dynamic link highlighting.

* Added changelog entry.

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
2026-09-27 08:13:54 +10:00
Oliver 979ddb3f06 Default receive location (#12911)
* Add global setting

* docs

* Dynamically set API field default

* UI elements

* regression testing

* Add CHANGELOG entry

* Fix unit test
2026-09-26 11:39:44 +10:00
Oliver a4518fb52b Allocate mixin (#12914)
* Create AllocateMixin plugin mixin class

* Add documentation

* Add hook-in points for the new code

* Add unit tests

* Add CHANGELOG entry

* Add loose typing
2026-09-23 06:39:26 +10:00
Oliver 2f91f9a068 [report] Add set_var and get_var helpers (#12901)
* [report] Add set_var and get_var helpers

* Add type hints

* Adjust helpers
2026-09-21 16:38:03 +10:00
Oliver bb195a77b8 Min db docs (#12897)
* Add minimum version information

* Update DB docs
2026-09-21 08:17:04 +10:00
Oliver 10422dc37b [db] Disable JIT for postgres (#12893)
* disable postgres JIT by default

* Update docs
2026-09-20 19:09:55 +10:00
lizerui1608-dev 417e93a012 docs: fix typos in development documentation (#12888) 2026-09-20 10:43:56 +10:00
Petr LedvinaandOliver f76d79baf1 Add SVG support to datamatrix (#12875)
* Extract Data Matrix rendering helpers

* Add SVG Data Matrix output

* Verify vector Data Matrix output in PDFs

---------

Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
2026-09-18 18:14:50 +10:00
Matthias Mair dca516b318 feat(backend): switch API token storage to hmac digest (#12850)
* [FR] switch API token storage to hmac digest
Fixes #12027

* add pr number

* fix implementation details
allign token prefix and token end (add date issuance)

* fix missing re-issuance

* ensure we raise if not exsistant

* fix test

* add ignore

* extend test

* add information regarding v2 tokens

* add fields for:
- revocation details (reason, revoker)
- issueance
- version
- pepper

* bump apiversion

* make revocation mesagge clearer

* add missing update fields

* ensure this only triggers for v2

* move comment

* re-add v1 coverage

* add missing annotation to api schema
2026-09-16 10:35:12 +10:00
Matthias Mair 63a434c652 feat: Add facility to completely hide parts of the interface (#12842)
* fix typing issue for pylance engine

* add flags to mark rough function of setting

* update pr version

* fix settings serialisation

* render security warnings

* move Transfer Orders

* respect return order hiding

* almost all confirm texts will have a warning

* add settings for sales, purchase and buildorder deactivation

* make permission check also ensure gloablsetting for view is available; reduce number of chained gates

* document possible missing check

* ensure we can still show the sales tab

* add additional warning to group cleanup

* hide more ui parts conditionally

* add tests for new code and remove duplication

* fix test

* alternative approach to fix SSO path

* remove patch; now done in serializer

* ignore ldap section
2026-09-15 21:13:59 +10:00
wyyd-yxcandMatthias Mair 9181097194 Add user option to rotate table column headers (#12837)
* Add user option to rotate table column headers (#12558)

Wide column titles (e.g. "Temperature coefficient [±ppm/°C]") take a
lot of horizontal space for narrow data. Add a ROTATE_TABLE_HEADERS
user setting (Display Options) which renders table header titles
vertically via a scoped CSS class, following the implementation
sketch from the issue discussion.

* Format ROTATE_TABLE_HEADERS description per ruff-format

* add missing doc place

* Document ROTATE_TABLE_HEADERS setting in user settings docs

* docs: add changelog entry for rotated table headers option

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2026-09-12 14:12:39 +10:00
Oliver c26db6a790 Squash migrations (#12830)
* Squash migrations for "users" app

* Squash migrations for "common" app

Note: we will come back again later to squash some more

* Significant squashing

* Update legacy migrations

* Further squashing of migrations

* Even more cleanup

* Adjust CI workflow

* Update CI Job

* Update docs

* Update CHANGELOG.md

* Cleanup old comments

* Throw error if pre 1.0.0 DB detected

* Refactor incomplete migration check
2026-09-11 16:03:41 +10:00
Matthias Mair c959ca4574 feat(frontend): add SAML helper (#12799)
* squash #12762

* implement https://github.com/inventree/InvenTree/issues/3509

* add changelog

* add option to use the full width
2026-09-07 16:52:24 +10:00
Matthias Mair 9bc5054d84 Clarify supported OS versions for installer (#12803)
Fixes #12798
2026-09-07 10:45:57 +10:00
Oliver 1218af7366 Adds bulk-import option for "import-records" task (#12792)
* skip plugin events if importing or migrating data

* Add bulkloaddata option

* Skip signals if importing

* Improve bulkloaddata command

* Optionally rebuild thumbnails

* enhancements for import_records task

* cache natural key references in bulkloaddata

* wrap export_records in @state_logger

* Reduce file size of exported data

* Added docs

* Test bulk workflow as part of CI

* Add progress bar for data import

* fix for import workflow bug

* Separately test bulk import workflow

* Exercise --prettify option

* Additional CI checks for content excludes

* Allow plugin loading for list_apps

* Additional CI unit tests

* Test for importing with conflicting records

* path fixes

* Adjust test conditions
2026-09-06 19:58:52 +10:00
Oliver 321489a41b Add error message for missing TLD (#12789)
* Add error message for missing TLD

* add error code for missing TLD
2026-09-06 15:00:22 +10:00
Matthias Mair 0a4f095397 feat(backend): enable OIDC/oAuth2 provider by default (#12731)
* Add SCIM
Closes https://github.com/inventree/InvenTree/issues/6339

* also test scim

* extend testing with conformance suite

* fix test suite results

* coverage completion

* fil test gaps

* add missing schema values

* fix more type issues

* fix error view

* remove route from OpenAPI

* User permissions check for Attachment API (#12689)

* enable oidc proivder by default

* add .well-known entry for OIDC server

* add default client registration

* add changelog entry

* add codeowners

* remove redundant info

* re-name and restructure panel

* add a smal explainer section on top

* flesh out section a bit more

* change name

* basic sso panel

* refactor rendering

* add api and mgmt functions

* add create/delete options

* simplify test

* handle secret generation

* fix merge

* update coverage

* add test

* reduce user friction

* add better labels

* make it more clear that this is only shown once

* add regenerate function

* update tests

* simplify test calls

* fix test
2026-09-05 12:10:13 +10:00