2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-16 12:05:53 +00:00
Commit Graph

968 Commits

Author SHA1 Message Date
cee679d6e3 fix pdf preview with background worker (#9591) 2025-04-28 07:13:18 +08:00
fc42b6d7a1 New Crowdin translations by GitHub Action (#9588)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
2025-04-27 20:05:55 +08:00
9729c41783 bump babel further (#9589) 2025-04-26 11:23:22 +10:00
2ed3e61a57 chore(frontend): bump dep resolution (#9523)
* chore(frontend): bump dep resolution
to adress GHSA-968p-4wvh-cqc8

* fix @types/react resolution

* reduce range of bumped deps
2025-04-26 08:07:12 +10:00
ee29e6aa7b Add revison column to BO table (#9580) 2025-04-25 09:39:39 +10:00
c41760a500 chore: bump zustand (#9577)
* bump zustand to v5

* add missing shallow

* fix missing shallow

---------

Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
2025-04-25 09:39:08 +10:00
71cf9f5452 [FR] Save widget state per user (#9567)
* [FR] Save widget state per user
Fixes #9562

* cleanup

* fix doc strings

* add reset stage
2025-04-24 17:29:28 +10:00
c6907a0bf2 New Crowdin translations by GitHub Action (#9543)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-22 22:09:24 +10:00
89b3f91ded Update notification fetching (#9557)
- Reduce interval to 1 minute
- Only fetch for visible tab
2025-04-22 09:52:50 +10:00
6b08e45eac Docs refactor (#9545)
* Refactor / reognaize docs structure

* Refactor plugin docs structure

* More refactoring / cleanup

* Update build images

* Gallery updates

* Order images

* Update part docs

* Settings images

* Stock images

* Reitntroduce gallery

* Add custom icon macro

* Update icons

* Cleanup

* Fix link

* Fix internal links

* Revert some page moves

* Fix links

* Fix links
2025-04-22 08:18:32 +10:00
e249a21622 Url fix 2 (#9548)
* Logic fix

* Playwright test

* Revert "Playwright test"

This reverts commit a63b23961e.

* Simplify test

* Cleanup test
2025-04-21 17:42:22 +10:00
bd74044ed9 Display "default expiry" on part detail page (#9549) 2025-04-21 16:23:01 +10:00
79dad13328 [UI] Barcode actions (#9538)
* Provide callback function for barcode scan dialog

* Adds hook for barcode scan dialog

* Fix callback processing

* Add function to extract API URL for a model instance

* Tweak page titles

* Extract instance data when scanning a barcode

* Scan item into location

* Scan in stock location

* Remove notYetImplemented func

* Revert "Remove notYetImplemented func"

This reverts commit a35408380e.

* Add stock item action

* Add playwright tests
2025-04-21 08:42:54 +10:00
13412adeb3 Reduce notification check frequency (#9542) 2025-04-20 11:42:30 +10:00
64f72381a1 New Crowdin translations by GitHub Action (#9529)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-20 11:23:21 +10:00
6b0a082b5a feat: New / Refactor "Nav Mixin" (#9283)
* [FR/P-UI] New / Refactor "Nav Mixin"
Fixes #5269

* remove logging

* fix sample item that causes issues

* Add test coverage

* Update src/frontend/src/components/plugins/PluginUIFeatureTypes.ts

Co-authored-by: Lukas <76838159+wolflu05@users.noreply.github.com>

* [FR/P-UI] New / Refactor "Nav Mixin"
Fixes #5269

* fix style

* remove requirement for source

* fix import

* bump api version

---------

Co-authored-by: Lukas <76838159+wolflu05@users.noreply.github.com>
2025-04-20 11:22:58 +10:00
62d058f0e3 New Crowdin translations by GitHub Action (#9508)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-17 13:17:41 +10:00
204e2e6d46 Edit BOM substitutes (#9521)
* Edit BOM substitutes

* Add playwright tests
2025-04-16 14:38:59 +10:00
0707ebf59b Remove unimplemented action (#9520)
- Duplication will have to wait until we move away from file-based templates
2025-04-16 10:59:51 +10:00
9ab82a187e fix(ci): dependabot config (#9514)
* fix(ci): dependabot config

* bump now updatable lingui/cli
2025-04-16 08:04:54 +10:00
5e7e258289 [Plugin] Plugin context (#9439)
* Pass more stuff to window

* Expose form functions to plugin context

* Breaking: Render plugin component in context tree

- Required due to createRoot function
- Adds necessary context providers

* Fix context

* Provide MantineThemeContext

* Bundle mantine/core

* Hack for useNavigate within ApiForm

- Errors out if called within plugin context
- Workaround to catch the error

* Update build cmd

* Define config for building "Library" mode

* Update package.json

* Add basic index file

* Factor out ApiEndpoints

* factor out ModelType

* Factor out role enums

* Further refactoring

* More refactoring

* Cleanup

* Expose apiUrl function

* Add instance data to plugin context type def

* Tweaks for loading plugin components

- LanguageContext must be on the inside

* Tweak StylishText

* Externalize notifications system

* Update lingui config

* Add functions for checking plugin interface version

* Extract package version at build time

* Enhance version checking

* Revert variable name change

* Public package

* Add README.md

* adjust packge name

* Adjust name to include org

* Update project files

* Add basic changelog info

* Refactoring to expose URL functions

* Refactor navigation functions

* Update package and README

* Improve navigateToLink function

* Refactor stylish text

- Move into ./lib
- Do not require user state

* Revert changes

- StylishText throws error in plugin
- Low priority, can work out later

* expose function to refresh page index

* Provide RemoteComponent with a method to reload itself

* Bump version

* Cleanup tests

* Prevent duplicate --emptyOutDir arg

* Tweak playwright tests

* Expose role and permission enums

* Fix imports

* Updated docs

* Fix spelling, typos, etc

* Include more package version information

* Expose more version context

* Cleanup

* Probably don't need hooks

* Fix links

* Docs updates

* Fix links
2025-04-16 00:30:34 +10:00
448d24de21 [UI] Serial Number Navigation (#9505)
* Add checkClose function to forms

- Allow custom check for whether form should be closed

* Add form to jump to serial number

* Tweak stock detail display

* Remove dead field

(might fix later, but it's hard with the current API)

* Add some icons

* Enhance extract_int functionality

* Add API endpoint for "next" and "previous" serials for a given stock item

* Add serial number navigation on stock item page

* Add playwright tests

* Bump API version

* Fix for serial number clipping

* Another tweak
2025-04-15 12:42:25 +10:00
8d44a0d330 New Crowdin translations by GitHub Action (#9489)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-15 11:39:30 +10:00
efce72b242 Bump vite from 6.2.5 to 6.2.6 in /src/frontend (#9496)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 6.2.5 to 6.2.6.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.2.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.2.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.2.6
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-12 08:04:28 +10:00
195cecb35b Schema: Batch of small fixes (#9492)
* Fix AllUnitList schema operation and serializer to match actual response

* Fix LicenseViewSerializer to match actual response

* Remove references to credits page (removed in #8811)

* Allow null commit_branch for detatched HEAD state

* Fix version formatting, add test, clean up parser

* Fix schema mapping and return type for VersionTextView

* Fix and test version off-by-one bug

* API version bump

* Merge version tests, enforce more formatting constraints for parsing
2025-04-11 14:22:01 +10:00
15be7ab988 [Refactor] Users and Groups (#9476)
* Cleanup UserDetail page

* Cleanup display

* Re-use UserTable

* Add 'users' permission role

* Check user roles in "admin center"

* Revert "Add 'users' permission role"

This reverts commit 35b047b2f9.

* Improve display logic

* Expose group rule-sets to API

* Prefetch rule_sets

* Add 'label' to RuleSetSerializer

* Add basic RuleSet table

* Add API endpoints for RuleSet model

* Edit group roles via table

* Refactor user permissions checks

- Remove duplicate function calls
- Refactor permission checks into new file

* Further refactoring

* Even more refactoring

* Fix user settings permission

* Add TransferList component

* Tweak GroupDrawer

* Tweak UserDrawer

* adjust user groups via API / UI

* Allow "users" detail on Group API

* Bump API version

* Enumeration of RuleSet name

* Update

* Add permission check

* Update src/frontend/src/pages/Index/Settings/AdminCenter/UserManagementPanel.tsx

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

* uncomment warning

* Extend enum usage

* More checks

* Bug fix

* Fix permission checks

* Additional testing for user roles endpoint

* Updated permission classes

- RolePermission with read-only fallback
- RolePermission with additional staff requirement

* Do not allow creation of new RuleSet objects

* Cleanup permission checks and unit tests

* Cleanup UI permission checks

* Updated class dostrings

* Cleanup

* Cleanup permission checks for UserTable

* Add playwright tests for "permission" checks

- Basic for now
- Can be extended in the future

* Tweak unit tests

* Adjust layout of warning / error messages

* Tweak group table logic

* Table cleanup

* Display roles associated with a particular group

* Cleanup

* Tweak user detail page

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2025-04-10 15:19:24 +10:00
4ea8f68819 Adjust layout of warning / error messages (#9484) 2025-04-10 06:49:00 +10:00
1cab0a1914 New Crowdin translations by GitHub Action (#9438)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-07 23:03:41 +10:00
3cd07c9da9 Cleanup tests (#9470) 2025-04-07 12:12:56 +10:00
ac181140c9 [UI] Row hover (#9465)
* Add red color

* Improve table cursor

- Show "pointer" (hand) icon when actions available
- Improve context menu
2025-04-06 12:31:28 +10:00
6b28bcca70 Bump vite from 6.2.4 to 6.2.5 in /src/frontend (#9457)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 6.2.4 to 6.2.5.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.2.5/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.2.5/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.2.5
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-05 15:55:32 +11:00
544a3c6263 Notification permissions (#9449)
* Updated type hints

* Fix tooltip bug

* Check user when sending notification

* Fix test

* Update unit test

* More unit test fixes

* Tweak playwright tests
2025-04-05 10:30:58 +11:00
6021035e3f User Setting To Search Notes (#9393)
* add search notes and tie user search settings to checkboxes in search drawer

* add user setting to optionally search the notes of objects

* add search filter test

* add PR link

* add limit parameter

* typo, meant to check part result

* resolve api_version.py conflict

* don't use search_whole and search_regex together

---------

Co-authored-by: Matthias Mair <code@mjmair.com>
2025-04-04 09:22:39 +11:00
b48ceb00f2 refactor(frontend): seperate Alerts into own component (#9442)
* refactor(frontend): seperate Alerts into own component

* refactor debug mode info

* add error code for debug mode and render help links in alerts

* add error message for background worker

* add error code for server restart required

* Add error code for missing email settings

* fix various typings

* add error code for missing migrations
2025-04-03 18:03:07 +11:00
c4f98cd6a1 Report cache fix (#9447)
* Adjust allowed CORS headers

* Disable caching in template preview
2025-04-03 15:11:36 +11:00
a18b18a3fd Serialize stock fix (#9441)
* Fix bug which hid the "serialize stock" button

* Add playwright tests

* Adjust check
2025-04-03 07:48:12 +11:00
15933a6b3a New Crowdin translations by GitHub Action (#9337)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-02 10:52:59 +11:00
ba703cf58a Template Editor Improvements (#9434)
* add unmount hook and context to report editor ui feature

* Fix tests

* Update pui_printing.spec.ts

* Update pui_printing.spec.ts

* try fix tests

* retrigger ci

* remove debug messages
2025-04-02 09:01:12 +11:00
6a964a4e2b Bump vite from 6.2.3 to 6.2.4 in /src/frontend (#9429)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 6.2.3 to 6.2.4.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.2.4/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.2.4/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-01 17:26:22 +11:00
fcc6709b3f Revert some playwright changes (#9419)
* Revert some playwright changes

- Use vite dev server all the time

* Simplify test
2025-03-31 20:12:26 +11:00
f7a4469590 Download params (#9413)
* Pass extra options through to data export plugins

* Add PartParameterExporter plugin

- Useful for including part parameter data in exporter

* Fix bug in InvenTreeTableHeader

* enable export for partparametertable

* Simplify tests

* Add typing hints
2025-03-31 19:45:59 +11:00
66d5180d8f [UI] Improve order parts wizard (#9389)
* [UI] Improve order parts wizard

- Enhance placeholder text
- Precalculate order quantity

* Tweak playwright tests

* Simplify tests
2025-03-31 18:19:21 +11:00
7f5a447769 [CI] Playwright improvements (#9395)
* Allow port 4173 (vite preview)

* Change 'base' attr based on vite command

* Allow api_host to be specified separately

* Harden API host functionality

* Adjust server selections

* Cleanup vite.config.ts

* Adjust playwright configuration

- Allow to run in "production" mode
- Builds the code first
- Runs only the backend web server
- Not suitable for coverage

* Tweak github actions

* Tweak QC file

* Reduce number of steps

* Tweak CI file

* Fix typo

* Ensure translation before build

* Fix hard-coded test

* Test tweaks

* uncomment

* Revert some changes

* Run with gunicorn, single worker

* Reduce log output in DEBUG mode

* Update deps

* Add global-setup func

* Fix for .gitignore file

* Cached auth state

* Tweak login func

* Updated tests

* Enable parallel workers again

* Simplify config

* Try with a single worker again

* Single retry mode

* Run auth setup first

- Prevent issues with parallel test doing login

* Improve test setup process

* Tweaks

* Bump to 3 workers

* Tweak playwright settings

* Revert change

* Revert change
2025-03-30 14:12:48 +11:00
99ec486b79 [Docker] Update node version (#9383)
* Update node version

* Install nvm

* Use n instead of nvm

* Use same approach in devcontainer

* nvm -> npm

* Split commands

* Fix typo

* Workaround : install bash

* Tweak playwright tests

* Bump number of retries

* Update deps

* Only one worker

* SEcurity fix

* Adjust
2025-03-27 01:25:58 +11:00
c4cf9ecd94 [UI] Allocation content (#9377)
* Refactor variable name

* Add part information when allocating serial numbers

- Easier identification of which part is being allocated

* Fix for part stock rendering
2025-03-26 16:03:16 +11:00
59f22a1627 Dayjs updates (#9388)
* Update Scan.tsx

* Tweak Scan.tsx
2025-03-26 14:27:55 +11:00
2bd26c0f49 use dayjs in datefield (#9380) 2025-03-26 10:35:26 +11:00
d8f5a56064 fix(backend): Bump maybe vulnerable esbuild (#9155)
* fix(backend): Bump vulnerable vanilla-extract

* bump deps futher

* remove @types/dompurify

* bump @lingui

* use more modern image
20.04 ships with node 18 as default, 24.04 with 20

* bump rest of image deps

* bump deps

* bump base deps

* bump resolution

* lower resolution

* fix resolution

* update lingui

* switch to build-in macro

* fix imports
2025-03-26 09:30:59 +11:00
a6e4742ce4 Show part revision in Build Details panel (#9373) 2025-03-25 10:57:16 +11:00
42dcc01f9d feat: Add email notification when a part is changed (#9275)
* Add function to star / unstar a part

* Also use with category

* Email notification when a part is changed
Fixes #7834

* enable disabling of recent checks

* Add error handler

* remove unneeded function
2025-03-25 09:21:11 +11:00