-
-
Notifications
You must be signed in to change notification settings - Fork 4
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
[17.0] [MIG] tg_base #6
Conversation
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.
Помимо комментариев ниже замечу, что не должно быть несколько коммитов вида "Migration to 17.0". Слей все в один коммит.
tg_base/views/res_country_views.xml
Outdated
<record id="country_view_search" model="ir.ui.view"> | ||
<field name="name">res.country.search.tg</field> | ||
<field name="model">res.country</field> | ||
<field name="arch" type="xml"> | ||
<search> | ||
<field name="name" /> | ||
<filter | ||
string="Archived" | ||
name="inactive" | ||
domain="[('active', '=', False)]" | ||
/> | ||
</search> | ||
</field> | ||
</record> |
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.
В 17.0 уже есть вьюха для поиска. odoo/odoo#106372
Надо сделать на основе основе ее.
tg_base/wizard/base_partner_merge.py
Outdated
def _merge(self, partner_ids, dst_partner=None, extra_checks=True): | ||
if self.env.user.has_group("account.group_account_user"): | ||
extra_checks = False | ||
return super()._merge(partner_ids, dst_partner, extra_checks) |
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.
Изначально в этот модуль в 14.0 вводилась возможность бухгалтерам с правами account.group_account_user сливать партнеров с разными записями account.move и account.move.line, поскольку основной метод _merge
не позволял это делать.
Но после коммита odoo/odoo@0148f19 оригинальный _merge уже позволяет это делать.
Соотвественно предлагаю метод удалить целиком и вместо него оставить это:
# removed since
# https://github.com/odoo/odoo/commit/0148f19f67f8725ae9bea7c208f09b4676652cc0
tg_base/README.rst
Outdated
* `Eugene Molotov <https://github.com/em230418>`__ | ||
|
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.
Предлагаю себя тоже сюда добавить
tg_base/README.rst
Outdated
|
||
* Allows to set country as archived | ||
|
||
* Allows accountant without admin previledges to merge contacts with existing journal entries |
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.
Этот момент надо тоже убрать. Объяснил тут https://github.com/it-projects-llc/tg-addons/pull/6/files/e663e036840fa1a1f5063740578405a052a3778f#diff-008aad618469a6cc33c93db38fbf40d52b4b5fac1ba10986a47706008c8bf3f8
9f477c2
to
1d055da
Compare
tg_base/README.rst
Outdated
* Allows to set country as archived | ||
|
||
* Allows accountant without admin previledges to merge contacts with existing journal entries | ||
|
||
Credits | ||
======= | ||
|
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.
Я предложил удалить только строку "* Allows accountant without admin previledges to merge contacts with existing journal entries". Остальное надо вернуть
4b1382e
to
6efacae
Compare
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.
6efacae
to
12fd1bd
Compare
[17.0] [MIG] tg_base