Commit Graph
141397 Commits
Author SHA1 Message Date
std-odoo bdb09107d0 [REF] website_slides: split computed editable fields
Purpose
=======
Some computed stored editable fields are computed in the same method.

In that case, when one of the value is provided in a create / write call,
the computed method is not called and other fields computed in the same
method do not have the right value.

Task 2377119
COM odoo/odoo/pull/65772
ENT odoo/enterprise/pull/16221

X-original-commit: c37ff784f2195325d770e41c70e24a0d1d0420c7
2021-03-05 11:54:14 +00:00
xO-Tx 048612f21b [FIX] web_editor: fix anchor range selection
When we double click a form submit anchor, and depending on the selected
element before click, the selection range ("document.getSelection()") can
start from a parent of the targeted node. This will send a wrong range
to be used in LinkDialog widget.

The goal of this commit is to prevent this behaviour by adjusting the range
if it starts from anchor parent.

Note: the bug only occurred in Firefox.

Part of https://github.com/odoo/odoo/pull/62206
task-2381305

closes odoo/odoo#62206

closes odoo/odoo#67171

closes odoo/odoo#67176

X-original-commit: 9a16c313f131ed2e1017566a5f1bed134e22cc10
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2021-03-04 16:48:50 +00:00
xO-Tx a06282903d [FIX] website_form: add support for redirection to anchors on submit
Part of https://github.com/odoo/odoo/pull/62206
task-2381305

X-original-commit: 49943014b0d16e2fed31d4601f76c471252e24c6
2021-03-04 16:25:12 +00:00
xO-Tx 6c8fea3c1e [FIX] website_form, *: allow to update buttons using link dialog
*: web_editor, website_mass_mailing

When we double click a link/button, a link dialog appears
to update the target properties, and since the current link dialog
can only handle anchor targets, using it on buttons leads to some
inconsistencies :

- visible href options for button & url required to save changes.
- missing preview when button style changed.
...

The goal of this commit is to add a fix (with minimum of code) on
summernote linkdialog to handle button elements using the same logic as
anchor nodes.

Also, update website form test tour to test those new changes.

Part of https://github.com/odoo/odoo/pull/62206
task-2381305

X-original-commit: 19fbbdc0327482b5d70bdbcf17c2a5a950327d63
2021-03-04 16:22:08 +00:00
Pratima Gupta 80c0d25503 [IMP] sale_coupon: check the expire date of coupon based on current time
currently, the expiration date of the coupon is checking based on quotation date

now in this commit, the expiration date of the coupon will be check based on the
current date and  if the quotation date is before the starting date of the
coupon then it will show this coupon is not yet usable.

task-2229956
Closes #49187

Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
2021-03-05 08:51:00 +00:00
Jeremy Kersten 1ff61fc714 [FIX] website: typo in drop snippet tour
task-2466754

closes odoo/odoo#67346

X-original-commit: 19ef4f1b318b979bf2c6e89ad9962a50e6684dc9
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-05 11:58:59 +00:00
Jorge Pinna Puissant be428584d4 [FIX] sale_coupon: fiscal position for promotion product line
create a SO;
Add a fiscal position;
Add a promotion of fixed amount kind.
Before this commit, the taxes of the promotion are the one of the
promotion product and not the one of the fiscal position.

Now, the taxes will be computed taken into account the fiscal position.

opw-2467966

closes odoo/odoo#67318

X-original-commit: 16dab7df5bb966219fa8798b77743149ad129572
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
2021-03-05 09:38:18 +00:00
Benjamin Vray cca12cd718 [FIX] website: fix showcase snippet images stretched
Before this commit, if we replaced an icon of the showcase snippet
with an image, this image was streched depending on title size (if too
long and on 2 lines). Its because the align-self default value of a
flex item is strech.

task-2447087

closes odoo/odoo#67244

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-04 13:53:34 +00:00
Josse Colpaert dc40a5a01c [FIX] account_edi: also send electronic document for the payments
When we want to send the invoice to the client, a hack was made in account_edi
to make sure that we put the XML of the electronic invoice formats as well, in
the case of web services such that the client has the XML we sent to the government.

For MX however, we also send the payment to the government.  However when we wanted
to send the confirmation about the different changes, we still needed to add the XML
manually before this fix.  Now it should be added manually even when manually composing
the mail to the customer with the payment receipt confirmation.  (but we hope it dies)

closes odoo/odoo#67315

X-original-commit: 327852a6399a19191bd78c820971cc4108dc7821
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
Signed-off-by: Josse Colpaert <jco@openerp.com>
2021-03-05 09:20:58 +00:00
Benjamin Frantzen (bfr) 77205beb92 [FIX] account_edi : fix visibility of 'Retry' button
Before this commit, the button 'Retry' would appear if the blocking_level of an account.move (aggregated value of all the related edi.document) was lower than 'error' even though the button 'Send now' also appears. The button 'retry' should only show if the blocking_level is 'error'.

Was fixed in https://github.com/odoo/odoo/pull/65714
Reintroduced in https://github.com/odoo/odoo/pull/65745

closes odoo/odoo#67312

Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2021-03-05 08:41:48 +00:00
Benjamin Frantzen (bfr) 082a370514 [IMP] account_edi: visual improvements on account.move and account.invoice.send
- don't show Electronic Invoicing field on account.move view if no EDI require web-service
Backport of https://github.com/odoo/odoo/pull/64493 (TASK ID: 2439258)

- don't show account_edi_format field on account_invoice_send

closes odoo/odoo#67282

X-original-commit: 049ccc0257b36bb6c66ffe8a4498857a77498791
Related: odoo/upgrade#2235
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
Signed-off-by: bfr-o <bfr-o@users.noreply.github.com>
2021-03-05 08:27:42 +00:00
xO-Tx 2cdd95f140 [IMP] web_editor: select siblings when block is removed
CONTEXT: Within a container, delete a block which has a sibling.

The actual behaviour is to select the container after deletion.

The goal of this commit is to select the previous sibling (if exists),
or next one. Otherwise the parent element will be selected (default behaviour).

task-2431506

closes odoo/odoo#64875

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2021-01-26 18:17:17 +00:00
Jeremy Kersten bccfe66486 [FIX] website_sale: we don't support rounding uom in ecommerce
We only support int, following #c9edca7896e3096289936f5399a82f08a59b60ce

opw-2456796

closes odoo/odoo#67286

X-original-commit: a05a34366f6dc8c70b39c15c3441beaf6bbb72d2
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-04 17:35:00 +00:00
Benjamin Vray 032d96ffbd [FIX] website: state not saved for accordion snippet
Before this commit, the states (collapsed/not collapsed) of the tabs
of the accordion snippet were not saved if it was the only changement
in edit mode.

After this commit, we trigger a content change when the states of the
tabs is changed.

task-2442237

closes odoo/odoo#67276

X-original-commit: 18af2ecade9482b5243059aefbfa79410ebf59a6
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-04 16:02:16 +00:00
nie 3a7db03295 [FIX] payment: link transaction to invoice with payment link
Steps:
- Install account,payment
- Go to Invoicing
- Create an invoice
- Click Actions > Generate a Payment Link
- Follow the generated link
- Pay

Bug:
The transaction is not linked to the sale order in the link table
`account_invoice_transaction_rel`

Explanation:
This fix is broadly mimicking the behavior of the sales module regarding
the link of an order to a transaction, adding `invoice_id`s where they
are needed throughout the payment process in order to link the
transaction to the invoice.

opw:2451534

closes odoo/odoo#67296

X-original-commit: 7c6d06fa5858f79f3b22cdeaf74cdc26a642742f
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: backspac <backspac@users.noreply.github.com>
2021-03-04 19:28:25 +00:00
Christophe Monniez 97579f9c13 [FIX] packaging: remove dead code that prevent rpm build
Since 9c2ce1f12c2, more files are included in packaging.  The rpm build
failed because shebang lines of packaged files must not use
`/usr/bin/env` [0] [1] [2].

As it seems that those old files are not of any use anymore, this commit
removes them.

[0] https://docs.fedoraproject.org/en-US/packaging-guidelines/#_shebang_lines
[1] https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#Multiple_Python_Runtimes
[2] https://pagure.io/packaging-committee/issue/738

closes odoo/odoo#67294

X-original-commit: 54b6a7a97e574249c22f16ea2756989e4bd4fac3
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
2021-03-04 18:39:14 +00:00
Nicolas Seinlet 35c0bad900 [IMP] crm: assign faster by commiting less
commit at each lead makes the system spend 80% of the time recomputing
bayesian probabilities. Avoid to commit too often speed up the process
while not altering final result.

Task ID-2475352

closes odoo/odoo#67275

X-original-commit: 34f6e38e68208b9509a429cdb09f8316a7ef566f
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-03-04 15:49:53 +00:00
Florian Gilbert cad9d41fac [FIX] account_fleet: Adding vehicle_id for in_refund.
Field vehicle_id is missing on the account.move.line view of refunds.
This fix updates the domain to make visible the field in in_refund.

Task ID: #2466914

closes odoo/odoo#67269

X-original-commit: 97fb335e3f70a55b18685b9b6b08fe0162e1a17b
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
2021-03-04 15:20:40 +00:00
Géry Debongnie 11d2e6dde5 [FIX] web: properly apply onchange in some cases
A previous commit (8dbd1efef899fb637acca3c318ae99cb23838b8f) fixed a
part of the basicmodel that used _.each to iterate on an object with
field names as keys, which does not work when a field is named "length".
To fix it, I simply used a native for ... in statement.  However, I
missed the fact that there was a second 'return' statement in the body
of the closure given to _.each, so the onchange method returned
prematurely.

The fix is to simply use the continue statement in that case.

closes odoo/odoo#67267

X-original-commit: d9834e65ee57511f4850fa2d74287eb0b67087b9
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Géry Debongnie (ged) <ged@openerp.com>
2021-03-04 15:17:33 +00:00
Carlos Roca 1ff825c012 [CLA] update Tecnativa signature
closes odoo/odoo#67262

X-original-commit: 42291b957ba4f33640c99097be73f16aa9e06d47
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-03-04 15:02:06 +00:00
Laurent Smet cc07cfdb69 [REV] account: Revert "set memo to ref if not payment_reference"
This reverts commit a59f255ef33c47449d028930e15c5390c62e39ed.

github issue: 67098

closes odoo/odoo#67255

X-original-commit: 86e2c6b7126e2e73f5acfc7ebfee490808a70df7
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2021-03-04 14:32:38 +00:00
wan 9b3c19b41e [FIX] account: fix standalone test with demo data creation
The test is running in sudo mode, so we need to specify the company in
the search.

Also do not load the demo data when installing as we would do the work
twice for most localization.

closes odoo/odoo#67235

Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2021-03-04 14:11:50 +00:00
Adrien Widart 567f192d98 [REV] l10n_mx: prevent MX from printing receipts
PR #66910 has been created so the MX can print their receipts.
Eventually, this needs to be reverted since printing a receipt is
actually illegal.

closes odoo/odoo#67209

X-original-commit: 7e9261cacd9f6963dca517fe7b1f3de067af1366
Signed-off-by: Adrien Widart <adwid@users.noreply.github.com>
2021-03-04 10:33:08 +00:00
Josse Colpaert cefb6bb39b [FIX] l10n_id_efaktur: filter invoice lines on display_type
opw-2451571

closes odoo/odoo#67163

X-original-commit: 9bafbca93150a55f8c8dcad19d5861bd05d40b99
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2021-03-04 13:41:28 +00:00
Barad Mahendra 3fe4016f6a [IMP] website_hr_recruitment,google_recaptcha: auto install online job
Currently, website_hr_recruitment(online job) is not auto
installed when hr_recruitment and website is installed.

So in this commit, auto install the online job(website_hr_recruitment)
when only website and hr_recruitment is installed.
so removed website_partner dependency from website_hr_recruitment as it's
not really needed. also make the website_hr_recruitment and
google_recaptcha auto install.

closes odoo/odoo#66737

Taskid: 2374617
Related: odoo/upgrade#2201
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-04 12:39:00 +00:00
Nidhi Patel dc9ef81ab2 [IMP] hr_timesheet, sale_timesheet: add a group by inv/so in portal view
Currently, user cannot group the timesheet by inv/so in portal view.

In this commit, add a group the timesheet by inv/so in portal view and
move the `view timesheets` button next th each sol to the top left pannel.

closes odoo/odoo#65932

Taskid: 2451359
Related: odoo/upgrade#2214
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-01 12:29:13 +00:00
Robin Heinz 0d0ba71f85 [IMP] hr: rename group Attendance
Rename group "Attendance" to "Attendance/POS"

closes odoo/odoo#65537

Task-id: 2244289
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
2021-03-03 13:56:56 +00:00
Robin Heinz 9b97764ed0 We remove the "close session" button to prevent an employee to have access to the back end if not eligible.
For example:
User A start a pos session.
Employee B, not related to User A, could close the session and have access to the back end as User A.

This commit also allows to display the select cashier popup correctly in mobile view.

Task-id: 2244289
2021-03-03 13:56:56 +00:00
Kevin Baptiste 278f5a6995 [IMP] hr_expense: show confirmation on duplicate expenses
Display a confirmation dialog when a user creates duplicate expenses.

Two expenses (or more) are considered duplicates when they share the same
date, amount, product, employee, company and currency.

closes odoo/odoo#64190

Taskid: 2368636
Related: odoo/upgrade#2061
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-04 12:54:34 +00:00
Xavier Dubuc b85bde9854 [FIX] mail: do not show falsy value in tracking values messages
task-2438828

closes odoo/odoo#67227

X-original-commit: 49585b8ee726af7edd113c3012b1168d24dc4d7c
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2021-03-04 12:41:05 +00:00
fw-bot ee58f698fd [FIX] sale_timesheet: give no sol if sol in task is False
Before this commit, when the project is employee rate and the user sets
the sale order item to False in a task with this project, the linked
timesheets should have the sales order item to False, but if a
employee mapping is matched for this timesheet, the sales order item of
this mapping is given to the timesheet.

This commit checks if the sales order item in the task linked to the
timesheet and if no sales order item in the task then the sales order
item in the timesheet should also be empty (False).

closes odoo/odoo#67202

Forward-port-of: #67055
X-original-commit: a325e75a8565039d5120d169df67ef2d16c7fdc4
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-04 09:05:46 +00:00
Ronald Portier 81c3974a01 [CLA] Add Danny de Jong to Therp CLA
closes odoo/odoo#67073

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-03-02 14:43:35 +00:00
Odoo's Mergebot f11fcba83c [MERGE] web,hr_timesheet,partner_autocomplete: make multi company timesheet uom work
# Purpose

This PR's primary objective is to ensure that the timesheet uom is working in accordance with the company settings in a multi company environment.

Prior to this PR:

 - The timesheet preferences sent to the front end were always those of the default
   company of the user.
 - The timesheet related widgets initialisation process (adding the correct ones in
   the fieldRegistry) was performed before the front end treatment of cids and coockies
   which prevented applying the front end selected company settings.

After this PR:

 - A dictionnary is used in the session in order to structure the companies info.
 - The company timesheet preferences are sent to the front end through the company dict.
 - The uom info is sent to the front end through the session.
 - The timesheet uom is now managed from the frontend and is now in sync with the settings.
 - Timesheet widgets are initialised during the AbstractWebClient init and are in sync with
   the multicompany front end settings

task-2168337

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

closes odoo/odoo#66551

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-04 13:25:17 +01:00
Odoo's Mergebot 667d3d1132 [MERGE] mail, mass_mailing, event, various: improve usability across various marketing-related apps (activities, marketing)
# Purpose
General Marketing usability improvements based on what has been seen observing users on Fullstory.
As the changes are relatively minor and related to specific apps, the rationale and improvements will be explained in more details in each commit.
# Commits
##### [IMP] `base`: modify some displayed texts for res_partner
* Error messages when trying to delete/archive a partner linked to an active user
* Partner Form placeholders
* Update main_flow tour to be consistent with above changes
* Update test_orm to use a model with less functional constraints
##### [IMP] `mass_mailing_sms`: prevent raising an error in sms mailing
* Allow to launch a sms campaign without recipients without raising an error
##### [IMP] `mass_mailing`: add various usability improvements
* Mass mailing preview in a new tab (to prevent data loss when leaving the page)
* Data display adjustments (better wording...)
##### [IMP] `mail`: revamp the activity type form view
* Change "force_next" checkbox into "chaining_type" selection
* Update the Form layout and wording
* Renamed fields :
  * default_next_type_id -> triggered_next_type_id
  * next_type_ids -> suggested_next_type_ids
  * default_description -> default_note
##### [IMP] `event`: improve the event form editor and update the tour
* Fix an undesired behavior with duplicate lines when switching event_type templates
* Remove steps from the event tour
##### [IMP] `web`: add an initial_date context key for CalendarView
* Add a context key ('initial_date') to the calendar view (to open it around a specified date)
##### [IMP] `crm`: add a reschedule action for activities
* Add a reschedule action alongside snooze 7d, for event-related activities
##### [IMP] `crm`: change the search order for a won stage
* In case "not won" stages are placed between "won" stages, put an opportunity marked as "won" in the correct stage (higher sequence if possible)
##### [MOV] `website_event`: move the website_event tour to tests/tours
* The scope of another tour (event_tour) include the scope of this tour and actually starts from the Event module. This smaller tour is thus disabled and kept as a test.
# Links
Task ID : 2410217
ENT PR : https://github.com/odoo/enterprise/pull/15406
UPGRADE PR : https://github.com/odoo/upgrade/pull/2167

closes odoo/odoo#63370

Related: odoo/upgrade#2167
Related: odoo/enterprise#15406
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-03-04 13:25:07 +01:00
Laurent Stukkens (LTU) a77aad8820 [IMP] hr_timesheet: add js tests for timesheet_uom
Prior to this commit:

- There were no tests on the timesheet_uom and the fact that the widget
  that is loaded in the fieldRegistry is corresponding to the current
  company preferences.

After this commit:

- Tests will be performed in order to check that the timesheet_uom that
  is loaded in the fieldRegistry is corresponding to the current company
  preferences.

task-2168337
Closes: #66551
2021-03-04 10:34:45 +01:00
Laurent Stukkens (LTU) 3e847fc8f4 [FIX] web,hr_timesheet,partner_autocomplete: make multi company timesheet uom work
This commit's primary objective is to ensure that the timesheet uom is working in accordance
with the company settings in a multi company environment.

Prior to this commit:

 - The timesheet preferences sent to the front end were always those of the default
   company of the user.
 - The timesheet related widgets initialisation process (adding the correct ones in
   the fieldRegistry) was performed before the front end treatment of cids and coockies
   which prevented applying the front end selected company settings.

After this commit:

 - A dictionnary is used in the session in order to structure the companies info.
 - The company timesheet preferences are sent to the front end through the company dict.
 - The uom info is sent to the front end through the session.
 - The timesheet uom is now managed from the frontend and is now in sync with the settings.
 - Timesheet widgets are initialised during the AbstractWebClient init and are in sync with
   the multicompany front end settings

task-2168337
Closes: #66551
2021-03-04 10:34:32 +01:00
Laurent Stukkens (LTU) c815ba7d40 [FIX] web: add missing semicolons and typo in multi company files
Before this commit:

 - Some semicolon where missing
 - There was a typo in the variable name

After this commit:

 - The above problems are solved

task-2168337
Closes: #66551
2021-03-04 09:05:47 +01:00
Raphael Collet 08d4707fe3 [FIX] website_event_meet: autovacuum method
Convert the override of method `power_on()` to an `@autovacuum` method.

closes odoo/odoo#67178

X-original-commit: f212223305a4d1da0f01f008c3874a72945fcae0
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2021-03-03 16:26:58 +00:00
Goffin Simon b6762a0b41 [FIX] sale: Wrong untaxed_amount_to_invoice
Steps to reproduce the bug:

- Let's consider an included tax T (10%) and a product P (11€) with invoicing policy based on delivery
- Create a sale order SO with one line L with 2 P and T
- Confirm SO and deliver it

Bug:

The untaxed_amount_to_invoice was 40€ on L instead 20€

opw:2457660

closes odoo/odoo#67188

X-original-commit: 56d92277f20566d5b652ce713551970d0b7784c0
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2021-03-03 18:30:29 +00:00
Odoo's Mergebot 03e2bd9638 [MERGE] sales_team, crm, crm_iap_*: improve reporting usability
PURPOSE

Purpose of this merge is to improve reporting usability
and views in crm, lead generation and iap services.

SPECIFICATIONS

Some usability improvements going to be done by this merge are listed
below.

Improve the action helpers for the actions bound to below listed menus
for better usability:

  * My Activities
  * Leads
  * Leads Analysis

Along with that, this commit also improves the following:

  * while generating leads, make 'Industries' field required on the modal so
    that results obtained are actionable instead of random leads;
  * after trying to generate leads, if no result is found, the same pop-up
    opens again with same criteria and displays a waring in the pop-up. It
    informs users that leads are not found and no credits are spent for their
    last search;
  * improve the warning message for unsuccessful enrichment due to invalid
    email;

This merge adds the color_picker widget for setting valid color of
CRM tags in the form view.

With this merge, the 'Enrich' button on lead now appears only after the
email is set and valid, which previously appeared even if no email is set
or if the value is not a valid email.

Right now, for the fetched contacts through enrichment, we display
name and title in separate columns (in the chatter), that leaves
lesser space for email and phone.

With this commit, we merge name and title columns, and provide a bit
extra space to email and phone so that chances for them being wrapped
in a new line are less. Also, if phone number is not available in any
contacts, the 'Phone' column is hidden, giving even more space for the
Name/Title and Email columns.

LINKS

COM PR odoo/odoo#64075
ENT PR odoo/enterprise#15561
Task ID-2393253

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-03-04 09:16:26 +01:00
Géry Debongnie 2c777546a7 [FIX] web: prevent traceback when pressing TAB in color_picker widget
The color_picker widget, that can be seen for example in the track form
view for event tracks, had an issue: if the user clicked on it, then
pressed TAB, a traceback was displayed.

The problem comes from the fact that the color picker widget inherits
from FieldInput, but is not a fieldinput, so many expectations made by
the FieldInput code do not hold, such as the code run when handling
navigation (by TAB and such keypress). Because of that, the code in
_onNavigationMove crashed, because it expected an input.

Since this is a bug fix, I simply disabled the navigation in that case,
so no crash happens.  Sadly, this widget has still a big issue: it
clearly does not work as most users would expect: pressing TAB or arrows
should update the selection.  But this would be a more complicated
refactoring, for a bug which is clearly not critical, therefore this
commit implements the simple and safe solution.

Also, we disable the focus outline to minimize the wrong expectation.
Seeing them kind of implied that one could update the selection with the
keyboard.

Note that the widget color_picker was moved from another addon to web/, without
any tests nor documentation.

OPW 2467369

closes odoo/odoo#67195

X-original-commit: 580456b6ab36d16195eae9ffd776ff245ecd936e
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2021-03-03 22:05:10 +00:00
ijas ahammed 6832d7f3f8 [IMP] crm_iap_lead: merge name and title in enrichment template
Right now, for the fetched contacts through enrichment, we display
name and title in separate columns (in the chatter), that leaves
lesser space for email and phone.

With this commit, we merge name and title columns, and provide a bit
extra space to email and phone so that chances for them being wrapped
in a new line are less. Also, if phone number is not available in any
contacts, the 'Phone' column is hidden, giving even more space for the
Name/Title and Email columns.

Task ID-2393253
COM PR odoo/odoo#64075
2021-03-03 16:04:43 +00:00
ijas ahammed da523d2042 [FIX] crm_iap_lead_enrich: show 'Enrich' button only if email is valid
With this commit, the 'Enrich' button on lead now appears only after the
email is set and valid, which previously appeared even if no email is set
or if the value is not a valid email.

Task ID-2393253
COM PR odoo/odoo#64075
2021-03-03 15:59:42 +00:00
ijas ahammed 52c372352b [IMP] sales_team: add color_picker widget for CRM tags
This commit adds the color_picker widget for setting valid color of
CRM tags in the form view.

Task ID-2393253
COM PR odoo/odoo#64075
2021-03-03 15:58:53 +00:00
ijas ahammed 79476eb349 [IMP] sales_team, crm{_iap}*: improve action helpers and usability
This commit improves the action helpers for the actions bound to below listed
menus for better usability:

  * My Activities
  * Leads
  * Leads Analysis

Along with that, this commit also improves the following:

  * while generating leads, make 'Industries' field required on the modal so
    that results obtained are actionable instead of random leads;
  * after trying to generate leads, if no result is found, the same pop-up
    opens again with same criteria and displays a waring in the pop-up. It
    informs users that leads are not found and no credits are spent for their
    last search;
  * improve the warning message for unsuccessful enrichment due to invalid
    email;

COM PR odoo/odoo#64075
ENT PR odoo/enterprise#15561
Task ID-2393253
2021-03-03 15:56:23 +00:00
Laurent Smet bb839c75cb [FIX] hr_expense: Don't write 'payment_id' on aml
This line was an hack to manage the custom register payment wizard of hr_expense.
Since this wizard is gone and 'payment_id' is a related stored field in account.move.line, we should not write such data explicitely.

closes odoo/odoo#67162

X-original-commit: 2d7f45e76607736bcc4f37bec480967ae2b373d7
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2021-03-03 14:51:25 +00:00
Odoo's Mergebot 212b107fa1 [MERGE] survey: improve certification templates
PURPOSE

Improve certification templates and make them more aligned with current
state of the art certifications.

SPECIFICATIONS

Design has been completely redone to be more modern.

Also displays dynamic certification number based on the ID of
certification record for both modern and classic layouts. It consists in
minimum 10 digits. It means that if the ID of the record is 5 it is displayed
as 0000000005.

Also improves the behavior by adding name of the certification in page title
so that use can see the proper string on browser tab. For doing so, we create
a new wrapper template that sets the title for the page, and use an iframe
to loads the pdf file from existing controlloer (which returns response for the
preview pdf).

LINKS

Task ID-2341847
COM PR #66028

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-03-03 18:20:55 +01:00
Lavish Chhatwani 45eb2b397f [IMP] survey: display title on certification preview
Right now while previewing the certification template, the proper title is not
displayed on the tab of browsers.

This commit improves the behavior by adding name of the certification in title
so that use can see the proper string on browser tab. For doing so, we create
a new wrapper template that sets the title for the page, and use an iframe
to loads the pdf file from existing controlloer (which returns response for the
preview pdf).

Task ID-2341847
COM PR odoo/odoo#66028
2021-03-03 16:16:00 +00:00
Dharmraj Jhala 45b448af99 [IMP] survey: display certification number based on ID
This commit displays dynamic certification number based on the ID of
certification record for both modern and classic layouts. It consists in
minimum 10 digits. It means that if the ID of the record is 5 it is displayed
as 0000000005.

Task ID-2341847
COM PR odoo/odoo#66028
2021-03-03 16:14:57 +00:00
Elisabeth DickinsonandDharmrajsinh Jhala ae4435af84 [REF] survey: implement new certificate templates
Improve certification templates and make them more aligned with current
state of the art certifications.

Task ID-2341847
COM PR odoo/odoo#66028

Co-Authored-By: Elisabeth Dickinson <edi@odoo.com>
Co-Authored-By: Dharmrajsinh Jhala <dja@odoo.com>
2021-03-03 16:13:20 +00:00