* use global pin for requests
* unify on yaml for workflo files
* format workflow files
* pin action versions
* fix pinned version
* use system venv
* switch args
* remove uv for now and add setting for pyyaml
* use requirements file
* also switch on docker flow
* generate hashes
* added hashes to reqs
* add hashes for CI too
* add hash checking
* require hashes everywhere possible
* require hashes where possible in docker
* Add recharts package
- Brings us in-line with mantine v7
* Add skeleton pricing page
* Fetch pricing data
* Rough implementation of variant pricing chart
- Needs better labels for tooltip and axis
* Cleanup
* More cleanup
* Improve rendering
* Add pricing overview
* Add pie chart for BOM pricing
- Needs extra work!
* Split components into separate files
* Backend: allow ordering parts by pricing
* Bump API version
* Update VariantPricingPanel:
- Table drives data selection now
* Refactor BomPricingPanel
- Table drives the data
* Allow BomItemList to be sorted by pricing too
* Sort bom table
* Make record index available to render function
* Refactor BomPricingPanel
- Better rendering of pie chart
* Update pricing overview panel
* Further updates
- Expose "pricing_updated" column to API endpoints
- Allow ordering by "pricing_updated" column
* Update API endpoint for PurchaseOrderLineItem
* Implement PurchaseOrderHistory panel
* Cleanup PurchaseHistoryPanel
* Enhance API for SupplierPriceBreak
* Implement SupplierPricingPanel
* Fix for getDetailUrl
- Take base URL into account also!
* Further fixes for getDetailUrl
* Fix number form field
* Implement SupplierPriceBreakTable
* Tweaks for StockItemTable
* Ensure frontend is translated when compiling static files
* Fixes for BomPricingPanel
* Simplify price rendering for bom table
* Update BomItem serializer
- Add pricing_min_total
- Add pricing_max_total
- Fix existing 1+N query issue
* Use values provided by API
* Fix BomItem serializer lookup
* Refactor pricing charts
* Fix for VariantPricingPanel
* Remove unused imports
* Implement SalePriceBreak table
- Refactor the InternalPriceBreak table to be generic
* Allow price breaks to be ordered by 'price'
* Display alert for no available data
* Update backend API filters
* Allow ordering by customer
* Implement SaleHistoryPanel
* Allow user to select pie or bar chart for BOM pricing detail
* Remove extra padding
* add coverage to PUI
* fix testing command
* always do all steps
* fix test assumptions
* add test for serving and logging into pui from django / cui tech stack
* fix up coverage
* fix intentation
* remove paralell flags
* remove coverage finish step
* remove flag
* change names
* add full clickdown test
* more tests
* more tests
* sprinkle in some timeouts
* try using admin
* disable page 1 tests for now
* remove additional tests for now
* only build sourcemaps if coverage is enabled
* fix sourcemap assumption
* add more tests
* fix test
* Update package.json
* move tests to seperate file
* rename test files
* move defaults to seperate file
* centralise user creds
* lower migration level
* re-add page 1
* rename and split tests
* split out problematic test
* Add thumbnail building step
* remove unneded steps
* fix filename
* add more logging
* add sourounding table
* add missing tabs
* wait instead of click
* fix test
* split tests out more
* disable test for stock
* tes part sub-pages
* split tests more
* add company tests
* more sales testing
* split parts testing
* Add test for settings + admin center
* append more apps
* set source
* use labels to force full CI suit
* always check for label
* use newer syntax
* remove unneeded carryforward flag
* improve action names
* remove unused upload steps
* enable discovery of locate test
* remove wrong module
* delete all ( :-) )lines for upload
* remove init for now
* add carryfoward back in again
* disable flaky test
* always run finsh step
* deactivate machine test for now
* specify refs explicitly
* add docker exception
* use xml for coverage info
* dummy fix
* remove dummy fix
* dummy change
* always export
* change path to ensure basepath is submitted
* add more paths
* reverst isort change
* remove unused html export
* remove paralell
* add plain InvenTree too
* Update pyproject.toml
* reset paths
* Update qc_checks.yaml
* Update qc_checks.yaml
* fix coverage runner setting
* fix coverage tool path
* use move, not copy
* ignore tmp
* reset isort settings
* use relative files for reporting
* Revert "use relative files for reporting"
This reverts commit 1f662bfb97.
* only run after at least 1 succeeds
* add TODO
* remove coverage subdir run
* also force migrations
* add coverage to migrations
* fix conditional for migration force check
* always upload coverage
* disable flaky test
* fix tests
* wait for migrations
* re-add function arg?
* adjust coverage targets
* add no-cov for fixes of flaky tests
* remove dummy
* revert to "old" upload method"
* append more apps
* set source
* use labels to force full CI suit
* always check for label
* use newer syntax
* remove unneeded carryforward flag
* improve action names
* remove unused upload steps
* enable discovery of locate test
* remove wrong module
* delete all ( :-) )lines for upload
* remove init for now
* add carryfoward back in again
* disable flaky test
* always run finsh step
* deactivate machine test for now
* specify refs explicitly
* add docker exception
* remove paralell
* Update qc_checks.yaml
* Update qc_checks.yaml
* fix coverage tool path
* use move, not copy
* ignore tmp
* only run after at least 1 succeeds
* add TODO
* remove coverage subdir run
* also force migrations
* add coverage to migrations
* fix conditional for migration force check
* always upload coverage
* fix tests
* wait for migrations
* re-add function arg?
* adjust coverage targets
* add no-cov for fixes of flaky tests
* add migration checks to codecov
* remove docker-sqlite file
- Do not want to encourage use of sqlite
* Add Caddyfile
* Add default site URL to .env
- Matches Caddyfile
* Cleanup / simplify .env file
* Remove dev nginx conf file
* Further cleanup of .env file
* Update docker-compose.yml
- Use caddy image instead of nginx as proxy
* Set max body size
* gunicorn: enable external logging
* Update file structure
* Cleanup docker-compose file
* Update docker/docker-compose.yml
Co-authored-by: Matthias Mair <code@mjmair.com>
* Update docker/Caddyfile
Co-authored-by: Matthias Mair <code@mjmair.com>
* Fix for postgresql packages
- Need postgresql13-client to be installed, it contains pg_dump
- Without this, backup / restore *does not work*
* Create static_i18n dir if it does not exist
* Reduce output from collectstatic
* Revert gunicorn logging
- Want to see the logs in docker
* Fix trailing slash
Ref: https://github.com/inventree/InvenTree/pull/6551#issuecomment-1962423765
* tasks.py - pass 'nouv' option through
* Update package requirements:
- Allow installation of rapidfuzz without building
* Install uv as part of docker image
* Add environment variable to control downstream URL
* Do not use uv package manager by default
- Currently does not work "correctly" - ignores installed packages
- Requires further work to run reliably
* Fix docker-compose file
- Do not build locally
* Cleanup gunicorn file
- Remove unused lien
* Cleanup docker-compose.yml
- Simpler volume management
* Update Caddyfile
Add newline
* Update requirements.txt
Add newline
* Update tasks.py
Add missing blank line
* Simplify Caddyfile
* Adds option for customizing web port
* cleanup docker-compose.yml
- Better mapping of caddy data
- Cleaner volume setup
* Add django version template
- Ensure all docs links point to the current django version we are using
* docs: cleanup intro.md
* Cleanup serving_files.md
* Cleanup config.md
* docker install docs updates
* Enable code block copying
* Fix include file
* Fix link
* Update docker install docs
* Update docker.md
* Add info about demo dataset
* Tweak heading
* Update docs link checks
* Fix workflow
* Another fix
* More ignore pattearns
---------
Co-authored-by: Matthias Mair <code@mjmair.com>
* move CUI JS files to CUI url section
* add flag to seperate CUI code and tests
* re-enable tests
* move urls back to backend patterns
* swap switch logic
* fix merge
* returning PUI paths if CUI not enabled
* revert test changes
* fix plugin settings url
* URL is not dependant on UI generation
* small fixes
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
---------
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
* test UV performance
* second dummy change
* fix CI
* set version - uv is already proving to be great
* dummy bump
* bump to newer uv
* use uv in more places
* revert uv
* add flag to disable UV
* fix vevn for CI
* bump uv version
* bump to uv-016
* bump
* bump
* switch to uv
* Add basic table for stock item test results
* Improve custom data formatter callback
* Custom data formatter for returned results
* Update YesNoButton functionality
- Add PassFailButton with custom text
* Enhancements for stock item test result table
- Render all data
* Add placeholder row actions
* Fix table link
* Add option to filter parttesttemplate table by "inherited"
* Navigate through to parent part
* Update PartTestTemplate model
- Save 'key' value to database
- Update whenever model is saved
- Custom data migration
* Custom migration step in tasks.py
- Add custom management command
- Wraps migration step in maintenance mode
* Improve uniqueness validation for PartTestTemplate
* Add 'template' field to StockItemTestResult
- Links to a PartTestTemplate instance
- Add migrations to link existing PartTestTemplates
* Add "results" count to PartTestTemplate API
- Include in rendered tables
* Add 'results' column to test result table
- Allow filtering too
* Update serializer for StockItemTestResult
- Include template information
- Update CUI and PUI tables
* Control template_detail field with query params
* Update ref in api_version.py
* Update data migration
- Ensure new template is created for top level assembly
* Fix admin integration
* Update StockItemTestResult table
- Remove 'test' field
- Make 'template' field non-nullable
- Previous data migrations should have accounted for this
* Implement "legacy" API support
- Create test result by providing test name
- Lookup existing template
* PUI: Cleanup table
* Update tasks.py
- Exclude temporary settings when exporting data
* Fix unique validation check
* Remove duplicate code
* CUI: Fix data rendering
* More refactoring of PUI table
* More fixes for PUI table
* Get row expansion working (kinda)
* Improve rendering of subtable
* More PUI updates:
- Edit existing results
- Add new results
* allow delete of test result
* Fix typo
* Updates for admin integration
* Unit tests for stock migrations
* Added migration test for PartTestTemplate
* Fix for AttachmentTable
- Rebuild actions when permissions are recalculated
* Update test fixtures
* Add ModelType information
* Fix TableState
* Fix dataFormatter type def
* Improve table rendering
* Correctly filter "edit" and "delete" buttons
* Loosen requirements for dataFormatter
* Fixtures for report tests
* Better API filtering for StocokItemTestResult list
- Add Filter class
- Add option for filtering against legacy "name" data
* Cleanup API filter
* Fix unit tests
* Further unit test fixes
* Include test results for installed stock items
* Improve rendering of test result table
* Fix filtering for getTestResults
* More unit test fixes
* Fix more unit tests
* FIx part unit test
* More fixes
* More unit test fixes
* Rebuild stock item trees when merging
* Helper function for adding a test result to a stock item
* Set init fix
* Code cleanup
* Cleanup unused variables
* Add docs and more unit tests
* Update build unit test
* Add basic task for generating apidocs
* Fix SPECTACTULAR_SETTINGS
- Some provided options were not correct
* Update .gitignore
* Fix for duplicated API path
- `/api/plugins/activate` routed to PluginActivate view
- Must be associated with a specific plugin ID
* By default, fail if warnings are raised
* Use GenericAPIView for GetAuthToken
* Use GenericAPIView for RolesDetail endpoint
* Refactor more endpoints to use GenericApiView
* More API cleanup
* Add extra type hints for exposed methods
* Update RoleDetails endpoint
- Specify serializer
- Use RetrieveAPI class type
* More type hints
* Export API docs as part of CI
* add more api views docs
* even more docs
* extend tests to api-version
* simplify serializer
* and more docs
* fix serializer
* added more API docs
* clean diff
* Added APISearch base
* do not assume you know the user
he might be anonymously creating the schema ;-)
* set empty serializer where no input is needed
* Use dummy model for schema generation
* fix OpenAPI docs section
* Update .github/workflows/qc_checks.yaml
Co-authored-by: Matthias Mair <code@mjmair.com>
* REmove duplicate commands
* Ignore warnings in CI
---------
Co-authored-by: Matthias Mair <code@mjmair.com>
* Prevent tracing in worker thread
* Tweak logic
* Further improvements
* Adds invoke command to launch gunicorn server
* Update docstring
* Add explicit check for migrations or data import
* Update tracing.py
Allow tracing in worker thread
* Ensure .ts files are generated
- "yarn run compile" before "yarn run dev"
- ensures that .ts locale files are all generated
* Implement "Add Part Category" button
* Create new stock location
* Rename customActionGroups to tableActions
* Rename customFilters to tableFilters
* Edit category from table
* Edit stock location from table
* Add some placeholder buttons
* More placeholders
* Move locales definition into separate file
- Cleanup settings.py a bit
* Update docstring
* Expose 'default_locale' to info API endpoint
* Validate settings.LANGUAGE_CODE
* Fix bug in BuildDetail page
* Use selected language when making API queries
* Translate more strings
* Tweak variable name
* Update locale config
* Remove duplicate code
* Remove compiled messages.ts translation files
* Fixes for LanguageContext.tsx
* Update messages.d.ts for sr locale
* Ensure compiled files are served by django runserver
* Amend changes to STATICFILES_DIRS
* Cleanup prerender.py
* Refetch status codes when locale is changed
* Fix log msg
* Clear out old static files
* Add API endpoint for background task overview
* Cleanup other pending heartbeat tasks
* Adds API endpoint for queued tasks
* Adds API endpoint for scheduled tasks
* Add API endpoint for failed tasks
* Update API version info
* Add table for displaying pending tasks
* Add failed tasks table
* Use accordion
* Annotate extra data to scheduled tasks serializer
* Extend API functionality
* Update tasks.py
- Allow skipping of static file step in "invoke update"
- Allows for quicker updates in dev mode
* Display task result error for failed tasks
* Allow delete of failed tasks
* Remove old debug message
* Adds ability to delete pending tasks
* Update table columns
* Fix unused imports
* Prevent multiple heartbeat functions from being added to the queue at startup
* Add unit tests for API
* Use '--natural-foreign' when exporting dataset
- Uses "natural keys" (model names) instead of ContentType ID
* Update task options
- Change 'include_plugins' to 'exclude_plugins'
- Change 'delete_temp' to 'retain_temp'
* Split data import into two-step process
- First, import auth models
- Second, import data
- Ensures auth.user and auth.group are in place before users.owner is loaded
* Adjust temp file name
* Touch apps.py
- Just so the proper CI checks run
* Updates to data import/export steps
- Allow import/export of users.owner model
- Allow export of API tokens (optional, default=False)
* Exclude plugin configuration data by default
* Add option to exclude socialaccount information from exported data
* Update docker image - base python version
- Also, build docker image on PR if any docker-related files have changed
* Update setuptools
* Update base level packages for docker image
* Reduce version
* Include docker workflow in filter
* Revert to python 3.10
* Remove call to upgrade setuptools
* Try newer version of setuptools
* Remove reliance on "minimal"
* Fix package URL
* Whoops. Fix typo
* Create new APIToken model
- Has custom 'name' field
- Has custom expiry date
* Add data migration to port across any existing user tokens
* Adds 'revoked' field - tokens can be manually revoked
* Update API token - allow multiple tokens per user
* Custom token auth handler
- Correctly handles revoked tokens
- Correctly handles expired tokens
* Update AuthRequiredMiddleware
- Check for token active status
* Token API endpoint improvements
- Can return tokens with custom names
- Return more information on the token too
* Consolidate migrations
* When requesting a token, overwrite inactive token for authenticated user
- An authenticated user must receive a token
- Unauthenticated users cannot do this
* Fix
* Use token name for frontend
* Force token expiry, and generate default expiry date
* Force generation of a new token when requested
* Reduce data exposed on token API endpoint
* Display redacted token in admin site
* Log when new token is created for user
* Add default value for token
- Allows raw token to be viewed in the admin interface when created
- After created, no longer visible
- Also provides ability to generate token with static prefix
* Fixes for admin interface
- Prevent user and expiry from being edited after creation
* Implement unit tests for token functionality
* Fix content exclude for import/export
* Fix typo
* Further tweaks
- Prevent editing of "name" field after creation
- Add isoformat date suffix to token
* Longer token requires longer database field!
* Fix other API tokens
* Remove 'delete' method from token API endpoint
* Bump API version
There shouldn't be any blank lines after the function docstring.
Remove the blank lines to fix this issue.
Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
- Until the new frontend is fully ready to be shipped, adding this option only serves to confuse users (and break the install process potentially)
- Remove this option entirely from the invoke script
- Update documentation accordingly
* added language toggle component
* added language and theme controls onto start page
* moved host selection out of auth
* optimized rendering
* make server option less obvious
* changed EditButton save symbol
* longer welcome text
* removed ColorToggle color schema
* reduced code
* disabled host selection when options are changing
* fix type error
* use GH reporter
* fix tests?
* compile frontend
* fix assertation
* revert unneeded change
* split up into more components
* separated functions / use cases for LanguageToggle more
* moved color toggle to profile
* moved language out of main menu into profile
* remapped settings link
* Add SPA views for react #2789
* split up frontend urls
* Add settings for frontend url loading
* add new UI scaffold
* remove tracking insert
* add platform app
* ensure static indexes work too
* add lingui
* add lingui config
* add mgmt tasks
* add base locales
* settings for frontend dev
* fix typo
* update deps
* add pre-commit
* add eslint
* add testing scaffold
* fix paths
* remove error - tests trip correctly
* merge workflow
* cleanup samples
* use name inline with other tests
* Add real worl frontend tests
* setup env
* tun migrations first
* optimize setup time
* setup demo dataset
* optimize run setup
* add test for class ui
* rename
* fix typo
* and another typo
* do install
* run migrations first
* fix name
* cleanup
* use other credentials
* use other credentials
* fix qc
* move envs to qc
* remove create_site
* reduce testing env
* fix test
* fix test call
* allaccess user
* add ui plattform check
* add better check
* remove unneeded env
* enable debug
* reduce wait time
* also build frontend on static
* add sort plugin
* fix order
* run pre-commit fixes
* add node min version
* Docker container (#129)
* Fix allocation check for completing build order (#5199)
- Allocation check only applies to untracked line items
* docker dev
Install required node packages to docker development image
* add import order settings
* cleanout built ui
* remove default arg from build
* remove eslint
* optimize svg
* add build step for plattform UI
* fix install command
* use alpine commands
* do not use cache when creating image
* Added release pipeline
* trigger: ci
* Fix ci
* Fix ci
* Fix ci
* fix: workflow
* fix: workflow
* fix: doubble zipping
* fix: doubble zipping
* fix: doubble zipping
* fix: doubble zipping
* fix: doubble zipping
* Added frontend-download helper to tasks.py
* revert unrelated change
* Add frontend step to update task
* add frontend stuff to version info
* small change to trigger ci
* keep terminal output clean
* return found versions
* fix suggested command
* revert small change
* move to multiline
* add flag to stop frontend compile
* make node building optional on static
* add node trans to transalte task
* ammend commands to use new flag
* remove unneeded flag
* add warning
* add yarn bypass
* docstrings
* check for docker env
---------
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
Co-authored-by: wolflu05 <76838159+wolflu05@users.noreply.github.com>
* Add SPA views for react #2789
* split up frontend urls
* Add settings for frontend url loading
* add new UI scaffold
* remove tracking insert
* add platform app
* ensure static indexes work too
* add lingui
* add lingui config
* add mgmt tasks
* add base locales
* settings for frontend dev
* fix typo
* update deps
* add pre-commit
* add eslint
* add testing scaffold
* fix paths
* remove error - tests trip correctly
* merge workflow
* cleanup samples
* use name inline with other tests
* Add real worl frontend tests
* setup env
* tun migrations first
* optimize setup time
* setup demo dataset
* optimize run setup
* add test for class ui
* rename
* fix typo
* and another typo
* do install
* run migrations first
* fix name
* cleanup
* use other credentials
* use other credentials
* fix qc
* move envs to qc
* remove create_site
* reduce testing env
* fix test
* fix test call
* allaccess user
* add ui plattform check
* add better check
* remove unneeded env
* enable debug
* reduce wait time
* also build frontend on static
* add sort plugin
* fix order
* run pre-commit fixes
* add node min version
* Docker container (#129)
* Fix allocation check for completing build order (#5199)
- Allocation check only applies to untracked line items
* docker dev
Install required node packages to docker development image
* add import order settings
* cleanout built ui
* remove default arg from build
* remove eslint
* optimize svg
* add build step for plattform UI
* fix install command
* use alpine commands
* do not use cache when creating image
---------
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
* Disable migration testing
- Compare how long the unit tests take
* Change file
- To get unit tests to run
* Fix format
* Consolidate tasks.py
- Remove coverage task
- Add --coverage flag to test task
* Fix typo
* Run migration unit tests if migration files are updated
* Fix
* Touch migration file
- Should cause migration unit tests to be run
* Force migration checks for docker build
* Prevent default report creation in unit tests
- Should save some time
* Add simple profiling for plugin loading
- Display time taken to load each plugin
* Fix to invoke test
* Disable get_git_log (for testing)
* Disable get_git_path in CI
- Might remove this entirely?
- For now, bypass for unit testing
* Add debug for unit registry
- Display time taken to load registry
* Don't full-reload unit registry
* Adjust migration test workflow
- env var updates
- change paths-filter output
* Fix for migration_test.yaml
- Actually need to set the output
* env fix
* db name
* Prevent sleep if in test mode
* Reduce sleep time on wait_for_db
* fix cli call to get a fully running invoke
* use relativ import
This is importend when imported from outside
* Add version command
* Add more information to version command
* make print easier to understand
* [FR] Update to OpenAPI from CoreAPI
Fixes#3226
* factor request function out
* add schema export task
* add api-docs
* add action to check if diff occured
* also wait for docstyle
* use full command
* add envs for inventree
* update inventree before running
* use relative path
* remove schema action
* remove tags to fit 3.0 parsers
* fix url base name for reloads
* revert change in plugin resolver
* remove unused tags
* add rapidoc too
* declare api regex
* fix as suggested by @martonmiklos in
https://github.com/inventree/InvenTree/pull/4178#discussion_r1167279443
* set inventree logo
* remove Rapidoc
* Adds ReturnOrder and ReturnOrderAttachment models
* Adds new 'role' specific for return orders
* Refactor total_price into a mixin
- Required for PurchaseOrder and SalesOrder
- May not be required for ReturnOrder (remains to be seen)
* Adds API endpoints for ReturnOrder
- Add list endpoint
- Add detail endpoint
- Adds required serializer models
* Adds basic "index" page for Return Order model
* Update API version
* Update navbar text
* Add db migration for new "role"
* Add ContactList and ContactDetail API endpoints
* Adds template and JS code for manipulation of contacts
- Display a table
- Create / edit / delete
* Splits order.js into multiple files
- Javascript files was becoming extremely large
- Hard to debug and find code
- Split into purchase_order / return_order / sales_order
* Fix role name (change 'returns' to 'return_order')
- Similar to existing roles for purchase_order and sales_order
* Adds detail page for ReturnOrder
* URL cleanup
- Use <int:pk> instead of complex regex
* More URL cleanup
* Add "return orders" list to company detail page
* Break JS status codes into new javascript file
- Always difficult to track down where these are rendered
- Enough to warrant their own file now
* Add ability to edit return order from detail page
* Database migrations
- Add new ReturnOrder modeles
- Add new 'contact' field to external orders
* Adds "contact" to ReturnOrder
- Implement check to ensure that the selected "contact" matches the selected "company"
* Adjust filters to limit contact options
* Fix typo
* Expose 'contact' field for PurchaseOrder model
* Render contact information
* Add "contact" for SalesOrder
* Adds setting to enable / disable return order functionality
- Simply hides the navigation elements
- API is not disabled
* Support filtering ReturnOrder by 'status'
- Refactors existing filter into the OrderFilter class
* js linting
* More JS linting
* Adds ReturnOrderReport model
* Add serializer for the ReturnOrderReport model
- A little bit of refactoring along the way
* Admin integration for new report model
* Refactoring for report.api
- Adds generic mixins for filtering queryset (based on updates to label.api)
- Reduces repeated code a *lot*
* Exposes API endpoints for ReturnOrderReport
* Adds default example report file for ReturnOrder
- Requires some more work :)
* Refactor report printing javascript code
- Replace all existing functions with 'printReports'
* Improvements for default StockItem test report template
- Fix bug in template
- Handle potential errors in template tags
- Add more helpers to report tags
- Improve test result rendering
* Reduce logging verbosity from weasyprint
* Refactor javascript for label printing
- Consolidate into a single function
- Similar to refactor of report functions
* Add report print button to return order page
* Record user reference when creating via API
* Refactor order serializers
- Move common code into AbstractOrderSerializer class
* Adds extra line item model for the return order
- Adds serializer and API endpoints as appropriate
* Render extra line table for return order
- Refactor existing functions into a single generic function
- Reduces repeated JS code a lot
* Add ability to create a new extra line item
* Adds button for creating a new lien item
* JS linting
* Update test
* Typo fix
(cherry picked from commit 28ac2be35b)
* Enable search for return order
* Don't do pricing (yet) for returnorder extra line table
- Fixes an uncaught error
* Error catching for api.js
* Updates for order models:
- Add 'target_date' field to abstract Order model
- Add IN_PROGRESS status code for return order
- Refactor 'overdue' and 'outstanding' API queries
- Refactor OVERDUE_FILTER on order models
- Refactor is_overdue on order models
- More table filters for return order model
* JS cleanup
* Create ReturnOrderLineItem model
- New type of status label
- Add TotalPriceMixin to ReturnOrder model
* Adds an API serializer for the ReturnOrderLineItem model
* Add API endpoints for ReturnOrderLineItem model
- Including some refactoring along the way
* javascript: refactor loadTableFilters function
- Pass enforced query through to the filters
- Call Object.assign() to construct a superset query
- Removes a lot of code duplication
* Refactor hard-coded URLS to use {% url %} lookup
- Forces error if the URL is wrong
- If we ever change the URL, will still work
* Implement creation of new return order line items
* Adds 'part_detail' annotation to ReturnOrderLineItem serializer
- Required for rendering part information
* javascript: refactor method for creating a group of buttons in a table
* javascript: refactor common buttons with helper functions
* Allow edit and delete of return order line items
* Add form option to automatically reload a table on success
- Pass table name to options.refreshTable
* JS linting
* Add common function for createExtraLineItem
* Refactor loading of attachment tables
- Setup drag-and-drop as part of core function
* CI fixes
* Refactoring out some more common API endpoint code
* Update migrations
* Fix permission typo
* Refactor for unit testing code
* Add unit tests for Contact model
* Tests for returnorder list API
* Annotate 'line_items' to ReturnOrder serializer
* Driving the refactor tractor
* More unit tests for the ReturnOrder API endpoints
* Refactor "print orders" button for various order tables
- Move into "setupFilterList" code (generic)
* add generic 'label printing' button to table actions buttons
* Refactor build output table
* Refactoring icon generation for js
* Refactoring for Part API
* Fix database model type for 'received_date'
* Add API endpoint to "issue" a ReturnOrder
* Improvements for stock tracking table
- Add new status codes
- Add rendering for SalesOrder
- Add rendering for ReturnOrder
- Fix status badges
* Adds functionality to receive line items against a return order
* Add endpoints for completing and cancelling orders
* Add option to allow / prevent editing of ReturnOrder after completed
* js linting
* Wrap "add extra line" button in setting check
* Updates to order/admin.py
* Remove inline admin for returnorderline model
* Updates to pass CI
* Serializer fix
* order template fixes
* Unit test fix
* Fixes for ReturnOrder.receive_line_item
* Unit testing for receiving line items against an RMA
* Improve example report for return order
* Extend unit tests for reporting
* Cleanup here and there
* Unit testing for order views
* Clear "sales_order" field when returning against ReturnOrder
* Add 'location' to deltas when returning from customer
* Bug fix for unit test
* Add integration for django-slowtest
* Sample test improvement
- Reduces test from 0.7s to 0.2s
* Run CI tests with slowreport
* Fix requirements file
* Fix test command
* Fix bulk_create in unit tests
* Remove bulk_create entirely
* remove another bulk_create call
* Reduce long test from ~1000 seconds to ~1 second