Commit Graph

14185 Commits

Author SHA1 Message Date
Matthias Mair
f5c2591fd4
Add 'Tag' management ()
* 'Tag' management
Fixes 

* Add for ManufacturerPart, SupplierPart

* Add tags for StockLocation, StockItem

* fix serializer definition

* add migrations

* update pre-commit

* bump dependencies

* revert updates

* set version for bugbear

* remove bugbear

* readd bugbear remove isort

* and remove bugbear again

* remove bugbear

* make tag fields not required

* add ruleset

* Merge migrations

* fix migrations

* add unittest for detail

* test tag add

* order api

* reduce database access

* add tag modification test

* use overriden serializer to ensuer the manager is always available

* fix typo

* fix serializer

* increae query thershold by 1

* move tag serializer

* fix migrations

* content_types are changing between tests - removing them

* remove unneeded fixture

* Add basic docs

* bump API version

* add api access to the docs

* add python code

* Add tags to search and filters for all models
2023-05-04 09:02:48 +10:00
Oliver
baaa147fd0
Ignore variant stock when performing stocktake ()
* Ignore variant stock when performing stocktake

- Including variant stock can cause duplicate counts of items
- Causes valuation numbers to be incorrect

* Fix unit tests

* Further unit test fixes
2023-05-02 23:57:40 +10:00
Oliver
6da108e031
Bug fix for label printing ()
* Bug fix for label printing

- Do not use "debug mode" when printing using a plugin
- Fixes https://github.com/inventree/InvenTree/issues/4745

* Fix inverted logic
2023-05-02 23:09:41 +10:00
Oliver
3ff217d229
Fix for sales order tables ()
- Allow line items to be allocated after partial shipment
- Fixes https://github.com/inventree/InvenTree/issues/4734
2023-05-02 22:55:53 +10:00
Oliver
be735e4568
Update FUNDING.yml ()
Fix typo
2023-05-02 22:28:32 +10:00
Oliver
52321af962
Add github link to funding.yml () 2023-05-02 22:25:26 +10:00
Oliver
61d613ff34
Base URL configuration options ()
* Improve construct_absolute_url method

- Look for hard-coded site URL if provided
- Otherwise look for specified site URL
- Otherwise look at the provided request object

* Refactor existing code which used base URL setting

* Update docs

* Validate that a provided base URL is valid
2023-05-02 22:14:57 +10:00
Matthias Mair
10c3d101e8
Replace mklint with djlint ()
* remove markuplint

* remove dedicated html step - will be done by pre-commit

* add djlint for django template linting

* Fix T003: Endblock should have name

* Fix H013: Img tag should have an alt attribute

* Fix H014: Found extra blank lines

* Fix T003: Endblock should have name

* Fix H013: Img tag should have an alt attribute

* small fixes

* Fix T001: Variables should be wrapped in a single whitespace

* Fix T003: Endblock should have name

* small fixes

* fix form method

* add entry to contributing

* fix template changes

* another fix

* use current version
2023-05-02 20:03:52 +10:00
Oliver
09fabff551
Fix filters for part variant table ()
- Slight adjustment to HTML tags
- Buttons were not displaying correctly inline
2023-05-02 14:47:02 +10:00
Oliver
149c4df231
Remove restriction on manual stock item installation ()
- Allow stock item to be manually inside an item which is iteself installed in an item
- No practical reason for this limitation to exist
2023-05-02 14:46:54 +10:00
Oliver
d9864fce69
New Crowdin updates ()
* updated translation base

* Fix: New translations django.po from Crowdin

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-05-02 14:46:46 +10:00
Oliver
20d8c2b4e6
Include error type when an error occurs updating exchange rates ()
- Will allow us to further introspect errors received by sentry
2023-05-02 09:34:03 +10:00
Lavissa
6bd95f3b15
Link changes and in-table clipboards ()
* Add clipboard to tables and external link changes

* Clipboard icon added to tables for screens >1200px wide. Enables
  copying of SKU/MPN/IPN from table cells where these otherwise are
  hyperlinks

* External links now open in new tabs with noreferrer

* Move external links into separate template

* All statically rendered external links have been moved out to a new
  template.
2023-05-02 08:13:50 +10:00
Miklós Márton
0b8feb2c4a
Display proper printing target name in the label printing modal dialog ()
Fix 
2023-05-02 07:59:54 +10:00
Matthias Mair
e5e1a09b45
CI cleanup ()
* merge doc checks into main QC checks

* rename

* well both APIs are closed now so this would be useless

* make header more concise

* add check if server code changed - make run conditional

* reformat
2023-05-02 07:58:57 +10:00
Matthias Mair
21e0679cb9
[FR] Remove Gitpod integration ()
Fixes 
2023-05-02 07:39:38 +10:00
Matthias Mair
5e99e54bbc
Update README.md with digitalocean info ()
* Update README.md with digitalocean info

* update link for DO in docs
2023-05-01 19:42:14 +02:00
Oliver
be856c3682
Scan in items fix ()
* Clean up comments

* Bug fix

- Pass options.modal through if provided when creating new barcodeDialog

* Fix for scanning from item context into location
2023-05-01 23:50:20 +10:00
Oliver
ad4acef459
Plugin metadata docs ()
* Add page for model metadata

* Add intro section

* Add info on direct access

* more updates
2023-05-01 23:33:44 +10:00
Matthias Mair
08c4aa4998
Make sure plugins are always on a new line ()
* "Install Plugin" via GUI fails to add plugin to plugins.txt correctly for first plugin
Fixes 

* remove old change as it was not the root issue

* make sure plugins are always written on a new line
2023-05-01 23:26:23 +10:00
Oliver
c5ba632463
Use coveralls github action () 2023-05-01 22:13:35 +10:00
Matthias Mair
abee2cee88
Code style improvements ()
* fix list comps

* mopre comp fixes

* reduce computing cost on any() calls

* add bugbear

* check for clean imports

* only allow limited relative imports

* fix notification method lookup

* fix notification method assigement

* rewrite assigment

* fix upstream changes to new style

* fix upstream change to new coding style
2023-04-28 20:49:53 +10:00
Matthias Mair
660a4f8e39
bump deps ()
* bump deps

* add markuplint setting to disable character-reference
2023-04-28 20:12:13 +10:00
Oliver
f6831558a4
Fix export of order data ()
* Adds extra unit test for exporting sales orders

- Exporting sales orders to .xls currently throws exception

* Fix 'total_price' field when exporting orders

* Fix for unit test
2023-04-28 06:54:50 +10:00
Oliver
f6021c4749
sentry.io improvements ()
* Write function to catch sentry.io events before sending

- Will let us ignore certain types of errors which we are not interested in

* Cleanup

* Include release info

* Allow sentry reporting in debug mode

* Consolidate DRF sentry code into InvenTree/sentry.py

* Add more error types to ignore

* update docs
2023-04-28 06:54:31 +10:00
miggland
8d28fc06be
Improve text when no sub-categories found ()
Avoids confusion when looking for parts
2023-04-27 22:57:16 +10:00
Oliver
e2c3b28640
Company docs updates ()
* Refactor order documentation into simpler consolidated pages

* Reorganize images

* Add documentation on "Contact"

* Add imgae
2023-04-27 22:27:21 +10:00
Oliver
bb860227c8
New Crowdin updates ()
* updated translation base

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-04-27 14:43:54 +10:00
Oliver
82e98dffb8
Add custom template loader class ()
- Specifically to ignore caching for generated reports and labels
- Fixes https://github.com/inventree/InvenTree/issues/4611
2023-04-27 13:28:00 +10:00
Matthias Mair
3975a85742
Check if doc links are broken ()
* add check for links

* fix style

* call silently

* add dep

* add path

* ignore readme as it contains necesarry broken links

* fix syntax

* check recursevly

* run in sync

* use linkcheckmd instaead

* use sync

* add requests

* revert fix to check if checks still work

* fix lookup

* fix old link

* run check verbose

* run async

* remove recurse

* introduce error for test

* fix link
2023-04-27 07:24:26 +10:00
Oliver
608f96c723
Add python example for deleting a part ()
* Add python example for deleting a part

* Ignore PRs which are just docs from release notes
2023-04-26 23:18:03 +10:00
Oliver
5fcab2aec3
Specify order currency ()
* Add 'order_currency' to the various external order models

- By default will use the currency specified for the supplier (or customer)
- Can be specified per order, also

* Display order currency on order pgae

* Add 'order_currency' field

* Enable "blank" currency option (to default to the currency specified by the referenced company

* Fix default currency code when adding line items

* Remove 'total_price_currency' serializer field

- Now replaced with 'order_currency' for greater flexibility

* Bump api_version.py

* Update default order report templates

* Updated docs

* More docs updaes

* Adjust unit tests

* Use 'order_currency' in order tables

* Update purchase order api unit tests
2023-04-26 17:35:15 +10:00
Oliver
36d17c082b
Homepage hide inactive ()
* Add user setting for including "inactive" parts in results displayed on homepage

* Adds user setting to hide inactive parts on the homepage

Closes https://github.com/inventree/InvenTree/issues/4688
2023-04-26 15:45:14 +10:00
Oliver
f382d7ef21
Disable httpstat.us tests ()
- Uptime of the eternal service is not great
- For now, disable tests
- Potentially reintroduce these at some point in the future
2023-04-26 14:27:13 +10:00
Oliver
eaa518852c
Mark "supplier" field as required on PurchaseOrder serializer ()
- Fixes https://github.com/inventree/InvenTree/issues/4687
2023-04-26 12:35:55 +10:00
Lavissa
011b5915e1
Fix missed translation of overallocation string ()
* Fix missed translation of overallocation string

* Added missing translation prefix on string for Overallocation REJECT choice

* Fix missing translation in part admin panel

* Added missing translation prefix on string for "variant of" column in
  admin panel
2023-04-25 22:41:31 +10:00
Matthias Mair
d7bdcd95a6
Fix plugin meta lookup ()
* fix website lookup

* use the raw data on error
2023-04-24 08:28:50 +10:00
Oliver
5411cf0878
Update README.md ()
Add documentation badge
2023-04-23 00:20:41 +10:00
Jakob Haufe
7537fd1278
Fix sorting by location in stock item table ()
Currently, when sorting the stock item table by location, it gets sorted
by location id.

This changes the sorting criterion to pathstring.
2023-04-23 00:12:03 +10:00
Oliver
8df207d8e1
Extend ReportMixin class to support labels ()
* Extend ReportMixin context to shim label templates also

* Update docs
2023-04-22 23:46:43 +10:00
Oliver
50cbaff76d
Fixes for docs building () 2023-04-22 23:35:25 +10:00
Oliver
2ffd2354eb
Documentation integration ()
* Add documentation under docs/ directory

* Add CI workflow for mkdocs configuration checking

* Add documentation issue template

* update pip-tools?

* Update .gitignore files

* Fix .gitignore rules

* Improve release notes page

* remove references to old repo
2023-04-22 22:40:29 +10:00
Oliver
20f01e8741
New Crowdin updates ()
* updated translation base

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-04-22 09:11:33 +10:00
Oliver
ad545bad24
Update to report plugin API ()
explicitly add the model instance when allowing plugins to add context data
2023-04-21 15:28:31 +10:00
Oliver
9198b52398
Add ordering and search to ProjectCodeList API endpoint () 2023-04-20 22:51:47 +10:00
Oliver
0f2fd2f678
New Crowdin updates ()
* updated translation base

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

* Fix: New translations django.po from Crowdin

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-04-20 22:49:31 +10:00
Oliver
91189fbb77
Fix for "focus" field in forms ()
- Reimplements ability to auto-focus fields when launching modal forms
- Can specify with the "focus" option
- Otherwise, will focus on the first available field
2023-04-20 22:40:08 +10:00
Oliver
7bc4de6a92
Fix persist buttons ()
Fixes "persist form" buttons for the following models:

- Part
- PartCategory
- StockItem
- StockLocation

Closes https://github.com/inventree/InvenTree/issues/4491
2023-04-20 22:12:43 +10:00
Oliver
c64ff9d569
Refactor table buttons for printing ()
- Make them to look like the other printing buttons
2023-04-20 22:12:33 +10:00
Oliver
68d1682000
Report Plugins ()
* Add plugin mixin class for extending reports

* Expose report context to the plugin system

* Add an example mixin for adding context data to a report

* Add the 'request' object to the plugin code
2023-04-20 14:21:22 +10:00