Commit Graph

2402 Commits

Author SHA1 Message Date
Oliver Walters 754a4c2e74 Fix migration conflict 2026-05-24 09:42:19 +00:00
Oliver Walters 433892018f Merge commit 'dd1edce2e59172c86e85fdd09d6ed01d3fcfefe4' into block-notes 2026-05-24 09:40:54 +00:00
Oliver dd1edce2e5
Set reasonable table height (#11998) 2026-05-24 11:02:28 +10:00
Oliver Walters 38e3c86307 Merge commit '749c4715ee022bdb39b500f5c3776c1ee18411e3' into block-notes 2026-05-23 23:30:06 +00:00
Oliver 749c4715ee
Offload build output functions: (#11990)
* Offload build output functions:

- cancel output
- scrap output
- complete output

Perform these in the background worker, and monitor for progress on the frontend.

* Refactor "build cancel"

- Offload expensive ops to background worker

* Offload build complete task

* Remove @atomic decorator from functions

- Allows operations to be performed "incrementally"
- If one task times out, the next task will get the rest

* Bug fix

* Bump API version

* Fix isInTestMode check

* Handle case where task returns immediately

* Fix docstring

* fix test_api

* Tweak order of operations

* additional unit testing for further coverage

* Adjust unit tests

* Offload order completion tasks

* Remove bad code

* Updated playwright test

* Robustify playwright tests

* Bump number of allowed queries

* Revert "Remove bad code"

This reverts commit 3a3ac3bdc7.

* Revert "Offload order completion tasks"

This reverts commit 6066dabe43.
2026-05-24 09:26:43 +10:00
Oliver 7d61203be8
Global part lock (#11995)
* Add new global setting

* Update lock checks

* Bug fix for task comparison

* Update user interface

* Hide locked field if locking not enabled

* Update existing unit tests

* Update docs
2026-05-24 07:41:52 +10:00
Oliver 8e7465dd24
Enable table ordering (#11992)
- Closes https://github.com/inventree/InvenTree/issues/10987
2026-05-24 00:30:27 +10:00
Oliver a1ed5bcf94
Bug fix for task comparison (#11993) 2026-05-24 00:18:56 +10:00
Oliver Walters 5cd7bfa1e4 Merge commit '27ca0836e7c7e46ebb41ea98d507972ae7a6b018' into block-notes 2026-05-23 12:41:47 +00:00
Oliver 27ca0836e7
[refactor] Attachment images (#11961)
* Add new Attachment model fields:

- is_image
- thumbnail

* Cache if the attachment is an image

* Add new setting for controlling max upload size

* Validate uploaded attachment file

* Add tqdm for progress bars

* Refactor migrations

- Don't need is_image field
- Can introspect from the thumbnail

* Data migration for existing attachments

* Bump API version

* Update tests and validators

* Add "is_image" field to the Attachment model

* Offload to background task

* Implement unit tests

* Docs

* Add unit test for data migration

* Additional unit test

* Omit migration tests from code coverage

* Additional unit tests
2026-05-22 23:37:32 +10:00
Jacob Felknor 74d9ab6d11
Transfer Order (#11281)
* initial skel commit for transfer orders

* initial transfer order backend model

* add some serializers, rename PLACED to ISSUED for TransferOrders

* adding from admin console works

* simple table list almost working, but we need to add order line items....

* add other cols to table

* add Transfer Order from table view

* moving towards a detail view

* wip: adding detail view

* add take from and destination serializer details

* add other detail grid items

* edit/duplicate transfer order

* more action buttons

* first crack at adding line items

* add to line item

* add filters

* starting work on row actions

* more action buttons for line items

* fix copy lines in duplicate

* basic allocation works

* allocations table actions

* allocate serials

* allocated serial row expansion

* add transferred qty to serializers

* move items on complete, show in tracking

* change panel to transferred stock upon complete

* allow incomplete line items

* disable edit allocations when completed

* add ref pattern and to settings

* add admin to line item inline

* add calendar and parametric view

* basic transfer order report

* add transfer order ruleset

* starting allocation buisness logic throughout for TOs

* disable accept incomplete logic, which was incorrect, until I fix

* fix incomplete allocation option

* add transferred col to default report

* add transfer order to calendar ics view

* chain condition for readability

* add transfer order allocations table to stockitem view

* don't account TO allocations in availability

* add transfer orders table for a part

* 'consume' option by doing take_stock

* squash migrations

* starting to test transfer order

* more transfer order tests

* add transfer order consume test

* wip, more tests

* more transfer order tests

* had to refresh_from_db

* switch "to" to "transfer-order" in url paths

* only select non-virtual parts from transfer order

* add transfer order docs

* deconflict migrations

* fix frontend build error

* fix validation on transfer order reference pattern

* add oath2 scope for transfer order

* fix state test to include transfer order state

* add barcode_model_type_code for transfer order

* bump api version

* check view role for transfer order, remove debug/commented out lines

* add serialized allocation test

* Fix migrations

* Frontend fixes

* Implement required 'company' attribute

* transfer order report context

* attempt to fix tests

* delete transfer order allocations on cancel

* add a few playwright tests, more incoming

* more playwright

* add source and destination locations to table

* deconflict migrations

* Fix build issue

* attempt to fix flaky transfer order test

* duplicate transfer order before running tests

* Adjust playwright tests

* Fix migration dependency order

---------

Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
Co-authored-by: Matthias Mair <code@mjmair.com>
2026-05-22 17:08:40 +10:00
Oliver 5489656016
[UI] Fix settings rendering (#11987)
- Do not duplicate global plugin settings
2026-05-22 15:19:01 +10:00
Oliver 5718b49bf1
Fix text size in build line table (#11986) 2026-05-22 14:37:48 +10:00
Oliver 8ae0a5ea66
Tree delete API (#11979)
* Add API serializer for deleting a location

* Add serializer for part category delete

* Bump API version

* Fix unit tests

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2026-05-22 14:37:36 +10:00
Oliver 8b9ea43b5b
[UI] Lock action (#11981)
- Toggle part lock directly from existing icon
2026-05-22 10:21:23 +10:00
Matthias Mair 9908870a81
realign user API endpoints (#11963)
* realign user API endpoints to make it clearer which one are only applicable to the current user

* fix name

* bump api

* fix test

* fix reference

* fix test exception

* update ref

* reduce breakage

* re-add legacy urls till next `breaking`
2026-05-22 09:44:24 +10:00
Matthias Mair f27b9b5443
feat(frontend): Add option for plugins to add header actions (#9570)
* [FR] PUI - Add option for plugins to add header actions
Fixes #8593

* fix parsing

* fix merge

* reduce diff

* fix sample implementation

* add support for icons and colors in primary actions

* add changelog entry

* add docs

* add more detailed sample text

* pass location into context

* fix test

---------

Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
2026-05-22 08:20:07 +10:00
dependabot[bot] 65d15a5945
chore(deps): bump idna from 3.13 to 3.15 in /contrib/dev_reqs (#11970)
* chore(deps): bump idna from 3.13 to 3.15 in /contrib/dev_reqs

Bumps [idna](https://github.com/kjd/idna) from 3.13 to 3.15.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.md)
- [Commits](https://github.com/kjd/idna/compare/v3.13...v3.15)

---
updated-dependencies:
- dependency-name: idna
  dependency-version: '3.15'
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix style

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Matthias Mair <code@mjmair.com>
2026-05-22 08:19:01 +10:00
Oliver e392348654
[UI] Calendar tooltips (#11980)
* Allow tooltips for calendar entries

* Render tooltip for purchase order calendar

* Calendar tooltip renderers

* Add tooltip for build calendar

* Add key to filter list

* Display responsible owner
2026-05-22 00:17:11 +10:00
Oliver Walters 7315c344f1 Merge branch 'block-notes' of github.com:SchrodingersGat/InvenTree into block-notes 2026-05-21 11:50:11 +00:00
Oliver Walters 0c1aa65cb9 Remove old deps 2026-05-21 11:49:41 +00:00
Oliver Walters 136c9256cb remove old editor 2026-05-21 11:47:58 +00:00
Oliver Walters 36e81c40c9 Sanitize before uploading 2026-05-21 11:46:37 +00:00
Oliver Walters 689bd1f224 Refactor save UX 2026-05-21 11:45:01 +00:00
Oliver Walters df340e363c Load notes into editor 2026-05-21 09:59:47 +00:00
Oliver fd3d64de99
Merge branch 'master' into block-notes 2026-05-21 19:59:00 +10:00
Oliver Walters 9e8764d28a Fix conflict (for now) 2026-05-21 09:27:08 +00:00
Oliver Walters c7d11dc939 Mark content field as 'safe' 2026-05-21 09:25:19 +00:00
Oliver Walters d77be246ae Add unit test 2026-05-21 07:51:05 +00:00
Oliver Walters c18fd25431 Update serializer 2026-05-21 07:26:54 +00:00
Oliver Walters ab0da25de8 Add "primary" field to Note model 2026-05-21 07:26:28 +00:00
Oliver 3f3433685d
Normalize BomItem quantity (#11975)
- Limit decimal places before save
- Prevents error in BomItem validation
2026-05-21 16:43:49 +10:00
github-actions[bot] 53d78be7f7
New Crowdin translations by GitHub Action (#11919)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-05-21 00:31:37 +10:00
Oliver Walters ac8e8d978c Add "no notes" item 2026-05-20 12:31:31 +00:00
Oliver Walters a0e528a509 Create new notes 2026-05-20 12:13:59 +00:00
Oliver Walters 51d8468e76 Fix serializer 2026-05-20 11:57:02 +00:00
Oliver Walters 6df13fe156 Add note mixin support for existing models 2026-05-20 11:50:55 +00:00
Oliver Walters 88158610af Add notes fetch 2026-05-20 11:43:17 +00:00
Oliver 9cac925e91
Prevent edit serial (#11964)
* Add new global setting

* Run serial number validation check

* Disable field in frontend

* Add unit test

* Docs tweak
2026-05-19 17:06:05 +10:00
Oliver Walters 19c497fb19 Merge commit '99358eb4e7e4b051fd35c0b72c5d75e11ea5f2ec' into block-notes 2026-05-19 06:43:01 +00:00
Oliver 99358eb4e7
Remove image download support (#11962)
* Remove image download support

- Helper function remains (it is used in the supplier plugin mixin)
- No longer available to user
- Close massive security hole entirely
- Will be defunct soon anyway (moving to generic attachments)

* Update CHANGELOG.md

* Bump API version

* Fix for unit tests
2026-05-19 07:02:05 +10:00
Oliver Walters 1078475acb API / serializer updates 2026-05-18 14:18:04 +00:00
Oliver Walters 176733d762 Add basic tab group for switching notes 2026-05-18 14:07:58 +00:00
Oliver Walters 71d51ff7b4 Add new generic "notes" model 2026-05-18 13:56:34 +00:00
Oliver Walters 01bc34e08a Add new notes editor using blocknote 2026-05-18 13:46:47 +00:00
Oliver Walters eff83e745e Install packages for blocknote 2026-05-18 13:42:11 +00:00
Oliver acc2786e44
[feature] Rename attachments (#11920)
* Implementation

* Update API and CHANGELOG

* Annotate response type

* Simplify attachment renaming

- Use the existing API endpoint

* Capture the actual saved path

* Tweak attachment table fields

* Use built-in validation

* Update docs

* Unit testing

* Ignore some lines from coverage

* Check if file exists before deleting
2026-05-18 20:02:46 +10:00
Oliver 73c7820ac0
Fix for dashboard item logic (#11960)
- Render cached value
2026-05-17 20:21:08 +10:00
Oliver 9f78e994c2
[UI] Mantine 9 (#11947)
* Update mantine deps

* Get it to compile

* Update QueryCount widgets

- use new RollingNumber component

* Table updates

- Remove "hack" for column ordering

* "Fix" the column pinning bug (maybe?)

* Fix ColumnRenderers.tsx

* Fix login code for playwright

* Remove hashing requirement

* Fix build tests

* More fixes

* More test fixes

* Fix playwright test for dashboard item

* Update frontend version

* Update changelog

* Reduce query repeats

* More playwright fixes

* Further playwright fixes

* Fix for useFilterSet hook

* Fix unique key error

* Fix rendering issues when opening edit forms

* reduce console errors

* Fix unique key issues in search drawer

* Update frontend CHANGELOG.md

* More form tweaks

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2026-05-17 19:26:37 +10:00
Aditya Kumar Mishra 582013e51c
Feature: Auto-select items tab for final stock locations (#11766) (#11955)
* Enhance: Auto-select items tab for final stock locations/categories

* Fix biome formatting in PanelGroup.tsx

* Change default setting to False per review

* Refactor: Rename setting to DISPLAY_ITEMS_FINAL_LEVEL to apply generically to both locations and categories per review

---------

Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
2026-05-17 19:06:00 +10:00