Website Product Document Download Counter
website_product_document_download_counter · OCA/website
Health
47/100
poor
-
Security25/25No findings
-
Activity12/25Last human commit 17 months ago
-
Required by5/250 modules depend on it
-
Maturity5/25In 1 Odoo series since 18.0
Heuristic over the facts below, not an audit · How it's computed
Required by
0
Modules depending on it
External deps
1 pip · 0 bin
Python packages / system binaries
License
LGPL-3
No conflicts with its dependencies
Folder size
0.1 MB
Module directory on disk
Code analysis
0 migration notes
1 model
3 views
1 HTTP endpoint
Description
This module allows you to track how many times product-related documents are downloaded from the Odoo website.
Main features:
- Automatic logging of the number of downloads for documents attached to products.
- View download statistics per product.
Dependencies
Code analysis
Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.
Views touched 3
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
product_document_form_inherit |
product.document.form.inherit.download_counter | product.document | form | Inherits website_sale.product_document_form |
product_document_kanban_inherit |
product.document.kanban.inherit.download_counter | product.document | kanban | Inherits website_sale.product_document_kanban |
product_documents_custom |
product_documents_custom | ir.ui.view | qweb | Inherits website_sale.product |
HTTP endpoints 1
| Route(s) | Handler | Auth | Type | Methods | Flags |
|---|---|---|---|---|---|
/shop/<model("product.template"):product_template>/document/<int:document_id>/count |
ProductDocumentDownloadCounterController.product_document_with_counter |
public | http | ALL | sudo website |
Models touched 1
New fields (2)
-
download_countIntegercopy=Falsedefault=0help='Number of times this document has been downloaded'readonly=True -
download_count_enabledBooleancopy=Falsehelp='Enable download counting for this document when published on website'
-
increment_download_count(self)Increment the download count for a specific product document. Caller must ensure appropriate permissions (e.g. via sudo()).