oca / brand Goto Github PK
View Code? Open in Web Editor NEWManage brands for products and companies
License: GNU Affero General Public License v3.0
Manage brands for products and companies
License: GNU Affero General Public License v3.0
If you use Brand, you cannot close and validate Pos.
A new module is needed to solve this
product_brand
When the pos_sale module is installed, an error is thrown when opening a product form view.
RPC_ERROR
Odoo Server Error
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/api.py", line 983, in get
cache_value = field_cache[record._ids[0]]
KeyError: 8
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/fields.py", line 1136, in get
value = env.cache.get(record, self)
File "/home/odoo/src/odoo/odoo/api.py", line 990, in get
raise CacheMiss(record, field)
odoo.exceptions.CacheMiss: 'product.template(8,).sales_count'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/api.py", line 983, in get
cache_value = field_cache[record._ids[0]]
KeyError: 8
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/fields.py", line 1136, in get
value = env.cache.get(record, self)
File "/home/odoo/src/odoo/odoo/api.py", line 990, in get
raise CacheMiss(record, field)
odoo.exceptions.CacheMiss: 'product.product(8,).sales_count'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/http.py", line 1549, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "/home/odoo/src/odoo/odoo/service/model.py", line 134, in retrying
result = func()
File "/home/odoo/src/odoo/odoo/http.py", line 1578, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "/home/odoo/src/odoo/odoo/http.py", line 1775, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 140, in _dispatch
result = endpoint(**request.params)
File "/home/odoo/src/odoo/odoo/http.py", line 673, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "/home/odoo/src/odoo/addons/web/controllers/dataset.py", line 42, in call_kw
return self._call_kw(model, method, args, kwargs)
File "/home/odoo/src/odoo/addons/web/controllers/dataset.py", line 33, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "/home/odoo/src/odoo/odoo/api.py", line 461, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "/home/odoo/src/odoo/odoo/api.py", line 448, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "/home/odoo/src/odoo/odoo/models.py", line 2991, in read
return self._read_format(fnames=fields, load=load)
File "/home/odoo/src/odoo/odoo/models.py", line 3130, in _read_format
vals[name] = convert(record[name], record, use_name_get)
File "/home/odoo/src/odoo/odoo/models.py", line 5840, in getitem
return self._fields[key].get(self, type(self))
File "/home/odoo/src/odoo/odoo/fields.py", line 1185, in get
self.compute_value(recs)
File "/home/odoo/src/odoo/odoo/fields.py", line 1344, in compute_value
records._compute_field_value(self)
File "/home/odoo/src/odoo/addons/mail/models/mail_thread.py", line 403, in _compute_field_value
return super()._compute_field_value(field)
File "/home/odoo/src/odoo/odoo/models.py", line 4185, in _compute_field_value
getattr(self, field.compute)()
File "/home/odoo/src/odoo/addons/sale/models/product_template.py", line 61, in _compute_sales_count
product.sales_count = float_round(sum([p.sales_count for p in product.with_context(active_test=False).product_variant_ids]), precision_rounding=product.uom_id.rounding)
File "/home/odoo/src/odoo/addons/sale/models/product_template.py", line 61, in
product.sales_count = float_round(sum([p.sales_count for p in product.with_context(active_test=False).product_variant_ids]), precision_rounding=product.uom_id.rounding)
File "/home/odoo/src/odoo/odoo/fields.py", line 1185, in get
self.compute_value(recs)
File "/home/odoo/src/odoo/odoo/fields.py", line 1344, in compute_value
records._compute_field_value(self)
File "/home/odoo/src/odoo/addons/mail/models/mail_thread.py", line 403, in _compute_field_value
return super()._compute_field_value(field)
File "/home/odoo/src/odoo/odoo/models.py", line 4185, in _compute_field_value
getattr(self, field.compute)()
File "/home/odoo/src/odoo/addons/sale/models/product_product.py", line 28, in _compute_sales_count
for group in self.env['sale.report']._read_group(domain, ['product_id', 'product_uom_qty'], ['product_id']):
File "/home/odoo/src/odoo/odoo/models.py", line 2176, in _read_group
return self.read_group(domain, fields, groupby, offset, limit, orderby, lazy)
File "/home/odoo/src/enterprise/sale_enterprise/report/sale_report.py", line 53, in read_group
res = super(SaleReport, self).read_group(domain, fields, groupby, offset=offset, limit=limit, orderby=orderby, lazy=lazy)
File "/home/odoo/src/odoo/odoo/models.py", line 2216, in read_group
result = self._read_group_raw(domain, fields, groupby, offset=offset, limit=limit, orderby=orderby, lazy=lazy)
File "/home/odoo/src/odoo/odoo/models.py", line 2347, in _read_group_raw
self._cr.execute(query, where_clause_params)
File "/home/odoo/src/odoo/odoo/sql_db.py", line 315, in execute
res = self._obj.execute(query, params)
psycopg2.errors.SyntaxError: each UNION query must have the same number of columns
LINE 108: -MIN(l.id) AS id,
^
In the server log:
2022-11-17 14:11:13,631 4 ERROR alpiek-oisterwijk-pauw-16-16-0-test-6392796 odoo.sql_db: bad query:
SELECT min("sale_report".id) AS id, count("sale_report".id) AS "product_id_count" , sum("sale_report"."product_uom_qty") AS "product_uom_qty","sale_report"."product_id" as "product_id"
FROM (
SELECT
MIN(l.id) AS id,
l.product_id AS product_id,
t.uom_id AS product_uom,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.product_uom_qty / u.factor * u2.factor) ELSE 0 END AS product_uom_qty,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.qty_delivered / u.factor * u2.factor) ELSE 0 END AS qty_delivered,
CASE WHEN l.product_id IS NOT NULL THEN SUM((l.product_uom_qty - l.qty_delivered) / u.factor * u2.factor) ELSE 0 END AS qty_to_deliver,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.qty_invoiced / u.factor * u2.factor) ELSE 0 END AS qty_invoiced,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.qty_to_invoice / u.factor * u2.factor) ELSE 0 END AS qty_to_invoice,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.price_total
* CASE COALESCE(s.currency_rate, 0) WHEN 0 THEN 1.0 ELSE s.currency_rate END
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
) ELSE 0
END AS price_total,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.price_subtotal
* CASE COALESCE(s.currency_rate, 0) WHEN 0 THEN 1.0 ELSE s.currency_rate END
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
) ELSE 0
END AS price_subtotal,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.untaxed_amount_to_invoice
* CASE COALESCE(s.currency_rate, 0) WHEN 0 THEN 1.0 ELSE s.currency_rate END
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
) ELSE 0
END AS untaxed_amount_to_invoice,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.untaxed_amount_invoiced
* CASE COALESCE(s.currency_rate, 0) WHEN 0 THEN 1.0 ELSE s.currency_rate END
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
) ELSE 0
END AS untaxed_amount_invoiced,
COUNT(*) AS nbr,
s.name AS name,
s.date_order AS date,
s.state AS state,
s.partner_id AS partner_id,
s.user_id AS user_id,
s.company_id AS company_id,
s.campaign_id AS campaign_id,
s.medium_id AS medium_id,
s.source_id AS source_id,
t.categ_id AS categ_id,
s.pricelist_id AS pricelist_id,
s.analytic_account_id AS analytic_account_id,
s.team_id AS team_id,
p.product_tmpl_id,
partner.country_id AS country_id,
partner.industry_id AS industry_id,
partner.commercial_partner_id AS commercial_partner_id,
CASE WHEN l.product_id IS NOT NULL THEN SUM(p.weight * l.product_uom_qty / u.factor * u2.factor) ELSE 0 END AS weight,
CASE WHEN l.product_id IS NOT NULL THEN SUM(p.volume * l.product_uom_qty / u.factor * u2.factor) ELSE 0 END AS volume,
l.discount AS discount,
CASE WHEN l.product_id IS NOT NULL THEN SUM(l.price_unit * l.product_uom_qty * l.discount / 100.0
* CASE COALESCE(s.currency_rate, 0) WHEN 0 THEN 1.0 ELSE s.currency_rate END
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
) ELSE 0
END AS discount_amount,
s.id AS order_id,
s.invoice_status AS invoice_status,
s.warehouse_id AS warehouse_id,
t.product_brand_id as product_brand_id
FROM
sale_order_line l
LEFT JOIN sale_order s ON s.id=l.order_id
JOIN res_partner partner ON s.partner_id = partner.id
LEFT JOIN product_product p ON l.product_id=p.id
LEFT JOIN product_template t ON p.product_tmpl_id=t.id
LEFT JOIN uom_uom u ON u.id=l.product_uom
LEFT JOIN uom_uom u2 ON u2.id=t.uom_id
JOIN (VALUES (1, 1.0, 2)) AS currency_table(company_id, rate, precision) ON currency_table.company_id = s.company_id
WHERE
l.display_type IS NULL
GROUP BY
l.product_id,
l.order_id,
t.uom_id,
t.categ_id,
s.name,
s.date_order,
s.partner_id,
s.user_id,
s.state,
s.company_id,
s.campaign_id,
s.medium_id,
s.source_id,
s.pricelist_id,
s.analytic_account_id,
s.team_id,
p.product_tmpl_id,
partner.country_id,
partner.industry_id,
partner.commercial_partner_id,
l.discount,
s.id,
currency_table.rate,
t.product_brand_id,
s.invoice_status,
s.warehouse_id
UNION ALL (
SELECT
-MIN(l.id) AS id,
l.product_id AS product_id,
t.uom_id AS product_uom,
SUM(l.qty) AS product_uom_qty,
SUM(l.qty) AS qty_delivered,
0 AS qty_to_deliver,
CASE WHEN pos.state = 'invoiced' THEN SUM(l.qty) ELSE 0 END AS qty_invoiced,
CASE WHEN pos.state != 'invoiced' THEN SUM(l.qty) ELSE 0 END AS qty_to_invoice,
SUM(l.price_subtotal_incl)
* MIN(CASE COALESCE(pos.currency_rate, 0) WHEN 0 THEN 1.0 ELSE pos.currency_rate END)
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
AS price_total,
SUM(l.price_subtotal)
* MIN(CASE COALESCE(pos.currency_rate, 0) WHEN 0 THEN 1.0 ELSE pos.currency_rate END)
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
AS price_subtotal,
(CASE WHEN pos.state != 'invoiced' THEN SUM(l.price_subtotal) ELSE 0 END)
* MIN(CASE COALESCE(pos.currency_rate, 0) WHEN 0 THEN 1.0 ELSE pos.currency_rate END)
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
AS amount_to_invoice,
(CASE WHEN pos.state = 'invoiced' THEN SUM(l.price_subtotal) ELSE 0 END)
* MIN(CASE COALESCE(pos.currency_rate, 0) WHEN 0 THEN 1.0 ELSE pos.currency_rate END)
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END
AS amount_invoiced,
count(*) AS nbr,
pos.name AS name,
pos.date_order AS date,
CASE WHEN pos.state = 'draft' THEN 'pos_draft' WHEN pos.state = 'done' THEN 'pos_done' else pos.state END AS state,
pos.partner_id AS partner_id,
pos.user_id AS user_id,
pos.company_id AS company_id,
NULL AS campaign_id,
NULL AS medium_id,
NULL AS source_id,
t.categ_id AS categ_id,
pos.pricelist_id AS pricelist_id,
NULL AS analytic_account_id,
pos.crm_team_id AS team_id,
p.product_tmpl_id,
partner.country_id AS country_id,
partner.industry_id AS industry_id,
partner.commercial_partner_id AS commercial_partner_id,
(SUM(p.weight) * l.qty / u.factor) AS weight,
(SUM(p.volume) * l.qty / u.factor) AS volume,
l.discount AS discount,
SUM((l.price_unit * l.discount * l.qty / 100.0
* CASE COALESCE(pos.currency_rate, 0) WHEN 0 THEN 1.0 ELSE pos.currency_rate END
* CASE COALESCE(currency_table.rate, 0) WHEN 0 THEN 1.0 ELSE currency_table.rate END))
AS discount_amount,
NULL AS order_id,
NULL AS invoice_status,
NULL AS warehouse_id
FROM
pos_order_line l
JOIN pos_order pos ON l.order_id = pos.id
LEFT JOIN res_partner partner ON (pos.partner_id=partner.id OR pos.partner_id = NULL)
LEFT JOIN product_product p ON l.product_id=p.id
LEFT JOIN product_template t ON p.product_tmpl_id=t.id
LEFT JOIN uom_uom u ON u.id=t.uom_id
LEFT JOIN pos_session session ON session.id = pos.session_id
LEFT JOIN pos_config config ON config.id = session.config_id
JOIN (VALUES (1, 1.0, 2)) AS currency_table(company_id, rate, precision) ON currency_table.company_id = pos.company_id
WHERE
l.sale_order_line_id IS NULL
GROUP BY
l.order_id,
l.product_id,
l.price_unit,
l.discount,
l.qty,
t.uom_id,
t.categ_id,
pos.name,
pos.date_order,
pos.partner_id,
pos.user_id,
pos.state,
pos.company_id,
pos.pricelist_id,
p.product_tmpl_id,
partner.country_id,
partner.industry_id,
partner.commercial_partner_id,
u.factor,
pos.crm_team_id,
currency_table.rate
)
) AS "sale_report"
WHERE ((("sale_report"."state" in ('sale', 'done', 'paid', 'pos_done', 'invoiced')) AND ("sale_report"."product_id" in (8))) AND ("sale_report"."date" >= '2021-11-17 00:00:00')) AND ("sale_report"."company_id" IS NULL OR ("sale_report"."company_id" in (1)))
GROUP BY "sale_report"."product_id"
ORDER BY "product_id"
ERROR: each UNION query must have the same number of columns
LINE 108: -MIN(l.id) AS id,
Affected versions:
Odoo 16
Steps to reproduce the behavior:
Expected behavior
A clear and concise description of what you expected to happen.
Additional context
Add any other context about the problem here. (e.g. OS, Python version, ...)
t.product_brand_id as product_brand_id has been added to the sale.report from the sale module, but not from the pos module.
With B2B marketplaces emerging (ankorstore.com, faire.com, orderchamp.com, etc.) there is often more than one supplier for products and brands โ sometimes, the brand itself can be one of them. Looking for brand suppliers from brand form is useful for retailers.
There is no need to record suppliers in brand, but recording brands in suppliers forms.
Odoo 13.0-20210518 (Community Edition)
Brand modules are installed from git on the 13.0 release.
Running Odoo in Docker.
I configured 2 brands. I can select a brand on the Quotation, ... however when I print I see no branded info. Just the general company information that's configured. Same for when I go to preview I see the normal company info and not the branded info.
Nothing else is really configured. This was a fresh install. Can someone confirm this (doesn't) work (anymore)?
Thanks!
brand_external_report_layout
in manifest.py of brand_external_report_layout assets is defnied
"assets": { "web.report_assets_common": [ "/brand_external_report_layout/" "static/src/legacy/scss/asset_styles_brand_report.scss" ] },
but this file doesn't exist. While previewing report error about missing file is shown
15.0, 16.0
Steps to reproduce the behavior:
I proposed this PR #16 that simplify the customization of the external layout.
With this module, all custom layouts will display brand information out of the box.
This module make the customization in external_layout_standard useless.
Like this is the only feature that in partner_brand module I propose to remove it (or find a new ideas for its usage) if the #16 is accepted.
cc: @sbidoul , @max3903 , @osi-scampbell
brand_external_report_layout
brand.document.layout
is defining company_details
(and should define is_company_details_empty
also, as declared in #167 ) so it's not possible to use the same brand for different companiescompany
Qweb variable is replaced by a res.brand
object in reports, so every module inheriting company to add information in reports is conflicting (for example, l10n_ca
from Odoo with account_fiscal_country_id
and l10n_ca_pst
fields)16.0:
Steps to reproduce the behavior:
brand_external_report_layout
installed and demo datacompany details
by default)Brand use level
= optional
Expected behavior
I think only "style" fields should be overridden by brands.
Additional context
I'll propose a PR that keeps the original company object and temporarily modify it with data from brand then go back to original after the report is generated.
This are the instructions of module sale_brand
1 Go to Sales > Quotations
2 Select or create a quotation
3 Enter the information and the brand
4 Print the PDF report. It includes the information of the brand.
5 Confirm the quotation and generate an invoice
6 Print the PDF report. It includes the information of the brand.
Point 3 enter the information of the brand. There is no field to enter brand information. Impossible to use
https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-14.0
Missing module? Check https://github.com/OCA/maintainer-tools/wiki/%5BFAQ%5D-Missing-modules-in-migration-issue-list
Hi,
As a first step when we moved the brand modules to this new repository, I proposed #5 to have a separate model for brands and not use the res.partner
.
As this refactoring is about to join the 12.0 and some questions are still outstanding and it's time to make a decision on these aspects before moving forward.
The main topics, I remember, we raised were:
1- What do you think about this proposals?
2- Do you approve this changes?
3- Should we made this changes ASAP or we can keep them in the roadmap?
Kind regards.
cc/ @max3903 , @rafaelbn , @gva-acsone
product_brand
Error while importing module 'product_brand'.
Impossible de charger le module product_brand รฉchec : fichier /tmp/tmp2dgvn5q8/product_brand/security/ir.model.access.csv :
Aucun enregistrement trouvรฉ pour id externe 'model_product_brand' dans le champ 'Model'
Aucun enregistrement trouvรฉ pour id externe 'model_product_brand' dans le champ 'Model'
Valeur requise manquante pour le champ 'Model' (model_id)
Valeur requise manquante pour le champ 'Model' (model_id)
Affected versions: 17.0
Steps to reproduce the behavior:
Expected behavior
Additional context
OS: Arch Linux
Python: 3.10
Odoo 15.0 completely updated.
Due to this line:
https://github.com/OCA/brand/blob/15.0/sale_brand/models/res_brand.py#L34
An error is raised on create a brand because module website is not installled.
This is the log:
Traceback (most recent call last):
File "/opt/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 237, in _dispatch
result = request.dispatch()
File "/opt/odoo/src/odoo/odoo/http.py", line 687, in dispatch
result = self._call_function(**self.params)
File "/opt/odoo/src/odoo/odoo/http.py", line 359, in _call_function
return checked_call(self.db, *args, **kwargs)
File "/opt/odoo/src/odoo/odoo/service/model.py", line 94, in wrapper
return f(dbname, *args, **kwargs)
File "/opt/odoo/src/odoo/odoo/http.py", line 348, in checked_call
result = self.endpoint(*a, **kw)
File "/opt/odoo/src/odoo/odoo/http.py", line 916, in call
return self.method(*args, **kw)
File "/opt/odoo/src/odoo/odoo/http.py", line 535, in response_wrap
response = f(*args, **kw)
File "/opt/odoo/src/odoo/addons/web/controllers/main.py", line 1342, in call_kw
return self._call_kw(model, method, args, kwargs)
File "/opt/odoo/src/odoo/addons/web/controllers/main.py", line 1334, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "/opt/odoo/src/odoo/odoo/api.py", line 464, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "/opt/odoo/src/odoo/odoo/api.py", line 451, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "/opt/odoo/src/odoo/odoo/models.py", line 6480, in onchange
record._onchange_eval(name, field_onchange[name], result)
File "/opt/odoo/src/odoo/odoo/models.py", line 6213, in _onchange_eval
method_res = method(self)
File "/opt/odoo/src/other-addons/sale_brand/models/res_brand.py", line 34, in _compute_terms_url
text = brand.website + brand.terms_page
Exception
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/opt/odoo/src/odoo/odoo/http.py", line 643, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/opt/odoo/src/odoo/odoo/http.py", line 301, in _handle_exception
raise exception.with_traceback(None) from new_cause
TypeError: unsupported operand type(s) for +: 'bool' and 'str'
Hi, tested this module, seems all is OK, except a fact that if I go here : "Go to Sales > Configuration > Products > Product Brands.
I dont have any Button to click on to "create new Brand....
Steps to reproduce the behavior:
1.Go to Sales App/Configuration/Products/Product brand
2. see the empty list, do not have button to create new brand
ODOO V16, EE, on premise, hosted on Ubuntu, almost empty with no user data.
Hi
This is a resume
Read: OCA/partner-contact#765
I'm new in this repository but not in working with brands. I create this issue as introduction of what's is done around brands:
Scenario 1: My company or companies (res.company) sell diferent company's brands (my brands). Example: Danone, Dadone's companies have brands like Danone, Danette, Actimel, Danonino, Activia, Oikos, ....
12
12
12
Note: In Spanish Localization we are using Brand (commercial Brand) since OpenERP 5: https://github.com/OCA/l10n-spain/blame/12.0/l10n_es_partner/README.rst#L30 :
Scenario 2: My company or companies product of different brands. Example: Lidl. Lidl sale product of diferent brands: Nestle, Cocacola, Danone, Heinz, ....
Product Brand: relate / add brand to products (module product_brand) 12.0 / 11.0 / 10.0 / 9.0 / 8.0 / 7.0 / 6.1
Website Product Brand: Product Brand Filtering in Website (module website_sale_product_brand) 11.0 / 9.0 / 8.0
Product Brand Sale Report: Adds product brand to the sale report. (product_brand_sale_report) 9
Product Brand in Invoices Analysis: Adds product brand to the invoices analysis report. Module: product_brand_invoice_report 9
Hello,
I would like to know if this module is very different from operating-unit because in my opinion they do the same and it is duplicating.
Edit: @pedrobaeza
When cofiguring the document layout, when you configure the Cahange Document Template to brand_external_layout, if you save it you have set the new layout, but when you go to change Document Template and Download PDF preview it shoyws you the standard layout and when you go back to configuration, you have the entry vaule for layout external_layout_standard.
If you set the brand_external_layout on your brand setup, if you go to Customers - Inovices and you try to create an invoice, if you print the invoice you get the following error:
RPC_ERROR
Arbitrary Uncaught Python Exception
500
Internal Server Error
The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.
The above server error caused the following client error:
RPC_ERROR: Arbitrary Uncaught Python Exception
RPCError@https://test.elogia-16.rapsodoo.com/web/assets/52050-c1ca215/web.assets_backend.min.js:989:274
makeErrorFromResponse@https://test.elogia-16.rapsodoo.com/web/assets/52050-c1ca215/web.assets_backend.min.js:993:163
download._download/</xhr.onload/decoder.onload@https://test.elogia-16.rapsodoo.com/web/assets/52050-c1ca215/web.assets_backend.min.js:981:7
The name of the module that has a bug.
A clear and concise description of what the bug is.
Affected versions:
Steps to reproduce the behavior:
Expected behavior
Get the new layout configured with the new logo and don't get an error message
Additional context
Add any other context about the problem here. (e.g. OS, Python version, ...)
Hi,
If I go to Settings > General Settings and select the brand use level "Required" I can't buy in my e-shop.
When we add a product to the cart this show:
Error: Brand is required
Thanks
Hello,
Does not work in Odoo 13, clean installation with OCA website and ecommerce modules.
If I select "brand_external_layout" on "Settings>Documents" the server return 500 after payment on website store.
In the backend when I generating the sales order, it don't generate the pdf:
Odoo Server Error
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/tools/cache.py", line 85, in lookup
r = d[key]
File "/home/usuario/odoo/odoo/tools/func.py", line 69, in wrapper
return func(self, *args, **kwargs)
File "/home/usuario/odoo/odoo/tools/lru.py", line 44, in getitem
a = self.d[obj].me
KeyError: ('ir.qweb', <function IrQWeb.compile at 0x7fa435ddd160>, 'web.external_layout_standard', ('en_US', False, None, None, None, None))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/tools/cache.py", line 85, in lookup
r = d[key]
File "/home/usuario/odoo/odoo/tools/func.py", line 69, in wrapper
return func(self, *args, **kwargs)
File "/home/usuario/odoo/odoo/tools/lru.py", line 44, in getitem
a = self.d[obj].me
KeyError: ('ir.ui.view', <function View._read_template at 0x7fa436393280>, frozenset({1, 2, 3, 4, 6, 7, 10, 14, 17, 18, 19, 21, 23, 27, 28, 29, 32, 33, 35, 36, 37, 38, 39, 40, 41, 44, 47, 50, 51, 54, 55, 56, 58, 59, 60, 62, 63, 64, 65, 66, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 81}), 213, ('en_US', False, None, None, None, None))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 669, in apply_inheritance_specs
source = apply_inheritance_specs(source, specs_tree,
File "/home/usuario/odoo/odoo/tools/template_inheritance.py", line 229, in apply_inheritance_specs
raise ValueError(
ValueError: El elemento '' no puede ser localizado en la vista padre
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 359, in get_template
document = options.get('load', self.load)(template, options)
File "/home/usuario/odoo/odoo/addons/base/models/ir_qweb.py", line 121, in load
template = env['ir.ui.view'].read_template(name)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 1071, in read_template
return self._read_template(self.get_view_id(xml_id))
File "", line 2, in _read_template
File "/home/usuario/odoo/odoo/tools/cache.py", line 90, in lookup
value = d[key] = self.method(*args, **kwargs)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 1063, in _read_template
arch = self.browse(view_id).read_combined(['arch'])['arch']
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 745, in read_combined
arch = self.apply_view_inheritance(arch_tree, root.id, self.model)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 694, in apply_view_inheritance
source = self.apply_inheritance_specs(source, specs_tree, view_id)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 673, in apply_inheritance_specs
self.raise_view_error(str(e), inherit_id)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 614, in raise_view_error
raise ValueError(message)
ValueError: El elemento '' no puede ser localizado en la vista padre
Error context:
View brand_external_layout
[view_id: 2340, xml_id: brand_external_report_layout.brand_external_layout, model: n/a, parent_id: 213]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/http.py", line 624, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/home/usuario/odoo/odoo/http.py", line 310, in _handle_exception
raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
File "/home/usuario/odoo/odoo/tools/pycompat.py", line 14, in reraise
raise value
File "/home/usuario/odoo/odoo/http.py", line 669, in dispatch
result = self._call_function(**self.params)
File "/home/usuario/odoo/odoo/http.py", line 350, in _call_function
return checked_call(self.db, *args, **kwargs)
File "/home/usuario/odoo/odoo/service/model.py", line 94, in wrapper
return f(dbname, *args, **kwargs)
File "/home/usuario/odoo/odoo/http.py", line 339, in checked_call
result = self.endpoint(*a, **kw)
File "/home/usuario/odoo/odoo/http.py", line 915, in call
return self.method(*args, **kw)
File "/home/usuario/odoo/odoo/http.py", line 515, in response_wrap
response = f(*args, **kw)
File "/home/usuario/odoo/addons/web/controllers/main.py", line 1327, in call_kw
return self._call_kw(model, method, args, kwargs)
File "/home/usuario/odoo/addons/web/controllers/main.py", line 1319, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "/home/usuario/odoo/odoo/api.py", line 387, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "/home/usuario/odoo/odoo/api.py", line 374, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "/home/usuario/odoo/odoo/models.py", line 6202, in onchange
record._onchange_eval(name, field_onchange[name], result)
File "/home/usuario/odoo/odoo/models.py", line 5981, in _onchange_eval
method_res = method(self)
File "/home/usuario/odoo/addons/mail/wizard/mail_compose_message.py", line 384, in onchange_template_id_wrapper
values = self.onchange_template_id(self.template_id.id, self.composition_mode, self.model, self.res_id)['value']
File "/home/usuario/odoo/addons/mail/wizard/mail_compose_message.py", line 405, in onchange_template_id
values = self.generate_email_for_composer(template_id, [res_id])[res_id]
File "/home/usuario/odoo/addons/mail/wizard/mail_compose_message.py", line 538, in generate_email_for_composer
template_values = self.env['mail.template'].with_context(tpl_partners_only=True).browse(template_id).generate_email(res_ids, fields=fields)
File "/home/usuario/odoo/addons/mail/models/mail_template.py", line 437, in generate_email
result, format = report.render_qweb_pdf([res_id])
File "/home/usuario/odoo/odoo/addons/base/models/ir_actions_report.py", line 734, in render_qweb_pdf
html = self.with_context(context).render_qweb_html(res_ids, data=data)[0]
File "/home/usuario/odoo/odoo/addons/base/models/ir_actions_report.py", line 774, in render_qweb_html
return self.render_template(self.report_name, data), 'html'
File "/home/usuario/odoo/odoo/addons/base/models/ir_actions_report.py", line 548, in render_template
return view_obj.render_template(template, values)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 1191, in render_template
return self.browse(self.get_view_id(template)).render(values, engine)
File "/home/usuario/odoo/addons/website/models/ir_ui_view.py", line 336, in render
return super(View, self).render(values, engine=engine, minimal_qcontext=minimal_qcontext)
File "/home/usuario/odoo/addons/web_editor/models/ir_ui_view.py", line 27, in render
return super(IrUiView, self).render(values=values, engine=engine, minimal_qcontext=minimal_qcontext)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 1199, in render
return self.env[engine].render(self.id, qcontext)
File "/home/usuario/odoo/odoo/addons/base/models/ir_qweb.py", line 58, in render
result = super(IrQWeb, self).render(id_or_xml_id, values=values, **context)
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 260, in render
self.compile(template, options)(self, body.append, values or {})
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 335, in _compiled_fn
raise e
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 333, in _compiled_fn
return compiled(self, append, new, options, log)
File "", line 1, in template_sale_report_saleorder_15121
File "", line 2, in body_call_content_15119
File "", line 3, in foreach_15118
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 335, in _compiled_fn
raise e
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 333, in _compiled_fn
return compiled(self, append, new, options, log)
File "", line 1, in template_sale_report_saleorder_document_15172
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 335, in _compiled_fn
raise e
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 333, in _compiled_fn
return compiled(self, append, new, options, log)
File "", line 1, in template_web_external_layout_15214
File "", line 2, in compile
File "/home/usuario/odoo/odoo/tools/cache.py", line 90, in lookup
value = d[key] = self.method(*args, **kwargs)
File "/home/usuario/odoo/odoo/addons/base/models/ir_qweb.py", line 113, in compile
return super(IrQWeb, self).compile(id_or_xml_id, options=options)
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 277, in compile
element, document = self.get_template(template, options)
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 365, in get_template
raise QWebException("load could not load template", e, path, name=template)
odoo.addons.base.models.qweb.QWebException: El elemento '' no puede ser localizado en la vista padre
Error context:
View brand_external_layout
[view_id: 2340, xml_id: brand_external_report_layout.brand_external_layout, model: n/a, parent_id: 213]
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/tools/cache.py", line 85, in lookup
r = d[key]
File "/home/usuario/odoo/odoo/tools/func.py", line 69, in wrapper
return func(self, *args, **kwargs)
File "/home/usuario/odoo/odoo/tools/lru.py", line 44, in getitem
a = self.d[obj].me
KeyError: ('ir.qweb', <function IrQWeb.compile at 0x7fa435ddd160>, 'web.external_layout_standard', ('en_US', False, None, None, None, None))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/tools/cache.py", line 85, in lookup
r = d[key]
File "/home/usuario/odoo/odoo/tools/func.py", line 69, in wrapper
return func(self, *args, **kwargs)
File "/home/usuario/odoo/odoo/tools/lru.py", line 44, in getitem
a = self.d[obj].me
KeyError: ('ir.ui.view', <function View._read_template at 0x7fa436393280>, frozenset({1, 2, 3, 4, 6, 7, 10, 14, 17, 18, 19, 21, 23, 27, 28, 29, 32, 33, 35, 36, 37, 38, 39, 40, 41, 44, 47, 50, 51, 54, 55, 56, 58, 59, 60, 62, 63, 64, 65, 66, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 81}), 213, ('en_US', False, None, None, None, None))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 669, in apply_inheritance_specs
source = apply_inheritance_specs(source, specs_tree,
File "/home/usuario/odoo/odoo/tools/template_inheritance.py", line 229, in apply_inheritance_specs
raise ValueError(
ValueError: El elemento '' no puede ser localizado en la vista padre
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/usuario/odoo/odoo/addons/base/models/qweb.py", line 359, in get_template
document = options.get('load', self.load)(template, options)
File "/home/usuario/odoo/odoo/addons/base/models/ir_qweb.py", line 121, in load
template = env['ir.ui.view'].read_template(name)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 1071, in read_template
return self._read_template(self.get_view_id(xml_id))
File "", line 2, in _read_template
File "/home/usuario/odoo/odoo/tools/cache.py", line 90, in lookup
value = d[key] = self.method(*args, **kwargs)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 1063, in _read_template
arch = self.browse(view_id).read_combined(['arch'])['arch']
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 745, in read_combined
arch = self.apply_view_inheritance(arch_tree, root.id, self.model)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 694, in apply_view_inheritance
source = self.apply_inheritance_specs(source, specs_tree, view_id)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 673, in apply_inheritance_specs
self.raise_view_error(str(e), inherit_id)
File "/home/usuario/odoo/odoo/addons/base/models/ir_ui_view.py", line 614, in raise_view_error
raise ValueError(message)
ValueError: El elemento '' no puede ser localizado en la vista padre
Error context:
View brand_external_layout
[view_id: 2340, xml_id: brand_external_report_layout.brand_external_layout, model: n/a, parent_id: 213]
load could not load template
ValueError: El elemento '' no puede ser localizado en la vista padre
Error context:
View brand_external_layout
[view_id: 2340, xml_id: brand_external_report_layout.brand_external_layout, model: n/a, parent_id: 213]
Template: web.external_layout
Path: /t/t[3]
Hello,
This development is really useful, I am grateful.
If I create a sales invoice and select brand, the invoice is generated with the new brand information, and this is great.
But I do not know how to make the sales invoices of the website (e-commerce) have the template of the brand.
If I try to edit the website sales orders, brand is not an editable field, as it is in the billing module.
Thanks
https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-13.0
Missing module? Check https://github.com/OCA/maintainer-tools/wiki/%5BFAQ%5D-Missing-modules-in-migration-issue-list
Hello,
I have the error bellow when printing the timesheet qweb report.
Other reports work fine.
Maybe it's related with the account.analytic.line model ?
I have this error on a clean database with only hr_timesheet and following brand modules installed :
brand, brand_external_report_layout, account_brand and sale_brand.
Edit : narrowed it down to brand_external_report_layout
Thanks for your help
AttributeError: 'NoneType' object has no attribute 'fields_get'
Error to render compiling AST
AttributeError: 'NoneType' object has no attribute 'fields_get'
Template: web.external_layout
Path: /templates/t/t[3]
Node: <t t-if="'brand_id' in o.fields_get() and o.brand_id and o.brand_id.external_report_layout_id" t-call="{{o.brand_id.external_report_layout_id.key}}">
<t t-set="company" t-value="o.brand_id.sudo()"/>
<t t-raw="0"/>
</t>
https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-17.0
Missing module? Check https://github.com/OCA/maintainer-tools/wiki/%5BFAQ%5D-Missing-modules-in-migration-issue-list
Not sure it can be improved in some way or it's a problem of our instance but: we have more than 250k products in database (many different machines and their spare parts) with one particular brand. When I try to open view listing the brands it takes ages to load. The same looooong waiting happens if I try to click on brand name in Product kanban view. Is the _compute_products_count
to blame? Any help would be appreciated.
Brand addon
I am trying to import the addon using the Odoo Apps import module UI.
while parsing /tmp/tmp3rsh2yse/brand/views/res_config_settings.xml:5
Erreur lors de la validation de la vue :
<field name="is_root_company" invisible="1"/>
<app data-string="General Settings" string="General Settings" name="general_settings" logo="/base/static/description/settings.png">
<div id="invite_users">
<block title="Users" name="users_setting_container">
Le champ "brand_use_level" n'existe pas dans le modรจle "res.config.settings"
View error context:
{'file': '/tmp/tmp3rsh2yse/brand/views/res_config_settings.xml',
'line': 4,
'name': 'res.config.settings form',
'view': ir.ui.view(2114,),
'view.model': 'res.config.settings',
'view.parent': ir.ui.view(223,),
'xmlid': 'res_config_settings_view_form'}
Affected versions: 17.0
Steps to reproduce the behavior:
Expected behavior
Additional context
OS: Arch Linux
Package: odoo-17
Python: 3.11.9
https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-15.0
Missing module? Check https://github.com/OCA/maintainer-tools/wiki/%5BFAQ%5D-Missing-modules-in-migration-issue-list
Install 17.0
Just install the module and read the log.
the following warning appears.
2024-04-01 22:51:33,665 1313001 WARNING databasename170 py.warnings: /home/nhomar/Documents/databasename17/odoo17/odoo/addons/base/models/ir_module.py:178: DeprecationWarning: XML declarations in HTML module descriptions are deprecated since Odoo 17, product_brand can just have a UTF8 description with not need for a declaration.
File "/home/nhomar/Documents/databasename17/odoo17/./odoo-bin", line 8, in <module>
odoo.cli.main()
File "/home/nhomar/Documents/databasename17/odoo17/odoo/cli/command.py", line 66, in main
o.run(args)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/cli/server.py", line 179, in run
main(args)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/cli/server.py", line 172, in main
rc = odoo.service.server.start(preload=preload, stop=stop)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/service/server.py", line 1402, in start
rc = server.run(preload, stop)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/service/server.py", line 579, in run
rc = preload_registries(preload)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/service/server.py", line 1302, in preload_registries
registry = Registry.new(dbname, update_module=update_module)
File "<decorator-gen-16>", line 2, in new
File "/home/nhomar/Documents/databasename17/odoo17/odoo/tools/func.py", line 87, in locked
return func(inst, *args, **kwargs)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/modules/registry.py", line 113, in new
odoo.modules.load_modules(registry, force_demo, status, update_module)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/modules/loading.py", line 480, in load_modules
processed_modules += load_marked_modules(env, graph,
File "/home/nhomar/Documents/databasename17/odoo17/odoo/modules/loading.py", line 364, in load_marked_modules
loaded, processed = load_module_graph(
File "/home/nhomar/Documents/databasename17/odoo17/odoo/modules/loading.py", line 222, in load_module_graph
module._check()
File "/home/nhomar/Documents/databasename17/odoo17/odoo/addons/base/models/ir_module.py", line 842, in _check
if not module.description_html:
File "/home/nhomar/Documents/databasename17/odoo17/odoo/fields.py", line 1207, in __get__
self.compute_value(recs)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/fields.py", line 1389, in compute_value
records._compute_field_value(self)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/models.py", line 4869, in _compute_field_value
fields.determine(field.compute, self)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/fields.py", line 102, in determine
return needle(*args)
File "/home/nhomar/Documents/databasename17/odoo17/odoo/addons/base/models/ir_module.py", line 178, in _get_desc
warnings.warn(
2024-04-01 22:51:33,673 1313001 INFO databasename170 odoo.modules.loading: loading product_brand/security/ir.model.access.csv
2024-04-01 22:51:33,678 1313001 WARNING databasename170 odoo.addons.base.models.ir_model: Rule product.brand.public has no group, this is a deprecated feature. Every access-granting rule should specify a group.
Affected versions:
Steps to reproduce the behavior:
Expected behavior
Just fix the error
account_brand
During the creation of an invoice brand_id is not visible in the form view.
Affected versions: 15.0
Steps to reproduce the behavior:
Expected behavior
Once a manual invoice is created brand_id should be visible in the form view
Additional context
Add any other context about the problem here. (e.g. OS, Python version, ...)
product_brand
Clicking any brand link on the product_template kanban view results in the error bellow:
EvalError: Can not evaluate python expression: ([('product_ids', 'in', id)])
Error: Name 'id' is not defined
at evaluateExpr (http://45.33.98.35/web/assets/0ddd052/web.assets_web.min.js:3029:54)
at _preprocessAction (http://45.33.98.35/web/assets/0ddd052/web.assets_web.min.js:10127:150)
at doAction (http://45.33.98.35/web/assets/0ddd052/web.assets_web.min.js:10209:170)
at async Object.doActionButton (http://45.33.98.35/web/assets/0ddd052/web.assets_web.min.js:10217:196)
at async execute (http://45.33.98.35/web/assets/0ddd052/web.assets_web.min.js:9843:293)
at async executeButtonCallback (http://45.33.98.35/web/assets/0ddd052/web.assets_web.min.js:9836:34)
Affected versions:
Odoo 17
Steps to reproduce the behavior:
Expected behavior
Action should open a Product Brand page with the filter applied to the selected brand, without throwing an error. Bug seems to have been introduced in this line
https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-16.0
Missing module? Check https://github.com/OCA/maintainer-tools/wiki/%5BFAQ%5D-Missing-modules-in-migration-issue-list
brand_external_layout
Error when printing a PDF report with external layout (e.g. invoice pdf). Odoo added a field to res.company which is used in the external report XML, but the field doesn't exist yet on res.brand.
odoo/odoo@5db133d
16.0
possible other versions if this field is backported
Steps to reproduce the behavior:
Error log
RPC_ERROR
Odoo Server Error
Traceback (most recent call last):
ย File "<199>", line 302, in template_199
ย File "<199>", line 75, in template_199_content
AttributeError: 'res.brand' object has no attribute 'is_company_details_empty'
ย
The above exception was the direct cause of the following exception:
ย
Traceback (most recent call last):
ย File "/home/odoo/src/odoo/addons/web/controllers/report.py", line 113, in report_download
ย ย ย response = self.report_routes(reportname, docids=docids, converter=converter, context=context)
ย File "/home/odoo/src/odoo/odoo/http.py", line 697, in route_wrapper
ย ย ย result = endpoint(self, *args, **params_ok)
ย File "/home/odoo/src/odoo/addons/web/controllers/report.py", line 42, in report_routes
ย ย ย pdf = report.with_context(context)._render_qweb_pdf(reportname, docids, data=data)[0]
ย File "/home/odoo/src/odoo/addons/account/models/ir_actions_report.py", line 61, in _render_qweb_pdf
ย ย ย return super()._render_qweb_pdf(report_ref, res_ids=res_ids, data=data)
ย File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 807, in _render_qweb_pdf
ย ย ย collected_streams = self._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
ย File "/home/odoo/src/odoo/addons/account_edi_ubl_cii/models/ir_actions_report.py", line 58, in _render_qweb_pdf_prepare_streams
ย ย ย collected_streams = super()._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
ย File "/home/odoo/src/odoo/addons/account_edi/models/ir_actions_report.py", line 14, in _render_qweb_pdf_prepare_streams
ย ย ย collected_streams = super()._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
ย File "/home/odoo/src/odoo/addons/account/models/ir_actions_report.py", line 20, in _render_qweb_pdf_prepare_streams
ย ย ย return super()._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
ย File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 708, in _render_qweb_pdf_prepare_streams
ย ย ย html = self.with_context(**additional_context)._render_qweb_html(report_ref, res_ids_wo_stream, data=data)[0]
ย File "/home/odoo/src/enterprise/web_studio/models/ir_actions_report.py", line 19, in _render_qweb_html
ย ย ย return super(IrActionsReport, self)._render_qweb_html(report_ref, docids, data)
ย File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 884, in _render_qweb_html
ย ย ย return self._render_template(report.report_name, data), 'html'
ย File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 623, in _render_template
ย ย ย return view_obj._render_template(template, values).encode()
ย File "/home/odoo/src/odoo/odoo/addons/base/models/ir_ui_view.py", line 2128, in _render_template
ย ย ย return self.env['ir.qweb']._render(template, values)
ย File "/home/odoo/src/odoo/odoo/tools/profiler.py", line 292, in _tracked_method_render
ย ย ย return method_render(self, template, values, **options)
ย File "/home/odoo/src/odoo/odoo/addons/base/models/ir_qweb.py", line 580, in _render
ย ย ย result = ''.join(rendering)
ย File "<694>", line 90, in template_694
ย File "<694>", line 72, in template_694_content
ย File "<694>", line 60, in template_694_t_call_0
ย File "<690>", line 2108, in template_690
ย File "<690>", line 2097, in template_690_content
ย File "<202>", line 150, in template_202
ย File "<202>", line 106, in template_202_content
ย File "<199>", line 308, in template_199
odoo.addons.base.models.ir_qweb.QWebException: Error while render the template
AttributeError: 'res.brand' object has no attribute 'is_company_details_empty'
Template: web.external_layout_boxed
Path: /t/div[1]/div/div/div[2]/div[2]/ul/li[1]
Node:
If a customer want to buy a product from mybrandwebsite.com then all communications should be done from that domain: emails, payment link, payment mean etc.
Add brand to CRM cf. PR #62
Mail server per brand. cf. PR #64
Let chatter send messages with the correct domain (email [email protected] / [email protected])
Add brand to website.
Currently, all website in same company use that company's information.
Different payment providers per brand (paypal for brand 1 / paypal for brand 2)
brand, sale_brand
When user is in "full accounting features" group, brand_id is hidden.
This happens when BRAND_USE_LEVEL_NO_USE_LEVEL is set because no default company is set as full accounting features adds the value after account selector
Install brand and sale_brand, create a brand, put brand external layout as "optional" in settings, put your user in "full accounting features" group and create a new invoice
Odoo changed the method signature for transfer_field_to_modifiers
on the model ir.ui.view
in this commit: odoo/odoo@5a68d25
brand
A traceback appears we try to open the tree
or form
view of a model that's mixed in with res.brand.mixin
.
Affected versions: 16.0
Steps to reproduce the behavior:
tree
or form
view of a model that's mixed in with res.brand.mixin
.Expenses module
When Brand module is installed, with Brand Use Level set to "Required", it is not possible to post an expense report if the expense report is set to "Paid By" "Company".
Affected versions:
Odoo 16 and the following modules
{
"name": "Brand",
"version": "16.0.1.0.2",
}
{
'name': 'Sales Expense',
'version': '1.0',
}
{
'name': 'Expenses',
'version': '2.0',
}
{
'name' : 'Invoicing',
'version' : '1.2',
}
Steps to reproduce the behavior:
Expected behavior
There should either be a select to pick the brand in the report view OR the brand should be considered not needed as probably it has no corresponding functionality in the accounting module (apart if one has brand accounting in use).
Additional context
GNU/Linux, Devuan, Python 3.11.2
Workaround
Set "Brand Use Level" to "Optional", post entries, set back "Brand Use Level" to "Required".
Backtrace
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/odoo/http.py", line 1584, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 133, in retrying
result = func()
^^^^^^
File "/usr/lib/python3/dist-packages/odoo/http.py", line 1611, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/http.py", line 1815, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_http.py", line 154, in _dispatch
result = endpoint(**request.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/http.py", line 697, in route_wrapper
result = endpoint(self, *args, **params_ok)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/dataset.py", line 46, in call_button
action = self._call_kw(model, method, args, kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/dataset.py", line 33, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 461, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 448, in _call_kw_multi
result = method(recs, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/hr_expense/models/hr_expense.py", line 1100, in action_sheet_move_create
res = expense_line_ids.with_context(clean_context(self.env.context)).action_move_create()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/sale_expense/models/hr_expense.py", line 58, in action_move_create
return super(Expense, self).action_move_create()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/hr_expense/models/hr_expense.py", line 640, in action_move_create
return self.sheet_id._do_create_moves() # backport
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/hr_expense/models/hr_expense.py", line 1123, in _do_create_moves
payments = self.env['account.payment'].with_context(**skip_context).create([sheet._prepare_payment_vals() for sheet in company_account_sheets])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/account/models/account_payment.py", line 695, in create
.create([{'name': '/', **vals} for vals in vals_list])\
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/mail/models/mail_thread.py", line 258, in create
threads = super(MailThread, self).create(vals_list)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_fields.py", line 669, in create
recs = super().create(vals_list)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3943, in create
parents = self.env[model_name].create([
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/account/models/account_move.py", line 2260, in create
moves = super().create([self._sanitize_vals(vals) for vals in vals_list])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/mail/models/mail_thread.py", line 258, in create
threads = super(MailThread, self).create(vals_list)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_fields.py", line 669, in create
recs = super().create(vals_list)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/models.py", line 3951, in create
records = self._create(data_list)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/odoo/models.py", line 4203, in _create
records._validate_fields(name for data in data_list for name in data['stored'])
File "/usr/lib/python3/dist-packages/odoo/models.py", line 1348, in _validate_fields
check(self)
File "/usr/lib/python3/dist-packages/odoo/addons/brand/models/res_brand_mixin.py", line 38, in _check_brand_requirement
raise ValidationError(_("Brand is required"))
odoo.exceptions.ValidationError: Brand is required
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.