-
Notifications
You must be signed in to change notification settings - Fork 5
[3860] Dotfiles Update for Repositories: Version 10.0 #220
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
Closed
Closed
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,23 @@ | ||
# Do NOT update manually; changes here will be overwritten by Copier | ||
_commit: v1.14.1 | ||
_commit: '1.23' | ||
_src_path: https://github.com/OCA/oca-addons-repo-template.git | ||
ci: GitHub | ||
dependency_installation_mode: PIP | ||
convert_readme_fragments_to_markdown: true | ||
generate_requirements_txt: true | ||
github_check_license: true | ||
github_ci_extra_env: {} | ||
github_enable_codecov: true | ||
github_enable_codecov: false | ||
github_enable_makepot: false | ||
github_enable_stale_action: true | ||
github_enforce_dev_status_compatibility: true | ||
github_enable_stale_action: false | ||
github_enforce_dev_status_compatibility: false | ||
include_wkhtmltopdf: false | ||
odoo_test_flavor: OCB | ||
odoo_version: 10.0 | ||
org_name: Quartile Limited | ||
org_name: '' | ||
org_slug: qrtl | ||
rebel_module_groups: [] | ||
repo_description: PCI Custom | ||
repo_name: null | ||
repo_description: '' | ||
repo_name: PCI Custom | ||
repo_slug: pci-custom | ||
repo_website: https://www.quartile.co | ||
travis_apt_packages: [] | ||
travis_apt_sources: [] | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[MESSAGES_CONTROL] | ||
disable=xml-deprecated-data-node,xml-deprecated-tree-attribute |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
48 changes: 48 additions & 0 deletions
48
fix_product_attribute_line_name_search/models/product_attribute_line_hook_name_search.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# -*- coding: utf-8 -*- | ||
# Copyright 2018 Quartile Limited | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from odoo.osv import expression | ||
from odoo import models, api | ||
from odoo.addons.product.models.product_attribute import ProductAttributeLine | ||
|
||
|
||
# """ | ||
# Odoo's original method completely overrides `args` which disables whatever | ||
# domain passed to this method, and therefore is not desiable. | ||
# We will fix it by extending args instead of overriding it. | ||
# Ref: https://github.com/odoo/odoo/pull/26133 | ||
# """ | ||
@api.model | ||
def name_search(self, name='', args=None, operator='ilike', limit=100): | ||
# TDE FIXME: currently overriding the domain; however as it includes a | ||
# search on a m2o and one on a m2m, probably this will quickly become | ||
# difficult to compute - check if performance optimization is required | ||
if name and operator in ('=', 'ilike', '=ilike', 'like', '=like'): | ||
# Correctly indented comment block | ||
# args = ['|', ('attribute_id', operator, name), | ||
# ('value_ids', operator, name)] | ||
# QTL del | ||
args = args or [] # QTL add | ||
domain = [ | ||
'|', | ||
('attribute_id', operator, name), | ||
('value_ids', operator, name) | ||
] # QTL add | ||
search_result = self.search(expression.AND([domain, args]), limit=limit) | ||
if search_result: | ||
return search_result.name_get() # QTL add | ||
|
||
return super(ProductAttributeLine, self).name_search( | ||
name=name, args=args, operator=operator, limit=limit | ||
) | ||
|
||
|
||
class ProductAttributeLineHookNameSearch(models.AbstractModel): | ||
_name = "product.attribute.line.hook.name.search" | ||
_description = "Provide hook point for name_search method" | ||
|
||
def _register_hook(self): | ||
ProductAttributeLine.name_search = name_search | ||
return super(ProductAttributeLineHookNameSearch, self).\ | ||
_register_hook() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why an addition of this entire file in this PR?