Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] shopfloor: Allow to manage supplierinfos on product templates #989

Open
wants to merge 1 commit into
base: 16.0
Choose a base branch
from

Conversation

rousseldenis
Copy link
Contributor

No description provided.

@OCA-git-bot
Copy link
Contributor

Hi @sebalix, @guewen, @simahawk,
some modules you are maintaining are being modified, check this out!

@rousseldenis
Copy link
Contributor Author

@jbaudoux

@rousseldenis rousseldenis added the enhancement New feature or request label Feb 26, 2025
@rousseldenis rousseldenis added this to the 16.0 milestone Feb 26, 2025
rec.seller_ids.filtered(lambda x: x.product_id == rec)
rec.seller_ids.filtered(
lambda x: x.product_id == rec
or x.product_tmpl_id == rec.product_tmpl_id
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
or x.product_tmpl_id == rec.product_tmpl_id
or (x.product_tmpl_id == rec.product_tmpl_id and not x.product_id)

[("product_id", "=", record.id)]
[
"|",
("product_tmpl_id", "=", record.product_tmpl_id.id),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
("product_tmpl_id", "=", record.product_tmpl_id.id),
"&",
("product_tmpl_id", "=", record.product_tmpl_id.id),
("product_id", "=", False),

supplier_info = product.seller_ids.filtered(lambda x: x.product_id == product)
supplier_info = product.seller_ids.filtered(
lambda x: x.product_id == product
or x.product_tmpl_id == product.product_tmpl_id
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
or x.product_tmpl_id == product.product_tmpl_id
or (x.product_tmpl_id == product.product_tmpl_id and not x.product_id)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants