Compare commits
1 Commits
14-add-bom
...
14.0-googl
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d4272eff9c |
@@ -52,7 +52,6 @@ This modules adds the following functions:
|
|||||||
* don't attach PDF upon invoice report generation on supplier invoices/refunds
|
* don't attach PDF upon invoice report generation on supplier invoices/refunds
|
||||||
* Add filter on debit and credit amount for Move Lines
|
* Add filter on debit and credit amount for Move Lines
|
||||||
* Add supplier invoice number in invoice tree view
|
* Add supplier invoice number in invoice tree view
|
||||||
* Add date in outstanding payment widget on invoice form view (requires `odoo PR 84180 <https://github.com/odoo/odoo/pull/84180>`_)
|
|
||||||
|
|
||||||
Together with this module, I recommend the use of the following modules:
|
Together with this module, I recommend the use of the following modules:
|
||||||
|
|
||||||
|
|||||||
@@ -19,26 +19,18 @@
|
|||||||
'data': [
|
'data': [
|
||||||
'views/account_account_type.xml',
|
'views/account_account_type.xml',
|
||||||
'views/account_account.xml',
|
'views/account_account.xml',
|
||||||
'views/account_group.xml',
|
|
||||||
'views/account_analytic_account.xml',
|
|
||||||
'views/account_analytic_group.xml',
|
|
||||||
'views/account_bank_statement.xml',
|
'views/account_bank_statement.xml',
|
||||||
'views/account_invoice_report.xml',
|
'views/account_invoice_report.xml',
|
||||||
'views/account_journal.xml',
|
'views/account_journal.xml',
|
||||||
'views/account_move.xml',
|
'views/account_move.xml',
|
||||||
'views/account_menu.xml',
|
'views/account_menu.xml',
|
||||||
'views/account_tax.xml',
|
'views/account_tax.xml',
|
||||||
'views/product.xml',
|
|
||||||
'views/res_config_settings.xml',
|
'views/res_config_settings.xml',
|
||||||
'views/res_partner.xml',
|
'views/res_partner.xml',
|
||||||
'views/res_company.xml',
|
|
||||||
'views/account_report.xml',
|
'views/account_report.xml',
|
||||||
'wizard/account_invoice_mark_sent_view.xml',
|
'wizard/account_invoice_mark_sent_view.xml',
|
||||||
'wizard/account_group_generate_view.xml',
|
'wizard/account_group_generate_view.xml',
|
||||||
'wizard/account_payment_register_views.xml',
|
|
||||||
'security/ir.model.access.csv',
|
'security/ir.model.access.csv',
|
||||||
'report/invoice_report.xml',
|
|
||||||
],
|
],
|
||||||
'qweb': ['static/src/xml/account_payment.xml'],
|
|
||||||
'installable': True,
|
'installable': True,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,6 +6,3 @@ from . import account_journal
|
|||||||
from . import account_move
|
from . import account_move
|
||||||
from . import account_partial_reconcile
|
from . import account_partial_reconcile
|
||||||
from . import res_partner
|
from . import res_partner
|
||||||
from . import res_company
|
|
||||||
from . import product
|
|
||||||
from . import account_invoice_report
|
|
||||||
|
|||||||
@@ -27,7 +27,9 @@ class AccountBankStatement(models.Model):
|
|||||||
|
|
||||||
def _check_balance_end_real_same_as_computed(self):
|
def _check_balance_end_real_same_as_computed(self):
|
||||||
for stmt in self:
|
for stmt in self:
|
||||||
if not stmt.hide_bank_statement_balance:
|
if stmt.hide_bank_statement_balance:
|
||||||
|
continue
|
||||||
|
else:
|
||||||
super(AccountBankStatement, stmt)._check_balance_end_real_same_as_computed()
|
super(AccountBankStatement, stmt)._check_balance_end_real_same_as_computed()
|
||||||
return True
|
return True
|
||||||
|
|
||||||
@@ -78,8 +80,7 @@ class AccountBankStatementLine(models.Model):
|
|||||||
|
|
||||||
def show_account_move(self):
|
def show_account_move(self):
|
||||||
self.ensure_one()
|
self.ensure_one()
|
||||||
action = self.env["ir.actions.actions"]._for_xml_id(
|
action = self.env.ref('account.action_move_line_form').read()[0]
|
||||||
'account.action_move_line_form')
|
|
||||||
# Note: this action is on account.move, not account.move.line !
|
# Note: this action is on account.move, not account.move.line !
|
||||||
action.update({
|
action.update({
|
||||||
'views': False,
|
'views': False,
|
||||||
|
|||||||
@@ -14,13 +14,3 @@ class AccountIncoterms(models.Model):
|
|||||||
for rec in self:
|
for rec in self:
|
||||||
res.append((rec.id, '[%s] %s' % (rec.code, rec.name)))
|
res.append((rec.id, '[%s] %s' % (rec.code, rec.name)))
|
||||||
return res
|
return res
|
||||||
|
|
||||||
@api.model
|
|
||||||
def name_search(self, name='', args=None, operator='ilike', limit=100):
|
|
||||||
if args is None:
|
|
||||||
args = []
|
|
||||||
if name and operator == 'ilike':
|
|
||||||
recs = self.search([('code', '=ilike', name + '%')] + args, limit=limit)
|
|
||||||
if recs:
|
|
||||||
return recs.name_get()
|
|
||||||
return super().name_search(name=name, args=args, operator=operator, limit=limit)
|
|
||||||
|
|||||||
@@ -1,17 +0,0 @@
|
|||||||
# Copyright 2022 Akretion (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import api, fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class AccountInvoiceReport(models.Model):
|
|
||||||
_inherit = 'account.invoice.report'
|
|
||||||
|
|
||||||
industry_id = fields.Many2one('res.partner.industry', string='Partner Industry', readonly=True)
|
|
||||||
|
|
||||||
@api.model
|
|
||||||
def _select(self):
|
|
||||||
res = super()._select()
|
|
||||||
res += ", COALESCE(partner.industry_id, commercial_partner.industry_id) AS industry_id"
|
|
||||||
return res
|
|
||||||
@@ -16,13 +16,6 @@ class AccountJournal(models.Model):
|
|||||||
"you don't want to enter the start/end balance manually: it "
|
"you don't want to enter the start/end balance manually: it "
|
||||||
"will prevent the display of wrong information in the accounting "
|
"will prevent the display of wrong information in the accounting "
|
||||||
"dashboard and on bank statements.")
|
"dashboard and on bank statements.")
|
||||||
# Used to set default user_type_id on account fields
|
|
||||||
account_type_current_liabilities_id = fields.Many2one(
|
|
||||||
'account.account.type',
|
|
||||||
default=lambda self: self.env.ref('account.data_account_type_current_liabilities').id)
|
|
||||||
account_type_current_assets_id = fields.Many2one(
|
|
||||||
'account.account.type',
|
|
||||||
default=lambda self: self.env.ref('account.data_account_type_current_assets').id)
|
|
||||||
|
|
||||||
@api.depends(
|
@api.depends(
|
||||||
'name', 'currency_id', 'company_id', 'company_id.currency_id', 'code')
|
'name', 'currency_id', 'company_id', 'company_id.currency_id', 'code')
|
||||||
|
|||||||
@@ -2,17 +2,16 @@
|
|||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
from odoo import api, fields, models, _
|
from odoo import api, fields, models
|
||||||
from odoo.tools import float_is_zero
|
from odoo.tools import float_is_zero
|
||||||
from odoo.tools.misc import format_date
|
from odoo.tools.misc import format_date
|
||||||
from odoo.osv import expression
|
|
||||||
from datetime import timedelta
|
|
||||||
from odoo.exceptions import UserError
|
|
||||||
|
|
||||||
|
|
||||||
class AccountMove(models.Model):
|
class AccountMove(models.Model):
|
||||||
_inherit = 'account.move'
|
_inherit = 'account.move'
|
||||||
|
|
||||||
|
default_move_line_name = fields.Char(
|
||||||
|
string='Default Label', states={'posted': [('readonly', True)]})
|
||||||
# By default, we can still modify "ref" when account move is posted
|
# By default, we can still modify "ref" when account move is posted
|
||||||
# which seems a bit lazy for me...
|
# which seems a bit lazy for me...
|
||||||
ref = fields.Char(states={'posted': [('readonly', True)]})
|
ref = fields.Char(states={'posted': [('readonly', True)]})
|
||||||
@@ -50,11 +49,11 @@ class AccountMove(models.Model):
|
|||||||
def _compute_has_attachment(self):
|
def _compute_has_attachment(self):
|
||||||
iao = self.env['ir.attachment']
|
iao = self.env['ir.attachment']
|
||||||
for move in self:
|
for move in self:
|
||||||
if iao.search_count([
|
if iao.search([
|
||||||
('res_model', '=', 'account.move'),
|
('res_model', '=', 'account.move'),
|
||||||
('res_id', '=', move.id),
|
('res_id', '=', move.id),
|
||||||
('type', '=', 'binary'),
|
('type', '=', 'binary'),
|
||||||
('company_id', '=', move.company_id.id)]):
|
('company_id', '=', move.company_id.id)], limit=1):
|
||||||
move.has_attachment = True
|
move.has_attachment = True
|
||||||
else:
|
else:
|
||||||
move.has_attachment = False
|
move.has_attachment = False
|
||||||
@@ -122,12 +121,8 @@ class AccountMove(models.Model):
|
|||||||
res = []
|
res = []
|
||||||
has_sections = False
|
has_sections = False
|
||||||
subtotal = 0.0
|
subtotal = 0.0
|
||||||
sign = self.move_type == 'out_refund' and -1 or 1
|
sign = self.type == 'out_refund' and -1 or 1
|
||||||
# Warning: the order of invoice line is forced in the view
|
for line in self.invoice_line_ids:
|
||||||
# <tree editable="bottom" default_order="sequence, date desc, move_name desc, id"
|
|
||||||
# it's not the same as the _order in the class AccountMoveLine
|
|
||||||
lines = self.env['account.move.line'].search([('exclude_from_invoice_tab', '=', False), ('move_id', '=', self.id)], order="sequence, date desc, move_name desc, id")
|
|
||||||
for line in lines:
|
|
||||||
if line.display_type == 'line_section':
|
if line.display_type == 'line_section':
|
||||||
# insert line
|
# insert line
|
||||||
if has_sections:
|
if has_sections:
|
||||||
@@ -154,72 +149,13 @@ class AccountMove(models.Model):
|
|||||||
""" French law requires to set sale order dates into invoice
|
""" French law requires to set sale order dates into invoice
|
||||||
returned string: "sale1 (date1), sale2 (date2) ..."
|
returned string: "sale1 (date1), sale2 (date2) ..."
|
||||||
"""
|
"""
|
||||||
for move in self:
|
for inv in self:
|
||||||
sales = move.invoice_line_ids.mapped(
|
sales = inv.invoice_line_ids.mapped(
|
||||||
'sale_line_ids').mapped('order_id')
|
'sale_line_ids').mapped('order_id')
|
||||||
dates = ["%s (%s)" % (
|
dates = ["%s (%s)" % (
|
||||||
x.name, format_date(move.env, x.date_order))
|
x.name, format_date(inv.env, self.date_order))
|
||||||
for x in sales]
|
for x in sales]
|
||||||
move.sale_dates = ", ".join(dates)
|
inv.sale_dates = ", ".join(dates)
|
||||||
|
|
||||||
# allow to manually create moves not only in general journals,
|
|
||||||
# but also in cash journal and check journals (= bank journals not linked to a bank account)
|
|
||||||
@api.depends('company_id', 'invoice_filter_type_domain')
|
|
||||||
def _compute_suitable_journal_ids(self):
|
|
||||||
for move in self:
|
|
||||||
if move.invoice_filter_type_domain:
|
|
||||||
super(AccountMove, move)._compute_suitable_journal_ids()
|
|
||||||
else:
|
|
||||||
company_id = move.company_id.id or self.env.company.id
|
|
||||||
domain = expression.AND([
|
|
||||||
[('company_id', '=', company_id)],
|
|
||||||
expression.OR([
|
|
||||||
[('type', 'in', ('general', 'cash'))],
|
|
||||||
[('type', '=', 'bank'), ('bank_account_id', '=', False)]
|
|
||||||
])
|
|
||||||
])
|
|
||||||
move.suitable_journal_ids = self.env['account.journal'].search(domain)
|
|
||||||
|
|
||||||
def button_draft(self):
|
|
||||||
super().button_draft()
|
|
||||||
# Delete attached pdf invoice
|
|
||||||
try:
|
|
||||||
report_invoice = self.env['ir.actions.report']._get_report_from_name('account.report_invoice')
|
|
||||||
except IndexError:
|
|
||||||
report_invoice = False
|
|
||||||
if report_invoice and report_invoice.attachment:
|
|
||||||
for move in self.filtered(lambda x: x.move_type in ('out_invoice', 'out_refund')):
|
|
||||||
# The pb is that the filename is dynamic and related to move.state
|
|
||||||
# in v12, the feature was native and they used that kind of code:
|
|
||||||
# with invoice.env.do_in_draft():
|
|
||||||
# invoice.number, invoice.state = invoice.move_name, 'open'
|
|
||||||
# attachment = self.env.ref('account.account_invoices').retrieve_attachment(invoice)
|
|
||||||
# But do_in_draft() doesn't exists in v14
|
|
||||||
# If you know how we could do that, please update the code below
|
|
||||||
attachment = self.env['ir.attachment'].search([
|
|
||||||
('name', '=', self._get_invoice_attachment_name()),
|
|
||||||
('res_id', '=', move.id),
|
|
||||||
('res_model', '=', self._name),
|
|
||||||
('type', '=', 'binary'),
|
|
||||||
], limit=1)
|
|
||||||
if attachment:
|
|
||||||
attachment.unlink()
|
|
||||||
|
|
||||||
def _get_invoice_attachment_name(self):
|
|
||||||
self.ensure_one()
|
|
||||||
return '%s.pdf' % (self.name and self.name.replace('/', '_') or 'INV')
|
|
||||||
|
|
||||||
def _get_accounting_date(self, invoice_date, has_tax):
|
|
||||||
# On vendor bills/refunds, we want date = invoice_date unless
|
|
||||||
# we have a company tax_lock_date and the invoice has taxes
|
|
||||||
# and invoice_date <= tax_lock_date
|
|
||||||
date = super()._get_accounting_date(invoice_date, has_tax)
|
|
||||||
if self.is_purchase_document(include_receipts=True):
|
|
||||||
tax_lock_date = self.company_id.tax_lock_date
|
|
||||||
if invoice_date and tax_lock_date and has_tax and invoice_date <= tax_lock_date:
|
|
||||||
invoice_date = tax_lock_date + timedelta(days=1)
|
|
||||||
date = invoice_date
|
|
||||||
return date
|
|
||||||
|
|
||||||
|
|
||||||
class AccountMoveLine(models.Model):
|
class AccountMoveLine(models.Model):
|
||||||
@@ -240,13 +176,10 @@ class AccountMoveLine(models.Model):
|
|||||||
matched_credit_ids = fields.One2many(string='Partial Reconcile Credit')
|
matched_credit_ids = fields.One2many(string='Partial Reconcile Credit')
|
||||||
reconcile_string = fields.Char(
|
reconcile_string = fields.Char(
|
||||||
compute='_compute_reconcile_string', string='Reconcile', store=True)
|
compute='_compute_reconcile_string', string='Reconcile', store=True)
|
||||||
# for optional display in tree view
|
|
||||||
product_barcode = fields.Char(related='product_id.barcode', string="Product Barcode")
|
|
||||||
|
|
||||||
def show_account_move_form(self):
|
def show_account_move_form(self):
|
||||||
self.ensure_one()
|
self.ensure_one()
|
||||||
action = self.env["ir.actions.actions"]._for_xml_id(
|
action = self.env.ref('account.action_move_line_form').read()[0]
|
||||||
'account.action_move_line_form')
|
|
||||||
action.update({
|
action.update({
|
||||||
'res_id': self.move_id.id,
|
'res_id': self.move_id.id,
|
||||||
'view_id': False,
|
'view_id': False,
|
||||||
@@ -266,25 +199,3 @@ class AccountMoveLine(models.Model):
|
|||||||
rec_str = ', '.join([
|
rec_str = ', '.join([
|
||||||
'a%d' % pr.id for pr in line.matched_debit_ids + line.matched_credit_ids])
|
'a%d' % pr.id for pr in line.matched_debit_ids + line.matched_credit_ids])
|
||||||
line.reconcile_string = rec_str
|
line.reconcile_string = rec_str
|
||||||
|
|
||||||
def _get_computed_name(self):
|
|
||||||
# This is useful when you want to have the product code in a dedicated
|
|
||||||
# column in your customer invoice report
|
|
||||||
# The same ir.config_parameter is used in sale_usability,
|
|
||||||
# purchase_usability and account_usability
|
|
||||||
no_product_code_param = self.env['ir.config_parameter'].sudo().get_param(
|
|
||||||
'usability.line_name_no_product_code')
|
|
||||||
if no_product_code_param and no_product_code_param == 'True':
|
|
||||||
self = self.with_context(display_default_code=False)
|
|
||||||
return super()._get_computed_name()
|
|
||||||
|
|
||||||
def reconcile(self):
|
|
||||||
"""Explicit error message if unposted lines"""
|
|
||||||
unposted_ids = self.filtered(lambda l: l.move_id.state != "posted")
|
|
||||||
if unposted_ids:
|
|
||||||
m = _("Please post the following entries before reconciliation :")
|
|
||||||
sep = "\n - "
|
|
||||||
unpost = sep.join([am.display_name for am in unposted_ids.move_id])
|
|
||||||
raise UserError(m + sep + unpost)
|
|
||||||
|
|
||||||
return super().reconcile()
|
|
||||||
|
|||||||
@@ -1,45 +0,0 @@
|
|||||||
# Copyright 2015-2021 Akretion (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import api, fields, models, _
|
|
||||||
|
|
||||||
|
|
||||||
class ProductTemplate(models.Model):
|
|
||||||
_inherit = 'product.template'
|
|
||||||
|
|
||||||
# DON'T put store=True on those fields, because they are company dependent
|
|
||||||
sale_price_type = fields.Selection(
|
|
||||||
'_sale_purchase_price_type_sel', compute='_compute_sale_price_type',
|
|
||||||
string='Sale Price Type', compute_sudo=False, readonly=True)
|
|
||||||
purchase_price_type = fields.Selection(
|
|
||||||
'_sale_purchase_price_type_sel', compute='_compute_purchase_price_type',
|
|
||||||
string='Purchase Price Type', compute_sudo=False, readonly=True)
|
|
||||||
|
|
||||||
@api.model
|
|
||||||
def _sale_purchase_price_type_sel(self):
|
|
||||||
return [('incl', _('Tax incl.')), ('excl', _('Tax excl.'))]
|
|
||||||
|
|
||||||
@api.depends('taxes_id')
|
|
||||||
def _compute_sale_price_type(self):
|
|
||||||
for pt in self:
|
|
||||||
sale_price_type = 'incl'
|
|
||||||
if pt.taxes_id and all([not t.price_include for t in pt.taxes_id if t.amount_type == 'percent']):
|
|
||||||
sale_price_type = 'excl'
|
|
||||||
pt.sale_price_type = sale_price_type
|
|
||||||
|
|
||||||
@api.depends('supplier_taxes_id')
|
|
||||||
def _compute_purchase_price_type(self):
|
|
||||||
for pt in self:
|
|
||||||
purchase_price_type = 'incl'
|
|
||||||
if pt.supplier_taxes_id and all([not t.price_include for t in pt.supplier_taxes_id if t.amount_type == 'percent']):
|
|
||||||
purchase_price_type = 'excl'
|
|
||||||
pt.purchase_price_type = purchase_price_type
|
|
||||||
|
|
||||||
|
|
||||||
class ProductSupplierinfo(models.Model):
|
|
||||||
_inherit = 'product.supplierinfo'
|
|
||||||
|
|
||||||
# DON'T put store=True on those fields, because they are company dependent
|
|
||||||
purchase_price_type = fields.Selection(
|
|
||||||
related='product_tmpl_id.purchase_price_type', related_sudo=False)
|
|
||||||
@@ -1,21 +0,0 @@
|
|||||||
# Copyright 2021 Akretion France (https://akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class ResCompany(models.Model):
|
|
||||||
_inherit = 'res.company'
|
|
||||||
|
|
||||||
# There is a native field invoice_terms which is displayed on res.config.settings
|
|
||||||
# when the ir.config_parameter account.use_invoice_terms is True
|
|
||||||
# But there are several problems with this native field:
|
|
||||||
# - it is copied on the 'narration' field of account.move => we don't want that
|
|
||||||
# - the text block is very small on the form view of res.config.settings
|
|
||||||
# So I decided to have our own field "fixed_invoice_terms"
|
|
||||||
# The native field can still be used when you need to customise some
|
|
||||||
# terms and conditions on each invoice (not very common, but...)
|
|
||||||
# To underline this different with the native field, I prefix it with 'static_'
|
|
||||||
static_invoice_terms = fields.Text(
|
|
||||||
translate=True, string="Legal Terms on Invoice")
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2022 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<templates id="template" xml:space="preserve">
|
|
||||||
|
|
||||||
<!-- Requires https://github.com/odoo/odoo/pull/84180 -->
|
|
||||||
<t t-extend="ShowPaymentInfo" >
|
|
||||||
<t t-jquery="td:first" t-operation="after">
|
|
||||||
<td style="max-width: 25em;" id="outstanding-date">
|
|
||||||
<div class="oe_form_field" style="margin-right: 5px; text-overflow: ellipsis; overflow: hidden; white-space: nowrap;"><t t-esc="line.date"></t></div>
|
|
||||||
</td>
|
|
||||||
</t>
|
|
||||||
</t>
|
|
||||||
|
|
||||||
</templates>
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!--
|
<!--
|
||||||
Copyright 2015-2021 Akretion France (http://www.akretion.com/)
|
Copyright 2015-2020 Akretion France (http://www.akretion.com/)
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
-->
|
-->
|
||||||
@@ -8,18 +8,6 @@
|
|||||||
<odoo>
|
<odoo>
|
||||||
|
|
||||||
|
|
||||||
<record id="view_account_form" model="ir.ui.view">
|
|
||||||
<field name="name">account.account.form</field>
|
|
||||||
<field name="model">account.account</field>
|
|
||||||
<field name="inherit_id" ref="account.view_account_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="deprecated" position="before">
|
|
||||||
<field name="reconcile" attrs="{'invisible': ['|', ('internal_type','=','liquidity'), ('internal_group', '=', 'off_balance')]}"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="view_account_search" model="ir.ui.view">
|
<record id="view_account_search" model="ir.ui.view">
|
||||||
<field name="name">account.account.search</field>
|
<field name="name">account.account.search</field>
|
||||||
<field name="model">account.account</field>
|
<field name="model">account.account</field>
|
||||||
@@ -31,9 +19,6 @@
|
|||||||
<field name="name" position="after">
|
<field name="name" position="after">
|
||||||
<field name="code" filter_domain="[('code', '=like', str(self)+'%')]" string="Code"/>
|
<field name="code" filter_domain="[('code', '=like', str(self)+'%')]" string="Code"/>
|
||||||
</field>
|
</field>
|
||||||
<filter name="accounttype" position="after">
|
|
||||||
<filter name="group_groupby" string="Group" context="{'group_by': 'group_id'}"/>
|
|
||||||
</filter>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
|||||||
@@ -1,33 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2015-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="view_account_analytic_account_list" model="ir.ui.view">
|
|
||||||
<field name="model">account.analytic.account</field>
|
|
||||||
<field name="inherit_id" ref="analytic.view_account_analytic_account_list"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="code" position="after">
|
|
||||||
<field name="group_id" optional="show"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="view_account_analytic_account_search" model="ir.ui.view">
|
|
||||||
<field name="model">account.analytic.account</field>
|
|
||||||
<field name="inherit_id" ref="analytic.view_account_analytic_account_search"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<filter name="associatedpartner" position="before">
|
|
||||||
<filter name="group_groupby" string="Group" context="{'group_by': 'group_id'}"/>
|
|
||||||
</filter>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="account_analytic_group_tree_view" model="ir.ui.view">
|
|
||||||
<field name="model">account.analytic.group</field>
|
|
||||||
<field name="inherit_id" ref="analytic.account_analytic_group_tree_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="name" position="after">
|
|
||||||
<field name="parent_id" optional="show"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,32 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="view_account_group_form" model="ir.ui.view">
|
|
||||||
<field name="model">account.group</field>
|
|
||||||
<field name="inherit_id" ref="account.view_account_group_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="name" position="after">
|
|
||||||
<field name="parent_id"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="view_account_group_tree" model="ir.ui.view">
|
|
||||||
<field name="model">account.group</field>
|
|
||||||
<field name="inherit_id" ref="account.view_account_group_tree"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="name" position="after">
|
|
||||||
<field name="parent_id" optional="show"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -14,38 +14,26 @@
|
|||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<tree string="Invoices Analysis">
|
<tree string="Invoices Analysis">
|
||||||
<field name="move_id"/>
|
<field name="move_id"/>
|
||||||
<field name="journal_id" optional="hide"/>
|
|
||||||
<field name="company_id" optional="hide" groups="base.group_multi_company"/>
|
|
||||||
<field name="invoice_date"/>
|
<field name="invoice_date"/>
|
||||||
<field name="invoice_date_due"/>
|
<field name="invoice_date_due"/>
|
||||||
<field name="move_type"/>
|
<field name="move_type"/>
|
||||||
<field name="commercial_partner_id"/>
|
<field name="commercial_partner_id"/>
|
||||||
<field name="partner_id" optional="hide"/>
|
|
||||||
<field name="country_id" optional="hide"/>
|
|
||||||
<field name="industry_id" optional="hide"/>
|
|
||||||
<field name="invoice_user_id"/>
|
<field name="invoice_user_id"/>
|
||||||
<field name="fiscal_position_id" optional="hide"/>
|
|
||||||
<field name="product_id"/>
|
<field name="product_id"/>
|
||||||
<field name="product_categ_id" optional="hide"/>
|
|
||||||
<field name="account_id" optional="hide"/>
|
|
||||||
<field name="analytic_account_id" optional="hide" groups="analytic.group_analytic_accounting"/>
|
|
||||||
<field name="quantity" sum="1"/>
|
<field name="quantity" sum="1"/>
|
||||||
<field name="product_uom_id" groups="uom.group_uom"/>
|
<field name="product_uom_id" groups="uom.group_uom"/>
|
||||||
<field name="price_subtotal" sum="1"/>
|
<field name="price_subtotal" sum="1"/>
|
||||||
<field name="state"/>
|
<field name="state"/>
|
||||||
<field name="payment_state" optional="hide"/>
|
|
||||||
</tree>
|
</tree>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="account.action_account_invoice_report_all_supp" model="ir.actions.act_window">
|
<record id="account.action_account_invoice_report_all_supp" model="ir.actions.act_window">
|
||||||
<field name="context">{'search_default_current': 1, 'search_default_supplier': 1, 'group_by': ['invoice_date']}</field> <!-- Remove group_by_no_leaf, which breaks tree view -->
|
<field name="context">{'search_default_current': 1, 'search_default_supplier': 1, 'group_by': ['invoice_date']}</field> <!-- Remove group_by_no_leaf, which breaks tree view -->
|
||||||
<field name="view_mode">pivot,graph</field>
|
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="account.action_account_invoice_report_all" model="ir.actions.act_window">
|
<record id="account.action_account_invoice_report_all" model="ir.actions.act_window">
|
||||||
<field name="context">{'search_default_current': 1, 'search_default_customer': 1, 'group_by': ['invoice_date']}</field> <!-- Remove group_by_no_leaf, which breaks tree view -->
|
<field name="context">{'search_default_current': 1, 'search_default_customer': 1, 'group_by': ['invoice_date']}</field> <!-- Remove group_by_no_leaf, which breaks tree view -->
|
||||||
<field name="view_mode">pivot,graph</field>
|
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="view_account_invoice_report_pivot" model="ir.ui.view">
|
<record id="view_account_invoice_report_pivot" model="ir.ui.view">
|
||||||
|
|||||||
@@ -14,17 +14,6 @@
|
|||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<field name="bank_statements_source" position="after">
|
<field name="bank_statements_source" position="after">
|
||||||
<field name="hide_bank_statement_balance" groups="account.group_account_readonly"/>
|
<field name="hide_bank_statement_balance" groups="account.group_account_readonly"/>
|
||||||
<field name="account_type_current_liabilities_id" invisible="1"/>
|
|
||||||
<field name="account_type_current_assets_id" invisible="1"/>
|
|
||||||
</field>
|
|
||||||
<field name="suspense_account_id" position="attributes">
|
|
||||||
<attribute name="context">{'default_user_type_id': account_type_current_liabilities_id, 'default_reconcile': True}</attribute>
|
|
||||||
</field>
|
|
||||||
<field name="payment_debit_account_id" position="attributes">
|
|
||||||
<attribute name="context">{'default_user_type_id': account_type_current_assets_id, 'default_reconcile': True}</attribute>
|
|
||||||
</field>
|
|
||||||
<field name="payment_credit_account_id" position="attributes">
|
|
||||||
<attribute name="context">{'default_user_type_id': account_type_current_assets_id, 'default_reconcile': True}</attribute>
|
|
||||||
</field>
|
</field>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|||||||
@@ -18,20 +18,8 @@
|
|||||||
<field name="invoice_incoterm_id" position="attributes">
|
<field name="invoice_incoterm_id" position="attributes">
|
||||||
<attribute name="widget">selection</attribute>
|
<attribute name="widget">selection</attribute>
|
||||||
</field>
|
</field>
|
||||||
<button name="action_register_payment" position="attributes">
|
|
||||||
<attribute name="class">btn-default</attribute>
|
|
||||||
</button>
|
|
||||||
<button name="action_register_payment" position="before">
|
|
||||||
<button name="%(account.account_invoices)d" type="action" string="Print" attrs="{'invisible': [('move_type', 'not in', ('out_invoice', 'out_refund'))]}"/>
|
|
||||||
</button>
|
|
||||||
<button name="preview_invoice" position="attributes">
|
|
||||||
<attribute name="attrs">{'invisible': 1}</attribute>
|
|
||||||
</button>
|
|
||||||
<!-- move sent field and make it visible -->
|
<!-- move sent field and make it visible -->
|
||||||
<field name="is_move_sent" position="replace"/>
|
<field name="is_move_sent" position="replace"/>
|
||||||
<field name="invoice_origin" position="attributes">
|
|
||||||
<attribute name="invisible">0</attribute>
|
|
||||||
</field>
|
|
||||||
<field name="invoice_origin" position="after">
|
<field name="invoice_origin" position="after">
|
||||||
<field name="is_move_sent" attrs="{'invisible': [('move_type', 'not in', ('out_invoice', 'out_refund'))]}"/>
|
<field name="is_move_sent" attrs="{'invisible': [('move_type', 'not in', ('out_invoice', 'out_refund'))]}"/>
|
||||||
</field>
|
</field>
|
||||||
@@ -42,9 +30,6 @@
|
|||||||
<field name="matching_number" optional="hide"/>
|
<field name="matching_number" optional="hide"/>
|
||||||
<field name="reconcile_string" optional="show"/>
|
<field name="reconcile_string" optional="show"/>
|
||||||
</xpath>
|
</xpath>
|
||||||
<xpath expr="//field[@name='invoice_line_ids']/tree/field[@name='product_id']" position="after">
|
|
||||||
<field name="product_barcode" optional="hide"/>
|
|
||||||
</xpath>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
@@ -73,37 +58,6 @@
|
|||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="view_account_move_line_filter" model="ir.ui.view">
|
|
||||||
<field name="name">account_usability.account_move_line_search</field>
|
|
||||||
<field name="model">account.move.line</field>
|
|
||||||
<field name="inherit_id" ref="account.view_account_move_line_filter"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<filter name="unposted" position="before">
|
|
||||||
<filter name="current_year" string="Current Year" domain="[('date', '>=', (context_today().strftime('%Y-01-01'))), ('date', '<=', (context_today().strftime('%Y-12-31')))]"/>
|
|
||||||
<filter name="previous_year" string="Previous Year" domain="[('date', '>=', (context_today() + relativedelta(day=1, month=1, years=-1)).strftime('%Y-%m-%d')), ('date', '<=', (context_today() + relativedelta(day=31, month=12, years=-1)).strftime('%Y-%m-%d'))]"/>
|
|
||||||
<separator/>
|
|
||||||
</filter>
|
|
||||||
<field name="partner_id" position="after">
|
|
||||||
<field name="reconcile_string" />
|
|
||||||
<field name="debit" filter_domain="['|', ('debit', '=', self), ('credit', '=', self)]" string="Debit or Credit"/>
|
|
||||||
</field>
|
|
||||||
<filter name="unreconciled" position="before">
|
|
||||||
<filter name="reconciled" string="Fully Reconciled" domain="[('reconciled', '=', True)]"/>
|
|
||||||
</filter>
|
|
||||||
<filter name="unreconciled" position="attributes">
|
|
||||||
<attribute name="string">Unreconciled or Partially Reconciled</attribute>
|
|
||||||
<attribute name="domain">[('reconciled', '=', False), ('balance', '!=', 0), ('account_id.reconcile', '=', True)]</attribute>
|
|
||||||
</filter>
|
|
||||||
<!--
|
|
||||||
<field name="name" position="attributes">
|
|
||||||
<attribute name="string">Name or Reference</attribute>
|
|
||||||
</field> -->
|
|
||||||
<field name="partner_id" position="attributes">
|
|
||||||
<attribute name="domain">['|', ('parent_id', '=', False), ('is_company', '=', True)]</attribute>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="account.action_move_journal_line" model="ir.actions.act_window">
|
<record id="account.action_move_journal_line" model="ir.actions.act_window">
|
||||||
<field name="context">{'default_move_type': 'entry', 'view_no_maturity': True}</field>
|
<field name="context">{'default_move_type': 'entry', 'view_no_maturity': True}</field>
|
||||||
<!-- Remove 'search_default_misc_filter': 1 -->
|
<!-- Remove 'search_default_misc_filter': 1 -->
|
||||||
|
|||||||
@@ -1,72 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2017-2020 Akretion (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<!-- In the official account module, on product category and product template,
|
|
||||||
some fields/groups are on account.group_account_invoice, some on
|
|
||||||
account.group_account_user and some on account.group_account_manager
|
|
||||||
Here, we set all those fields on account.group_account_invoice
|
|
||||||
-->
|
|
||||||
|
|
||||||
<record id="product_template_form_view" model="ir.ui.view">
|
|
||||||
<field name="name">account_usability.product.template.form</field>
|
|
||||||
<field name="model">product.template</field>
|
|
||||||
<field name="priority">100</field> <!-- when you replace a field, it's always better to inherit at the end -->
|
|
||||||
<field name="inherit_id" ref="account.product_template_form_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="property_account_income_id" position="attributes">
|
|
||||||
<attribute name="groups">account.group_account_invoice</attribute>
|
|
||||||
</field>
|
|
||||||
<field name="property_account_expense_id" position="attributes">
|
|
||||||
<attribute name="groups">account.group_account_invoice</attribute>
|
|
||||||
</field>
|
|
||||||
<field name="list_price" position="replace">
|
|
||||||
<div name="list_price">
|
|
||||||
<field name="list_price" widget='monetary' options="{'currency_field': 'currency_id', 'field_digits': True}" class="oe_inline"/>
|
|
||||||
<label for="sale_price_type" string=" "/>
|
|
||||||
<field name="sale_price_type"/>
|
|
||||||
</div>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="view_category_property_form" model="ir.ui.view">
|
|
||||||
<field name="name">account_usability.product.category.form</field>
|
|
||||||
<field name="model">product.category</field>
|
|
||||||
<field name="inherit_id" ref="account.view_category_property_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<group name="account_property" position="attributes">
|
|
||||||
<attribute name="groups">account.group_account_invoice</attribute>
|
|
||||||
</group>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="product_supplierinfo_form_view" model="ir.ui.view">
|
|
||||||
<field name="name">account_usability.product.supplierinfo.form</field>
|
|
||||||
<field name="model">product.supplierinfo</field>
|
|
||||||
<field name="inherit_id" ref="product.product_supplierinfo_form_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="currency_id" position="after">
|
|
||||||
<field name="purchase_price_type"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="product_supplierinfo_tree_view" model="ir.ui.view">
|
|
||||||
<field name="name">account_usability.product.supplierinfo.tree</field>
|
|
||||||
<field name="model">product.supplierinfo</field>
|
|
||||||
<field name="inherit_id" ref="product.product_supplierinfo_tree_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="price" position="after">
|
|
||||||
<field name="purchase_price_type" string="Tax"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="view_company_form" model="ir.ui.view">
|
|
||||||
<field name="name">account_usability.res.company.form</field>
|
|
||||||
<field name="model">res.company</field>
|
|
||||||
<field name="inherit_id" ref="base.view_company_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<notebook position="inside">
|
|
||||||
<page string="Legal Terms" name="legal_terms">
|
|
||||||
<group string="Invoice Legal Terms" name="static_invoice_terms">
|
|
||||||
<field name="static_invoice_terms" nolabel="1"/>
|
|
||||||
</group>
|
|
||||||
</page>
|
|
||||||
</notebook>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -16,9 +16,6 @@
|
|||||||
<field name="property_account_position_id" position="attributes">
|
<field name="property_account_position_id" position="attributes">
|
||||||
<attribute name="widget">selection</attribute>
|
<attribute name="widget">selection</attribute>
|
||||||
</field>
|
</field>
|
||||||
<xpath expr="//field[@name='bank_ids']/tree/field[@name='acc_number']" position="after">
|
|
||||||
<field name="acc_type"/>
|
|
||||||
</xpath>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
|||||||
@@ -1,23 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<!-- When you change the date, it resets the amount via the onchange
|
|
||||||
So, in the view, the date should be BEFORE the amount -->
|
|
||||||
<record id="view_account_payment_register_form" model="ir.ui.view">
|
|
||||||
<field name="model">account.payment.register</field>
|
|
||||||
<field name="inherit_id" ref="account.view_account_payment_register_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<label for="amount" position="before">
|
|
||||||
<field name="payment_date" position="move"/>
|
|
||||||
</label>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,62 +0,0 @@
|
|||||||
# Copyright 2020-2021 Akretion France (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'Base Dynamic List',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Tools',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'Dynamic lists',
|
|
||||||
'description': """
|
|
||||||
Base Dynamic List
|
|
||||||
=================
|
|
||||||
|
|
||||||
Very often during an Odoo implementation, we need to add selection fields on a native objet, and we don't want to have a hard-coded selection list (fields.Selection), but a selection list that can be changed by users (Many2one field). For that, the developper needs to add a new object (with just a 'name' and 'sequence' field) with a form/tree view. The goal of this module is to speed-up this process by defining a dynamic list object that already has all the required views.
|
|
||||||
|
|
||||||
This module provides several ready-to-go objects:
|
|
||||||
|
|
||||||
* simple list : fields *name*, *sequence* and *active*
|
|
||||||
* translatable list : fields *name* with translate=True, *sequence* and *active*
|
|
||||||
* code list : fields *code* (unique), *name*, *sequence* and *active*
|
|
||||||
* translatable code list : fields *code* (unique), *name* with translate=True, *sequence* and *active*
|
|
||||||
|
|
||||||
These objects are readable by the employee group. The system group has full rights on it.
|
|
||||||
|
|
||||||
To use it, you need to do 2 or 3 things :
|
|
||||||
|
|
||||||
1) Add an entry in the domain field and the object you selected:
|
|
||||||
|
|
||||||
domain = fields.Selection(selection_add=[('risk.type', "Risk Type")], ondelete={"risk.type": "cascade"})
|
|
||||||
|
|
||||||
2) Add the many2one field on your object:
|
|
||||||
|
|
||||||
risk_type_id = fields.Many2one(
|
|
||||||
'dynamic.list', string="Risk Type",
|
|
||||||
ondelete='restrict', domain=[('domain', '=', 'risk.type')])
|
|
||||||
|
|
||||||
|
|
||||||
3) Optionally, you can add a dedicated action and a menu entry (otherwize, you can use the generic menu entry under *Settings > Technical > Dynamic Lists*:
|
|
||||||
|
|
||||||
<record id="dynamic_list_risk_type_action" model="ir.actions.act_window">
|
|
||||||
<field name="name">Risk Type</field>
|
|
||||||
<field name="res_model">dynamic.list</field>
|
|
||||||
<field name="view_mode">tree,form</field>
|
|
||||||
<field name="domain">[('domain', '=', 'risk.type')]</field>
|
|
||||||
<field name="context">{'default_domain': 'risk.type'}</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<menuitem id="dynamic_list_risk_type_menu" action="dynamic_list_risk_type_action"
|
|
||||||
parent="parent_menu_xmlid"/>
|
|
||||||
|
|
||||||
Limitation: when you want to have different access rights on these lists depending on the source object, you should prefer to use dedicated objects.
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': ['base'],
|
|
||||||
'data': [
|
|
||||||
'security/ir.model.access.csv',
|
|
||||||
'views/dynamic_list.xml',
|
|
||||||
],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import dynamic_list
|
|
||||||
@@ -1,115 +0,0 @@
|
|||||||
# Copyright 2020-2021 Akretion France (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import api, fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class DynamicList(models.Model):
|
|
||||||
_name = 'dynamic.list'
|
|
||||||
_description = 'Dynamic List (non translatable)'
|
|
||||||
_order = 'sequence, id'
|
|
||||||
|
|
||||||
name = fields.Char(required=True)
|
|
||||||
sequence = fields.Integer(default=10)
|
|
||||||
active = fields.Boolean(default=True)
|
|
||||||
domain = fields.Selection([], string='Domain', required=True, index=True)
|
|
||||||
|
|
||||||
_sql_constraint = [(
|
|
||||||
'domain_name_uniq',
|
|
||||||
'unique(domain, name)',
|
|
||||||
'This entry already exists!'
|
|
||||||
)]
|
|
||||||
|
|
||||||
|
|
||||||
class DynamicListTranslate(models.Model):
|
|
||||||
_name = 'dynamic.list.translate'
|
|
||||||
_description = 'Translatable Dynamic List'
|
|
||||||
_order = 'sequence, id'
|
|
||||||
|
|
||||||
name = fields.Char(translate=True, required=True)
|
|
||||||
sequence = fields.Integer(default=10)
|
|
||||||
active = fields.Boolean(default=True)
|
|
||||||
domain = fields.Selection([], string='Domain', required=True, index=True)
|
|
||||||
|
|
||||||
_sql_constraint = [(
|
|
||||||
'domain_name_uniq',
|
|
||||||
'unique(domain, name)',
|
|
||||||
'This entry already exists!'
|
|
||||||
)]
|
|
||||||
|
|
||||||
|
|
||||||
class DynamicListCode(models.Model):
|
|
||||||
_name = 'dynamic.list.code'
|
|
||||||
_description = 'Dynamic list with code'
|
|
||||||
_order = 'sequence, id'
|
|
||||||
|
|
||||||
code = fields.Char(required=True)
|
|
||||||
name = fields.Char(translate=True, required=True)
|
|
||||||
sequence = fields.Integer(default=10)
|
|
||||||
active = fields.Boolean(default=True)
|
|
||||||
domain = fields.Selection([], string='Domain', required=True, index=True)
|
|
||||||
|
|
||||||
_sql_constraint = [(
|
|
||||||
'domain_code_uniq',
|
|
||||||
'unique(domain, code)',
|
|
||||||
'This code already exists!'
|
|
||||||
)]
|
|
||||||
|
|
||||||
@api.depends('code', 'name')
|
|
||||||
def name_get(self):
|
|
||||||
res = []
|
|
||||||
for rec in self:
|
|
||||||
res.append((rec.id, '[%s] %s' % (rec.code, rec.name)))
|
|
||||||
return res
|
|
||||||
|
|
||||||
@api.model
|
|
||||||
def name_search(
|
|
||||||
self, name='', args=None, operator='ilike', limit=80):
|
|
||||||
if args is None:
|
|
||||||
args = []
|
|
||||||
if name and operator == 'ilike':
|
|
||||||
recs = self.search(
|
|
||||||
[('code', '=', name)] + args, limit=limit)
|
|
||||||
if recs:
|
|
||||||
return recs.name_get()
|
|
||||||
return super().name_search(
|
|
||||||
name=name, args=args, operator=operator, limit=limit)
|
|
||||||
|
|
||||||
|
|
||||||
class DynamicListCodeTranslate(models.Model):
|
|
||||||
_name = 'dynamic.list.code.translate'
|
|
||||||
_description = 'Translatable dynamic list with code'
|
|
||||||
_order = 'sequence, id'
|
|
||||||
|
|
||||||
code = fields.Char(required=True)
|
|
||||||
name = fields.Char(translate=True, required=True)
|
|
||||||
sequence = fields.Integer(default=10)
|
|
||||||
active = fields.Boolean(default=True)
|
|
||||||
domain = fields.Selection([], string='Domain', required=True, index=True)
|
|
||||||
|
|
||||||
_sql_constraint = [(
|
|
||||||
'domain_code_uniq',
|
|
||||||
'unique(domain, code)',
|
|
||||||
'This code already exists!'
|
|
||||||
)]
|
|
||||||
|
|
||||||
@api.depends('code', 'name')
|
|
||||||
def name_get(self):
|
|
||||||
res = []
|
|
||||||
for rec in self:
|
|
||||||
res.append((rec.id, '[%s] %s' % (rec.code, rec.name)))
|
|
||||||
return res
|
|
||||||
|
|
||||||
@api.model
|
|
||||||
def name_search(
|
|
||||||
self, name='', args=None, operator='ilike', limit=80):
|
|
||||||
if args is None:
|
|
||||||
args = []
|
|
||||||
if name and operator == 'ilike':
|
|
||||||
recs = self.search(
|
|
||||||
[('code', '=', name)] + args, limit=limit)
|
|
||||||
if recs:
|
|
||||||
return recs.name_get()
|
|
||||||
return super().name_search(
|
|
||||||
name=name, args=args, operator=operator, limit=limit)
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
|
||||||
access_dynamic_list_read,Read access on dynamic.list to employees,model_dynamic_list,base.group_user,1,0,0,0
|
|
||||||
access_dynamic_list_full,Full access to dynamic.list to System group,model_dynamic_list,base.group_system,1,1,1,1
|
|
||||||
access_dynamic_list_translate_read,Read access on dynamic.list.translate to employees,model_dynamic_list_translate,base.group_user,1,0,0,0
|
|
||||||
access_dynamic_list_translate_full,Full access to dynamic.list.translate to System group,model_dynamic_list_translate,base.group_system,1,1,1,1
|
|
||||||
access_dynamic_list_code_read,Read access on dynamic.list.code to employees,model_dynamic_list_code,base.group_user,1,0,0,0
|
|
||||||
access_dynamic_list_code_full,Full access to dynamic.list.code to System group,model_dynamic_list_code,base.group_system,1,1,1,1
|
|
||||||
access_dynamic_list_code_translate_read,Read access on dynamic.list.code.translate to employees,model_dynamic_list_code_translate,base.group_user,1,0,0,0
|
|
||||||
access_dynamic_list_code_translate_full,Full access to dynamic.list.code.translate to System group,model_dynamic_list_code_translate,base.group_system,1,1,1,1
|
|
||||||
|
@@ -1,220 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2020-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<menuitem id="dynamic_list_root_menu" name="Dynamic Lists" parent="base.menu_custom" sequence="100"/>
|
|
||||||
|
|
||||||
<record id="dynamic_list_form" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<form>
|
|
||||||
<sheet>
|
|
||||||
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
|
|
||||||
<group name="main">
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_main_view')"/>
|
|
||||||
<field name="active" invisible="1"/>
|
|
||||||
</group>
|
|
||||||
</sheet>
|
|
||||||
</form>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_tree" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<tree>
|
|
||||||
<field name="sequence" widget="handle"/>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_main_view')"/>
|
|
||||||
</tree>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_search" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<search>
|
|
||||||
<field name="name"/>
|
|
||||||
<separator/>
|
|
||||||
<filter string="Archived" name="inactive" domain="[('active', '=', False)]"/>
|
|
||||||
<group string="Group By" name="groupby">
|
|
||||||
<filter name="domain_groupby" string="Domain" context="{'group_by': 'domain'}"/>
|
|
||||||
</group>
|
|
||||||
</search>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_action" model="ir.actions.act_window">
|
|
||||||
<field name="name">Simple List</field>
|
|
||||||
<field name="res_model">dynamic.list</field>
|
|
||||||
<field name="view_mode">tree,form</field>
|
|
||||||
<field name="context">{'dynamic_list_main_view': True, 'search_default_domain_groupby': True}</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<menuitem id="dynamic_list_menu" action="dynamic_list_action" parent="dynamic_list_root_menu" sequence="10"/>
|
|
||||||
|
|
||||||
<record id="dynamic_list_translate_form" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.translate</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<form>
|
|
||||||
<sheet>
|
|
||||||
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
|
|
||||||
<group name="main">
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_translate_main_view')"/>
|
|
||||||
<field name="active" invisible="1"/>
|
|
||||||
</group>
|
|
||||||
</sheet>
|
|
||||||
</form>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_translate_tree" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.translate</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<tree>
|
|
||||||
<field name="sequence" widget="handle"/>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_translate_main_view')"/>
|
|
||||||
</tree>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_translate_search" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.translate</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<search>
|
|
||||||
<field name="name"/>
|
|
||||||
<separator/>
|
|
||||||
<filter string="Archived" name="inactive" domain="[('active', '=', False)]"/>
|
|
||||||
<group string="Group By" name="groupby">
|
|
||||||
<filter name="domain_groupby" string="Domain" context="{'group_by': 'domain'}"/>
|
|
||||||
</group>
|
|
||||||
</search>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_translate_action" model="ir.actions.act_window">
|
|
||||||
<field name="name">Translatable Simple List</field>
|
|
||||||
<field name="res_model">dynamic.list.translate</field>
|
|
||||||
<field name="view_mode">tree,form</field>
|
|
||||||
<field name="context">{'dynamic_list_translate_main_view': True, 'search_default_domain_groupby': True}</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<menuitem id="dynamic_list_translate_menu" action="dynamic_list_translate_action" parent="dynamic_list_root_menu" sequence="20"/>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_form" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.code</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<form>
|
|
||||||
<sheet>
|
|
||||||
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
|
|
||||||
<group name="main">
|
|
||||||
<field name="code"/>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_code_main_view')"/>
|
|
||||||
<field name="active" invisible="1"/>
|
|
||||||
</group>
|
|
||||||
</sheet>
|
|
||||||
</form>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_tree" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.code</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<tree>
|
|
||||||
<field name="sequence" widget="handle"/>
|
|
||||||
<field name="code"/>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_code_main_view')"/>
|
|
||||||
</tree>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_search" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.code</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<search>
|
|
||||||
<field name="name" string="Name or Code" filter_domain="['|', ('name', 'ilike', self), ('code', 'ilike', self)]"/>
|
|
||||||
<separator/>
|
|
||||||
<filter string="Archived" name="inactive" domain="[('active', '=', False)]"/>
|
|
||||||
<field name="code"/>
|
|
||||||
<group string="Group By" name="groupby">
|
|
||||||
<filter name="domain_groupby" string="Domain" context="{'group_by': 'domain'}"/>
|
|
||||||
</group>
|
|
||||||
</search>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_action" model="ir.actions.act_window">
|
|
||||||
<field name="name">Code List</field>
|
|
||||||
<field name="res_model">dynamic.list.code</field>
|
|
||||||
<field name="view_mode">tree,form</field>
|
|
||||||
<field name="context">{'dynamic_list_code_main_view': True, 'search_default_domain_groupby': True}</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<menuitem id="dynamic_list_code_menu" action="dynamic_list_code_action" parent="dynamic_list_root_menu" sequence="30"/>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_translate_form" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.code.translate</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<form>
|
|
||||||
<sheet>
|
|
||||||
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
|
|
||||||
<group name="main">
|
|
||||||
<field name="code"/>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_code_translate_main_view')"/>
|
|
||||||
<field name="active" invisible="1"/>
|
|
||||||
</group>
|
|
||||||
</sheet>
|
|
||||||
</form>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_translate_tree" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.code.translate</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<tree>
|
|
||||||
<field name="sequence" widget="handle"/>
|
|
||||||
<field name="code"/>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="domain" invisible="not context.get('dynamic_list_code_translate_main_view')"/>
|
|
||||||
</tree>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_translate_search" model="ir.ui.view">
|
|
||||||
<field name="model">dynamic.list.code.translate</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<search>
|
|
||||||
<field name="name" string="Name or Code" filter_domain="['|', ('name', 'ilike', self), ('code', 'ilike', self)]"/>
|
|
||||||
<field name="code"/>
|
|
||||||
<separator/>
|
|
||||||
<filter string="Archived" name="inactive" domain="[('active', '=', False)]"/>
|
|
||||||
<group string="Group By" name="groupby">
|
|
||||||
<filter name="domain_groupby" string="Domain" context="{'group_by': 'domain'}"/>
|
|
||||||
</group>
|
|
||||||
</search>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="dynamic_list_code_translate_action" model="ir.actions.act_window">
|
|
||||||
<field name="name">Translatable Code List</field>
|
|
||||||
<field name="res_model">dynamic.list.code.translate</field>
|
|
||||||
<field name="view_mode">tree,form</field>
|
|
||||||
<field name="context">{'dynamic_list_code_translate_main_view': True, 'search_default_domain_groupby': True}</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<menuitem id="dynamic_list_code_translate_menu" action="dynamic_list_code_translate_action" parent="dynamic_list_root_menu" sequence="40"/>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import models
|
|
||||||
@@ -1,21 +0,0 @@
|
|||||||
# Copyright 2017-2022 Akretion (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'Mail Sender Bcc',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Mail',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': "Always send a copy of the mail to the sender",
|
|
||||||
'description': """
|
|
||||||
Mail Sender Bcc
|
|
||||||
===============
|
|
||||||
|
|
||||||
With this module, when Odoo sends an outgoing email, it adds the sender as Bcc (blind copy) of the email.
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'https://github.com/akretion/odoo-usability',
|
|
||||||
'depends': ['base'],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import ir_mail_server
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
# Copyright 2017-2022 Akretion France
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import models
|
|
||||||
|
|
||||||
|
|
||||||
class IrMailServer(models.Model):
|
|
||||||
_inherit = 'ir.mail_server'
|
|
||||||
|
|
||||||
def build_email(
|
|
||||||
self, email_from, email_to, subject, body, email_cc=None,
|
|
||||||
email_bcc=None, reply_to=False, attachments=None,
|
|
||||||
message_id=None, references=None, object_id=False,
|
|
||||||
subtype='plain', headers=None,
|
|
||||||
body_alternative=None, subtype_alternative='plain'):
|
|
||||||
if email_from:
|
|
||||||
if email_bcc is None:
|
|
||||||
email_bcc = [email_from]
|
|
||||||
elif isinstance(email_bcc, list) and email_from not in email_bcc:
|
|
||||||
email_bcc.append(email_from)
|
|
||||||
return super().build_email(
|
|
||||||
email_from, email_to, subject, body, email_cc=email_cc,
|
|
||||||
email_bcc=email_bcc, reply_to=reply_to, attachments=attachments,
|
|
||||||
message_id=message_id, references=references, object_id=object_id,
|
|
||||||
subtype=subtype, headers=headers,
|
|
||||||
body_alternative=body_alternative, subtype_alternative=subtype_alternative)
|
|
||||||
@@ -4,11 +4,11 @@
|
|||||||
#
|
#
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Odoo Server 14.0\n"
|
"Project-Id-Version: Odoo Server 10.0\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2021-10-29 21:12+0000\n"
|
"POT-Creation-Date: 2020-01-27 18:03+0000\n"
|
||||||
"PO-Revision-Date: 2021-10-29 21:12+0000\n"
|
"PO-Revision-Date: 2020-01-27 18:03+0000\n"
|
||||||
"Last-Translator: \n"
|
"Last-Translator: <>\n"
|
||||||
"Language-Team: \n"
|
"Language-Team: \n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
@@ -16,120 +16,92 @@ msgstr ""
|
|||||||
"Plural-Forms: \n"
|
"Plural-Forms: \n"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_create_uid
|
||||||
msgid "Contact"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__create_uid
|
|
||||||
msgid "Created by"
|
msgid "Created by"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__create_date
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_create_date
|
||||||
msgid "Created on"
|
msgid "Created on"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__display_name
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_display_name
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__display_name
|
|
||||||
msgid "Display Name"
|
msgid "Display Name"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__email
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_email
|
||||||
msgid "E-Mail"
|
msgid "E-Mail"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:61
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "E-mail field must be empty when type is Primary/Secondary Phone, Primary/Secondary Mobile or Primary/Secondary Fax."
|
||||||
"E-mail field must be empty when type is Primary/Secondary Phone, "
|
|
||||||
"Primary/Secondary Mobile or Primary/Secondary Fax."
|
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:51
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "E-mail field must have a value when type is Primary E-mail or Secondary E-mail."
|
||||||
"E-mail field must have a value when type is Primary E-mail or Secondary "
|
|
||||||
"E-mail."
|
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__email
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_id
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__email
|
|
||||||
msgid "Email"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__id
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__id
|
|
||||||
msgid "ID"
|
msgid "ID"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner____last_update
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone___last_update
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone____last_update
|
|
||||||
msgid "Last Modified on"
|
msgid "Last Modified on"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__write_uid
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_write_uid
|
||||||
msgid "Last Updated by"
|
msgid "Last Updated by"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__write_date
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_write_date
|
||||||
msgid "Last Updated on"
|
msgid "Last Updated on"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__mobile
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_note
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__mobile
|
|
||||||
msgid "Mobile"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner_phone
|
|
||||||
msgid "Multiple emails and phones for partners"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__note
|
|
||||||
msgid "Note"
|
msgid "Note"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__phone
|
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__phone
|
msgid "Partner"
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__phone
|
msgstr ""
|
||||||
|
|
||||||
|
#. module: base_partner_one2many_phone
|
||||||
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_phone
|
||||||
msgid "Phone"
|
msgid "Phone"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_form
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:54
|
||||||
msgid "Phone and E-mail"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "Phone field must be empty when type is Primary E-mail or Secondary E-mail."
|
||||||
"Phone field must be empty when type is Primary E-mail or Secondary E-mail."
|
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:58
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "Phone field must have a value when type is Primary/Secondary Phone, Primary/Secondary Mobile or Primary/Secondary Fax."
|
||||||
"Phone field must have a value when type is Primary/Secondary Phone, "
|
|
||||||
"Primary/Secondary Mobile or Primary/Secondary Fax."
|
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_tree
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_ids
|
||||||
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users_phone_ids
|
||||||
|
msgid "Phones"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. module: base_partner_one2many_phone
|
||||||
|
#: model:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_tree
|
||||||
msgid "Phones and E-mail"
|
msgid "Phones and E-mail"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
@@ -140,63 +112,63 @@ msgid "Phones/E-mails"
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__phone_ids
|
#: selection:res.partner.phone,type:0
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__phone_ids
|
|
||||||
msgid "Phones/Emails"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__1_email_primary
|
|
||||||
msgid "Primary E-mail"
|
msgid "Primary E-mail"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__7_fax_primary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Primary Fax"
|
msgid "Primary Fax"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__5_mobile_primary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Primary Mobile"
|
msgid "Primary Mobile"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__3_phone_primary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Primary Phone"
|
msgid "Primary Phone"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__partner_id
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_partner_id
|
||||||
msgid "Related Partner"
|
msgid "Related Partner"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
#: model:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
||||||
msgid "Search Phones/E-mail"
|
msgid "Search Phones/E-mail"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__2_email_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary E-mail"
|
msgid "Secondary E-mail"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__8_fax_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary Fax"
|
msgid "Secondary Fax"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__6_mobile_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary Mobile"
|
msgid "Secondary Mobile"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__4_phone_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary Phone"
|
msgid "Secondary Phone"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__type
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_type
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
#: model:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
||||||
msgid "Type"
|
msgid "Type"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
#. module: base_partner_one2many_phone
|
||||||
|
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner_phone
|
||||||
|
msgid "res.partner.phone"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
|||||||
@@ -4,11 +4,11 @@
|
|||||||
#
|
#
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Odoo Server 14.0\n"
|
"Project-Id-Version: Odoo Server 10.0\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2021-10-29 21:12+0000\n"
|
"POT-Creation-Date: 2020-01-27 17:56+0000\n"
|
||||||
"PO-Revision-Date: 2021-10-29 21:12+0000\n"
|
"PO-Revision-Date: 2020-01-27 17:56+0000\n"
|
||||||
"Last-Translator: \n"
|
"Last-Translator: <>\n"
|
||||||
"Language-Team: \n"
|
"Language-Team: \n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
@@ -16,187 +16,159 @@ msgstr ""
|
|||||||
"Plural-Forms: \n"
|
"Plural-Forms: \n"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_create_uid
|
||||||
msgid "Contact"
|
|
||||||
msgstr "Contact"
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__create_uid
|
|
||||||
msgid "Created by"
|
msgid "Created by"
|
||||||
msgstr "Créé par"
|
msgstr "Créé par"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__create_date
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_create_date
|
||||||
msgid "Created on"
|
msgid "Created on"
|
||||||
msgstr "Créé le"
|
msgstr "Créé le"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__display_name
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_display_name
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__display_name
|
|
||||||
msgid "Display Name"
|
msgid "Display Name"
|
||||||
msgstr "Nom affiché"
|
msgstr "Nom à afficher"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__email
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_email
|
||||||
msgid "E-Mail"
|
msgid "E-Mail"
|
||||||
msgstr "E-Mail"
|
msgstr "Courriel"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:61
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "E-mail field must be empty when type is Primary/Secondary Phone, Primary/Secondary Mobile or Primary/Secondary Fax."
|
||||||
"E-mail field must be empty when type is Primary/Secondary Phone, "
|
msgstr "Le champ courriel doit être vide quand le type est tél. primaire/secondaire, portable primaire/secondaire ou fax primaire/secondaire."
|
||||||
"Primary/Secondary Mobile or Primary/Secondary Fax."
|
|
||||||
msgstr "Le champ E-mail doit être vide quand le type est Tél. principal/secondaire, Portable principal/secondaire ou Fax principal/secondaire."
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:51
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "E-mail field must have a value when type is Primary E-mail or Secondary E-mail."
|
||||||
"E-mail field must have a value when type is Primary E-mail or Secondary "
|
msgstr "Le champ courriel doit être renseigné quand le type est courriel primaire ou courriel secondaire."
|
||||||
"E-mail."
|
|
||||||
msgstr "Le champ E-mail doit avoir une valeur quand le type est E-mail principal ou secondaire."
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__email
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_id
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__email
|
|
||||||
msgid "Email"
|
|
||||||
msgstr "E-mail"
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__id
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__id
|
|
||||||
msgid "ID"
|
msgid "ID"
|
||||||
msgstr ""
|
msgstr "ID"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner____last_update
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone___last_update
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone____last_update
|
|
||||||
msgid "Last Modified on"
|
msgid "Last Modified on"
|
||||||
msgstr "Dernière modification le"
|
msgstr "Dernière modification le"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__write_uid
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_write_uid
|
||||||
msgid "Last Updated by"
|
msgid "Last Updated by"
|
||||||
msgstr "Dernière modification par"
|
msgstr "Dernière mise à jour par"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__write_date
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_write_date
|
||||||
msgid "Last Updated on"
|
msgid "Last Updated on"
|
||||||
msgstr "Dernière modification le"
|
msgstr "Dernière mise à jour le"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__mobile
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_note
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__mobile
|
|
||||||
msgid "Mobile"
|
|
||||||
msgstr "Portable"
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner_phone
|
|
||||||
msgid "Multiple emails and phones for partners"
|
|
||||||
msgstr "Multiples e-mails et téléphones pour les partenaires"
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__note
|
|
||||||
msgid "Note"
|
msgid "Note"
|
||||||
msgstr "Note"
|
msgstr "Note"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__phone
|
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__phone
|
msgid "Partner"
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__phone
|
msgstr "Partenaire"
|
||||||
|
|
||||||
|
#. module: base_partner_one2many_phone
|
||||||
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_phone
|
||||||
msgid "Phone"
|
msgid "Phone"
|
||||||
msgstr "Tél."
|
msgstr "Téléphone"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_form
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:54
|
||||||
msgid "Phone and E-mail"
|
|
||||||
msgstr "Tél. et E-mail"
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "Phone field must be empty when type is Primary E-mail or Secondary E-mail."
|
||||||
"Phone field must be empty when type is Primary E-mail or Secondary E-mail."
|
msgstr "Le champ téléphone doit être vide quand le type est courriel primaire ou courriel secondaire."
|
||||||
msgstr "Le champ Tél. doit être vide quand le type est E-mail principal ou E-mail secondaire."
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: code:addons/base_partner_one2many_phone/partner_phone.py:0
|
#: code:addons/base_partner_one2many_phone/partner_phone.py:58
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid ""
|
msgid "Phone field must have a value when type is Primary/Secondary Phone, Primary/Secondary Mobile or Primary/Secondary Fax."
|
||||||
"Phone field must have a value when type is Primary/Secondary Phone, "
|
msgstr "Le champ téléphone doit être renseigné quand le type est tél. primaire/secondaire, portable primaire/secondaire ou fax primaire/secondaire.."
|
||||||
"Primary/Secondary Mobile or Primary/Secondary Fax."
|
|
||||||
msgstr "Le champ Tél. doit avoir une valeur quand le type est Tél. principal/secondaire, Portable principal/secondaire ou Fax principal/secondaire."
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_tree
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_ids
|
||||||
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users_phone_ids
|
||||||
|
msgid "Phones"
|
||||||
|
msgstr "Téléphones"
|
||||||
|
|
||||||
|
#. module: base_partner_one2many_phone
|
||||||
|
#: model:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_tree
|
||||||
msgid "Phones and E-mail"
|
msgid "Phones and E-mail"
|
||||||
msgstr "Téls et E-mail"
|
msgstr "Téls et courriels"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.actions.act_window,name:base_partner_one2many_phone.res_partner_phone_action
|
#: model:ir.actions.act_window,name:base_partner_one2many_phone.res_partner_phone_action
|
||||||
#: model:ir.ui.menu,name:base_partner_one2many_phone.res_partner_phone_menu
|
#: model:ir.ui.menu,name:base_partner_one2many_phone.res_partner_phone_menu
|
||||||
msgid "Phones/E-mails"
|
msgid "Phones/E-mails"
|
||||||
msgstr "Téls/E-mails"
|
msgstr "Téls/Courriels"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner__phone_ids
|
#: selection:res.partner.phone,type:0
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_users__phone_ids
|
|
||||||
msgid "Phones/Emails"
|
|
||||||
msgstr "Téls/E-mails"
|
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__1_email_primary
|
|
||||||
msgid "Primary E-mail"
|
msgid "Primary E-mail"
|
||||||
msgstr "E-mail principal"
|
msgstr "Courriel principal"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__7_fax_primary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Primary Fax"
|
msgid "Primary Fax"
|
||||||
msgstr "Fax principal"
|
msgstr "Fax principal"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__5_mobile_primary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Primary Mobile"
|
msgid "Primary Mobile"
|
||||||
msgstr "Portable principal"
|
msgstr "Portable principal"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__3_phone_primary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Primary Phone"
|
msgid "Primary Phone"
|
||||||
msgstr "Tél. principal"
|
msgstr "Tél principal"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__partner_id
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_partner_id
|
||||||
msgid "Related Partner"
|
msgid "Related Partner"
|
||||||
msgstr "Partenaire associé"
|
msgstr "Partenaire associé"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
#: model:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
||||||
msgid "Search Phones/E-mail"
|
msgid "Search Phones/E-mail"
|
||||||
msgstr ""
|
msgstr "Search Phones/E-mail"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__2_email_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary E-mail"
|
msgid "Secondary E-mail"
|
||||||
msgstr "E-mail secondaire"
|
msgstr "Courriel secondaire"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__8_fax_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary Fax"
|
msgid "Secondary Fax"
|
||||||
msgstr "Fax secondaire"
|
msgstr "Fax secondaire"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__6_mobile_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary Mobile"
|
msgid "Secondary Mobile"
|
||||||
msgstr "Portable secondaire"
|
msgstr "Portable secondaire"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields.selection,name:base_partner_one2many_phone.selection__res_partner_phone__type__4_phone_secondary
|
#: selection:res.partner.phone,type:0
|
||||||
msgid "Secondary Phone"
|
msgid "Secondary Phone"
|
||||||
msgstr "Tél. secondaire"
|
msgstr "Tél. secondaire"
|
||||||
|
|
||||||
#. module: base_partner_one2many_phone
|
#. module: base_partner_one2many_phone
|
||||||
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone__type
|
#: model:ir.model.fields,field_description:base_partner_one2many_phone.field_res_partner_phone_type
|
||||||
#: model_terms:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
#: model:ir.ui.view,arch_db:base_partner_one2many_phone.res_partner_phone_search
|
||||||
msgid "Type"
|
msgid "Type"
|
||||||
msgstr "Type"
|
msgstr "Type"
|
||||||
|
|
||||||
|
#. module: base_partner_one2many_phone
|
||||||
|
#: model:ir.model,name:base_partner_one2many_phone.model_res_partner_phone
|
||||||
|
msgid "res.partner.phone"
|
||||||
|
msgstr "res.partner.phone"
|
||||||
|
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ class ResPartnerPhone(models.Model):
|
|||||||
@api.onchange('phone', 'partner_id')
|
@api.onchange('phone', 'partner_id')
|
||||||
def _onchange_phone_validation(self):
|
def _onchange_phone_validation(self):
|
||||||
if self.phone:
|
if self.phone:
|
||||||
self.phone = self.phone_format(self.phone, country=self.partner_id.country_id)
|
self.phone = self.phone_format(self.phone)
|
||||||
|
|
||||||
@api.constrains('type', 'phone', 'email')
|
@api.constrains('type', 'phone', 'email')
|
||||||
def _check_partner_phone(self):
|
def _check_partner_phone(self):
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
<field name="name">res.partner.phone.tree</field>
|
<field name="name">res.partner.phone.tree</field>
|
||||||
<field name="model">res.partner.phone</field>
|
<field name="model">res.partner.phone</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<tree editable="bottom">
|
<tree string="Phones and E-mail" editable="bottom">
|
||||||
<field name="partner_id" invisible="not context.get('partner_phone_main_view')"/>
|
<field name="partner_id" invisible="not context.get('partner_phone_main_view')"/>
|
||||||
<field name="type"/>
|
<field name="type"/>
|
||||||
<field name="phone" widget="phone" options="{'enable_sms': false}" attrs="{'required': [('type', 'not in', ('1_email_primary', '2_email_secondary'))], 'readonly': [('type', 'in', ('1_email_primary', '2_email_secondary'))]}"/>
|
<field name="phone" widget="phone" options="{'enable_sms': false}" attrs="{'required': [('type', 'not in', ('1_email_primary', '2_email_secondary'))], 'readonly': [('type', 'in', ('1_email_primary', '2_email_secondary'))]}"/>
|
||||||
@@ -28,7 +28,7 @@
|
|||||||
<field name="name">res.partner.phone.form</field>
|
<field name="name">res.partner.phone.form</field>
|
||||||
<field name="model">res.partner.phone</field>
|
<field name="model">res.partner.phone</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<form>
|
<form string="Phone and E-mail">
|
||||||
<group name="main">
|
<group name="main">
|
||||||
<field name="partner_id" invisible="not context.get('partner_phone_main_view')"/>
|
<field name="partner_id" invisible="not context.get('partner_phone_main_view')"/>
|
||||||
<field name="type"/>
|
<field name="type"/>
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
<field name="name">res.partner.phone.search</field>
|
<field name="name">res.partner.phone.search</field>
|
||||||
<field name="model">res.partner.phone</field>
|
<field name="model">res.partner.phone</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<search>
|
<search string="Search Phones/E-mail">
|
||||||
<field name="phone" />
|
<field name="phone" />
|
||||||
<field name="email" />
|
<field name="email" />
|
||||||
<group name="groupby">
|
<group name="groupby">
|
||||||
@@ -72,9 +72,7 @@
|
|||||||
<record id="view_partner_form" model="ir.ui.view">
|
<record id="view_partner_form" model="ir.ui.view">
|
||||||
<field name="name">add.phone_ids.on.partner.form</field>
|
<field name="name">add.phone_ids.on.partner.form</field>
|
||||||
<field name="model">res.partner</field>
|
<field name="model">res.partner</field>
|
||||||
<field name="inherit_id" ref="mail.res_partner_view_form_inherit_mail"/>
|
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||||
<!-- This module depends on contacts which depends on mail
|
|
||||||
and the mail module replaces the email field -->
|
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<field name="phone" position="after">
|
<field name="phone" position="after">
|
||||||
<field name="phone_ids" nolabel="1" colspan="2"/>
|
<field name="phone_ids" nolabel="1" colspan="2"/>
|
||||||
@@ -85,12 +83,9 @@
|
|||||||
<field name="mobile" position="attributes">
|
<field name="mobile" position="attributes">
|
||||||
<attribute name="invisible">1</attribute>
|
<attribute name="invisible">1</attribute>
|
||||||
</field>
|
</field>
|
||||||
<label for="email" position="attributes">
|
<field name="email" position="attributes">
|
||||||
<attribute name="invisible">1</attribute>
|
<attribute name="invisible">1</attribute>
|
||||||
</label>
|
</field>
|
||||||
<xpath expr="//field[@name='email']/.." position="attributes">
|
|
||||||
<attribute name="invisible">1</attribute>
|
|
||||||
</xpath>
|
|
||||||
<!-- I can't display phone_ids in the Contacts
|
<!-- I can't display phone_ids in the Contacts
|
||||||
because there is a very strange thing in the web client: if
|
because there is a very strange thing in the web client: if
|
||||||
you have a res.partner.phone on one of the fields,
|
you have a res.partner.phone on one of the fields,
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
from . import models
|
from . import partner
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
# Copyright 2017-2021 Akretion (http://www.akretion.com)
|
# Copyright 2017-2019 Akretion (http://www.akretion.com)
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
{
|
{
|
||||||
'name': 'Base Partner Reference',
|
'name': 'Base Partner Reference',
|
||||||
'version': '14.0.1.0.0',
|
'version': '12.0.1.0.0',
|
||||||
'category': 'Partner',
|
'category': 'Partner',
|
||||||
'license': 'AGPL-3',
|
'license': 'AGPL-3',
|
||||||
'summary': "Improve usage of partner's Internal Reference",
|
'summary': "Improve usage of partner's Internal Reference",
|
||||||
@@ -21,6 +21,6 @@ Base Partner Reference
|
|||||||
'author': 'Akretion',
|
'author': 'Akretion',
|
||||||
'website': 'http://www.akretion.com',
|
'website': 'http://www.akretion.com',
|
||||||
'depends': ['base'],
|
'depends': ['base'],
|
||||||
'data': ['views/res_partner.xml'],
|
'data': ['partner_view.xml'],
|
||||||
'installable': True,
|
'installable': False,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
from . import res_partner
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
# Copyright 2017-2021 Akretion
|
# Copyright 2017-2019 Akretion
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
@@ -18,9 +18,9 @@ class ResPartner(models.Model):
|
|||||||
)]
|
)]
|
||||||
|
|
||||||
# add 'ref' in depends
|
# add 'ref' in depends
|
||||||
@api.depends('ref', 'invalidate_display_name')
|
@api.depends('is_company', 'name', 'parent_id.name', 'type', 'company_name', 'ref', 'invalidate_display_name')
|
||||||
def _compute_display_name(self):
|
def _compute_display_name(self):
|
||||||
super()._compute_display_name()
|
super(ResPartner, self)._compute_display_name()
|
||||||
|
|
||||||
def _get_name(self):
|
def _get_name(self):
|
||||||
partner = self
|
partner = self
|
||||||
@@ -28,17 +28,16 @@ class ResPartner(models.Model):
|
|||||||
|
|
||||||
# START modif of native method
|
# START modif of native method
|
||||||
if partner.ref:
|
if partner.ref:
|
||||||
name = "[%s] %s" % (partner.ref, name)
|
name = u"[%s] %s" % (partner.ref, name)
|
||||||
# END modif of native method
|
# END modif of native method
|
||||||
if partner.company_name or partner.parent_id:
|
if partner.company_name or partner.parent_id:
|
||||||
if not name and partner.type in ['invoice', 'delivery', 'other']:
|
if not name and partner.type in ['invoice', 'delivery', 'other']:
|
||||||
name = dict(self.fields_get(
|
name = dict(self.fields_get(['type'])['type']['selection'])[partner.type]
|
||||||
['type'])['type']['selection'])[partner.type]
|
|
||||||
if not partner.is_company:
|
if not partner.is_company:
|
||||||
# START modif of native name_get() method
|
# START modif of native name_get() method
|
||||||
company_name = partner.commercial_company_name or partner.parent_id.name
|
company_name = partner.commercial_company_name or partner.parent_id.name
|
||||||
if partner.parent_id.ref:
|
if partner.parent_id.ref:
|
||||||
company_name = "[%s] %s" % (partner.parent_id.ref, company_name)
|
company_name = u"[%s] %s" % (partner.parent_id.ref, company_name)
|
||||||
name = "%s, %s" % (company_name, name)
|
name = "%s, %s" % (company_name, name)
|
||||||
# END modif of native name_get() method
|
# END modif of native name_get() method
|
||||||
if self._context.get('show_address_only'):
|
if self._context.get('show_address_only'):
|
||||||
@@ -48,8 +47,7 @@ class ResPartner(models.Model):
|
|||||||
name = name.replace('\n\n', '\n')
|
name = name.replace('\n\n', '\n')
|
||||||
name = name.replace('\n\n', '\n')
|
name = name.replace('\n\n', '\n')
|
||||||
if self._context.get('address_inline'):
|
if self._context.get('address_inline'):
|
||||||
splitted_names = name.split("\n")
|
name = name.replace('\n', ', ')
|
||||||
name = ", ".join([n for n in splitted_names if n.strip()])
|
|
||||||
if self._context.get('show_email') and partner.email:
|
if self._context.get('show_email') and partner.email:
|
||||||
name = "%s <%s>" % (name, partner.email)
|
name = "%s <%s>" % (name, partner.email)
|
||||||
if self._context.get('html_format'):
|
if self._context.get('html_format'):
|
||||||
@@ -57,14 +55,3 @@ class ResPartner(models.Model):
|
|||||||
if self._context.get('show_vat') and partner.vat:
|
if self._context.get('show_vat') and partner.vat:
|
||||||
name = "%s ‒ %s" % (name, partner.vat)
|
name = "%s ‒ %s" % (name, partner.vat)
|
||||||
return name
|
return name
|
||||||
|
|
||||||
@api.model
|
|
||||||
def name_search(self, name='', args=None, operator='ilike', limit=100):
|
|
||||||
if args is None:
|
|
||||||
args = []
|
|
||||||
if name and operator == 'ilike':
|
|
||||||
recs = self.search([('ref', '=', name)] + args, limit=limit)
|
|
||||||
if recs:
|
|
||||||
rec_childs = self.search([('id', 'child_of', recs.ids)])
|
|
||||||
return rec_childs.name_get()
|
|
||||||
return super().name_search(name=name, args=args, operator=operator, limit=limit)
|
|
||||||
@@ -11,34 +11,29 @@
|
|||||||
<field name="name">Move ref in partner form to make it more visible</field>
|
<field name="name">Move ref in partner form to make it more visible</field>
|
||||||
<field name="model">res.partner</field>
|
<field name="model">res.partner</field>
|
||||||
<field name="inherit_id" ref="base.view_partner_form"/>
|
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||||
<field name="priority">1000</field> <!-- inherit after l10n_fr -->
|
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<field name="type" position="after">
|
<field name="type" position="after">
|
||||||
<field name="ref"/>
|
<field name="ref"/>
|
||||||
</field>
|
</field>
|
||||||
<xpath expr="//page[@name='sales_purchases']//field[@name='ref']" position="attributes">
|
<xpath expr="//page[@name='sales_purchases']//field[@name='ref']" position="replace"/>
|
||||||
<attribute name="invisible">1</attribute>
|
|
||||||
</xpath>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<!-- show name and ref in separate columns -->
|
|
||||||
<!-- ref is added in tree view by base_usability with optional="hide"
|
|
||||||
<record id="view_partner_tree" model="ir.ui.view">
|
<record id="view_partner_tree" model="ir.ui.view">
|
||||||
<field name="name">Add ref in partner tree view</field>
|
<field name="name">Add ref in partner tree view</field>
|
||||||
<field name="model">res.partner</field>
|
<field name="model">res.partner</field>
|
||||||
<field name="inherit_id" ref="base.view_partner_tree"/>
|
<field name="inherit_id" ref="base.view_partner_tree"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
|
<!-- show name and ref in separate columns -->
|
||||||
<field name="display_name" position="after">
|
<field name="display_name" position="after">
|
||||||
<field name="name"/>
|
<field name="name"/>
|
||||||
<field name="ref" optional="hide"/>
|
<field name="ref"/>
|
||||||
</field>
|
</field>
|
||||||
<field name="display_name" position="attributes">
|
<field name="display_name" position="attributes">
|
||||||
<attribute name="invisible">1</attribute>
|
<attribute name="invisible">1</attribute>
|
||||||
</field>
|
</field>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
-->
|
|
||||||
|
|
||||||
<record id="res_partner_kanban_view" model="ir.ui.view">
|
<record id="res_partner_kanban_view" model="ir.ui.view">
|
||||||
<field name="name">Add ref in partner kanban view</field>
|
<field name="name">Add ref in partner kanban view</field>
|
||||||
@@ -1,194 +0,0 @@
|
|||||||
# Translation of Odoo Server.
|
|
||||||
# This file contains the translation of the following modules:
|
|
||||||
# * base_usability
|
|
||||||
#
|
|
||||||
msgid ""
|
|
||||||
msgstr ""
|
|
||||||
"Project-Id-Version: Odoo Server 14.0\n"
|
|
||||||
"Report-Msgid-Bugs-To: \n"
|
|
||||||
"POT-Creation-Date: 2021-07-01 10:02+0000\n"
|
|
||||||
"PO-Revision-Date: 2021-07-01 10:02+0000\n"
|
|
||||||
"Last-Translator: \n"
|
|
||||||
"Language-Team: \n"
|
|
||||||
"MIME-Version: 1.0\n"
|
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
|
||||||
"Content-Transfer-Encoding: \n"
|
|
||||||
"Plural-Forms: \n"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_partner_bank
|
|
||||||
msgid "Bank Accounts"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank__bank_name
|
|
||||||
msgid "Bank Name"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_company
|
|
||||||
msgid "Companies"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_partner
|
|
||||||
msgid "Contact"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Currency"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Customer Number:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_mail_server__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_model__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_company__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__display_name
|
|
||||||
msgid "Display Name"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "E-mail:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Group By"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_mail_server__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_model__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_company__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__id
|
|
||||||
msgid "ID"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.view_module_filter
|
|
||||||
msgid "Installable"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_mail_server____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_model____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_company____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users____last_update
|
|
||||||
msgid "Last Modified on"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_ir_mail_server
|
|
||||||
msgid "Mail Server"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Mobile:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_ir_model
|
|
||||||
msgid "Models"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Name or Code"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.view_res_partner_filter
|
|
||||||
msgid "Name or Email or Reference"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__name_title
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__name_title
|
|
||||||
msgid "Name with Title"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:res.groups,name:base_usability.group_nobody
|
|
||||||
msgid "Nobody (used to hide native menus)"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_partner_category
|
|
||||||
msgid "Partner Tags"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__ref
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__ref
|
|
||||||
msgid "Reference"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Search Countries"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Supplier Number:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category__name
|
|
||||||
msgid "Tag Name"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Tel:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_users
|
|
||||||
msgid "Users"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "VAT Number:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "VAT:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Website:"
|
|
||||||
msgstr ""
|
|
||||||
@@ -1,192 +0,0 @@
|
|||||||
# Translation of Odoo Server.
|
|
||||||
# This file contains the translation of the following modules:
|
|
||||||
# * base_usability
|
|
||||||
#
|
|
||||||
msgid ""
|
|
||||||
msgstr ""
|
|
||||||
"Project-Id-Version: Odoo Server 14.0\n"
|
|
||||||
"Report-Msgid-Bugs-To: \n"
|
|
||||||
"POT-Creation-Date: 2021-07-01 10:02+0000\n"
|
|
||||||
"PO-Revision-Date: 2021-07-01 12:15+0200\n"
|
|
||||||
"Last-Translator: Alexis de Lattre <alexis@via.ecp.fr>\n"
|
|
||||||
"Language-Team: \n"
|
|
||||||
"MIME-Version: 1.0\n"
|
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
|
||||||
"Content-Transfer-Encoding: \n"
|
|
||||||
"Plural-Forms: \n"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_partner_bank
|
|
||||||
msgid "Bank Accounts"
|
|
||||||
msgstr "Comptes bancaires"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank__bank_name
|
|
||||||
msgid "Bank Name"
|
|
||||||
msgstr "Nom de la banque"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_company
|
|
||||||
msgid "Companies"
|
|
||||||
msgstr "Sociétés"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_partner
|
|
||||||
msgid "Contact"
|
|
||||||
msgstr "Contact"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Currency"
|
|
||||||
msgstr "Devise"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Customer Number:"
|
|
||||||
msgstr "N° client :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_mail_server__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_model__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_company__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category__display_name
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__display_name
|
|
||||||
msgid "Display Name"
|
|
||||||
msgstr "Nom affiché"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "E-mail:"
|
|
||||||
msgstr "E-mail :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Group By"
|
|
||||||
msgstr "Grouper par"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_mail_server__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_model__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_company__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category__id
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__id
|
|
||||||
msgid "ID"
|
|
||||||
msgstr "ID"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.view_module_filter
|
|
||||||
msgid "Installable"
|
|
||||||
msgstr "Installable"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_mail_server____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_ir_model____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_company____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_bank____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category____last_update
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users____last_update
|
|
||||||
msgid "Last Modified on"
|
|
||||||
msgstr "Dernière modification le"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_ir_mail_server
|
|
||||||
msgid "Mail Server"
|
|
||||||
msgstr "Serveur mail"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Mobile:"
|
|
||||||
msgstr "Portable :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_ir_model
|
|
||||||
msgid "Models"
|
|
||||||
msgstr "Modèles"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Name or Code"
|
|
||||||
msgstr "Nom ou code"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.view_res_partner_filter
|
|
||||||
msgid "Name or Email or Reference"
|
|
||||||
msgstr "Nom ou e-mail ou référence"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__name_title
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__name_title
|
|
||||||
msgid "Name with Title"
|
|
||||||
msgstr "Nom avec titre"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:res.groups,name:base_usability.group_nobody
|
|
||||||
msgid "Nobody (used to hide native menus)"
|
|
||||||
msgstr "Personne (utilisé pour cacher des entrées de menu natifs)"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_partner_category
|
|
||||||
msgid "Partner Tags"
|
|
||||||
msgstr "Étiquettes du partenaire"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner__ref
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_users__ref
|
|
||||||
msgid "Reference"
|
|
||||||
msgstr "Référence"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model_terms:ir.ui.view,arch_db:base_usability.res_country_search
|
|
||||||
msgid "Search Countries"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Supplier Number:"
|
|
||||||
msgstr "N° fournisseur :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model.fields,field_description:base_usability.field_res_partner_category__name
|
|
||||||
msgid "Tag Name"
|
|
||||||
msgstr "Nom de l'étiquette"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Tel:"
|
|
||||||
msgstr "Tél :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: model:ir.model,name:base_usability.model_res_users
|
|
||||||
msgid "Users"
|
|
||||||
msgstr "Utilisateurs"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "VAT Number:"
|
|
||||||
msgstr "N° TVA :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "VAT:"
|
|
||||||
msgstr "TVA :"
|
|
||||||
|
|
||||||
#. module: base_usability
|
|
||||||
#: code:addons/base_usability/models/res_company.py:0
|
|
||||||
#: code:addons/base_usability/models/res_partner.py:0
|
|
||||||
#, python-format
|
|
||||||
msgid "Website:"
|
|
||||||
msgstr "Site web :"
|
|
||||||
@@ -4,5 +4,4 @@ from . import res_partner_bank
|
|||||||
from . import res_partner_category
|
from . import res_partner_category
|
||||||
from . import res_company
|
from . import res_company
|
||||||
from . import ir_mail_server
|
from . import ir_mail_server
|
||||||
from . import ir_actions_report
|
|
||||||
from . import ir_model
|
from . import ir_model
|
||||||
|
|||||||
@@ -1,15 +0,0 @@
|
|||||||
# Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class IrActionsReport(models.Model):
|
|
||||||
_inherit = "ir.actions.report"
|
|
||||||
|
|
||||||
# since v13, print_report_name is a translatable field
|
|
||||||
# It means that you can't set the value via an inherit of
|
|
||||||
# ir.actions.report as XML
|
|
||||||
# I think it was easier when this field was not translatable
|
|
||||||
print_report_name = fields.Char(translate=False)
|
|
||||||
@@ -51,7 +51,7 @@ class ResCompany(models.Model):
|
|||||||
'label': _('Website:')},
|
'label': _('Website:')},
|
||||||
'vat': {
|
'vat': {
|
||||||
'value': self.vat,
|
'value': self.vat,
|
||||||
'label': _('VAT:')},
|
'label': _('TVA :')}, # TODO translate
|
||||||
}
|
}
|
||||||
return options
|
return options
|
||||||
|
|
||||||
|
|||||||
@@ -8,9 +8,25 @@ from odoo import models, fields, api, _
|
|||||||
class ResPartner(models.Model):
|
class ResPartner(models.Model):
|
||||||
_inherit = 'res.partner'
|
_inherit = 'res.partner'
|
||||||
|
|
||||||
# tracking=True is handled in the 'mail' module, and base_usability
|
# track_visibility is handled in the 'mail' module, and base_usability
|
||||||
# doesn't depend on 'mail', so adding tracking on res.partner fields
|
# doesn't depend on 'mail', but that doesn't hurt, it will just be
|
||||||
# has been moved to mail_usability
|
# ignored if mail is not installed
|
||||||
|
# TODO move to mail module
|
||||||
|
# name = fields.Char(tracking=True)
|
||||||
|
# parent_id = fields.Many2one(tracking=True)
|
||||||
|
# ref = fields.Char(tracking=True)
|
||||||
|
# lang = fields.Selection(tracking=True)
|
||||||
|
# user_id = fields.Many2one(tracking=True)
|
||||||
|
# vat = fields.Char(tracking=True)
|
||||||
|
# street = fields.Char(tracking=True)
|
||||||
|
# street2 = fields.Char(tracking=True)
|
||||||
|
# zip = fields.Char(tracking=True)
|
||||||
|
# city = fields.Char(tracking=True)
|
||||||
|
# state_id = fields.Many2one(tracking=True)
|
||||||
|
# country_id = fields.Many2one(tracking=True)
|
||||||
|
# is_company = fields.Boolean(tracking=True)
|
||||||
|
# active = fields.Boolean(tracking=True)
|
||||||
|
# company_id = fields.Many2one(tracking=True)
|
||||||
ref = fields.Char(copy=False)
|
ref = fields.Char(copy=False)
|
||||||
# For reports
|
# For reports
|
||||||
name_title = fields.Char(
|
name_title = fields.Char(
|
||||||
@@ -40,8 +56,9 @@ class ResPartner(models.Model):
|
|||||||
|
|
||||||
# for reports
|
# for reports
|
||||||
def _display_full_address(
|
def _display_full_address(
|
||||||
self,
|
self, details=[
|
||||||
details=['company', 'name', 'address', 'phone', 'mobile', 'email'],
|
'company', 'name', 'address', 'phone',
|
||||||
|
'mobile', 'email'],
|
||||||
icon=True):
|
icon=True):
|
||||||
self.ensure_one()
|
self.ensure_one()
|
||||||
# To make the icons work with py3o with PDF export, on the py3o server:
|
# To make the icons work with py3o with PDF export, on the py3o server:
|
||||||
@@ -102,28 +119,7 @@ class ResPartner(models.Model):
|
|||||||
},
|
},
|
||||||
'address': {
|
'address': {
|
||||||
'value': self._display_address(without_company=True),
|
'value': self._display_address(without_company=True),
|
||||||
},
|
}
|
||||||
'vat': {
|
|
||||||
'value': self.commercial_partner_id.vat,
|
|
||||||
'label': _('VAT Number:'),
|
|
||||||
},
|
|
||||||
'commercial_ref': {
|
|
||||||
'value': self.commercial_partner_id.ref,
|
|
||||||
'label': _('Customer Number:'),
|
|
||||||
},
|
|
||||||
'ref': {
|
|
||||||
'value': self.ref,
|
|
||||||
'label': _('Customer Number:'),
|
|
||||||
},
|
|
||||||
# Same with 'supplier_' prefix, to change the label
|
|
||||||
'supplier_commercial_ref': {
|
|
||||||
'value': self.commercial_partner_id.ref,
|
|
||||||
'label': _('Supplier Number:'),
|
|
||||||
},
|
|
||||||
'supplier_ref': {
|
|
||||||
'value': self.ref,
|
|
||||||
'label': _('Supplier Number:'),
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
res = []
|
res = []
|
||||||
for detail in details:
|
for detail in details:
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
<field name="name">base_usability.res.country.search</field>
|
<field name="name">base_usability.res.country.search</field>
|
||||||
<field name="model">res.country</field>
|
<field name="model">res.country</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<search>
|
<search string="Search Countries">
|
||||||
<field name="name" filter_domain="['|', ('name', 'ilike', self), ('code', '=', self)]" string="Name or Code"/>
|
<field name="name" filter_domain="['|', ('name', 'ilike', self), ('code', '=', self)]" string="Name or Code"/>
|
||||||
<field name="code"/>
|
<field name="code"/>
|
||||||
<field name="currency_id"/>
|
<field name="currency_id"/>
|
||||||
|
|||||||
@@ -16,10 +16,6 @@
|
|||||||
<xpath expr="//field[@name='child_ids']/form//field[@name='title']" position="attributes">
|
<xpath expr="//field[@name='child_ids']/form//field[@name='title']" position="attributes">
|
||||||
<attribute name="attrs"></attribute>
|
<attribute name="attrs"></attribute>
|
||||||
</xpath>
|
</xpath>
|
||||||
<!-- Show double VAT partner even when not in editable mode -->
|
|
||||||
<div attrs="{'invisible': [('same_vat_partner_id', '=', False)]}" position="attributes">
|
|
||||||
<attribute name="class">alert alert-warning</attribute>
|
|
||||||
</div>
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
@@ -39,9 +35,6 @@
|
|||||||
<field name="model">res.partner</field>
|
<field name="model">res.partner</field>
|
||||||
<field name="inherit_id" ref="base.view_partner_tree"/>
|
<field name="inherit_id" ref="base.view_partner_tree"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<field name="display_name" position="after">
|
|
||||||
<field name="ref" optional="hide"/>
|
|
||||||
</field>
|
|
||||||
<field name="phone" position="after">
|
<field name="phone" position="after">
|
||||||
<field name="mobile" optional="show" widget="phone" class="o_force_ltr"/>
|
<field name="mobile" optional="show" widget="phone" class="o_force_ltr"/>
|
||||||
</field>
|
</field>
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
from . import models
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
# Copyright 2016-2021 Akretion (http://www.akretion.com)
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'CRM Usability',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Customer Relationship Management',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'CRM usability enhancements',
|
|
||||||
'description': """
|
|
||||||
CRM Usability
|
|
||||||
=============
|
|
||||||
|
|
||||||
This module has been written by Alexis de Lattre from Akretion
|
|
||||||
<alexis.delattre@akretion.com>.
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': ['crm'],
|
|
||||||
'data': [
|
|
||||||
'views/crm_lead.xml',
|
|
||||||
],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import crm_lead
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
# Copyright 2017-2021 Akretion (http://www.akretion.com)
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class CrmLead(models.Model):
|
|
||||||
_inherit = 'crm.lead'
|
|
||||||
|
|
||||||
probability = fields.Float(tracking=100)
|
|
||||||
date_deadline = fields.Date(tracking=110)
|
|
||||||
name = fields.Char(tracking=1)
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 9.5 KiB |
@@ -1,22 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2017-2021 Akretion (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<!-- SEARCH OPPOR -->
|
|
||||||
<record id="view_crm_case_opportunities_filter" model="ir.ui.view">
|
|
||||||
<field name="name">usability.crm.lead.opportunity.search</field>
|
|
||||||
<field name="model">crm.lead</field>
|
|
||||||
<field name="inherit_id" ref="crm.view_crm_case_opportunities_filter"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<filter name="saleschannel" position="after">
|
|
||||||
<filter name="partner_groupby" string="Customer" context="{'group_by': 'partner_id'}"/>
|
|
||||||
</filter>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1 +1 @@
|
|||||||
from . import models
|
from . import stock
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
# Copyright 2018-2021 Akretion (http://www.akretion.com)
|
# Copyright 2018-2019 Akretion (http://www.akretion.com)
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
{
|
{
|
||||||
'name': 'Delivery Usability',
|
'name': 'Delivery Usability',
|
||||||
'version': '14.0.1.0.0',
|
'version': '12.0.1.0.0',
|
||||||
'category': 'Stock',
|
'category': 'Stock',
|
||||||
'license': 'AGPL-3',
|
'license': 'AGPL-3',
|
||||||
'summary': 'Several usability enhancements in Delivery',
|
'summary': 'Several usability enhancements in Delivery',
|
||||||
@@ -14,6 +14,7 @@ Delivery Usability
|
|||||||
|
|
||||||
The usability enhancements include:
|
The usability enhancements include:
|
||||||
* allow modification of carrier and it's tracking ref. on a done picking
|
* allow modification of carrier and it's tracking ref. on a done picking
|
||||||
|
* display field 'invoice_shipping_on_delivery' on sale.order form view
|
||||||
|
|
||||||
This module has been written by Alexis de Lattre from Akretion <alexis.delattre@akretion.com>.
|
This module has been written by Alexis de Lattre from Akretion <alexis.delattre@akretion.com>.
|
||||||
""",
|
""",
|
||||||
@@ -21,7 +22,8 @@ This module has been written by Alexis de Lattre from Akretion <alexis.delattre@
|
|||||||
'website': 'http://www.akretion.com',
|
'website': 'http://www.akretion.com',
|
||||||
'depends': ['delivery'],
|
'depends': ['delivery'],
|
||||||
'data': [
|
'data': [
|
||||||
'views/stock_picking.xml',
|
'sale_view.xml',
|
||||||
|
'stock_view.xml',
|
||||||
],
|
],
|
||||||
'installable': True,
|
'installable': False,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
from . import stock_picking
|
|
||||||
23
delivery_usability/sale_view.xml
Normal file
23
delivery_usability/sale_view.xml
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
Copyright 2018-2019 Akretion
|
||||||
|
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
|
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
-->
|
||||||
|
|
||||||
|
<odoo>
|
||||||
|
|
||||||
|
|
||||||
|
<record id="view_order_form_with_carrier" model="ir.ui.view">
|
||||||
|
<field name="name">delivery_usability.sale.order.form</field>
|
||||||
|
<field name="model">sale.order</field>
|
||||||
|
<field name="inherit_id" ref="delivery.view_order_form_with_carrier"/>
|
||||||
|
<field name="arch" type="xml">
|
||||||
|
<group name="sale_pay" position="inside">
|
||||||
|
<field name="invoice_shipping_on_delivery"/>
|
||||||
|
</group>
|
||||||
|
</field>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
|
||||||
|
</odoo>
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
# Copyright 2018-2021 Akretion (http://www.akretion.com)
|
# Copyright 2018-2019 Akretion (http://www.akretion.com)
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
@@ -8,5 +8,5 @@ from odoo import fields, models
|
|||||||
class StockPicking(models.Model):
|
class StockPicking(models.Model):
|
||||||
_inherit = 'stock.picking'
|
_inherit = 'stock.picking'
|
||||||
|
|
||||||
carrier_id = fields.Many2one(tracking=True)
|
carrier_id = fields.Many2one(track_visibility='onchange')
|
||||||
carrier_tracking_ref = fields.Char(tracking=True)
|
carrier_tracking_ref = fields.Char(track_visibility='onchange')
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!--
|
<!--
|
||||||
Copyright 2018-2021 Akretion France
|
Copyright 2018 Akretion (Alexis de Lattre <alexis.delattre@akretion.com>)
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
# Copyright 2014-2021 Akretion France (http://www.akretion.com)
|
# Copyright 2014-2019 Akretion France (http://www.akretion.com)
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
|
|
||||||
{
|
{
|
||||||
'name': 'Eradicate Quick Create',
|
'name': 'Eradicate Quick Create',
|
||||||
'version': '14.0.1.0.0',
|
'version': '12.0.2.0.0',
|
||||||
'category': 'Tools',
|
'category': 'Tools',
|
||||||
'license': 'AGPL-3',
|
'license': 'AGPL-3',
|
||||||
'summary': 'Disable quick create on all objects',
|
'summary': 'Disable quick create on all objects',
|
||||||
@@ -13,7 +13,7 @@ Eradicate Quick Create
|
|||||||
|
|
||||||
Disable quick create on all objects of Odoo.
|
Disable quick create on all objects of Odoo.
|
||||||
|
|
||||||
This module uses the module *web_m2x_options* from the OCA *web* project (in v10 and lower, it was using the module *base_optional_quick_create* from the OCA project *server-ux*).
|
This new version of the module uses the module *web_m2x_options* from the OCA *web* project instead of the module *base_optional_quick_create* from the OCA project *server-ux*.
|
||||||
|
|
||||||
This module has been written by Alexis de Lattre from Akretion <alexis.delattre@akretion.com>.
|
This module has been written by Alexis de Lattre from Akretion <alexis.delattre@akretion.com>.
|
||||||
""",
|
""",
|
||||||
@@ -21,5 +21,5 @@ This module has been written by Alexis de Lattre from Akretion <alexis.delattre@
|
|||||||
'website': 'http://www.akretion.com',
|
'website': 'http://www.akretion.com',
|
||||||
'depends': ['web_m2x_options'],
|
'depends': ['web_m2x_options'],
|
||||||
'post_init_hook': 'web_m2x_options_create',
|
'post_init_hook': 'web_m2x_options_create',
|
||||||
'installable': True,
|
'installable': False,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
# Copyright 2019-2021 Akretion France
|
# Copyright 2019 Akretion France
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
@@ -11,7 +11,7 @@ def web_m2x_options_create(cr, registry):
|
|||||||
config_parameter = env['ir.config_parameter'].search(
|
config_parameter = env['ir.config_parameter'].search(
|
||||||
[('key', '=', 'web_m2x_options.create')])
|
[('key', '=', 'web_m2x_options.create')])
|
||||||
if config_parameter and config_parameter.value != 'False':
|
if config_parameter and config_parameter.value != 'False':
|
||||||
config_parameter.write({'value': 'False'})
|
config_parameter.value = 'False'
|
||||||
else:
|
else:
|
||||||
env['ir.config_parameter'].create({
|
env['ir.config_parameter'].create({
|
||||||
'key': 'web_m2x_options.create',
|
'key': 'web_m2x_options.create',
|
||||||
|
|||||||
16
google_calendar_usability/__manifest__.py
Normal file
16
google_calendar_usability/__manifest__.py
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
# Copyright 2021 Akretion (http://www.akretion.com)
|
||||||
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
{
|
||||||
|
"name": "Google Calendar Usability",
|
||||||
|
"version": "14.0.1.0.0",
|
||||||
|
"category": "Productivity",
|
||||||
|
"description": "Removes displaying credentials from the general settings view, "
|
||||||
|
"prevents deleting calendar events",
|
||||||
|
"depends": ["google_calendar"],
|
||||||
|
"data": [
|
||||||
|
"views/res_config_settings_views.xml",
|
||||||
|
],
|
||||||
|
"demo": [],
|
||||||
|
"installable": True,
|
||||||
|
"auto_install": False,
|
||||||
|
}
|
||||||
2
google_calendar_usability/models/__init__.py
Normal file
2
google_calendar_usability/models/__init__.py
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
from . import res_config_settings
|
||||||
|
from . import calendar
|
||||||
15
google_calendar_usability/models/calendar.py
Normal file
15
google_calendar_usability/models/calendar.py
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# Copyright 2021 Akretion (http://www.akretion.com)
|
||||||
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
|
from odoo import models
|
||||||
|
|
||||||
|
|
||||||
|
class Meeting(models.Model):
|
||||||
|
_inherit = "calendar.event"
|
||||||
|
|
||||||
|
def unlink(self):
|
||||||
|
to_archive = self.filtered(lambda r: r.google_id and r.active)
|
||||||
|
if to_archive:
|
||||||
|
to_archive.write({"active": False})
|
||||||
|
to_unlink = self - to_archive
|
||||||
|
super(Meeting, to_unlink).unlink()
|
||||||
32
google_calendar_usability/models/res_config_settings.py
Normal file
32
google_calendar_usability/models/res_config_settings.py
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
# Copyright 2021 Akretion (http://www.akretion.com)
|
||||||
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
|
from odoo import fields, models
|
||||||
|
|
||||||
|
|
||||||
|
class ResConfigSettings(models.TransientModel):
|
||||||
|
_inherit = "res.config.settings"
|
||||||
|
|
||||||
|
dummy_cal_client_id = fields.Char(
|
||||||
|
"Client_id",
|
||||||
|
compute="_compute_dummy_gcal_credentials",
|
||||||
|
inverse="_inverse_dummy_cal_client_id",
|
||||||
|
)
|
||||||
|
dummy_cal_client_secret = fields.Char(
|
||||||
|
"Client_key",
|
||||||
|
compute="_compute_dummy_gcal_credentials",
|
||||||
|
inverse="_inverse_dummy_cal_client_secret",
|
||||||
|
)
|
||||||
|
|
||||||
|
def _compute_dummy_gcal_credentials(self):
|
||||||
|
for rec in self:
|
||||||
|
rec.dummy_cal_client_id = ""
|
||||||
|
rec.dummy_cal_client_secret = ""
|
||||||
|
|
||||||
|
def _inverse_dummy_cal_client_id(self):
|
||||||
|
for rec in self:
|
||||||
|
rec.cal_client_id = rec.dummy_cal_client_id
|
||||||
|
|
||||||
|
def _inverse_dummy_cal_client_secret(self):
|
||||||
|
for rec in self:
|
||||||
|
rec.cal_client_secret = rec.dummy_cal_client_secret
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<odoo>
|
||||||
|
|
||||||
|
<record id="res_config_settings_view_form" model="ir.ui.view">
|
||||||
|
<field name="model">res.config.settings</field>
|
||||||
|
<field name="inherit_id" ref="base_setup.res_config_settings_view_form"/>
|
||||||
|
<field name="arch" type="xml">
|
||||||
|
<xpath expr="//field[@name='cal_client_id']" position="replace">
|
||||||
|
<field name="dummy_cal_client_id" nolabel="1"/>
|
||||||
|
</xpath>
|
||||||
|
<xpath expr="//label[@for='cal_client_id']" position="replace">
|
||||||
|
<label for="dummy_cal_client_id" string="Client ID" class="col-3 col-lg-3 o_light_label"/>
|
||||||
|
</xpath>
|
||||||
|
<xpath expr="//field[@name='cal_client_secret']" position="replace">
|
||||||
|
<field name="dummy_cal_client_secret" nolabel="1"/>
|
||||||
|
</xpath>
|
||||||
|
<xpath expr="//label[@for='cal_client_secret']" position="replace">
|
||||||
|
<label for="dummy_cal_client_secret" string="Client Secret" class="col-3 col-lg-3 o_light_label"/>
|
||||||
|
</xpath>
|
||||||
|
</field>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
</odoo>
|
||||||
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import models
|
|
||||||
@@ -1,20 +0,0 @@
|
|||||||
# Copyright 2021 Akretion (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'HR Contract Usability',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Human Resources/Contracts',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'Usability improvements on HR Contract module',
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': [
|
|
||||||
'hr_contract',
|
|
||||||
],
|
|
||||||
'data': [
|
|
||||||
'views/hr_payroll_structure_type.xml',
|
|
||||||
],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import hr_payroll_structure_type
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
# Copyright 2021 Akretion (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
class HrPayrollStructureType(models.Model):
|
|
||||||
_inherit = 'hr.payroll.structure.type'
|
|
||||||
|
|
||||||
active = fields.Boolean(default=True)
|
|
||||||
@@ -1,63 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<record id="hr_payroll_structure_type_form" model="ir.ui.view">
|
|
||||||
<field name="model">hr.payroll.structure.type</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<form>
|
|
||||||
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" attrs="{'invisible': [('active', '=', True)]}"/>
|
|
||||||
<group name="main">
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="default_resource_calendar_id"/>
|
|
||||||
<field name="active" invisible="1"/>
|
|
||||||
<field name="country_id"/>
|
|
||||||
</group>
|
|
||||||
</form>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="hr_payroll_structure_type_tree" model="ir.ui.view">
|
|
||||||
<field name="model">hr.payroll.structure.type</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<tree>
|
|
||||||
<field name="name"/>
|
|
||||||
<field name="default_resource_calendar_id" optional="show"/>
|
|
||||||
<field name="country_id"/>
|
|
||||||
</tree>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="hr_payroll_structure_type_search" model="ir.ui.view">
|
|
||||||
<field name="model">hr.payroll.structure.type</field>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<search>
|
|
||||||
<field name="name"/>
|
|
||||||
<separator/>
|
|
||||||
<filter string="Archived" name="inactive" domain="[('active', '=', False)]"/>
|
|
||||||
<group name="groupby">
|
|
||||||
<filter name="country_groupby" string="Country" context="{'group_by': 'country_id'}"/>
|
|
||||||
</group>
|
|
||||||
</search>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="hr_payroll_structure_type_action" model="ir.actions.act_window">
|
|
||||||
<field name="name">Salary Structure Types</field>
|
|
||||||
<field name="res_model">hr.payroll.structure.type</field>
|
|
||||||
<field name="view_mode">tree,form</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<menuitem
|
|
||||||
id="hr_payroll_structure_type_menu"
|
|
||||||
action="hr_payroll_structure_type_action"
|
|
||||||
parent="hr_contract.menu_human_resources_configuration_contract"
|
|
||||||
sequence="10"/>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
# Copyright 2019-2021 Akretion France (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'Link Tracker Usability',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Marketing',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'Improve usability for link tracker',
|
|
||||||
'description': """
|
|
||||||
Link Tracker Usability
|
|
||||||
======================
|
|
||||||
|
|
||||||
Several small usability improvements.
|
|
||||||
|
|
||||||
This module has been written by Alexis de Lattre from Akretion
|
|
||||||
<alexis.delattre@akretion.com>.
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': ['link_tracker'],
|
|
||||||
'data': [
|
|
||||||
'views/link_tracker_click.xml',
|
|
||||||
],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1,45 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2019-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="link_tracker_click_view_tree" model="ir.ui.view">
|
|
||||||
<field name="name">usability.link.tracker.click.tree</field>
|
|
||||||
<field name="model">link.tracker.click</field>
|
|
||||||
<field name="inherit_id" ref="link_tracker.link_tracker_click_view_tree"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="country_id" position="after">
|
|
||||||
<field name="create_date" string="Click Date"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="link_tracker_click_view_form" model="ir.ui.view">
|
|
||||||
<field name="name">usability.link.tracker.click.form</field>
|
|
||||||
<field name="model">link.tracker.click</field>
|
|
||||||
<field name="inherit_id" ref="link_tracker.link_tracker_click_view_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="country_id" position="after">
|
|
||||||
<field name="create_date" string="Click Date"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="link_tracker_click_view_search" model="ir.ui.view">
|
|
||||||
<field name="name">usability.link.tracker.click.search</field>
|
|
||||||
<field name="model">link.tracker.click</field>
|
|
||||||
<field name="inherit_id" ref="link_tracker.link_tracker_click_view_search"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<filter name="groupby_link_id" position="before">
|
|
||||||
<filter name="create_date_groupby" string="Click Date" context="{'group_by': 'create_date'}"/>
|
|
||||||
</filter>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import models
|
|
||||||
@@ -1,32 +0,0 @@
|
|||||||
# Copyright 2016-2021 Akretion France (http://www.akretion.com)
|
|
||||||
# @author Benoît Guillot <benoit.guillot@akretion.com>
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'Mail Usability',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Productivity/Discuss',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'Usability improvements on mails',
|
|
||||||
'description': """
|
|
||||||
Mail Usability
|
|
||||||
==============
|
|
||||||
|
|
||||||
Small usability improvements on mails:
|
|
||||||
|
|
||||||
* remove link in mail footer (TODO mig v14)
|
|
||||||
|
|
||||||
* remove 'sent by' in notification footer (TODO mig v14)
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': ['mail'],
|
|
||||||
'data': [
|
|
||||||
#'views/mail_view.xml',
|
|
||||||
#'data/mail_data.xml',
|
|
||||||
#'wizard/email_template_preview_view.xml',
|
|
||||||
#'wizard/mail_compose_message_view.xml',
|
|
||||||
],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
from . import res_partner
|
|
||||||
from . import mail_template
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
# Copyright 2018-2021 Akretion France (http://www.akretion.com).
|
|
||||||
# @author Sébastien BEAU <sebastien.beau@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class MailTemplate(models.Model):
|
|
||||||
_inherit = 'mail.template'
|
|
||||||
|
|
||||||
auto_delete = fields.Boolean(default=False)
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
# Copyright 2015-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import models, fields
|
|
||||||
|
|
||||||
|
|
||||||
class ResPartner(models.Model):
|
|
||||||
_inherit = 'res.partner'
|
|
||||||
|
|
||||||
# tracking=True is handled in the 'mail' module, so it's better
|
|
||||||
# to have this in mail_usability than in base_usability
|
|
||||||
name = fields.Char(tracking=True)
|
|
||||||
parent_id = fields.Many2one(tracking=True)
|
|
||||||
ref = fields.Char(tracking=True)
|
|
||||||
lang = fields.Selection(tracking=True)
|
|
||||||
vat = fields.Char(tracking=True)
|
|
||||||
street = fields.Char(tracking=True)
|
|
||||||
street2 = fields.Char(tracking=True)
|
|
||||||
zip = fields.Char(tracking=True)
|
|
||||||
city = fields.Char(tracking=True)
|
|
||||||
state_id = fields.Many2one(tracking=True)
|
|
||||||
country_id = fields.Many2one(tracking=True)
|
|
||||||
is_company = fields.Boolean(tracking=True)
|
|
||||||
active = fields.Boolean(tracking=True)
|
|
||||||
company_id = fields.Many2one(tracking=True)
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import models
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
# Copyright 2019-2021 Akretion France (http://www.akretion.com)
|
|
||||||
# @author Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'Mass Mailing Campaigns Usability',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Marketing',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'Improve usability of mass mailing campaigns',
|
|
||||||
'description': """
|
|
||||||
Mass Mailing Campaigns Usability
|
|
||||||
================================
|
|
||||||
|
|
||||||
Several small usability improvements on the module mass_mailing:
|
|
||||||
|
|
||||||
* show fields on link.tracker.click that are not displayed by default
|
|
||||||
|
|
||||||
This module has been written by Alexis de Lattre from Akretion
|
|
||||||
<alexis.delattre@akretion.com>.
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': ['mass_mailing', 'link_tracker_usability'],
|
|
||||||
'data': [
|
|
||||||
# 'views/link_tracker.xml',
|
|
||||||
],
|
|
||||||
'installable': False,
|
|
||||||
}
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--
|
|
||||||
Copyright 2019 Akretion (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="view_link_tracker_click_tree" model="ir.ui.view">
|
|
||||||
<field name="name">mm.usability.link.tracker.click.tree</field>
|
|
||||||
<field name="model">link.tracker.click</field>
|
|
||||||
<field name="inherit_id" ref="link_tracker.view_link_tracker_click_tree"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="country_id" position="after">
|
|
||||||
<field name="mass_mailing_id"/>
|
|
||||||
<field name="mail_stat_recipient"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="view_link_tracker_click_form" model="ir.ui.view">
|
|
||||||
<field name="name">mm.usability.link.tracker.click.form</field>
|
|
||||||
<field name="model">link.tracker.click</field>
|
|
||||||
<field name="inherit_id" ref="link_tracker.view_link_tracker_click_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="country_id" position="after">
|
|
||||||
<field name="mass_mailing_id"/>
|
|
||||||
<field name="mass_mailing_campaign_id"/>
|
|
||||||
<field name="mail_stat_id"/>
|
|
||||||
<field name="mail_stat_recipient"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="link_tracker_click_search" model="ir.ui.view">
|
|
||||||
<field name="name">mm.usability.link.tracker.click.search</field>
|
|
||||||
<field name="model">link.tracker.click</field>
|
|
||||||
<field name="inherit_id" ref="link_tracker_usability.link_tracker_click_search"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="link_id" position="after">
|
|
||||||
<field name="mail_stat_recipient"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -12,20 +12,16 @@ class ProductTemplate(models.Model):
|
|||||||
only one BoM form or a list of BoMs."""
|
only one BoM form or a list of BoMs."""
|
||||||
self.ensure_one()
|
self.ensure_one()
|
||||||
if self.bom_count == 1:
|
if self.bom_count == 1:
|
||||||
action_xml_id = "mrp.mrp_bom_form_action"
|
action = self.env.ref("mrp.mrp_bom_form_action").read()[0]
|
||||||
action = self.env["ir.actions.actions"]._for_xml_id(action_xml_id)
|
|
||||||
bom = self.env["mrp.bom"].search([("product_tmpl_id", "=", self.id)])
|
bom = self.env["mrp.bom"].search([("product_tmpl_id", "=", self.id)])
|
||||||
action.update(
|
action.update({
|
||||||
{
|
|
||||||
"context": {"default_product_tmpl_id": self.id},
|
"context": {"default_product_tmpl_id": self.id},
|
||||||
"views": False,
|
"views": False,
|
||||||
"view_mode": "form,tree",
|
"view_mode": "form,tree",
|
||||||
"res_id": bom.id,
|
"res_id": bom.id,
|
||||||
}
|
})
|
||||||
)
|
|
||||||
else:
|
else:
|
||||||
action_xml_id = "mrp.template_open_bom"
|
action = self.env.ref("mrp.template_open_bom").read()[0]
|
||||||
action = self.env["ir.actions.actions"]._for_xml_id(action_xml_id)
|
|
||||||
return action
|
return action
|
||||||
|
|
||||||
|
|
||||||
@@ -36,11 +32,9 @@ class ProductProduct(models.Model):
|
|||||||
action = super().action_view_bom()
|
action = super().action_view_bom()
|
||||||
bom_target_ids = self.env["mrp.bom"].search(action["domain"])
|
bom_target_ids = self.env["mrp.bom"].search(action["domain"])
|
||||||
if len(bom_target_ids) == 1:
|
if len(bom_target_ids) == 1:
|
||||||
action.update(
|
action.update({
|
||||||
{
|
|
||||||
"views": False,
|
"views": False,
|
||||||
"view_mode": "form,tree",
|
"view_mode": "form,tree",
|
||||||
"res_id": bom_target_ids[0].id,
|
"res_id": bom_target_ids[0].id,
|
||||||
}
|
})
|
||||||
)
|
|
||||||
return action
|
return action
|
||||||
|
|||||||
28
pos_no_product_template_menu/__manifest__.py
Normal file
28
pos_no_product_template_menu/__manifest__.py
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
|
{
|
||||||
|
'name': 'POS No Product Template Menu',
|
||||||
|
'version': '12.0.1.0.0',
|
||||||
|
'category': 'Point of sale',
|
||||||
|
'license': 'AGPL-3',
|
||||||
|
'summary': "Replace product.template menu entries by product.product menu",
|
||||||
|
'description': """
|
||||||
|
POS No Product Template
|
||||||
|
=======================
|
||||||
|
|
||||||
|
This module replaces the menu entry for product.template by menu entries
|
||||||
|
for product.product in the *Point Of Sale > Product* menu.
|
||||||
|
|
||||||
|
This module also switches to the tree view by default
|
||||||
|
for Product menu entries, instead of the kanban view.
|
||||||
|
|
||||||
|
This module has been written by David Béal
|
||||||
|
from Akretion <david.beal@akretion.com>.
|
||||||
|
""",
|
||||||
|
'author': 'Akretion',
|
||||||
|
'website': 'http://www.akretion.com',
|
||||||
|
'depends': ['point_of_sale', 'sale_purchase_no_product_template_menu'],
|
||||||
|
'auto_install': True,
|
||||||
|
'data': ['pos_view.xml'],
|
||||||
|
'installable': False,
|
||||||
|
}
|
||||||
16
pos_no_product_template_menu/pos_view.xml
Normal file
16
pos_no_product_template_menu/pos_view.xml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
|
||||||
|
<odoo>
|
||||||
|
|
||||||
|
<record id="product_product_action_pos" model="ir.actions.act_window">
|
||||||
|
<field name="name">Products</field>
|
||||||
|
<field name="res_model">product.product</field>
|
||||||
|
<field name="view_mode">kanban,tree,form</field>
|
||||||
|
<field name="context">{'default_available_in_pos': True, 'search_default_filter_to_availabe_pos': 1}</field>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
<record id="point_of_sale.menu_pos_products" model="ir.ui.menu">
|
||||||
|
<field name="action" ref="product_product_action_pos"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
</odoo>
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
# Copyright 2021 Akretion (http://www.akretion.com)
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
|
|
||||||
{
|
|
||||||
'name': 'POS Product Tree Default',
|
|
||||||
'version': '14.0.1.0.0',
|
|
||||||
'category': 'Product',
|
|
||||||
'license': 'AGPL-3',
|
|
||||||
'summary': 'Tree view by default instead of kanban for Products',
|
|
||||||
'description': """
|
|
||||||
Replace default kanban view by tree view for product menu in Point of Sale
|
|
||||||
main menu
|
|
||||||
""",
|
|
||||||
'author': 'Akretion',
|
|
||||||
'website': 'http://www.akretion.com',
|
|
||||||
'depends': ['point_of_sale'],
|
|
||||||
'data': [
|
|
||||||
'views/product_template.xml'
|
|
||||||
],
|
|
||||||
'installable': True,
|
|
||||||
}
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<record id="point_of_sale.product_template_action_pos_product" model="ir.actions.act_window">
|
|
||||||
<field name="view_mode">tree,form,kanban,activity</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
from . import models
|
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
# Copyright 2014-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
{
|
{
|
||||||
"name": "POS Usability",
|
"name": "POS Usability",
|
||||||
"version": "14.0.1.0.0",
|
"version": "12.0.1.0.0",
|
||||||
"category": "Point of sale",
|
"category": "Point of sale",
|
||||||
"license": "AGPL-3",
|
"license": "AGPL-3",
|
||||||
"summary": "Misc usability improvement for point of sale",
|
"summary": "Misc usability improvement for point of sale",
|
||||||
@@ -26,12 +24,6 @@ Akretion:
|
|||||||
"author": "Akretion",
|
"author": "Akretion",
|
||||||
"website": "http://www.akretion.com",
|
"website": "http://www.akretion.com",
|
||||||
"depends": ["point_of_sale"],
|
"depends": ["point_of_sale"],
|
||||||
"data": [
|
"data": ["report/pos.xml"],
|
||||||
"report/pos.xml",
|
"installable": False,
|
||||||
"views/report_pos_order.xml",
|
|
||||||
"views/pos_category.xml",
|
|
||||||
"views/pos_session.xml",
|
|
||||||
"views/product.xml",
|
|
||||||
],
|
|
||||||
"installable": True,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,3 +0,0 @@
|
|||||||
from . import product
|
|
||||||
from . import pos_category
|
|
||||||
from . import pos_payment_method
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
# Copyright 2017-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class PosCategory(models.Model):
|
|
||||||
_inherit = 'pos.category'
|
|
||||||
|
|
||||||
product_count = fields.Integer(
|
|
||||||
'# Products', compute='_compute_product_count',
|
|
||||||
help="The number of products under this point of sale category "
|
|
||||||
"(does not consider the children categories)")
|
|
||||||
|
|
||||||
# inspired by the code of odoo/addons/product/models/product.py
|
|
||||||
def _compute_product_count(self):
|
|
||||||
read_group_res = self.env['product.template'].read_group(
|
|
||||||
[('pos_categ_id', 'in', self.ids)],
|
|
||||||
['pos_categ_id'], ['pos_categ_id'])
|
|
||||||
group_data = dict(
|
|
||||||
(data['pos_categ_id'][0], data['pos_categ_id_count']) for data
|
|
||||||
in read_group_res)
|
|
||||||
for pos_categ in self:
|
|
||||||
pos_categ.product_count = group_data.get(pos_categ.id, 0)
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
# Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class PosPaymentMethod(models.Model):
|
|
||||||
_inherit = 'pos.payment.method'
|
|
||||||
_check_company_auto = True
|
|
||||||
|
|
||||||
cash_journal_id = fields.Many2one(check_company=True)
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
# Copyright 2017-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
|
|
||||||
from odoo import fields, models
|
|
||||||
|
|
||||||
|
|
||||||
class ProductTemplate(models.Model):
|
|
||||||
_inherit = 'product.template'
|
|
||||||
|
|
||||||
available_in_pos = fields.Boolean(tracking=True)
|
|
||||||
pos_categ_id = fields.Many2one(tracking=True)
|
|
||||||
@@ -1,35 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
|
|
||||||
<!--
|
|
||||||
Copyright 2015-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<record id="product_pos_category_form_view" model="ir.ui.view">
|
|
||||||
<field name="name">pos_usability.pos.category.form</field>
|
|
||||||
<field name="model">pos.category</field>
|
|
||||||
<field name="inherit_id" ref="point_of_sale.product_pos_category_form_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<div class="oe_title" position="before">
|
|
||||||
<div class="oe_button_box" name="button_box">
|
|
||||||
<button class="oe_stat_button"
|
|
||||||
name="%(product.product_template_action_all)d"
|
|
||||||
icon="fa-th-list"
|
|
||||||
type="action"
|
|
||||||
context="{'search_default_pos_categ_id': active_id}">
|
|
||||||
<div class="o_form_field o_stat_info">
|
|
||||||
<span class="o_stat_value"><field name="product_count"/></span>
|
|
||||||
<span class="o_stat_text"> Products</span>
|
|
||||||
</div>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<record id="view_pos_session_form" model="ir.ui.view">
|
|
||||||
<field name="model">pos.session</field>
|
|
||||||
<field name="inherit_id" ref="point_of_sale.view_pos_session_form"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<button name="show_journal_items" position="after">
|
|
||||||
<button name="%(point_of_sale.action_report_pos_order_all)d" type="action" class="oe_stat_button" icon="fa-table" string="Stats" context="{'search_default_session_id': active_id}"/>
|
|
||||||
</button>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="view_pos_session_tree" model="ir.ui.view">
|
|
||||||
<field name="model">pos.session</field>
|
|
||||||
<field name="inherit_id" ref="point_of_sale.view_pos_session_tree"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="state" position="attributes">
|
|
||||||
<attribute name="decoration-success">state == 'opened'</attribute>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,43 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
|
|
||||||
<!--
|
|
||||||
Copyright 2015-2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
|
|
||||||
<!-- put option "available in POS" at the top of product form view -->
|
|
||||||
<record id="product_template_form_view" model="ir.ui.view">
|
|
||||||
<field name="name">usability.pos.product.template</field>
|
|
||||||
<field name="model">product.template</field>
|
|
||||||
<field name="inherit_id" ref="point_of_sale.product_template_form_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<xpath expr="//group[@name='pos']//field[@name='available_in_pos']" position="replace"/>
|
|
||||||
<xpath expr="//div[@name='options']//field[@name='sale_ok']/.." position="after">
|
|
||||||
<div name="available_in_pos">
|
|
||||||
<field name="available_in_pos"/>
|
|
||||||
<label for="available_in_pos"/>
|
|
||||||
</div>
|
|
||||||
</xpath>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="product_template_search_view" model="ir.ui.view">
|
|
||||||
<field name="name">pos_usability.product.template.search</field>
|
|
||||||
<field name="model">product.template</field>
|
|
||||||
<field name="inherit_id" ref="product.product_template_search_view"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="categ_id" position="after">
|
|
||||||
<field name="pos_categ_id" filter_domain="[('pos_categ_id', 'child_of', raw_value)]"/>
|
|
||||||
</field>
|
|
||||||
<filter name="categ_id" position="after">
|
|
||||||
<filter name="pos_categ_groupby" string="Point of Sale Category" context="{'group_by': 'pos_categ_id'}"/>
|
|
||||||
</filter>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
|
|
||||||
<!--
|
|
||||||
Copyright 2021 Akretion France (http://www.akretion.com/)
|
|
||||||
@author: Alexis de Lattre <alexis.delattre@akretion.com>
|
|
||||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<odoo>
|
|
||||||
|
|
||||||
<record id="view_report_pos_order_search" model="ir.ui.view">
|
|
||||||
<field name="model">report.pos.order</field>
|
|
||||||
<field name="inherit_id" ref="point_of_sale.view_report_pos_order_search"/>
|
|
||||||
<field name="arch" type="xml">
|
|
||||||
<field name="product_categ_id" position="after">
|
|
||||||
<field name="session_id"/>
|
|
||||||
</field>
|
|
||||||
</field>
|
|
||||||
</record>
|
|
||||||
|
|
||||||
<record id="point_of_sale.action_report_pos_order_all" model="ir.actions.act_window">
|
|
||||||
<field name="view_mode">pivot,graph</field> <!-- invert native order -->
|
|
||||||
</record>
|
|
||||||
|
|
||||||
|
|
||||||
</odoo>
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user