Commit Graph
163215 Commits
Author SHA1 Message Date
Benoit Socias d1292a96a6 [IMP] base,*: support image/webp image format
*: mail, mrp, test_website, web, web_editor

Before this commit '.webp' images could not be used in odoo.

After this commit '.webp' images can be uploaded to odoo.
- can be used in image field
- can be used in HTML field image
- can be used in mails and website
- can be transformed (shape mask, filter effect, crop, rotate, resize,
  adjust quality)

task-2774352

Part-of: odoo/odoo#85494
2023-07-15 05:10:45 +02:00
tsm-odoo 406b8a4896 [FIX] im_livechat: keep same livechat name after inviting members
Before this commit, inviting a channel member to a livechat channel
would change its name. This is not what we want as the thread name
should always be the one of the visitor (e.g. "Visitor 20", task-3332872).

Steps to reproduce:
- Open two tabs, one with admin log, one on the support page
- Click on the livechat button and send a message from the support page
- Invite a member with the admin tab
- The name of the thread changed.

closes odoo/odoo#128238

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-07-15 04:01:17 +02:00
Saurabh Choraria de782a680d [FIX] payment_stripe: handle error for unsupported country while stripe setup
Currently, When a user tries to set up a stripe account but his country is not
supported by stripe then he receives a error message at backend side and a
ValidationError ("Stripe Proxy: An error occurred when communicating with
the proxy.") on frontend side.

After applying this commit the error message will be updated to a warning level
which will reduce the noise in sentry. I have also added a condition in
'action_stripe_connect_account' method to check whether the country is
supported by stripe or not and if it is not supported the user will be
redirected to other payment providers page.

sentry-3935758343

closes odoo/odoo#128140

X-original-commit: c7b0d8eebe686d9c38f9f5c71577c80718ffb791
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2023-07-15 04:01:14 +02:00
Adesh Jolhe 8eda018910 [FIX] website_event_track: resolve issue with setting SVG as favicon
Steps to Produce:-
- Install `Advanced Events`
- Go to ` website` then `Configuration`
- Open `setting`
- Then change favicon and Select svg type file and click on save
- Traceback is here

Cause :-
- The traceback occurs when an SVG image is passed to the ImageProcess method.
 In this scenario, the method sets the image as false, and then attempts to
access its size, resulting in the traceback

Fix :-
- The issue has been resolved by implementing a condition check for the image
before accessing its properties. This ensures that the image is valid before
trying to retrieve its size, preventing the traceback from occurring.

sentry-4199175498

closes odoo/odoo#127958

X-original-commit: ebb1e89b367dced4a2157751de12a53bf41ae400
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Signed-off-by: Achraf Ben Azzouz (abz) <abz@odoo.com>
2023-07-15 04:01:12 +02:00
althaf shaik 2d66c22a60 [FIX] account_tax_python: prevent traceback while computing python code in tax
Syntax Error generates when the user gives invalid python code in 'account_tax'
module and uses that tax while creating invoice.

Steps to produce:
 * Install 'account_tax_python' module
 * Go to configuration/taxes and create a new tax.
 * Select Tax Computation as 'python code' and give some special characters to
   python code field and save it.
 * Now create an invoice, add a  product and add the above created tax in taxes.
 * At this moment traceback raises.

By applying these changes will resolve this issue.

closes odoo/odoo#127919

Sentry: 4060222060
X-original-commit: f42bd9c9fbd9a5e4c3eb127453a38d0c21a9d4fb
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
2023-07-15 04:01:09 +02:00
vishal padhiyar c1d42a42a1 [FIX] web_editor: link with / not recognized
Before this commit:

When user try to create link with / it is not recognized as a link.

After this commit:

Now when user try to create link with  /  it is recognized as a link.

Task-3347775

closes odoo/odoo#127842

X-original-commit: e99ccfa1ed7aa338f99c4142d109b2860cc9be4a
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-07-15 04:01:06 +02:00
Julien Alardot (jual) 495546de79 [IMP] hr_expense: Allow user to fix currency rate
This allows the user to set the total_amount_company

Currently, when an employee set the amount
in a foreign currency, Odoo doesn't let the employee
register how much they have been charged after
conversion in their own currency
(assuming that it's the company one)

After this if the user changes the total_amount_company,
the new rate is computed and used

Task-3255758

closes odoo/odoo#127246

Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2023-07-15 04:01:01 +02:00
Maximilien (malb) a6414b9dde [IMP] sale: tooltip change
Change of tooltip for "expense_policy"

task-3342969

closes odoo/odoo#124683

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2023-07-14 20:34:47 +02:00
Alexandre Kühn 1adad23fcb [FIX] mail: no crash when open invitation menu from start a meeting
The "add-user" thread action is not necessarily present in the view,
therefore the action should not necessarily be programmatically
called.

This commit fixes the issue by letting discuss app programmatically
call the invitation button precisely in the next rendering when
it was requested from click on "start a meeting".

Fixes runbot-23240

closes odoo/odoo#128510

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-07-14 19:25:55 +02:00
Gurupreet Singh 94d4205751 [IMP] sale: allow the customer to sign in the quotation
Previously, customers were not allowed to sign a draft quotation.
We consider that if the customer has access to the quote, he should be able to sign/pay it (instead of getting some strange feedback that the order is not in a state requiring signature/payment)

task-3340541

closes odoo/odoo#124486

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2023-07-14 15:34:46 +02:00
Maximilien (malb) 82383c0ad3 [IMP] account: add reversal info in the chatter
Before this commit, when an invoice is reversed we used to put the message
"this entry has been duplicated from XXXX" but the message that we log in the
chatter was not very clear and also to have the info on the invoice that it has
been reversed you add to go on the credit note itself.

Now when an entry is reversed, the link to the credit note is put in the chatter
of the invoice and the message on the credit note has been changed.

closes odoo/odoo#124060

Task-id: 3326780
Signed-off-by: William André (wan) <wan@odoo.com>
2023-07-14 15:34:44 +02:00
niyasraphy 538f9222e1 [IMP] website_profile: add karma_profile_min field to view
before this commit, currently the field karma_profile_min
field in website model is not added in any views and
the default value set for the field is 150, as it is
not added in any views, the end users have no option to
change the value of this field.

this field value is used in _check_user_profile_access
function and thus the non logged in users or logged in
users with karma less than 150(default value) is not
able to open any public profiles.

after this commit, end users is not able to change
the default value set for the field and also default
value is changed to 0.

closes odoo/odoo#123411

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-07-14 15:34:41 +02:00
Audric Onockx (auon) 69d6715491 [REF] project,hr_timesheet: reorganize project/src/js files
task-3300649

closes odoo/odoo#120668

Related: odoo/enterprise#40774
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-07-14 15:34:35 +02:00
Audric Onockx (auon) 09a90aa9ca [IMP] project,web: change groupby project label 'None' to 'Private'
Be consistent with the terminology used in all views,
'None' doesn't add value and makes the private task stage user-friendly.

Add filter "Private Tasks" to search private tasks easily.

task-3300649

Part-of: odoo/odoo#120668
2023-07-14 15:34:35 +02:00
Aurelien van Delft (avd) c025a8ad84 [FIX] mail: avoid serialization errors with multiple tabs
A serialization error can happen when chatting with another
user from the company. To reproduce:

- Log into Odoo as User A
- Open another Odoo tab in the same window as User A
- In private mode log into Odoo as User B
- Send a message via chat from User B to User A.

A concurrent update happens in channel_fetched method when writing
on mail_channel_partner.fetched_message_id.

To fix that, update the field
through raw SQL using FOR NO KEY UPDATE SKIP LOCKED in select subquery.
This skips the row should it be already locked, which is fine
as we only need to first transaction in the queue to complete.

opw-3164584

closes odoo/odoo#128464

X-original-commit: 5e95bfc2a9e68ea7643ea436968dcad19fdeeff9
Signed-off-by: Aurélien van Delft (avd) <avd@odoo.com>
Signed-off-by: Matthieu Stockbauer (tsm) <tsm@odoo.com>
2023-07-14 08:48:56 +02:00
Maruan Aguerdouh (magm) 954f3ad6e0 [FIX] account: no traceback thrown in older browsers when formatting
Trying to access quotations using an older version of a browser, that
doesn't support `structuredClone` like i.e Safari <15.3 will throw a
traceback that will block the regular usage of the app.

We can use an older alternative to handle the deep cloning, with this
approach tho, we will lose the support of Dates, RegExps, Maps, Sets,
Blobs, FileLists, ImageDatas, sparse Arrays, Typed Arrays.

opw-3386434

closes odoo/odoo#128472

X-original-commit: 5b4526b5dab519178a7c694de0625629e8686396
Signed-off-by: Samuel Degueldre (sad) <sad@odoo.com>
2023-07-14 07:37:45 +02:00
Alexandre Kühn b711020e8d [FIX] mail: no suggested recipients in full composer of log note
Before this commit, opening full composer from chatter were always
copying the selected suggested recipients, regardless of the mode
of the composer.

Suggested recipients only makes sense in "Send message" mode,
therefore it should not copy them in "Log note" mode, which this
commit fixes.

Also fix a bug where copying of suggested recipients in full composer
was taking all suggested recipients into account, regardless of
checkbox state. This commit fixes issue by copying only checked
suggested recipients

closes odoo/odoo#128466

X-original-commit: 89afc58a69a53824a9100ceaf4f3574bb82dfc1d
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-13 19:28:37 +02:00
Bert Stomphorst 872065e0ee [FIX] on archiving product notify only about active used_in_boms
closes odoo/odoo#128427

X-original-commit: 0cc5900c929b969b6cf905ed2950a0566275f35d
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-07-13 19:28:34 +02:00
Renilkumar Kajavadra 360af3dc38 [FIX] barcodes_gs1_nomenclature: barcode scan for GS1 date rule
When user adds rule in the 'Default GS1 Nomenclature' that contains
'Unit product' in Type and 'Date' in GS1 Content Type.

Steps to reproduce the issue:
- Go to Inventory > Configuration > Settings > Barcode
  > Select 'Default GS1 Nomenclature' in Barcode Nomenclature
- Go to Inventory > Configuration > Barcode Nomenclatures
  > Open Default GS1 Nomenclature > Add a line > Select 'Unit Product' in Type
  > Select 'Date' in GS1 Content Type > Add Barcode Pattern for Date
    (ex. '(20)(\d{6})' )
- Go to Barcode > Inventory Adjustment > Click on Add Product
  > In product, add value for that Barcode Pattern (ex. 20230614)

Error: A traceback appears: 'TypeError: expected string or bytes-like object'

When user add barcode of date for product
https://github.com/odoo/odoo/blob/ae94f14a844352f66490ec326fe2d1a716023891/addons/barcodes_gs1_nomenclature/models/barcode_nomenclature.py#LL156C25-L156C63
Here we will receive datetime.date datatype for value.
Now when it tries to match re with datetime.date, it will lead to the
above traceback.

sentry-4236166678

closes odoo/odoo#128424

X-original-commit: fbec8cd5cc3e75f2079928537a31d59a0b4ce03d
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-07-13 19:28:32 +02:00
niyasraphy 73521a9fbc [FIX] base: invalid format is shown as valid in user error
before this commit, if user imports a non valid file,
in the import translation wizard, the users is notified
about the invalid file format by a user error and in
this message .pot is shown as a valid format.

but the only valid format's are csv and po files.

after this commit, the .pot from the user error is removed.

closes odoo/odoo#128422

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-07-13 19:28:29 +02:00
Adrien Widart (awt) 5a0f546dba [FIX] purchase{,_stock,_mrp}: get unit price of AVCO kit-component
Receiving a kit's component will fail in AVCO + multi-uom

To reproduce:
1. Create a product category PC
   - Costing Method: AVCO
2. Create two products P_compo, P_kit
   - P_kit:
     - In Units
   - P_compo:
     - In L
     - Storable
     - Category PC
3. Create a BoM
   - Product: P_kit
   - Type: Kit
   - Components: 1 x P_compo
4. Create and confirm a PO with 1 x P_kit
5. Process the receipt

Error: When validating the receipt, a user error is displayed: "The
unit of measure L defined on the order line doesn't belong to the
same category [...]"

When processing the SM, we create the in-SVL. To do so, at some
point, we need the unit price of the SM, and here is where the error
comes from:
https://github.com/odoo/odoo/blob/708c3d063482e365e49a04f633c83e90e6fa4356/addons/purchase_stock/models/stock_move.py#L39
`self.product_id` is P_component, but `line.product_id` is P_kit,
hence the error with the UoM1
And there will be some similar errors with the `if` block, L40 (we
compare some SM quantities and some POL quantities: we are mixing
components and kit)

For now, in case of a kit, we will always use the `else` block (i.e.,
the unit price of the POL). This will be improved in master

OPW-3357685

closes odoo/odoo#128386

X-original-commit: 3a81eb79cad7f25843315e39da421efa2c34aaf1
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Adrien Widart (awt) <awt@odoo.com>
2023-07-13 19:28:21 +02:00
Julien Castiaux c92331aa78 [FIX] core: -i/-u shouldn't be allowed with multiple db
The `-i`/`--init` and `-u`/`--update` cli options behavior is only
defined when using a single database with `-d`/`--database`/`db_name`.

Using those two cli options along with multiple databases is undefined
and can have disastrous consequences[^1].

The server now crashes in this situation.

Fixes: #107188
Fixes: #128273
[^1]: https://github.com/odoo/odoo/issues/107188#issuecomment-1627996425

closes odoo/odoo#128306

Signed-off-by: Julien Castiaux (juc) <juc@odoo.com>
2023-07-13 19:28:12 +02:00
oco-odoo 8166e46353 [IMP] account: introduce sections on accounting reports
This branch adds the fields and constraints required by its enterprise counterpart.

Task 3098971

closes odoo/odoo#127236

Related: odoo/enterprise#43601
Signed-off-by: John Laterre (jol) <jol@odoo.com>
2023-07-13 19:28:10 +02:00
aliya d3fda38f00 [IMP] account_peppol: improve participant onboarding
This commit adds several improvements in Peppol onboarding process:
- Adds a phone number verification process
- Adds a possibility to migrate away/cancel the registration
- Adds a possibility to update contact details for the participant
- UX improvements like autosave
- Set 0208 as the default EAS code for Belgium
- Add a check for certain peppol endpoint numbers (based on Peppol schematron rules)

task-3060814

closes odoo/odoo#127092

Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2023-07-13 19:28:04 +02:00
David Monnom (moda) b0668f106e [FIX] pos_self_order: some bugs fixes
- Corrected incorrect use of access_token in an order.
- Correction of order change calculation in self_order.

closes odoo/odoo#125941

Signed-off-by: Robin Heinz (rhe) <rhe@odoo.com>
2023-07-13 19:28:01 +02:00
David Monnom (moda) 0a6cac7002 [IMP] pos_self_order: ux improvements
- Remove the notification and add a persistent banner at the top of the
screen when the restaurant is closed.
- Change the size of the product card to make it more compact and
smaller.
- Added a little shadow to the element fixed at the top and bottom.
- Corrected the alignment of price and quantity in the product list.
- In the card, the calculated price is now below the product list.
- The "add to cart" button is now dynamic, and will be
"remove from cart" if if the requested quantity is 0.
- Make the "my orders" button visible in meal mode and in each mode.

Part-of: odoo/odoo#125941
2023-07-13 19:28:01 +02:00
Valeriya(vchu) 6bc5cef302 [IMP] website(_sale,_payment,_sale_picking): improve provider options
When no payment provider is active, admin users should see the 'Activate
Stripe' button on the checkout page, allowing them to configure Stripe
faster.

This commit also disables the provider 'Pay in store when picking the
product' in the demo data to improve the testing experience of the
eCommerce settings on runbot.

task-3235154

closes odoo/odoo#121138

Related: odoo/enterprise#40934
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2023-07-13 19:27:55 +02:00
Arthur Detroux (ard) 51b1808ebe [REF] web, *: make web.public.widget independent of web.Widget
*: im_livechat, website_event, website_event_track_live,
website_livechat

The goal of this commit is to ease the removal of web.Widget while
keeping web.public.widget.

The reason we want to keep the public widget is because it is not
currently possible to hook OWL components to existing DOM elements,
which is mostly what is done in the frontend.

To remove the inheritance, most of the code from web.Widget was
duplicated into web.public.widget.

This commit also adapts a few widgets which were using web.Widget as
frontend widgets.

However, there are still legacy widgets used both in the backend and the
frontend. Those were not adapted.

This commit adapts the following widgets:

- website_event: EventRegistrationForm
- website_event_track_live: WebsiteEventReplaySuggestion
- website_event_track_live: WebsiteEventTrackSuggestion

The modules that still use web.Widget but were not adapted can be listed
by using: `odoo.__DEBUG__.getDependents("web.Widget");`

Following this commit, any new frontend widgets should exclusively use
web.public.widget. They should have done so before, but in the near
future, widgets using web.Widget will no longer work.

task-3249625

closes odoo/odoo#117210

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-07-13 19:27:52 +02:00
Arthur Detroux (ard) afbbf75ec9 [MOV] web: moving the RootWidget definition after PublicWidget
In the next commit, the PublicWidget class will be made independent of
the legacy Widget class.

Therefore, the RootWidget cannot be defined before the PublicWidget as
it will extend the PublicWidget rather than the legacy Widget.

This commit moves its definition after the PublicWidget definition.

task-3249625

Part-of: odoo/odoo#117210
2023-07-13 19:27:52 +02:00
Bastien (bvdn) db6b6880d6 [FIX] project: avoid traceback on View Task in project sharing + other small bugfix
This commit will fix the following bugs:
- prevents a traceback to appear when clicking on View Task button in sub-tasks tab
	when in project sharing
- adds a forgotten state display in the sub-tasks tab in project sharing
	(was missing)
- in the kanban card sub-tasks dropdown, only the sub-tasks without project should
	toggle from In Progress to Done (previously every subtask toggled)

Task-3280844

closes odoo/odoo#128385

X-original-commit: 928c8cc2ac83c5ac4a175848b1ac862e9b914daa
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-07-13 18:18:09 +02:00
luvi 7c07a73b6c [FIX] web,*: properly format phone href
*: mail

This commit fixes the href used by the PhoneField. Following the
specs of a phone uri, spaces must be removed from the phone number
when using the href attribute.

A test has been added to verify that any spaces are removed from
a given phone number.

In mail, the SMS button href has been edited for the same purpose.

task-3371999

closes odoo/odoo#128383

X-original-commit: 9ff0270c8acf9596ebd404627c4f5b1a98b37c59
Signed-off-by: Florent Dardenne (dafl) <dafl@odoo.com>
Signed-off-by: Luca Vitali (luvi) <luvi@odoo.com>
2023-07-13 18:18:06 +02:00
William Henrotin d7ce5553c7 [FIX] stock: write on item instead of iterable
The stock.quant `_compute_display_name` overide was writing the name on
the recordset `self` instead of the current loop element making the
quant name all the same.

This commit also remove the ' - no data -' fallback by displaying at
least the location.

closes odoo/odoo#128375

Signed-off-by: Steve Van Essche <svs@odoo.com>
2023-07-13 18:18:03 +02:00
Walid 0fe78c01d9 [FIX] website_sale_delivery: correct adress states
Steps to reproduce:
- set shipping methods country to mexico (empty states)
- fill an order on website on check out select seprate shipping/billing
- on billing set country as US
- on shipping the only country avialable is mexico
- avialable states are the ones from the US not mexico

Bug:
the states are set from the country of the customer even though it isn't
an option on any carrier.
bug was introduced by this commit[1]

Fix:
revert the mentioned commit(1) since a new commit[2] was introduced that
correctly handles that use case too

[1]:https://github.com/odoo/odoo/commit/d59fe9c58c2dcc2bf6613adb7ac3662597b50496
[2]:https://github.com/odoo/odoo/commit/297641da69982d6c76bd591296636b479cabf657

opw-3230361

closes odoo/odoo#128349

X-original-commit: c59bc765f186858bffb642987cd88fcb80fe262a
Signed-off-by: Walid Hanniche (waha) <waha@odoo.com>
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-07-13 18:17:55 +02:00
Earth Patel 543e0b22f1 [FIX] mail: open invitation popup on start a meeting button
Before this commit
When the user clicks on "Start a meeting" button, the invitation popup does not
open.

After this commit
The invitation popup now opens when the user clicks the "Start a meeting"
button.

Task-3346081

closes odoo/odoo#128320

X-original-commit: 12f2ddf722d659df651e5ef929f775ea1cabed88
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-13 18:17:52 +02:00
Vincent Larcin caec298d21 [FIX] project: make tests demo data independent
The test `test_duplicate_project_duplicates_milestones_on_tasks` and the test class `TestSoLineMilestones`
fail when demo data are not installed.
This commit makes it demo data independent.

Task-3410352

closes odoo/odoo#128307

X-original-commit: 9193168d39a808d66e67ad8d5d704d72fdc5f3a0
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-07-13 16:53:09 +02:00
Vincent Larcin 0b51310b5b [FIX] project: make tests demo data independent
The test `test_recurrent_tasks_fields` fails when demo data are not installed.
This commit makes it demo data independent.

Task-3410352

closes odoo/odoo#128296

X-original-commit: 985662758ad68dc2655bd12d883ae95b1e2f1220
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-07-13 16:53:04 +02:00
tsm-odoo 2b401d078d [IMP] mail, website_livechat: show visitor lang on member list
Before this commit, the lang of the visitor was only shown on the
member list based on the `anonymous_country` of the channel.

In order for this information to be as complete as possible, the
lang is now also checked on the website visitor if there is one.

part of task-3332872

closes odoo/odoo#128242

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-13 16:52:58 +02:00
Yosua Nicolaus 41d56e2e98 [IMP] expense: default expense category on scan
Description of the issue/feature this PR addresses:
- Expenses are automatically created when uploading or scanning receipts. This is a feature often used by employees who have a lot of tickets and upload them in batch. The expenses created have a random category (product_id) specified. Companies may however want to specify the default category for accounting or management purposes. They are currently unable to do so.

Current behavior before PR:
- Companies can't specify default category for scanned/uploaded expenses

Desired behavior after PR is merged:
- In the Expenses setting, combine the "Default Journals" and "Payment" block into one and name the new block "Accounting"
- Add new setting in Expenses for specifying default category for scanned/uploaded expenses
- If that setting is set, use the value inside it for the category field of new scanned/uploaded expenses

closes odoo/odoo#124205

Task-id: 3354763
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2023-07-13 16:52:52 +02:00
Maximilien (malb) ea8acc17b4 [FIX] account,sale: Sale person and team
When creating a Vendor Bill, the default Sales Team & Person of the company is
assigned to the Vendor Bill. The field isn't even displayed, it's hidden, you
can only display it with Studio and can't even change it.

The fact is : purchases and sales are two completely different roles and
business in companies. This has the indirect consequence that any user that
follows the default Sales Team will get notified of any new Vendor Bill created
in Accounting, which he very likely does not need/want to see.

This PR correct that by adding a condition on the filling of these fields. These
 fields will be filled when the move is a sale document.

closes odoo/odoo#120628

Task-id: 3279233
Related: odoo/enterprise#44034
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2023-07-13 16:52:46 +02:00
Maximilien (malb) 929f6288ec [REV] purchase: ensure all vendor bills are gathered from purchase order
With the recent change made in this task:
https://www.odoo.com/web#id=3279233&menu_id=4720&cids=1&action=333&active_id=967&model=project.task&view_type=form
The following commit can be reverted. (@Whenrow confirm to me that this commit
is no longer useful).
https://github.com/odoo/odoo/commit/e3101d92187946b2bd539e05956e4e83cd9c9097

opw-3214033

Part-of: odoo/odoo#120628
2023-07-13 16:52:45 +02:00
Sarika Shekhada 3e09bdff0c [FIX] mrp: traceback while value of variable 'value' is passed as False
While printing the "mo overview" report we get a traceback because in some cases
decorator passes as False because of that we can not concatenate with the string
value.

Applying these changes will resolve this issue.

sentry - 4199472992

closes odoo/odoo#128164

X-original-commit: 6dbec317e63db37f787bdc1a3758b2f20a18706f
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-07-13 14:47:55 +02:00
Benjamin Boulle (bebo) 3de6048314 [FIX] purchase: fixing wrong currency when autocompleting a vendor bill using l10n_in
Before the fix, when trying to autocomplete a bill with a PO using India localization, the invoice lines would not get the same currency as the autocompleted PO.
This is because with India localization, the journal_id gets updated at the same time of the currency_id, which recomputes and erases the currency set just before.
I propose to update the currency at the end to avoid all sort of recomputation it could be subject to.

opw-3374634

closes odoo/odoo#127657

X-original-commit: 7f37e523cffbe3d7d98fd7457b30e2fb93f453d5
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Benjamin Boullé (bebo) <bebo@odoo.com>
2023-07-13 14:47:50 +02:00
Audric Onockx (auon) 9e0277eeec [FIX] hr_timesheet_attendance: base report on employees, not users
The report is currently base on timesheets/attendances.user_id.employee_id.
As a result, some data weren't taken into account.
As both models have employee_id, there is no reason not to use it.

task-3251675

closes odoo/odoo#127492

Related: odoo/upgrade#4900
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-07-13 14:47:44 +02:00
Audric Onockx (auon) dfd5d33a05 [REM] hr_timesheet_attendance: remove unused view
We had a view in this module that was not used
and didn't seem to make any sense, so we delete it here.

task-3251675

Part-of: odoo/odoo#127492
2023-07-13 14:47:44 +02:00
Pierre Pulinckx (pipu) 504b4a7178 [REF] *:Replace moment usages with luxon
luxon and moment are both used in the solution, but
these two libraries facilitate the manipulation of dates.
It was decided to replace all uses of moment with
luxon so we can then remove moment.js from the
code and lighten the assets.

task-3391739

closes odoo/odoo#127406

Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-07-13 14:47:41 +02:00
hupo-odoo 5b5699e0c1 [IMP] l10n_gr: complete rework of Greece localization
Greece localization package was previously based on deprecated documentation. This commit add
- A new Chart of Accounts based on Greek Accounting Standards (Law 4308/2014)
- Account Groups
- Tax Report (based on Greece F2 Form)
- Taxes
- Tax Groups
- Fiscal Positions

task-2744373

closes odoo/odoo#126923

Related: odoo/enterprise#43415
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2023-07-13 14:47:36 +02:00
Julien Alardot (jual) 81fe11fabb [IMP] hr_expense: Split company payments per expense
When an expense sheet move is created, there is only one
outstanding line, but it is usual to pay separately.
That makes the reconciliation step harder.

This makes sure one move is created per expense

Task-3328877

closes odoo/odoo#126805

Related: odoo/upgrade#4873
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2023-07-13 14:47:30 +02:00
SaddemAmine 35ea7f5979 [IMP] account: added default order by invoice_date
This commit aims to improve the order of draft bills / invoices. Currently when importing multiple vendor bills they aren't ordered logically since they're still draft bills. Adding a fallback order by invoice_date until they're posted will help the user find the bill he's looking for more easily. It also allows to preserve the order of the imported bills in case of validation in batches.

Task ID: 3383575

closes odoo/odoo#126691

Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2023-07-13 14:47:27 +02:00
Zelong Lin 5438599af9 [IMP] mail: add single user to self-chat makes a DM chat
Opening DM chat or making group chat is determined by amount of
members in the resulting conversation to start. Before this commit,
starting a conversation with self and another user was wrongly
considered as making a group chat, because it wrongly assumed there'd
be 3 channel members in this conversation: the other user,
self (explicitly), and self again (implicitly).

This commit makes DM or group chat more natural when dealing with
self user:

- Adding only self to start a conversation should open a self-chat
- Adding a user to self-chat should open DM chat
- Invite more than one user in self-chat should make a group chat

task-3382231

closes odoo/odoo#126361

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-13 14:47:24 +02:00
Sohail JAIDI (soja) 5a51816415 [IMP] account_move: Adding a warning when uploading duplicate invoice
The aim of this commit is to add a warning when an invoice is uploaded and a duplicate of this invoice already exists in db.
It is the same behaviour that we already have for vendor bills

Previous to this commit:
When uploading duplicate vendor bill -> Warning
When uploading duplicate invoice -> NO Warning

After this commit:

Warning in both cases

closes odoo/odoo#126096

Task: 3378169
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2023-07-13 14:47:21 +02:00