mirror of
https://github.com/inventree/inventree-docs.git
synced 2025-06-13 10:45:32 +00:00
Add info on buidl report
This commit is contained in:
@ -48,6 +48,24 @@ For example, rendering the name of a part (which is available in the particular
|
||||
!!! info "Variables"
|
||||
Templates will have different variables available to them depending on the report type. Read the detail information on each report type for further information.
|
||||
|
||||
### Context Data
|
||||
|
||||
Each report has access to a number of context variables by default. The following context variables are provided to every report template:
|
||||
|
||||
| Variable | Description |
|
||||
| --- | --- |
|
||||
| date | Current date, represented as a Python datetime.date object |
|
||||
| datetime | Current datetime, represented as a Python datetime object |
|
||||
| default_page_size | InvenTree default page size variable |
|
||||
| report_name | Name of the report template |
|
||||
| report_description | Description of the report template |
|
||||
| report_revision | Revision of the report template |
|
||||
| request | Django request object |
|
||||
| user | User who made the request to render the template |
|
||||
|
||||
!!! info "Specific Report Context"
|
||||
Specific report types may have additional context variables
|
||||
|
||||
### Conditional Rendering
|
||||
|
||||
The django template system allows for conditional rendering, providing conditional flow statements such as `{% raw %}{% if <condition> %}{% endraw %}`, `{% raw %}{% for <item> in <list> %}{% endraw %}`, etc.
|
||||
@ -182,7 +200,7 @@ InvenTree supports the following reporting functionality:
|
||||
|
||||
### Build Report
|
||||
|
||||
Build Report: TODO
|
||||
[Build Order](../build): Format a build order report
|
||||
|
||||
### Purchase Order
|
||||
[Purchase Order report](../order): Order line items
|
||||
|
Reference in New Issue
Block a user