2
0
mirror of https://github.com/inventree/InvenTree.git synced 2026-04-29 14:24:25 +00:00
Commit Graph

16 Commits

Author SHA1 Message Date
Matthias Mair 10c3d101e8 Replace mklint with djlint (#4746)
* 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 74bec86675 Part page loading improvements (#3185)
* Lazy load the pricing bom table when the "pricing" tab is selected

* Update django-debug-toolbar configuration

* Major refactoring for the 'can_build' function

- Use a single annotated query to the db, rather than a for loop (which is what a caveman would use)
- Query performance is greatly improved
- Also refactors existing variant-part-stock subquery code, to make it re-usable

* Use minified JS and CSS where possible

* Render a 'preview' version of each part image

- Saves load time when the image is quite large
- Adds a data migration to render out the new variation

* Adds 'preview' version of company images

* Defer loading of javascript files

Note: some cannot be deferred - jquery in particular

* Crucial bugfix for user roles context

- Previously was *not* being calculated correctly
- A non-superuser role would most likely display pages incorrectly

* Prevent loading of "about" on every page

- Load dynamically when requested
- Takes ~400ms!
- Cuts out a lot of fat

* Match displayed image size to preview image size

* Utilize caching framework for accessing user "role" information

- Reduces number of DB queries required by rendering framework

* Remove redundant query elements

* Remove 'stock' field from PartBrief serializer

- A calculated field on a serializer is a *bad idea* when that calculation requires a DB hit

* Query improvements for StockItem serializer

- Remove calculated fields
- Fix annotations

* Bug fixes

* Remove JS load test

- Loading of JS files is now deferred, so the unit test does not work as it used to

* Fix broken template for "maintenance" page

* Remove thumbnail generation migrations

- Already performed manually as part of ''invoke migrate"
- Running as a migration causes unit test problems
- Not sensible to run this as a data-migration anyway

* tweak for build table
2022-06-17 21:26:28 +10:00
Matthias Mair 93b6934127 fix trailing 2022-05-20 13:20:55 +02:00
Oliver Walters 0797e9ebf0 Simplify the new template rendering
- No extra template code is required for any new page
- All loaded in base.html or page_base.html
- Oh, so clean!
2022-05-06 23:19:21 +10:00
Oliver 84115b3a8e Reduce width of thumbnail div 2021-12-01 08:07:09 +11:00
Oliver a2a436ea69 Column improvements 2021-12-01 08:05:30 +11:00
Oliver b34b3c6d85 Place part details below main part display tab 2021-11-30 19:38:48 +11:00
Matthias Mair 05a86c863f Update page_base.html 2021-11-01 01:38:21 +01:00
Matthias 338e85ff52 remove breadcrub div where no breadcrumb 2021-11-01 01:09:08 +01:00
matmair 6af866557d fixes missing wraping on iPdas and iPhones
Fixes #2210
2021-10-30 12:34:31 +00:00
Oliver c04118ed8a Driving the refactor tractor around the farm 2021-10-29 22:20:06 +11:00
Oliver b41d1aed12 Refactor admin button for:
- build order
- part detail
- stock item
- stock location
- company detail
- manufacturer-part
- purchase order
- sales order
2021-10-29 17:07:35 +11:00
Oliver ae2c3e8293 remove "panel-inventree" references 2021-10-28 08:31:36 +11:00
Oliver fe25ce8cd1 Refactor "manufacturer_part" view 2021-10-27 22:52:11 +11:00
Oliver 8fdaab233c Refactor build page 2021-10-27 22:44:33 +11:00
Oliver e178a2c370 Refactoring for "stock" pages 2021-10-27 21:50:18 +11:00