Thursday, October 29, 2020
38 changes · master
Enhancements to existing features
This update introduces standardized names and helper functions for managing linked record lists, replacing hard-coded numeric commands across Odoo. It makes the code easier for developers to read and maintain while preserving compatibility with older frontend command names.
Original PR description
One2many and Many2many use a special "commands" format to manipulate the set of records stored in/linked to the field. There is a total of 7 commands: `create`, `update`, `delete`, `unlink`, `link`,…
One2many and Many2many use a special "commands" format to manipulate the set of records stored in/linked to the field. There is a total of 7 commands: `create`, `update`, `delete`, `unlink`, `link`, and `set`. * The `create` command (id: 0) is used to create a new record in the related model and to link it in the current record. * The `update` command (id: 1) is used to update the targeted record id with new values. * The `delete` command (id: 2) is used to both remove the target record id from the related table and to remove its link from the current record. * The `unlink` command (id: 3) is used to remove the link to the targeted record id from the current record. * The `link` command (id: 4) is used to link the targeted record id which exists already in the related model in the current record. * The `clear` command (id: 5) is used to empty the list of linked record ids. * The `set` command (id: 6) is used to replace the list of linked record ids with the provided. Each command is a tuple with up to 3 elements, the second and/or third element is ignored when it is not applicable to the command: 1) the mandatory command identifier 2) the targeted record id (1, 2, 3, 4) 3) create/write values dictionary (0, 1) or target record ids (6) -- Before this contribution, the several commands did not have a standardized name, the tuples were just hard-coded with the integer identifier. For long developers have been complaining the commands were hard to write and hard to read mainly due to the meaningless integer. This contribution provide a new namespace with the constants and functions desired to ease writting and reading the X2Many commands. All modules have been updated to use the new constants instead of the integer identifier. On the frontend side, such constants (in the form of strings) do exist already but do not conform to the new standardized names. It has been decided to enforce the new nomenclature but to provide aliases to the old names to ensure a better compatibility. Task: 2366606
This change standardizes the way Odoo code refers to commands that update linked records, replacing hard-coded numbers with clear names. It improves maintainability and reduces the risk of developer mistakes, while preserving compatibility with older frontend command names.
Original PR description
One2many and Many2many use a special "commands" format to manipulate the set of records stored in/linked to the field. There is a total of 7 commands: `create`, `update`, `delete`, `unlink`, `link`,…
Resolved issues and error corrections
This change fixes an unreliable automated test in the Belgian payroll accounting area. It prevents random test failures caused by changing demo data dependencies, helping keep build results dependable without changing user-facing behavior.
Original PR description
Since this test is designed to be dependent of demo data, it depends of already installed modules that is not deterministic. Therefore, this test is causing red build everywhere.
Miscellaneous changes
Currently the delivery date on PO line will always be set to today if there is no receipt date on PO, which makes the delivery lead time not working. Fixed this issue in this commit. Task 2357198 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60047
Original PR description
Currently the delivery date on PO line will always be set to today if there is no receipt date on PO, which makes the delivery lead time not working. Fixed this issue in this commit. Task 2357198 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60047
One2many and Many2many use a special "commands" format to manipulate the set of records stored in/linked to the field. There is a total of 7 commands: `create`, `update`, `delete`, `unlink`, `link`, and `set`. * The `create` command (id: 0) is used to create a new record in the related model and to link it in the current record. * The `update` command (id: 1) is used to update the targeted record id with new values. * The `delete` command (id: 2) is used to both remove the target record id from the related table and to remove its link from the current record. * The `unlink` command (id: 3) is used to remove the link to the targeted record id from the current record. * The `link` command (id: 4) is used to link the targeted record id which exists already in the related model in the current record. * The `clear` command (id: 5) is used to empty the list of linked record ids. * The `set` command (id: 6) is used to replace the list of linked record ids with the provided. Each command is a tuple with up to 3 elements, the second and/or third element is ignored when it is not applicable to the command: 1) the mandatory command identifier 2) the targeted record id (1, 2, 3, 4) 3) create/write values dictionary (0, 1) or target record ids (6) -- Before this contribution, the several commands did not have a standardized name, the tuples were just hard-coded with the integer identifier. For long developers have been complaining the commands were hard to write and hard to read mainly due to the meaningless integer. This contribution provide a new namespace with the constants and functions desired to ease writting and reading the X2Many commands. All modules have been updated to use the new constants instead of the integer identifier. On the frontend side, such constants (in the form of strings) do exist already but do not conform to the new standardized names. It has been decided to enforce the new nomenclature but to provide aliases to the old names to ensure a better compatibility. Task: 2366606
This fix improves the reliability of dashboard behavior by ensuring the Measures menu is available before tests or actions continue. It helps prevent intermittent issues that could make dashboard-related checks fail unexpectedly.
Original PR description
The commit ee5461038cebbde234a5897d448e62c94e7e21dd did not complete the job as expected. The present commit should.
In current Debian version (0.19) ofxparse gives the following warning: ofxparse/ofxparse.py:40: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.9 it will stop working return isinstance(candidate, collections.Iterable) Since we can't do anything about it, we filter it for now. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is m
Original PR description
In current Debian version (0.19) ofxparse gives the following warning: ofxparse/ofxparse.py:40: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.9 it will stop working return isinstance(candidate, collections.Iterable) Since we can't do anything about it, we filter it for now. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60805
- Use the tax tags returned by the compute_all for the base lines instead of recomputing them separately Splitting the computation caused inconsistent computation in some cases between the base and tax lines (one could select the refund distribution, while the other selected the invoice one). - Pass the is_refund parameter to True if either the quantity or the price is negative (but not both) Those negative lines should correspond to refund repartition (double-checked with the Belgian t
Original PR description
- Use the tax tags returned by the compute_all for the base lines instead of recomputing them separately Splitting the computation caused inconsistent computation in some cases between the base and tax lines (one could select the refund distribution, while the other selected the invoice one). - Pass the is_refund parameter to True if either the quantity or the price is negative (but not both) Those negative lines should correspond to refund repartition (double-checked with the Belgian tax report in v12). OPW 2351412 Forward-Port-Of: odoo/odoo#60852 Forward-Port-Of: odoo/odoo#60798
- Activate stock locations - Go to Inventory > Configuration > Locations - Click on the 'Products' stat button The filters `real_stock_available` and `real_stock_negative` are not applied although they are in `search_default_`. This is due to c1f7987f493ca655390 which refactored the various search views of products. The solution is to add the `search_view_id` in the action. However: - `<act_window>` doesn't support it - `<act_window>` is deprecated in 14.0 Therefore, we convert
Original PR description
- Activate stock locations - Go to Inventory > Configuration > Locations - Click on the 'Products' stat button The filters `real_stock_available` and `real_stock_negative` are not applied although they are in `search_default_`. This is due to c1f7987f493ca655390 which refactored the various search views of products. The solution is to add the `search_view_id` in the action. However: - `<act_window>` doesn't support it - `<act_window>` is deprecated in 14.0 Therefore, we convert the `act_window` element into a regular `record` and add the appropriate `search_view_id`. opw-2371962 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60920 Forward-Port-Of: odoo/odoo#60882
In order to ease the usage of lazy translation, add the possibility to add the `_lt` objects together and with strings. Adding two `_lt` objects together or to a string will execute their translation, so these operations still must be done once the user's language has been defined. For example, this is now possible: ```python MESSAGES = { 1: _lt("Hello, world!"), 2: _lt("Lorem ipsum"), } def get_text(code): return _("Text is: ") + MESSAGES[code] ``` Forward-Port-Of:
Original PR description
In order to ease the usage of lazy translation, add the possibility to add the `_lt` objects together and with strings.
Adding two `_lt` objects together or to a string will execute their translation, so these operations still must be done once the user's
language has been defined.
For example, this is now possible:
```python
MESSAGES = {
1: _lt("Hello, world!"),
2: _lt("Lorem ipsum"),
}
def get_text(code):
return _("Text is: ") + MESSAGES[code]
```
Forward-Port-Of: odoo/odoo#60804… module The payment token is no longer available when registering a payment for invoices. This new module aims to restore this lost feature during the payment-pocalyse in stable version. Of course, this module must be merged in existing modules during the forwart-port in master. task: 2352628 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60289
Original PR description
… module The payment token is no longer available when registering a payment for invoices. This new module aims to restore this lost feature during the payment-pocalyse in stable version. Of course, this module must be merged in existing modules during the forwart-port in master. task: 2352628 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60289
-- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60910
Original PR description
-- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60910
context was lost while replacing field `email` during https://github.com/odoo/odoo/blob/d62d1e23c876b6154d1ef8d972a482e280430f34/addons/mail/views/res_partner_views.xml#L16 With this commit, we add the same context which is present at the original field at https://github.com/odoo/odoo/blob/12.0/odoo/addons/base/views/res_partner_views.xml#L260 Fixes: #50978 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged:
Original PR description
context was lost while replacing field `email` during https://github.com/odoo/odoo/blob/d62d1e23c876b6154d1ef8d972a482e280430f34/addons/mail/views/res_partner_views.xml#L16 With this commit, we add the same context which is present at the original field at https://github.com/odoo/odoo/blob/12.0/odoo/addons/base/views/res_partner_views.xml#L260 Fixes: #50978 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr courtesy of @skeller1 Forward-Port-Of: odoo/odoo#54758 Forward-Port-Of: odoo/odoo#50980
- Some tax_base_amounts checks were missing - The type of repartition used to generate tax lines was not tested; it made the test confusing (as in this case, sales taxes invert their tag, given here the impression the wrong repartition was used, and potentially shadowing a bug) Forward-Port-Of: odoo/odoo#60905 Forward-Port-Of: odoo/odoo#60884
Original PR description
- Some tax_base_amounts checks were missing - The type of repartition used to generate tax lines was not tested; it made the test confusing (as in this case, sales taxes invert their tag, given here the impression the wrong repartition was used, and potentially shadowing a bug) Forward-Port-Of: odoo/odoo#60905 Forward-Port-Of: odoo/odoo#60884
Issue - Install "Accounting" - Go to "Accounting Overview/Invoices" - Switch to kanban view Cause The wrong field ("journal_id") was present instead of "partner_id" Solution Change with "partner_id" opw-2367738 Forward-Port-Of: odoo/odoo#60901
Original PR description
Issue
- Install "Accounting"
- Go to "Accounting Overview/Invoices"
- Switch to kanban view
Cause
The wrong field ("journal_id") was present instead of "partner_id"
Solution
Change with "partner_id"
opw-2367738
Forward-Port-Of: odoo/odoo#60901ValueError: Expected singleton: resource.calendar() Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60563
Original PR description
ValueError: Expected singleton: resource.calendar() Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60563
Show a nice error message when starting negative transactions on Adyen terminals. opw-2368978 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60961
Original PR description
Show a nice error message when starting negative transactions on Adyen terminals. opw-2368978 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60961
Use of '_for_xml_id' instead of read in order to avoid access right issue on 'ir.actions.act_window'. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60853
Original PR description
Use of '_for_xml_id' instead of read in order to avoid access right issue on 'ir.actions.act_window'. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60853
These lines have an additional column making reconcile=True instead of False and chart_template_id=False. Note: For some reasons, chart_template_id is not required on account.account.template. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60959
Original PR description
These lines have an additional column making reconcile=True instead of False and chart_template_id=False. Note: For some reasons, chart_template_id is not required on account.account.template. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60959
This commit adds a test case for the multi-company chat. LINKS: PR #47398 Task 2207147 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60973 Forward-Port-Of: odoo/odoo#47398
Original PR description
This commit adds a test case for the multi-company chat. LINKS: PR #47398 Task 2207147 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60973 Forward-Port-Of: odoo/odoo#47398
The icon of the chrome app from the timesheet setting should not be displayed on mobile. Task-Id: 2323254 Forward-Port-Of: odoo/odoo#59333
Original PR description
The icon of the chrome app from the timesheet setting should not be displayed on mobile. Task-Id: 2323254 Forward-Port-Of: odoo/odoo#59333
Before this commit, the badges' background color was not possible to edit: the previews were done correctly but the background color was removed after final selection. This was because the background color property is animated on badges, messing with the related edition function. Closes https://github.com/odoo/odoo/issues/59337 Forward-Port-Of: odoo/odoo#60742 Forward-Port-Of: odoo/odoo#60717
Original PR description
Before this commit, the badges' background color was not possible to edit: the previews were done correctly but the background color was removed after final selection. This was because the background color property is animated on badges, messing with the related edition function. Closes https://github.com/odoo/odoo/issues/59337 Forward-Port-Of: odoo/odoo#60742 Forward-Port-Of: odoo/odoo#60717
In order to allow modifying background images, we need information on the image, this is done by creating a placeholder img and calling the loadImageInfo function on it. However this function did not account for the case where an image had not src attribute, which causes an unnecessary rpc. Other problems could arise from this as an attachment that doesn't have the correct mimetype but has a matching src could be returned, causing its image_src field to be false, which we would then attem
Original PR description
In order to allow modifying background images, we need information on the image, this is done by creating a placeholder img and calling the loadImageInfo function on it. However this function did not account for the case where an image had not src attribute, which causes an unnecessary rpc. Other problems could arise from this as an attachment that doesn't have the correct mimetype but has a matching src could be returned, causing its image_src field to be false, which we would then attempt to load as a valid image, causing crashes. This commit fixes that by not trying to load image infos when the src of an image is empty, only looking for attachments of the supported mimetypes, and also checking that we actually did receive an image_src before setting it as the original src of the image, which will prevent accidentally trying to load a falsy src as an actual image. Forward-Port-Of: odoo/odoo#60953
When creating a vehicle from the user that have no administration rights it gives an error in security rules. In this task, we fix this issue. task - 2309192 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#56192
Original PR description
When creating a vehicle from the user that have no administration rights it gives an error in security rules. In this task, we fix this issue. task - 2309192 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#56192
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60952
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60952
In the odoorc file, set a `logfile` path, but disable it via the command line with `--logfile=`. The logs are output to the logfile configured in the config file instead of stdout. Parsing `--logile=` yield an empty string which was interpreted as argument not set and skipped. Closes #3852 Forward-Port-Of: odoo/odoo#55737
Original PR description
In the odoorc file, set a `logfile` path, but disable it via the command line with `--logfile=`. The logs are output to the logfile configured in the config file instead of stdout. Parsing `--logile=` yield an empty string which was interpreted as argument not set and skipped. Closes #3852 Forward-Port-Of: odoo/odoo#55737
Create 3 items: * FP ** manufactured from SFP ** reordering rule ** manufacture lead time 2 days * SFP ** manufactured from CP ** reordering rule ** manufacture lead time 2 days * CP ** buy from vendor ** reordering rule ** manufacture lead time 2 days Create a sales quotation: * Product: FP * Delivery Date: +7 days from now Save and confirm Run scheduler. No Manufacturing process will be started. This occur because the reordering rule (orderpoint) will check
Original PR description
Create 3 items: * FP ** manufactured from SFP ** reordering rule ** manufacture lead time 2 days * SFP ** manufactured from CP ** reordering rule ** manufacture lead time 2 days * CP ** buy from vendor ** reordering rule ** manufacture lead time 2 days Create a sales quotation: * Product: FP * Delivery Date: +7 days from now Save and confirm Run scheduler. No Manufacturing process will be started. This occur because the reordering rule (orderpoint) will check the quantity needed using the date scheduled for the MO without delay, while the move are being generated for the delivery date specified by the user, so no quantity will be scheduled for production. opw-2366925 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60845
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60669
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#60669
also fix a problem with composer.hasFocus field not always correctly updated (e.g. when switching from a channel to another in discuss) task-2278915 Forward-Port-Of: odoo/odoo#60079
Original PR description
also fix a problem with composer.hasFocus field not always correctly updated (e.g. when switching from a channel to another in discuss) task-2278915 Forward-Port-Of: odoo/odoo#60079
Missing `alert` class create an unwanted margin inside the form view. task-2343736 Forward-Port-Of: odoo/enterprise#13555
Original PR description
Missing `alert` class create an unwanted margin inside the form view. task-2343736 Forward-Port-Of: odoo/enterprise#13555
Currently, when user chnage the lang like french tour stop after click on 'Adopt and Sign' So in this commit, tour is continue after click on 'Adopt and Sign' TaskID: 2335283 Forward-Port-Of: odoo/enterprise#13200
Original PR description
Currently, when user chnage the lang like french tour stop after click on 'Adopt and Sign' So in this commit, tour is continue after click on 'Adopt and Sign' TaskID: 2335283 Forward-Port-Of: odoo/enterprise#13200
currently, in saas13.3 when we create a task and save so field in field service it switches back to false so, in this commit the so field is correctly saved when we create a task. TaskId: 2345357 Forward-Port-Of: odoo/enterprise#14133 Forward-Port-Of: odoo/enterprise#13668
Original PR description
currently, in saas13.3 when we create a task and save so field in field service it switches back to false so, in this commit the so field is correctly saved when we create a task. TaskId: 2345357 Forward-Port-Of: odoo/enterprise#14133 Forward-Port-Of: odoo/enterprise#13668
Currently, Pivot and grid view is migrated to the owl so old mixin which override the _renderview method will not work so to fix that we need a new mixin and keep the old mixin as it is used in other view. So in this commit, create a new mixin for QRcode, to enable the play store icon click events and open the QRcode in wizard for desktop view and direct link for mobile view. TaskID: 2323254 Forward-Port-Of: odoo/enterprise#13615
Original PR description
Currently, Pivot and grid view is migrated to the owl so old mixin which override the _renderview method will not work so to fix that we need a new mixin and keep the old mixin as it is used in other view. So in this commit, create a new mixin for QRcode, to enable the play store icon click events and open the QRcode in wizard for desktop view and direct link for mobile view. TaskID: 2323254 Forward-Port-Of: odoo/enterprise#13615
Issue - Create a project and the name of the project contains '/' - Create a task in the project, fill the 'Start date', 'End date' and 'assigned to' field - Go to 'All tasks' and switch to Gantt view - Group by 'Project > Assigned to' JS error: "Unexpected end of JSON input". Cause The Gantt model use '/' as a separator to create unique paths. When a group of combinaison ends up with "Assigned to" group and the username contains '/', the path will be broken since can
Original PR description
Issue - Create a project and the name of the project contains '/' - Create a task in the project, fill the 'Start date', 'End date' and 'assigned to' field - Go to 'All tasks' and switch to Gantt view - Group by 'Project > Assigned to' JS error: "Unexpected end of JSON input". Cause The Gantt model use '/' as a separator to create unique paths. When a group of combinaison ends up with "Assigned to" group and the username contains '/', the path will be broken since cannot differenciate separator anymore. Solution Replace the separator '/' with '\n', should be less common to have it in a user name. opw-2368910 Forward-Port-Of: odoo/enterprise#14455
Purpose ======= Ensure the validity of several CP200 payslips, like the commissions/warrant and some corner cases in credit time payslips. For the use cases see: https://docs.google.com/document/d/1Q1cdgSP7bzf_ZC8FYEO06AX8WkMqNVD-VtDIqaOhZys/edit#heading=h.j9uf3hnxs7e TaskID: 2371907 Forward-Port-Of: odoo/enterprise#14452 Forward-Port-Of: odoo/enterprise#14304
Original PR description
Purpose ======= Ensure the validity of several CP200 payslips, like the commissions/warrant and some corner cases in credit time payslips. For the use cases see: https://docs.google.com/document/d/1Q1cdgSP7bzf_ZC8FYEO06AX8WkMqNVD-VtDIqaOhZys/edit#heading=h.j9uf3hnxs7e TaskID: 2371907 Forward-Port-Of: odoo/enterprise#14452 Forward-Port-Of: odoo/enterprise#14304
The total in foreign currency has been removed by: https://github.com/odoo/enterprise/pull/14013/commits/d9cfe2a64995f262d8b9a8897377f84c7fefd86b However, when the currency is set on the account, all journal items using this account should share the same currency. This commit re-adds this total in foreign currency but under the condition the account is well configurated as using a foreign currency. Forward-Port-Of: odoo/enterprise#14423 Forward-Port-Of: odoo/enterprise#14245
Original PR description
The total in foreign currency has been removed by: https://github.com/odoo/enterprise/pull/14013/commits/d9cfe2a64995f262d8b9a8897377f84c7fefd86b However, when the currency is set on the account, all journal items using this account should share the same currency. This commit re-adds this total in foreign currency but under the condition the account is well configurated as using a foreign currency. Forward-Port-Of: odoo/enterprise#14423 Forward-Port-Of: odoo/enterprise#14245
Forward-Port-Of: odoo/enterprise#14449
Original PR description
Forward-Port-Of: odoo/enterprise#14449
### task 381 To reproduce the bug: - Go to accounting settings and change the configuration "Verify Vendor Bills validity in AFIP" to available - Create a vendor bill from an argentinean partner (e.g. "ADHOC SA") - In the field AFIP authorization select "CAE" and complete with a random number - Save and a traceback will happen after hitting print It happens because we are trying to generate a barcode without the due date of the invoice (which one we don't have it because is a vendor
Original PR description
### task 381 To reproduce the bug: - Go to accounting settings and change the configuration "Verify Vendor Bills validity in AFIP" to available - Create a vendor bill from an argentinean partner (e.g. "ADHOC SA") - In the field AFIP authorization select "CAE" and complete with a random number - Save and a traceback will happen after hitting print It happens because we are trying to generate a barcode without the due date of the invoice (which one we don't have it because is a vendor bill) The propoused solution is to check if we have that date before generating the barcode Forward-Port-Of: odoo/enterprise#13772
- Go to Field Service > Configuration > Settings and enable "Worksheet Templates" - Create 2 internal users with the following rights: (i.e. User X and User Y) * Sales: User: All Documents * Field Service: User * Project: User - Go to Sales and create a Quotation with Product "Field Service" - Save and Confirm (A task should be created) - Connect with User X - Go to Field Service and open the created task - Click on Worksheet smart button and save a comment - Connect with User Y
Original PR description
- Go to Field Service > Configuration > Settings and enable "Worksheet Templates" - Create 2 internal users with the following rights: (i.e. User X and User Y) * Sales: User: All Documents * Field…
- Go to Field Service > Configuration > Settings and enable "Worksheet Templates" - Create 2 internal users with the following rights: (i.e. User X and User Y) * Sales: User: All Documents * Field Service: User * Project: User - Go to Sales and create a Quotation with Product "Field Service" - Save and Confirm (A task should be created) - Connect with User X - Go to Field Service and open the created task - Click on Worksheet smart button and save a comment - Connect with User Y - Go to Field Service and open the created task There is no indication on Worksheet smart button signaling that it is completed. If User Y click on the smart button, he will not see previously entered comment and will be able to enter his own comment. But when trying to save it, the following error will be raised: "duplicate key value violates unique constraint "x_project_worksheet_template_1_x_task_id_uniq" DETAIL: Key (x_task_id)=(42) already exists." A Project user can edit a Worksheet, but he can only view the ones he has created. So, when on a Task, he will not see if a Worksheet has already been done by someone else, but will be able to create one. As there can only be one Worksheet by Task, the unicity error is raised. This commit will allow FSM users to view and edit all Worksheets. This would prevent to force an user with the Project manager rights to allow him to be able to view and edit an existing Worksheet. opw-2368606 Forward-Port-Of: odoo/enterprise#14444