The main goal of this task is to apply the same style used by
event_barcode.
A new button "tap to scan" is now available in some barcode
screens to use the phone camera.
Task ID: 2210396
closesodoo/odoo#50118
Related: odoo/enterprise#9616
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
odoo/odoo#42015 removed code supporting the sales/CRM dashboards which
hadn't been a thing for two years at that point.
This is doubly dead code as it's an override for the dead code which
has already been removed for a feature which hasn't existed since
2017.
Issue 2285940
closesodoo/odoo#53891
X-original-commit: 1d73a1a7c52fcc3a3ab29446b9ca3b6e4d95b451
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Steps to reproduce:
- Let's consider a user U with no access to hr.attendance
- Let's consider that U has made some check in and check out
- Log with U
- Go to your profile and on Last month
Bug:
U can modifiy manually his attendances.
opw:2279682
closesodoo/odoo#53878
X-original-commit: 53a4a95270622f3aa08136470fb627d51ed4b365
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
- Install Accounting, Point of Sale
- Go to Accounting > Configuration > Taxes
- Create 2 taxes (e.g. Tax 15% and Tax 21%)
- Go to Accounting > Configuration > Fiscal Positions
- Create a new Fiscal Postion with the following line for Tax Mapping:
* Tax on Product: Tax 21%
* Tax to Apply: Tax 15%
- Go to Point of Sale > Products > Products
- Create a new Product (e.g. Test Product) with "Tax 15%" and "Tax 21%" in Customer Taxes
(Make sure that the Tax 15% is the same than the one for the "Tax to Apply" in the Fiscal Position)
- Go to Point of Sale and configure a POS:
* Activate "Fiscal Position per Order" and choose the created Fiscal Position
* Add Bank as Payment Method
- Start a POS session
- Search "Test Product" and add it
- Click on Tax button and select the created Fiscal Position
- Proceed to payment
- Choose Bank and validate
- Exit the POS session
- Click on "CLOSE" and "VALIDATE CLOSING & POST ENTRIES"
An error message appeared with the following message: "Cannot create unbalanced journal entry"
When closing and posting entries, an account move and account move lines are created from the session orders.
For each order lines, taxes are computed from taxes on product and fiscal position of the order.
In this case, the product has 2 taxes applied (Tax 15% and Tax 21%).
Due to the chosen Fiscal Position, the Tax 15% is applied instead of Tax 21%.
For the order line, Tax 15% is applied 2 times.
But during the account move lines generation, the original Tax 15% and the converted Tax 15% are merged together,
because they represent the same tax (same model id).
So the Tax 15% is only applied once, which results on unbalanced amounts during reconciliation.
In Sales, for the same case, the tax is only applied once.
To stay consistent with Sales behavior, the tax will also be applied once in Point of Sale.
opw-2278826
closesodoo/odoo#53880
X-original-commit: 17a9feff69ec772bf3427dda886ae122fd6c7c2c
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
*: web_editor
Do not display the backdrop element added by bootstrap in the body and
add a background on the modal to keep the same effect. The bootstrap
backdrop was probably useful for compatibility with <IE9 but is no
longer needed. This also avoids z-index issues because modals could be
opened in an element (e.g. the website #wrapwrap) whose stacking context
is different of the body one (where the backdrop is opened). This would
make the backdrop appears on top of the modal.
Part of https://github.com/odoo/odoo/pull/49142
Related to task-2229551
Co-authored-by: qsm-odoo <qsm@odoo.com>
Before this commit the cart was hidden when it was empty. Now we have
added a new option to display it any time.
Part of https://github.com/odoo/odoo/pull/49142
task-2229551
This commit fixes all issues detected by the new pylint
gettext-variable test.
It converts some calls to the new syntax
_("Foo %s", bar)
to progressively migrate the code to the new syntax.
A few calls were not technically incorrect but still detected by the
linter.
_("Foo" +
"Bar")
has been converted to
_("Foo"
"Bar")
as it has the same effect and make sure the argument is of type
asteroid.Const instead of BinOp).
closesodoo/odoo#53683
Related: odoo/enterprise#11467
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
More often than it should, translations calls are made using
_("Foo %s" % bar)
instead of
_("Foo %s") % bar
or the even better (but more recent)
_("Foo %s", bar)
The issue of using the first writing is that the translation lookup
won't work at the execution (looking for ir.translation for src "Foo
Alice", "Foo Bob",... instead of "Foo %s").
Add a pylint test to ensure this won't happen anymore
Avoid returning False if, for any reason, the return is falsy (False,
None,...)
Following the discussion in odoo/odoo#53254, the root cause was a call in the form
_(foo)
where foo was equal False
While nothing else than a string should be the argument of _, it's
still technically possible to pass something else and get a bad return
value.
Fallback on empty string to be consistent.
Hide sections "Account Properties" & "Account Stock Properties" if the inventory
valuation (property_valuation) is set to manual.
task-2232026
closesodoo/odoo#52351
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
* Improve layout of access error messages from group restriction
* Improve layout of access error messages from security records rules
* Use the error title in the js crash manager when possible
* adapt unit tests
closesodoo/odoo#50369
Taskid: 2206787
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Currently, when the payment is done by the wire transfer or by sepa
then the transaction is going to be in the 'pending' state and due
to that confirmation mail will display the button as
'Sign and Pay Quotation' but is should be the 'view quotation'.
So in this commit we check for the last transaction and if transaction
status is 'pending' then display the 'View Quatation' instead of
'Sign and Pay Quatation'.
We have not modified method has_to_be_paid because it's used to display
the button on portal so still it will display the 'Sign and Pay' on portal.
closes odoo/odoo#49389
Taskid: 2210990
Closes: #49389
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Create some attributes with "create dynamically" set
Create a product template using these attributes (=> product variants
should not be created)
Set this product as manufactured, and create an associated BOM with some
components
Try to print the BOM
User will face a traceback due to the product_id being non existant
opw-2283649
closesodoo/odoo#53872
X-original-commit: 4d77ada68fb4d8113a5fbf95f20ccb49d0611fc5
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
This fix will complete the task 1965890 by allowing the user with
access rights to edit fields (reference, account_id, taxes_ids
& analytic_account_id) depending the sheet state.
Also added Tests to check if access rights on expense lines are
working well depending on the expense.sheet.state and the user group.
Task ID 2226352
closesodoo/odoo#53862
X-original-commit: f42c812916a50438078210c020f6144c7417d365
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: bon-odoo <nboulif@users.noreply.github.com>
- Create a new POS session with User A
- Make an order
- Logout and connect as User B
- Resume the session
The session cannot be resumed and the user is redirected to the POS
Dashboard.
When searching for a session to resume, the search restricts the user to
the current user. Therefore, no session is found.
If no session is found, we search on sessions corresponding to the given
configuration. The configuration is mandatory to avoid being redirected
to a random session.
opw-2274973
X-original-commit: 2deb94aa9da821455374df5602e2d30c5befcdec
The on_attach_callback methods on the widgets (comming from a tag
'widget') of a form renderer were not called at an appropriate time.
They were not called at all or called before the widgets were actually
in the dom. This was made manifest in the dashboards that generally use
pie charts widgets. Each time a pie chart widget is renderered,
a new canvas with a unique id is created. The above mentioned problem
explains why Chart.js was not able to acquire the canvas contexts: they
are obtained by looking for a specific id in the dom.
The present commit fixes that problem by doing in the class FormRenderer
what was already done correctly in the child class DashboardRenderer and
remove the unapropriate calls to on_attach_callback in _renderWidget.
Task ID: 2278717
closesodoo/odoo#53853
X-original-commit: 7641c7074616b4375f1eb4f1fcb5a96e2ed39f94
Related: odoo/enterprise#11537
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit, when a search_default on a many2one field tried to
update its label after a name_get, the value was set on its initial
associated query element which could have been erased by a default
favorite.
Now, the model determines whether there is a default favorite before
processing default filters, preventing any unnecessary RPC.
closesodoo/odoo#53840
X-original-commit: ff834d0ba6f9b7eadc23c28dbbf892eba2058583
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
- Create a repair order
- Choose a customer A
- Change the invoicing address to customer B > set default
- Create invoice
The delivery address set on the repair order is not taken into account
on the invoice. The delivery address field on the invoice stays empty
despite having a delivery address set up on the repair order.
opw-2285659
closesodoo/odoo#53831
X-original-commit: e109faec5f1e14864addfb1eb56c508ab04f6eb0
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
The do-action handler added was calling directly doAction method of
action_manager which lead to an issue in enterprise as the override
taking care of closing home menu in web_enterprise/do_action was no
more called. This commit fixes that by calling the do_action method of
abstract_web_client and thus the override to be executed.
Originally detected in task-2282273
closesodoo/odoo#53836
X-original-commit: 7949baf08b7e07cb5f25f1a42b4eb12ed3a65a64
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit, when archiving a record through the action
menu, the 'Archive' link was not updated to 'Unarchive' and same
when unarchive was clicked, the link was not updated to 'Archive'.
After this commit, when archiving a record through the action menu,
the 'Archive' link is updated to 'Unarchive', same way when
unarchiving a record link is updated to 'Archive'.
This commit also introduces a new prop 'closeOnSelected' to the
Dropdown component, to specify whether the dropdown should be
closed when an item is selected, and makes Action Menu dropdown
closed on item selected.
task-2251739
closesodoo/odoo#53835
X-original-commit: dc5d02ade7747c74c31566c74932ef45c30e9356
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Co-authored-by: Mohammed Shekha <msh@odoo.com>
Issue
- Turn on Sales Product Configurator
- Create a product template with an attribute and an attribute value defined as "is custom".
- Create a new quote, add the template, and configure the product, entering a custom value.
- Save.
- Duplicate the Quote
Custom value missing.
Cause
Custom value (field product_custom_attribute_value_ids) not duplicated.
Solution
Add attribute 'copy=True' to field product_custom_attribute_value_ids.
opw-2279933
closesodoo/odoo#53827
X-original-commit: 0ca092361819bb198c87ca6772ec0e93a2158018
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Signed-off-by: bon-odoo <nboulif@users.noreply.github.com>
Issue
- Install eCommerce, Stripe
- Setup stripe for testing
- Order something
- Open stripe payment interface (not with odoo)
- Go back with the stripe interface button
Order Cancelled
- Go back with browser back button
- Enter your data
Can pay but order still cancelled so
you paid for nothing
Cause
I fixed a linked error in
b8b9a04ff5b5b2ba40b26632
but I didn't mind that we should cancel
the stripe payment intent too
Solution
Cancel the stripe payment intent so that
filling the stripe form by following
those step will returns an error from
stripe
OPW-2282946
closesodoo/odoo#53819
X-original-commit: 5acb2a649a2f2490725283c7f4cff5a5183d8ed0
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
Fields that are shared between account.payment & account.move models are badly set when creating the records.
For example, 'partner_bank_id' in vals will be set on account.payment but not on the account.move.
closesodoo/odoo#53832
X-original-commit: a23c1e30c5b6b28f25c5f76d9fb85f075433b18f
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
Code's been dead since 3407fb70e4
essentially inlined its behaviour into the base class.
closesodoo/odoo#53774
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
1. Show only date not datetime on update portal. When update the
scheduled date, set it to be the last minute of that date.
2. Send updated date immediately when user pick a date.
3. If an activity for update the date already exist, update the
note instead of creating a new one.
Task #2265912
PR 52809
The string formating was called inside _() which does not work.
closesodoo/odoo#53781
X-original-commit: aef420570ca153da34796a80d3e22193f17c2cf0
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
This commit sets the fields date_from and date_to as optional hidden on
the resource.calendar.attendace.
closesodoo/odoo#51527
Taskid: 2241686
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>