Commit Graph
152817 Commits
Author SHA1 Message Date
Luis González df7dbad634 [FIX] website_hr_recruitment: job positions w/o address are not shown
When accessing the job positions page, country is detected automatically
to filter only those jobs whose country match current one + the ones
available in any country. However, when job positions have no specific
country, they're being excluded due to the usage of an old API
(expecting relational fields as `None` when they're empty), so only
positions with country are being taken into account.

This commit fixes the above by expecting the correct value (an empty
recordset) when an address is not set.

closes odoo/odoo#95454

X-original-commit: 65a285124bc0833c511905719da1712b0c747e24
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2022-07-06 21:22:56 +02:00
Sébastien Theys 87c7c82286 [FIX] mail: remove readonly from isSquashed
There are situations where a message view is re-used in a different context
where the isSquashed value has to change.

For example a message being starred could be squashed in its original thread but
not squashed in the starred box, leading to a crash before this fix.

closes odoo/odoo#95403

Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2022-07-06 20:18:23 +02:00
William Braeckman d54c6a7c12 [FIX] mail: fix css for o_kanban_attachment
This commit fixes the css rule for the class `o_kanban_attachment` that
was broken for owl kanban views since f795af0160ed7977d07041d1bb1923598df48320.

closes odoo/odoo#95444

Signed-off-by: Samuel Degueldre <sad@odoo.com>
2022-07-06 17:10:45 +02:00
qsm-odoo 30aeb62b59 [FIX] website: remove visitor-related dead JS files
Some files were emptied in stable at [1] but were not properly removed
via the forward-port PR. This commit does that, in master.

[1]: https://github.com/odoo/odoo/commit/3d9a2de3575777c87327691319d89f9de6b8eada

closes odoo/odoo#95434

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2022-07-06 17:10:42 +02:00
Samuel Degueldre 162b42e4cd [FIX] web: form: correctly handle empty buttonbox
Before this commit, a form view with an empty button box would
produce a crash, in the ButtonBox component, because it assumed to
have slots. This commit prevents this from happening as we no
longer put a ButtonBox component in the template if there's nothing
in it.

closes odoo/odoo#95427

Signed-off-by: Samuel Degueldre <sad@odoo.com>
2022-07-06 17:10:38 +02:00
Guillaume (gdi) fadf643f97 [FIX] base: force to specify the language when installing a new language
Before this commit, the user could try to install a language without
specifying which language he wanted to install, resulting in a TB. This
commit forces to specify which language you want to install. The bug
appeared with this commit [1] which allows to install several languages
at the same time.

[1]: https://github.com/odoo/odoo/commit/47041f2d45915e2ed74c4317f9aafe3dfa840f0a

task-2878405

closes odoo/odoo#95426

X-original-commit: bc083e6616859d51364b90ad4d0c6f0d99e34631
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2022-07-06 17:10:32 +02:00
Mathieu Duckerts-Antoine f3543be406 [FIX] web: process context.form_view_initial_mode
Before this commit, the context parameter "form_view_initial_mode" was
ignored by the form views, so that the form view would not be always
initialized in the appropriate mode.

closes odoo/odoo#95413

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-07-06 17:10:28 +02:00
Mathieu Duckerts-Antoine 3d6f0c200d [FIX] web: compile a button with id
Before this commit, button ids (if any) were absent from the templates
generated by a view compiler.

Part-of: odoo/odoo#95413
2022-07-06 17:10:28 +02:00
Mathieu Duckerts-Antoine 825fa5b9f0 [FIX] web: kanban: transaction error on record dragged twice
Problem:

Have
 - a slow network
 - a kanban view grouped

then move a given record from a column to another twice quickly.
An error occurs.

This is due to the way the transaction system in kanban model works:
the first move done in the first transaction being not yet finished,
no other transaction can begin and an error is thrown.

Solution:

Subclass Error and catch the specific transaction error at the
appropriate time to cancel the second order.

Note that the problem does not occur in a not grouped kanban view
because the hook useSortable prevent asking again a resequencing via
a proper management of the class o_record_draggable. That class is also
used in the grouped case but a rendering of the kanban view takes place
possibly before the end of the transaction: the record is moved in any
case to the targeted column and moved back if the overall operation
fails for some reason.

closes odoo/odoo#95235

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-07-06 17:10:20 +02:00
Gorash b3a3969b2e [FIX] website, *: href form link alternate depends on the current url
*: test_website

Issue: The url is cached and no longer depends on the url. This part
should not be cached.

closes odoo/odoo#95222

X-original-commit: 4b255ed129b0e458d3cf7f432d076913b14d5450
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2022-07-06 17:10:17 +02:00
Gorash ae3354b306 [FIX] web, *: debug icon consistency according to the mode and the url
*: website

X-original-commit: 0cd55d90121cd5bcebdf4c7b0212910ef44a9d85
Part-of: odoo/odoo#95222
2022-07-06 17:10:17 +02:00
Gorash 5a2c267c20 [FIX] website: display the flag image of the language selector
Issue introduced by commit b0a2a41
The template's "flags" value was not in the t-nocache values to use when
rendering languages.

X-original-commit: 7827d2dbc1fbef3cc0dc898baa0af30ed1f23fca
Part-of: odoo/odoo#95222
2022-07-06 17:10:16 +02:00
Laura Schauer ace3c1e53c [FIX] payment: Standardize validation transaction reference
Before this commit, the reference of a validation transaction followed
this format: “validation-20220222072710”, which did not match the
standard format for refund transactions (”R-S000001”). Moreover, some
providers limit the length of transaction references which forced us to
truncate the quite long reference.

With this commit, future validation transactions will have a reference of
the format: “V-20220222072710”.

task-2830826

closes odoo/odoo#94921

Related: odoo/enterprise#29076
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2022-07-06 17:10:07 +02:00
Umesh Gupta 48737a8ffc [FIX] survey*: avoid traceback for data/demo data surveys
Currently, in demo data (or data) of some surveys, there are records of
'survey.question' having 'is_page' field value as true and 'question_type'
is not defined. When question type is not defined, default value
'simple_choice' is assigned to the 'question_type' field. Now when we
create a live session of that survey and go to the page, it tries to read
the data for bar chart but data is not available (undefined) and the
traceback is thrown. This happens  because question types 'simple_choice'
and 'multiple_choice') are expected to load a bar chart.

It used to work before commit[1] where default 'question_type' value was
being set to 'text_box' (so attempt to load bar chart was not made).

This commit improves the behavior by adapting data/demo data/test cases
and by adding a python constraint that prevents question creation of
page type if there is a question type set, and compute `question_type`
based on `is_page` field. Now that we have python constraint and a
compute method, we no longer need the `default_get` method, so it is
also removed.

commit[1] - https://github.com/odoo/odoo/commit/1fb99d79b1567d4c150dc07f309ce54a3beea8e3

taskID-2841582

closes odoo/odoo#93414

Related: odoo/enterprise#28305
Related: odoo/upgrade#3600
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-07-06 17:09:59 +02:00
umgu-odoo 24bc6f9777 [rev] survey: revert the fix for live session traceback
This commit reverts the fix done for stable that prevented the traceback
for the live survey on page type of questions had `question_type` set,
in order to fix it in a more robust way in the master.

Reverted commit: https://github.com/odoo/odoo/commit/651af6292c6797c5bd4ed918040508ad8f377ad3

taskID-2841582

Part-of: odoo/odoo#93414
2022-07-06 17:09:58 +02:00
Mitul Shah e3f13e08e3 [IMP] crm,website_crm_{iap_reveal, partner_assign}: organize reporting measures
This commit removes the unnecessary measures(like partner latitude/longitude)
from the lead related graph views. Also, we try to order the measures and keep
time related measures(Days to Assign, Days to Close, Exceeded Closing Days, etc)
first and revenue related measures(Expected Revenues, Prorated Revenues, etc)
last.

Note that with this commit, recurring revenue related measures will be displayed
only when the feature is activated.

ent PR: https://github.com/odoo/enterprise/pull/21981

Task-2674367

closes odoo/odoo#79167

Related: odoo/enterprise#21981
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-07-06 15:29:26 +02:00
Alvaro Fuentes 2ba68a266c [FIX] stock: traceback when there is no delveries for a lot
Fixes 38bfbed
We cannot create a `set` from `None`
```
   File "/home/odoo/src/odoo/15.0/addons/stock/models/stock_production_lot.py", line 225, in <listcomp>
    delivery_ids.update(*[set(delivery_by_lot.get(lot_id)) for lot_id in (producing_move_lines.produce_line_ids.lot_id - next_lots).ids])
 TypeError: 'NoneType' object is not iterable
```
Small optimization: no need to create a list that's immediately unpacked.

This error was detected during upgrades.
upg-360084

closes odoo/odoo#95398

X-original-commit: 1870ef4cf4c177846fce72325ff3f2fa97224417
Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
Signed-off-by: Tiffany Chang <tic@odoo.com>
Signed-off-by: Alvaro Fuentes Suarez (afu) <afu@odoo.com>
2022-07-06 13:11:48 +02:00
Aurélien (avd) 6c0744d672 [FIX] stock: speed up _find_delivery_ids_by_lot
Rewrite _find_delivery_ids_by_lot to reduce the number
of recursive calls by grouping the producing move lines
together before each recursive calls. This reduces
the number of search calls, speeding up the whole method.

Add a unittest to check if the delivery_ids field
of a lot recordset is properly computed.

opw-2824464

X-original-commit: e7b9f14d4a9ce4ed61451b24b567f751fb4bcbe2
Part-of: odoo/odoo#95398
2022-07-06 13:11:48 +02:00
Aaron Bohy e7750dce2a [FIX] web: support force_save attribute on fields
In an x2many sub view, the attribute "force_save" on a field
indicates that the field value must be saved, even if the field is
readonly. Before this commit, this attribute was ignored by the
new views. In the BasicRelationalModal, we only needed to propagate
this attribute to the fieldsInfo given to the BasicModel. In the
RelationalModel, we needed to take the attribute into account.

closes odoo/odoo#95396

Signed-off-by: Géry Debongnie <ged@odoo.com>
2022-07-06 13:11:42 +02:00
Samuel Degueldre ff82425e27 [FIX] web: fix colorlist css by restoring mistakenly deleted file
During the wowl refactoring, the colorpicker field was converted into a
new field component and the colorlist that allows to pick the color was
extracted into a new component with its own style. While doing so, the
stylesheet for the color picker was reworked into the stylesheet of the
colorlist, which is ultimately what we want, but in the mean time, the
legacy colorpicker widget no longer has the style it needs to be
displayed properly. A partial fix was applied previously by resoring
part of the scss directly in the colorpicker field css which is a
mistake.

This commit simply restores the old colorpicker scss file so that the
legacy field displays properly and removes the parts of it that had been
copied over to the new color picker field.

closes odoo/odoo#95392

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-07-06 13:11:39 +02:00
Guillaume (guva) 4805103274 [FIX] account: change journal on draft invoice
Step to reproduce:

- Create a SO, save and confirm it
- Create an invoice, on edit mode, change the journal and click on save

Issue:

- If the invoice is the first one in the current month, a sequence
  number is automatically assigned and an error is displaid.

forwardport of https://github.com/odoo/odoo/commit/b8328e45d526d276b5781da3523a0d5874da64bd

opw-2660571
opw-2879716

closes odoo/odoo#79084

closes odoo/odoo#95386

X-original-commit: 7b296982139518460405fa63eca6774bd82ba7b1
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Minet Adrien (admi) <admi@odoo.com>
2022-07-06 13:11:34 +02:00
Laurent Smet e96757194c [FIX] account: Prevent deletion of tax lines
Improvement of the current fixes:
https://github.com/odoo/odoo/commit/ac3cf2ed59c1dd5a6c91da201a0d4093212b26ae
https://github.com/odoo/odoo/commit/feb4e839dc4e35ab16527e5e264b5cc1c0a76c8e

- A tax line is linked to a tax repartition line. If you suppose a tax with 2 repartition lines then, removing one tax line should recompute the tax line.
- There are multiple taxes configuration leading to a tax line with a zero amount. For example, python tax, fixed tax with quantity = 0, a tax with a tiny amount...etc

closes odoo/odoo#95342

X-original-commit: 33d3b17e88d17314b88264f17780d500d67d72f1
Signed-off-by: William André (wan) <wan@odoo.com>
2022-07-06 11:49:57 +02:00
FrancoisGe f1856cce24 [FIX] web: Adds missing placeholders to fields with an input
This commit adds the ability to pass a placeholder to all fields
containing an input.

This commit tests the ability to use a placeholder in all fields
containing an input.

closes odoo/odoo#95309

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-07-06 10:36:28 +02:00
sofiagvaladze 102136f2ae [IMP] hr_expense: prevent change of employee on line sheet
In case we change the employee on an expense and  in case expense has
sheet which has only one expense_line_ids, then changing the
expense.employee_id triggers changing the sheet.employee_id too.

In case there are more than one expense linked to the report, then we
unlink the expense line from sheet, (so that the user can create a new report).

task - 2890095

closes odoo/odoo#94424

Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-07-06 10:36:22 +02:00
Hubert Van de Walle (huvw) 91d58bd260 [FIX] web: owl_compatibility: force status 1 on attach callback
When a widget is detached form the DOM, we manually set the owl status of
the corresponding node to 0 (new), but we before this commit, we didn't reset it
to 1 (mounted) when the widget was re-attached. As a consequence, event handlers
were not bound anymore.

Steps to reproduce:
  - Open Inventory
  - Click on Products > Lots/Serial Numbers
  - Open a product
  - Click on the Traceability smart button
  - Click on a reference (eg: Inventory Adjustment)
  - Click on the Traceability Report breadcrumb
  -> Breadcrumbs are not working anymore

opw-2838994

closes odoo/odoo#95375

X-original-commit: 7945f7c40045def5e46e8a2f91bdfcc3a42d9f78
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
2022-07-06 09:30:43 +02:00
Thomas Beckers 4e67c4adeb [FIX] purchase: don't mix PO's lines in generated invoices
If we use the auto-complete feature to add PO's lines to an bill or we select multiple PO's then use
'create bill' button, the generated invoice line will copy the sequence line from the PO's line. This
can lead to situation where we will have all the first lines of each PO then all the second, etc, ending
with a mix of all PO's in the bill.

Example:
Purchase order 1
- seq 10 line A
- seq 11 line B
- seq 12 line C

Purchase order 2
- seq 10 line A'
- seq 11 line B'
- seq 12 line C'

Invoice created from those PO's
- seq 10 PO1:line A
- seq 10 PO2:line A'
- seq 11 PO1:line B
- seq 11 PO2:line B'
- seq 12 PO1:line C
- seq 12 PO2:line C'

After this PR this PR the lines from the same PO's will be contiguous like:

Invoice created from those PO 1 and 2
- seq 10 PO1:line A
- seq 11 PO1:line B
- seq 12 PO1:line C
- seq 13 PO2:line A'
- seq 14 PO2:line B'
- seq 15 PO2:line C'

opw-2749682

closes odoo/odoo#95343

X-original-commit: cafe5c1aff1ca1632ce4924a6b027629c283a5e9
Signed-off-by: Steve Van Essche <svs@odoo.com>
Signed-off-by: Beckers Thomas (tbs) <tbs@odoo.com>
2022-07-06 08:18:08 +02:00
Thibault Delavallée d480ecea4e [ADD][MOV] mass_mailing_themes: move to community
Rationale

Due to business decisions mass mailing themes are moved to community repository.
As some other moves are planned, notably coupon or mobile UI that are coming
to community repository, this makes sense to have mailing templates along
with the mobile UI.

Having a responsive and mailing-friendly mailing is now part of community
standards.

For any questions please refer to decision makers.

Task-2903948

closes odoo/odoo#95379

X-original-commit: 58ec2382e4e16ca8cff468a7d731d1de84df66ff
Related: odoo/enterprise#29142
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-07-05 21:09:52 +02:00
Guillaume (guva) 4c701091e6 [FIX] l10n_au: don't duplicate tax repartit° lines when upgrade
Complement of this commit 7d7c53edf714a07409316750b2b09deaa089a12d
because added records were missed during fw-port.

opw-2862296
opw-2877133

closes odoo/odoo#95374

X-original-commit: 0ec6629de721042ed215e0e011fe38daddccb0d5
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
Signed-off-by: Guillaume Vanleynseele (guva) <guva@odoo.com>
2022-07-05 19:45:59 +02:00
Bruno Boi 969a9ab7c0 [FIX] web: some fields are shrunk on quick create
closes odoo/odoo#94952

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-07-05 17:32:51 +02:00
Bruno Boi 8eaddda496 [FIX] web: field translate button unapplied style
Before this commit
There is  an issue about the translatable field button not properly
shown.
A translatable field <input/> or <textarea/> should have a right padding
in order to ensure its text content does not go behind the translate
button.

After this commit
Existing style regarding this is reapplied.

Part-of: odoo/odoo#94952
2022-07-05 17:32:51 +02:00
Bruno Boi 25e1b12f49 [FIX] web: traceback on focus empty kanban from the control panel
Before this commit
On an empty kanban having a record in quick creation, if a user manage
to give the focus somewhere inside the bottom-left zone of the control
panel (or inside the searchview input) WITHOUT closing the form of the
record in quick creation, and then press the ArrowDown key on its
keyboard, a traceback appears.

How to reproduce?
- i.e. go to "Social Marketing > Campaigns"
- change the filter to show no records
- click on create
- make the record dirty BUT invalid (no value for the Responsible field)
- click on the search input
- press arrow down
- => traceback

After this commit
The traceback is not shown anymore because the kanban renderer makes a
safer check before trying to focus a kanban card.

Part-of: odoo/odoo#94952
2022-07-05 17:32:51 +02:00
Bruno Boi ebcecf74c6 [FIX] web: missing t-attf-class part for ViewButtons
Before this commit
When defining a view button in some view arch, the combination of its
class attribute with a `t-attf-class` is not correctly handled.

After this commit
This is fixed.

Part-of: odoo/odoo#94952
2022-07-05 17:32:51 +02:00
Bruno Boi 0bef662b80 [REF] web: viewCompiler factorize string interpolation handling
Before this commit
The view compiler and the kanban compiler both have code to handle
string interpolation.

After this commit
The code is reworked and factorized in a single place.

Part-of: odoo/odoo#94952
2022-07-05 17:32:50 +02:00
Bruno Boi 2c2f6b5bb7 [FIX] utm: apply legacy kanban style
For the few remaining uses of the legacy kanban view, the utm addon
style wasn't applied.

This is due to the fact that the legacy kanban view does not have a
"o_kanban_renderer" class.

Part-of: odoo/odoo#94952
2022-07-05 17:32:50 +02:00
Bruno Boi 683c29c43f [FIX] web: kanban in the quick create style issue
Before this commit
The quick create form view uses the new wowl form renderer, but
with the CSS style of the legacy form view.
This led to some issues, i.e. the width of some input fields
were ridiculously small.

After this commit
The quick create form view still uses the new form renderer, but with
the proper class "o_wowl_form_view" to ensure the proper style is
applied.

Part-of: odoo/odoo#94952
2022-07-05 17:32:50 +02:00
Victor Feyens efcf488d23 [FIX] core/tests: test form without fields specified
Since #91909, the settings form view is tested with different levels
of access rights, post install.

But when the test is run with only the base module, it crashes because
the settings view specified in base is empty, without any field.

On save, the test form reads the view fields, but read fallbacks on
all fields if no field is specified, and it breaks when we try to
compare the read results to the fields requested (empty).

This commit skips the read when no fields is present in the view.

closes odoo/odoo#95340

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-07-05 16:20:56 +02:00
David Monjoie f2e8c22831 [FIX] web_editor: only partially clean for urgentSave
The urgentSave fix at f9d27d41 was broken by 9e02cec48.

Do not wait for the resolution of the cleanForSave promise to update
the internal value in case this happens during an urgentSave as the
beforeunload event does not play well with asynchronicity. It is
better to have a partially cleared value than to lose changes. When
this function is called outside of an urgentSave context, the full
cleaning is still awaited below and `_super` will reupdate the value.

Task-2861050

closes odoo/odoo#95336

X-original-commit: 0483a778a4032fe2264cfdd5f037834cfb903845
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2022-07-05 16:20:53 +02:00
Antoine Guenet 51f1db9ce4 [FIX] web_editor: properly paste lists within lists
Pasting a list within a list resulted in wrongly nested li elements
(<li><li>text</li></li>). This applies the same principles for pasting
lists within lists as were already applied for blocks within paragraphs.

task-2879892

closes odoo/odoo#95331

X-original-commit: 49058d63b7a8d03c9b6e323cac19b66bf542a5b3
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Signed-off-by: Antoine Guenet (age) <age@odoo.com>
2022-07-05 16:20:49 +02:00
Antoine Guenet 3352fa4b05 [REF] web_editor: refactoring of the insert command for maintainability
This refactors the insertion loops in the insert command, in order to
make it more maintainable.

X-original-commit: cb87020ab4e893ca62a677c9104f16c3aa9938cf
Part-of: odoo/odoo#95331
2022-07-05 16:20:49 +02:00
Antoine Guenet b3acaa7b52 [FIX] web_editor: properly paste blocks at the beginning of the editable
Pasting blocks at the beginning of the editable pasted the content in
the wrong place (after the first node instead of before it).

task-2879892

X-original-commit: f810b11204a3e227d7ac98429f21b2ddf93de215
Part-of: odoo/odoo#95331
2022-07-05 16:20:49 +02:00
Sébastien Theys 60d1d69b19 [IMP] mail: clean unnecessary CSS selectors
`.o-isInFormSheetBg` and `.o-aside` are mutually exclusive.

Part of task-2871070

closes odoo/odoo#95323

Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2022-07-05 16:20:43 +02:00
Sébastien Theys d8fc0e07b9 [IMP] mail: simplify conditions that control chatter position
This better highlights the different cases that need to be handled.

Part of task-2871070

Part-of: odoo/odoo#95323
2022-07-05 16:20:43 +02:00
debu-odoo 6da6add464 [FIX] mrp,stock: UI fixes
Purpose of this commit to fix the UI in Manufacture app.

So, in this commit done following changes As suggested in Task:
    - Able to expand next activity column of MO list view
    - Added tooltip of default capacity field on work center
    - Added quantity tooltip of BOM

TaskID - 2689994

closes odoo/odoo#95315

X-original-commit: 463a81eb325f624e8947f1b3444947f8ba1dc24b
Related: odoo/enterprise#29113
Signed-off-by: Tiffany Chang <tic@odoo.com>
2022-07-05 13:53:55 +02:00
CarmenMiranda cd63ae6637 [FIX] mrp: Access Error on MRP Stock Picking Type
Now the way of access to an action is using the method `_for_xml_id` of
the model `ir.actions.actions` and not reading the action itself because
they need the access of the group "Administration/Settings" which not
all the users have it, so we were having an error with users that have
the permissions to see MRP Picking Types but they didn't have the group
mentioned above.

closes odoo/odoo#95312

X-original-commit: 1554fc9f8a98f4723b4f3cc1a8c0bd772c317ce5
Signed-off-by: Tiffany Chang <tic@odoo.com>
2022-07-05 13:53:46 +02:00
Achraf (abz) b288bf39df [FIX] website_sale: Use company bank instead of acquirer to generate qr code
Before this commit wire transfer was using this line to generate qr code
`payment_tx_id.acquirer_id.sudo().journal_id.bank_account_id.build_qr_code_base64`
But this is a problem has transfert doesn't use `journal_id`.

Instead we can use the bank_id of the company's partner_id.

opw-2855065

closes odoo/odoo#95279

X-original-commit: 15a5bc956ad865d4a6ebb001b5767a5009533782
Signed-off-by: William André (wan) <wan@odoo.com>
2022-07-05 13:53:43 +02:00
Louis Wicket (wil) c56c5ca28f [FIX] mail: don't crash on click reply
Fix bug introduced in https://github.com/odoo/odoo/pull/94948.
Add test for MessageInReplyToView.

closes odoo/odoo#95303

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-07-05 12:42:39 +02:00
qsm-odoo 44f80b2c95 [FIX] website: remove useless list_website_pages rules
Commit [1] made a mistake of copy/pasting the "list_website_pages" ID in
two views related to the "search in everything" and "search in pages"
views (used when checking all results after a search using the "search"
snippet that you can configure to search in everything or in pages).

At the time, that ID induced some CSS rules and JS related to the page
manager (not made for visitors).

- For the "search in everything" page, both the CSS rules and JS had no
  effect (except instantiating an useless widget in JS).

- For the "search in pages" page, the JS had no effect (except the same
  instantiation of an useless widget) but the CSS had an impact on the
  `<table>` used to display the results:

    - The header used an hardcoded odoo-purple background color.
    - The table paddings were not the ones defined by the theme.

Of course, in custos, more of the CSS could have had an impact (for
example some icons would use bootstrap blue info color by default for
no apparent reason).

Since [2], the page manager was removed (converted into a backend view)
so the CSS and JS rules actually became totally useless. The JS was
removed with [2] but the CSS was kept thinking it was necessary for the
"search in everything" and "search in pages" pages.
This commit removes the useless CSS and the useless ID in the two views.
It also modifies the "search in pages" layout a bit.

A fix could be made in stable later on to at least remove the hardcoded
odoo-purple background color in the "search in pages" page. The rest
should stay as per-stable policy.

[1]: https://github.com/odoo/odoo/commit/7559626c54e34b41e1549e28276a650accec6986
[2]: https://github.com/odoo/odoo/commit/31cc10b91dc7762e23b4bde9b945be0c4ce3fe3b

closes odoo/odoo#95272

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2022-07-05 12:42:36 +02:00
Valentin Chevalier b5dab9b119 [IMP] account_payment: hide pay button when paid
Hide the 'Pay Now' button for invoices which transactions total amount
equals their total amount.

When the total amount of all transactions related to the invoice is
equal to or greater than the total amount of said invoice, the 'Pay Now'
button should no longer be displayed.

task-2527323

closes odoo/odoo#95262

X-original-commit: de81225d39e7951ea9a63e24bab3a0138a6942e3
Signed-off-by: Achraf <abz@odoo.com>
2022-07-05 12:42:33 +02:00
Achraf (abz) 5d8fcdf492 [FIX] account_payment: Don't display pay now button if the status is paid
Correct "Status" position in the account_portal header

opw-2817794

X-original-commit: acf1003d46360bff23b605ccb77a44d099f1c1a8
Part-of: odoo/odoo#95262
2022-07-05 12:42:33 +02:00
Mathieu Duckerts-Antoine 8359337a6c [FIX] web: kanban: "muted" already in progress bar colors
Problem:

In a kanban view with progress bars, have
 - a record with a false value for the progress bar field
 - "muted" be the color of a progress bar field value different from false
a crash occurs.

This happens because no fallback is found for value = false in
findProgressValueFromRecord.

Solution:

Always add a bar for the value false (as it was the case before).

closes odoo/odoo#95215

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-07-05 12:42:28 +02:00