54 Commits
Author SHA1 Message Date
Odoo Translation Bot b31ea21cab [I18N] Update translation terms from Transifex 2024-04-28 00:10:20 +02:00
Odoo Translation Bot 3275156773 [I18N] Update translation terms from Transifex 2024-04-14 00:09:33 +02:00
Odoo Translation Bot 684745f5de [I18N] Update translation terms from Transifex 2024-03-31 00:09:16 +01:00
Odoo Translation Bot 395140671f [I18N] Update translation terms from Transifex 2024-03-24 00:12:07 +01:00
Odoo Translation Bot c4bc200b47 [I18N] Update translation terms from Transifex 2024-03-17 00:11:43 +01:00
Odoo Translation Bot 1b9fd01d46 [I18N] Update translation terms from Transifex 2024-03-10 00:13:03 +01:00
Odoo Translation Bot cb45934163 [I18N] Update translation terms from Transifex 2024-03-03 00:09:56 +01:00
Odoo Translation Bot 4f4ca50e8d [I18N] Update translation terms from Transifex 2024-02-25 00:13:04 +01:00
Odoo Translation Bot dd40867949 [I18N] Update translation terms from Transifex 2024-02-11 00:14:17 +01:00
Tiffany Chang (tic) 94c58407f6 [I18N] *: add in Russian translations
For a first iteration, Russian translations were done using DeepL using
1 large .pot file of all the standard modules to translate (e.g. no
localizations, no test modules, etc). Unfortunately for some reason
doing a msgmerge with the existing ru.po files didn't seem to work, so
old "Translators" metadata at top of files were lost (maybe they will be
re-added during next Transifex sync?)

Part-of: odoo/odoo#152285
2024-02-06 18:49:02 +00:00
Odoo Translation Bot 625dac5a10 [I18N] Update translation terms from Transifex 2024-01-28 00:16:34 +01:00
Odoo Translation Bot 95a4b6dfdc [I18N] Update translation terms from Transifex 2024-01-21 00:17:03 +01:00
Odoo Translation Bot ad35458e8b [I18N] Update translation terms from Transifex 2023-12-31 00:18:24 +01:00
Odoo Translation Bot 50e8e08183 [I18N] Update translation terms from Transifex 2023-12-24 00:18:24 +01:00
Odoo Translation Bot 304a6caa14 [I18N] Update translation terms from Transifex 2023-12-17 00:08:26 +01:00
Odoo Translation Bot 8ab45d4a85 [I18N] Update translation terms from Transifex 2023-12-10 00:12:46 +01:00
Odoo Translation Bot 2ac98dc2e5 [I18N] Update translation terms from Transifex 2023-12-03 00:18:54 +01:00
Odoo Translation Bot 3ffba892de [I18N] Update translation terms from Transifex 2023-11-26 00:20:02 +01:00
Odoo Translation Bot f6fe982853 [I18N] Update translation terms from Transifex 2023-11-19 00:28:08 +01:00
Louis (wil) 68b4dfc2bb [I18N] *: import translations
closes odoo/odoo#141655

Related: odoo/enterprise#50484
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-11-08 20:48:14 +00:00
Odoo Translation Bot 5d2bc9e9b3 [I18N] Update translation terms from Transifex 2023-11-05 00:21:55 +01:00
Odoo Translation Bot 6739c317d1 [I18N] Update translation terms from Transifex 2023-10-29 00:07:17 +02:00
Louis (wil) 3f6f949fa5 [I18N] export sources
closes odoo/odoo#140002

Related: odoo/enterprise#49687
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-10-27 08:36:16 +00:00
Paolo Gatti (pgi) 43fc30a3f7 [IMP] account_*: Proxy user refactor
- Proxy user is no longer a computed store=True field, but a proper one.
  The type cannot be deduced just by some field on the company.
  A company may be Italian and also use Peppol, so the two Proxy Users
  must be different.
- The Proxy user `get_proxy_identification` method needs a proxy_type
  argument, otherwise the method won't know if the current override
  is to be applied or not. It cannot be handled by a field of the user
  itself because it is also used contextually to the user creation.
- new `_get_default_enable_send_by_post` function on the Send and Print
  wizard, so that it can be overridden by the features of the move
- Renamed `_compute_send_mail_extra_fields`
  to `_compute_fields_from_moves_state`

Part-of: odoo/odoo#122194
2023-09-19 16:37:09 +00:00
Gorash 774a3fad0e [REF] base,all: Update modifier syntax: view migration
Apply of the migration script to update all view modifiers.

Part-of: odoo/odoo#104741
2023-08-18 09:49:13 +02:00
aliya 2d051168a4 [FIX] account_peppol: fix migration key, sql constraints
Currently, the migration key is stored through a workaround as a config parameter,
because the behaviour needed to be changed in stable.
Now, several things can be fixed:
- `account_peppol_migration_key` is now a field on `res.company`, not `account_edi_proxy_client.user`
- `account_peppol_attachment_ids` can be removed as the specs changed and it's no longer necessary
- `peppol_proxy_state` can be removed as it's no longer useful after `enable_peppol` was added
- SQL constraints need to be changed to only include active users.
  This allows users to deregister/migrate away from Peppol and then re-register later, with their previous edi user being archived

closes odoo/odoo#129595

Related: odoo/upgrade#4980
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2023-08-03 08:26:28 +02:00
Thomas Beckers 4261024aa5 [FIX] account_edi_proxy_client: neutralize proxy user
Since commit 8590c6a, the edi proxy user is no more neutralized.
Now proxy users related to l10n_it_edi are set to 'demo' mode and other users
are set to 'test' mode.

opw-3439385

closes odoo/odoo#129935

X-original-commit: 4b8759d340e7ad2ae38572f374726087db2437cf
Signed-off-by: Laurent Smet (las) <las@odoo.com>
Signed-off-by: Thomas Beckers (tbs) <tbs@odoo.com>
2023-07-28 08:13:55 +02:00
Martin Trigaux 2afdda2576 [I18N] *: export saas-16.3 source terms
closes odoo/odoo#123046

X-original-commit: 137f5ca0cb703ee953cb01db525362f7a778e6bd
Related: odoo/enterprise#41703
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-06-01 11:43:51 +02:00
Martin Trigaux 077bbd0b0b [I18N] *: export master source terms
closes odoo/odoo#121563

Related: odoo/enterprise#41140
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-05-17 10:34:00 +02:00
aliya be00ef8e37 [ADD] account_peppol: send and receive invoice via peppol
This commits adds `account_peppol` module that allows:
- Registering as an account edi user and send an application to the peppol proxy,
  where the participant can be approved or rejected after reviewing the documents attached.
- Sending invoices by selecting 'Send via Peppol' option in the send & print wizard.
- Receiving peppol documents.

task-3159912

closes odoo/odoo#119120

Signed-off-by: Laurent Smet <las@odoo.com>
2023-05-11 18:25:03 +02:00
aliya 8590c6a929 [IMP] account_edi_proxy_client,l10n_it_edi: remove edi format dependency
Edi format is going to be removed eventually - `account_edi_proxy_client` should not depend on it and be more flexible in general.

This commit:
- Removes edi_format field from `account_edi_proxy_client.user` model. We still have to add them in `l10n_it_edi` as it still heavily relies on edi format for now.
- Adds a way to have a unique edi user per company, proxy user, edi mode combination.

This is a necessary step before adding peppol, which will also depend on the account_edi_proxy_client

closes odoo/odoo#116059

Related: odoo/upgrade#4458
Signed-off-by: Laurent Smet <las@odoo.com>
2023-04-17 16:34:44 +02:00
Paolo Gatti (pgi) 2a3d65e3e9 [IMP] account_edi_proxy_client: Debug views added
Added views and menuitems for account_edi.document
and account_edi_proxy_client.user, so that our technical team
will be autonomous in its investigations.

Task link: https://www.odoo.com/web#model=project.task&id=3204255
Task-3204255

closes odoo/odoo#115751

X-original-commit: 5e771b131e85b42a747936daf698f62fe2b125b5
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Paolo Gatti (pgi) <pgi@odoo.com>
2023-03-18 03:32:40 +01:00
Paolo Gatti (pgi) a03549d771 [IMP] account, account_edi, l10n_it_edi: allow link from imported VB to PO, fixes
Every imported vendor bill now will have the chance to make its invoice_origin linked to a Purchase Order.
The function is moved from account_journal to account_edi_format to allow the link being done from all webservices, thread attachments and upload.

- Avoid mocking the proxy testing

The test on the check that the same attachment is coming twice from the proxy doesn't actually need to test the proxy. By splitting the function, we avoid mocking the proxy for no added value. Added an ir.rule for companies to only look for their account_edi_proxy_client.users

- PA Index label should be Destination Code

PA Index is a completely wrong description. This is the destination "address" of the partner at which our EDI documents (invoices) should be directed to inside the SdI e-invoicing system, much like an IP address. It's not an index, doesn't have much to share with the Public Administration. The correct literal translation of the name should be "Destination Code"
for Codice Destinatario. We have clients opening tickets because they don't recognize this field on the partner form because of the wrong translation.

- Fixes on taxes import

Lines didn't have their taxes cleared, so invoices actually added the taxes in the XML to the default supplier taxes of the product VAT taxes on import search was conflicting with actual withholding / pension fund taxes, so extra conditions are added in the search if withholding / pension fund fields are not specified

Task link: https://www.odoo.com/web#id=3175353&model=project.task
Task-3175353

closes odoo/odoo#114870

Forward-port-of: #111365
Signed-off-by: Josse Colpaert <jco@odoo.com>
2023-03-15 16:08:08 +01:00
Denis Ledoux b4a7996e96 [IMP] base, *: change the API of init hooks to pass env
This is mostly a cleaning/refactoring change.

The current API for init hooks (pre, post, uninstall) is to pass
`cr, registry`.
But the first thing which was done by most
post init and uninstall hooks was to create an env using
the cr passed
e.g.
`env = api.Environment(cr, SUPERUSER_ID, {})`
and the `registry` argument was unused in all these hooks,
completely.

By changing the API of hooks to pass `env` instead
of `cr, registry`, we gain in average two lines in every
hooks:
- the line creating the env `env = api.Environment(cr, SUPERUSER_ID, {})`
- the line importing `api` and `SUPERUSER_ID`

Therefore removing ~250 lines of repeated code lines accross odoo/odoo and
odoo/enterprise.
In addition to these lines removed,
it also ease the API of init hooks for Odoo developers,
who are used to that `env` and not so much how to create an `env`
from a cursor.

Part-of: odoo/odoo#108254
2023-02-01 10:25:01 +01:00
Xavier-Do cd765440b3 [FIX] account_edi_proxy_client: truncate invalid constraints name
closes odoo/odoo#109065

Related: odoo/enterprise#35424
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2023-01-16 09:32:51 +01:00
Laurent Desausoi 7593c073d2 [IMP] core: use inert SQL based neutralization
Before this commit the neutralize system introduced in v16 was using ORM
methods in order to change appropriate records. Although flexible, this approach
could lead to call some methods with side effects while neutralizing
(eg: overloads of write).

This patch converts the neutralize system to a safer "inert" SQL based approach
by migrating the generic method _neutralize to SQL files exposed in the
data folder.

Task id: 2961687

closes odoo/odoo#102792

X-original-commit: e5dbded9bb363351feff7ca8a56c7f8a6860f492
Related: odoo/enterprise#32580
Signed-off-by: Fabien Meghazi <fme@odoo.com>
2022-10-09 22:04:00 +02:00
Fabien Pinckaers 781a771295 [IMP] remove duplicated index
The following indexes were in double:
- ir_module_module_name_index, ir_module_module_name_uniq
- ir_model_obj_name_uniq, ir_model_model_index
- ir_config_parameter_key_index, ir_config_parameter_key_uniq
- decimal_precision_name_index, decimal_precision_name_uniq
- account_edi_proxy_client_user_id_client_index, account_edi_proxy_client_user_unique_id_client
- mail_channel_rtc_session_channel_member_id_index, mail_channel_rtc_session_channel_member_unique
- loyalty_card_code_index, loyalty_card_card_code_unique

Part-of: odoo/odoo#99795
2022-09-08 12:46:50 +02:00
Raphael Collet 6cf8db906f [REF] *: adapt code to new flush API
closes odoo/odoo#87527

Related: odoo/upgrade#3497
Related: odoo/enterprise#26939
Signed-off-by: Raphael Collet <rco@odoo.com>
2022-05-25 18:00:47 +02:00
Victor Feyens 42bad1a6d2 [IMP] *: remove useless keys from manifests
Remove most values uselessly specified because giving the same value as 
the default one (see _DEFAULT_MANIFEST in odoo/modules/module.py)

* auto_install is Falsy by default
* author is Odoo SA by default
* summary & description are empty strings by default
* application is False by default
* test, demo, depends and data are empty lists by default

This will reduce noise/inconsistencies between manifests specifications, 
simplify analysis of manifests content, ...

closes odoo/odoo#90209

Related: odoo/enterprise#26807
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-05-03 13:31:16 +02:00
dbkosky 57874da264 [FIX] account_edi_proxy_user: update test server url
The proxy test server has been updated, and there is a new url, this
commit updates the default server constant in the code to match the new
url.

closes odoo/odoo#87271

X-original-commit: d1485227096a6bf1d473c6d3c26ca54dbffbe3e0
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Daniel Kosky (dako) <dako@odoo.com>
2022-03-29 10:56:30 +02:00
dbkosky b19021b047 [FIX] account_edi_proxy_client: don't update the demo state
The issue is that the config param is data, which means that when the
module is updated, the config parameter will be updated (i.e. reset to
the 'demo' state), which will cause havoc on client databases. Even if
we set the record to 'noupdate=1', the existing clients will have the
record updated.

The solution is to remove the config param from the data entirely, thus
preventing it from being updated when updating the module, and instead
have a 'post_init_hook' that sets the parameter to 'demo' (this will
only happen when the module is installed, and never again).

closes odoo/odoo#86607

X-original-commit: 1d3cd7ee32caede10cd4ffd496ffd59a4103b04f
Signed-off-by: Josse Colpaert <jco@odoo.com>
2022-03-18 00:22:51 +01:00
dbkosky dae20acffb [FIX] l10n_it_edi_sdicoop: adapt user registration on res_config_settings
To properly register account_edi_proxy_client.user when saving the res
config settings page, the radio buttons needed to be modified, and the
'register' button was adapted to be a checkbox instead.

Registering multiple demo proxy clients lead to an error, as it is
asserted that id_client should be unique, and the demo client has
'id_client': 'demo'.
To fix this, the id of a demo client is 'demo' + the company id.
Searching for demo clients is adapted to search on the first four
characters.

closes odoo/odoo#85794

X-original-commit: 54e54466f0858d4b19fa8f61ff2b927e00f8f5a8
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Daniel Kosky (dako) <dako@odoo.com>
2022-03-09 11:21:47 +00:00
Josse Colpaert 54dea0d81a [FIX] l10n_it_edi_sdicoop: fix access rights so demo user can send invoices
As the proxy client user can only be accessed by base.group_system,
we need a sudo() to make it possible for a regular user to send
invoices.

closes odoo/odoo#85566

X-original-commit: 79a076b832a785b78ed6d73d539d3eae6eb2fd02
Signed-off-by: William André (wan) <wan@odoo.com>
2022-03-01 03:23:05 +00:00
Josse Colpaert 8e6595857c [FIX] account_edi_proxy_client, l10n_it_edi_sdicoop: timeouts and concurrency
- Sometimes the refresh_token is not saved in the db because the code
after it fails (timeout).  We also want to avoid 2 processes
trying to renew the token at the same time (=> avoid desynchronization
of the refresh_token)

So, we added a locking mechanism and do a commit after we refresh the
token.

- If we have very big invoices to receive, they do not get imported into
the database.  At the moment we risk timeouts.

Our solution is to do a lot of intermediary commits and we link it
to a temporary account_move before doing the import logic and maybe
putting it into the definitive one.

closes odoo/odoo#85372

X-original-commit: ce47d09c05e4bcc91ee4de68db3a7a471bcb4df8
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Josse Colpaert <jco@odoo.com>
2022-02-25 09:22:56 +00:00
Paolo (pgi) d2d50ba63b [ADD] l10n_it_edi_sdicoop: user settings for demo mode
- A new flag is added to the Setting (l10n_it_edi_sdicoop_demo_mode)
  that is computed from the ir.config_parameter
  'account_edi_proxy_client.demo'.

  If the flag is 'demo', Odoo will not send invoices through the EDI,
  if the flag is 'test', Odoo will send invoices to an IAP test server
  instance that operates with a test SDICoop service
  if the flag is 'prod', Odoo will send invoices to production IAP,
  that routes them to the official SDICoop service.

- Some minor UI rework for the EDI parameters on res.company
  The EDI settings in the res_company form, under the
  'Electronic Invoicing' tab, must stay on the left

closes odoo/odoo#84925

X-original-commit: c5d049c55d21f9885e79182df2bd5f433c5bb782
Signed-off-by: Josse Colpaert <jco@odoo.com>
2022-02-18 18:13:37 +00:00
dbkosky 732f21dd71 [FIX] account_edi_proxy_client, l10n_it_edi_sdicoop: adapt config params to make use of the test iap server
This commit adapts the l10n_it_edi_sdicoop and account_edi_proxy_client
modules to make use of the existing config param
'account_edi_proxy_client.demo' in order to target the correct odoo iap
server for italian edi requests.

When the config param is set to:
'prod' or False (when the config param doesn't exist): Target the
production odoo iap server (by default), which submits and collects edi from the
production channel. Though if the config parameter
'account_edi_proxy_client.edi_server_url' exists, we use the value
provided there instead.

'test': Target the test odoo iap server, which submits and collects edi
from the test channel

'demo' or anything else not above: don't send anything, and simulate the
flow of italian edi submissions in odoo

task-id 2764978

X-original-commit: 32683b70a34a900a112d19bf780446a973753ae5
Part-of: odoo/odoo#84826
2022-02-18 10:46:46 +00:00
Christophe Monniez e34430c822 [IMP] various: implement _neutralize method
As an overridable _neutralize model method was added in a previous
commit, the method is now implemented for various models.

closes odoo/odoo#67825

Related: odoo/enterprise#19042
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
2022-02-01 09:54:08 +00:00
Martin Trigaux a8e50921af [FIX] *: correct typos and English errors
closes odoo/odoo#80181

X-original-commit: efd178daee689192d4e930a075475587038b3e0d
Related: odoo/enterprise#22439
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-11-22 14:48:04 +00:00
Paolo (pgi) ce8156d00d [IMP] account_edi_proxy_client: Making the EDI Iap server configurable
There is a test_mode to allow experimentation on the IAP server.
To be able to switch between the two, we need to make the
SERVER_URL configurable.

closes odoo/odoo#77977

X-original-commit: 11be1b25c60ae27a5e8078802883a1db867a6452
Signed-off-by: Josse Colpaert <jco@openerp.com>
Signed-off-by: Paolo Gatti <lordkrandel@users.noreply.github.com>
2021-10-07 14:17:34 +00:00
Paolo (pgi) 7e05dbbad0 [FIX] account_edi_proxy_client, l10n_it_edi, l10n_it_edi_sdicoop: Fixing Base64 issues
When encoding a string or bytes with base64,
the resulting byte string must be decoded
to get the string back.

* `addons/account_edi_proxy_client/models/account_edi_proxy_user.py`
  AccountEdiProxyUser._register_proxy_user()

* `addons/l10n_it_edi/models/account_invoice.py`
  AccountMove._prepare_fatturapa_export_values()

* `addons/l10n_it_edi_sdicoop/models/account_edi_format.py`
  AccountEdiFormat._l10n_it_post_invoices_step_1()

X-original-commit: 3a705d93543e910b6af4b3b4aa53c523f367782a
Part-of: odoo/odoo#77977
2021-10-07 14:17:33 +00:00