* Add 'existing_image' field to part API serializer
* Ensure that the specified directory exists
* Fix serializer
- Use CharField instead of FilePathField
- Custom validation
- Save part with existing image
* Add unit test for new feature
* Bump API version
* Add skeleton for builtin label printing plugin
* Force selection of plugin when printing labels
* Enhance LabelPrintingMixin class
- Add render_to_pdf method
- Add render_to_html method
* Enhance plugin mixin
- Add class attribute to select blocking or non-blocking printing
- Add render_to_png method
- Add default method for printing multiple labels
- Add method for offloding print job
* Simplify print_label background function
- All arguments now handled by specific plugin
* Simplify label printing API
- Simply pass data to the particular plugin
- Check result type
- Return result
* Updated sample plugin
* Working on client side code
* Cleanup
* Update sample plugin
* Add new model type
- LabelOutput model
- Stores generated label file to the database
- Makes available for download
* Update label printing plugin mixin
* Add background task to remove any old label outputs
* Open file if response contains filename
* Remove "default printer" option which does not specify a plugin
* Delete old labels after 5 days
* Remove debug statements
* Update API version
* Changed default behaviour to background printing
* Update label plugin mixin docs
* Provide default printer if none provided (legacy)
* Update unit test
* unit test updates
* Further fixes for unit tests
* unit test updates
* fix .gitignore and spelling issues
* Fix setting get not cached correctly
* Add model to settings key type
* Fix plugin setting slug url
* Fix typo
* Fix resetting of related setting field
* Improved model comment
* Pass "Part" instance to plugins when calling validate_serial_number
* Pass part instance through when validating IPN
* Improve custom part name validation
- Pass the Part instance through to the plugins
- Validation is performed at the model instance level
- Updates to sample plugin code
* Pass StockItem through when validating batch code
* Pass Part instance through when calling validate_serial_number
* Bug fix
* Update unit tests
* Unit test fixes
* Fixes for unit tests
* More unit test fixes
* More unit tests
* Furrther unit test fixes
* Simplify custom batch code validation
* Further improvements to unit tests
* Further unit test
* Add unit test for deleting part which has pricing information
* Test delete of part without pricing
* Deal with post_delete errors
1. Deleting a Part deleted related objects (e.g. InternalPriceBreak)
2. post_delete signal is called for InternalPriceBreak
3. Subsequent updates to Part / PartPricing throw error
* Add unit test for deleting a Part via the API
- Add InternalPriceBreak so the previous error condition is checked
* Fix for unit test
* More unit test fixes
(cherry picked from commit fa346257f5)
* Ensure unique part names for unit testing
* Further unit test fixes
* Added devcontainer configuration files
* Added launch.json and improved devcontainer
* Added tasks.json
* fix: lint
* fix: lint
* Applied suggestions from codereview
* Added more system dependencies and preserve history
* devcontainer updates
- Add extra environment variables for InvenTree config
- Move venv into dev directory (cleaner structure)
- Ensure base package requirements get installed
- Handle write-permission error for compiling translations
- Install test data inside dev directory
* Auto create plugin dir and added gh cli
* Refactored postCreateCommand into own file
* Applied suggestions from codereview
Co-authored-by: Oliver Walters <oliver.henry.walters@gmail.com>
* Simplify settings.py / config.py
- get_setting function has been streamlined
- move some functions into config.py
* Spelling fix: IGNORRED is IGNORED
* Ensure yaml is installed as part of docker image
- invoke path is still mucking us around
* Fix broken migration
* Copy media files from demo dataset when installing test data
* Cleanup settings.py
* Fix for configuration file traversal
* Line fix
* Update quickstart guide for docker
* Allow plugin file and plugin dir to be specified in configuration file
* Cleanup config template file
* Allow secret_key information to be provided in configuration file
* Adjust root paths for CI tests
* resolve paths
* Revert paths for CI step
* remove dead code
* Revert configuration variables to old names
- Prevent breaking changes
* Simplify secret key generation
* Fix default timeout for background worker process
* Revert change for customization options
* Simplification of development docker-compose file
- Rename .env file
- Remove requirement for variable interpolation within the docker-compose file itself
* Add debug flag to CI test
* Additional quick-start docs (for docker)
* docker-compose update
- Introspection did not work quite as expected
- Set project name inside docker-compose file
* Fixes for "setup_test" task
- Check if directory exists before first deleting it
- Parameterize the "path" variable
- Add option to ignore update step
* Add demo data dir to .gitignore
* Remove debug call
* Update CONTRIBUTING.md
* Simplified dockerfile
- Changed from alpine to python:slim
- Removed some database libs (because we *connect* to a db, not host it)
* - Add gettext as required package
- Only create inventree user as part of production build (leave admin access for dev build)
* Tweaks for tasks.py
* Fix user permissions (drop to inventree user)
* Drop to the 'inventree' user level as part of init.sh
- As we have mounted volumes at 'run time' we need to ensure that the inventree user has correct permissions!
- Ref: https://stackoverflow.com/questions/39397548/how-to-give-non-root-user-in-docker-container-access-to-a-volume-mounted-on-the
* Adjust user setup
- Only drop to non-root user as part of "production" build
- Mounted external volumes make it tricky when in the dev build
- Might want to revisit this later on
* More dockerfile changes
- reduce required system packages
-
* Add new docker github workflow
* Print some more debug
* GITHUB_BASE_REF
* Add gnupg to base requirements
* Improve debug output during testing
* Refactoring updates for label printing API
- Update weasyprint version to 55.0
- Generate labels as pdf files
- Provide filename to label printing plugin
- Additional unit testing
- Improve extraction of some hidden debug data during TESTING
- Fix a spelling mistake (notifaction -> notification)
* Working on github action
* More testing
* Add requirement for pdf2image
* Fix label printing plugin and update unit testing
* Add required packages for CI
* Move docker files to the top level directory
- This allows us to build the production image directly from soure
- Don't need to re-download the source code from github
- Note: The docker install guide will need to be updated!
* Fix for docker ci file
* Print GIT SHA
* Bake git information into the production image
* Add some exta docstrings to dockerfile
* Simplify version check script
* Extract git commit info
* Extract docker tag from check_version.py
* Newline
* More work on the docker workflow
* Dockerfile fixes
- Directory / path issues
* Dockerfile fixes
- Directory / path issues
* Ignore certain steps on a pull request
* Add poppler-utils to CI
* Consolidate version check into existing CI file
* Don't run docker workflow on pull request
* Pass docker image tag through to the build
Also check .j2k files
* Add supervisord.conf example file back in
* Remove --no-cache-dir option from pip install
- Previous migration needed some tweaking to get it to run... because.. why?
- It seems to pass when running manage.py migrate but fails when running manage.py test
- Stumped on this one