Commit Graph
123157 Commits
Author SHA1 Message Date
Pratima Gupta 2f4ec15a37 [IMP]base: Unique barcode for customers.
If two customers have same barcode -
Current functionality : To select customer in POS, if we scan barcode, only the newly created customer will be selected.

To resolve this: Created the unique sql constraint for customer per company.
This commit is related to task# 1877329.

closes odoo/odoo#28316
2019-01-15 04:45:36 +00:00
Robot Odoo 4155bc5614 [MERGE][REF] link_tracker: strengthen ACLs and add tests
[REF] link_tracker: strengthen ACLs and add tests

Purpose of this merge is to clean ACLs of link tracker models. Those are rather
technical and should not be accessed as it is by external people. Let us
delegate control to controllers and lessen a bit model accessibility.

Some code is cleaned and code field is made required on link.tracker.code
model to ensure database integritry.

See commits for more details.

This merge is linked to task ID 1904277 and closes PR #28242.
2019-01-14 15:00:23 +01:00
Thibault Delavallée 6842d5cbd8 [IMP] link_tracker: make code field required on link.tracker.code model
Indeed it makes no sense to have void codes.

This commit is linked to task ID 1904277 and PR #28242.
2019-01-14 10:34:47 +00:00
Thibault Delavallée 7222f0ab53 [CLN] link_tracker: clean some code
Purpose of this commit is to remove some unnecessary code in link tracker.

 * remove unnecessary code / parameters:
 * remove unused field click_date on click as create_date is already used for
   that purpose;

This commit is linked to task ID 1904277 and PR #28242.
2019-01-14 10:34:27 +00:00
Thibault Delavallée b670911a92 [REF] link_tracker, mass_mailing: simplify add_click method and add tests
In this commit we rewrite a bit add_click in order to remove the inlined sudo
and ease inheritance and parameter management inside the method.

Access through controllers is sudo-ed as the main API method is now done
with current user access rights.

This commit is linked to task ID 1904277 and PR #28242.
2019-01-14 10:34:26 +00:00
Thibault Delavallée 75638ffb94 [REF] link_tracker: do not let public read technical / private link data
Link tracker models are rather technical and should not be accessed as it is
by external people. Let us delegate control to controllers and lessen a bit
model accessibility.

Currently everyone can use add_click method and generate statistics. Now
statistics will be generated only through dedicated routes. It will make
statistics more reliable and ensure technical data remain private.

Next commit will update code from controllers and main methods in order to be
have a more readable click API and avoid link between non dependent modules.

This commit is linked to task ID 1904277 and PR #28242.
2019-01-14 10:34:21 +00:00
mgh-odoo 9ee9724a10 [Generic] unaccent search
- added unaccent search on POS customer/partner and product
- moved unaccent from "mail.utils" to "web.utils"
- added more character to make function accurate

We might use str.normalize(from ES6) but the problem is str.normalize method can not consider some double characters i.e. accented character when normalized it returns 2 normal characters and normalize method returns single character, so here custom unaccent method is used to normalize the string

What we can improve here: We can use str.normalize method and check if string is still have unaccented charaters that we can call our unaccent method but this unaccent method is also working and performing well

closes odoo/odoo#27671
2019-01-10 12:31:53 +00:00
XavierDo 80f3eb27f7 [FIX] mail: add index on mail.activity create_uid
The activity create_user_id field is now replaced by magic create_uid field.
Since most of the search are done on this field, create_uid should be indexed as
create_user_id was.

closes odoo/odoo#30061
2019-01-09 09:30:05 +00:00
Robot Odoo a57503bfd0 [MERGE] web: update bootstrap from 4.1.3 to 4.2.1
Bootstrap just released a brand new version with new components and new possibilities, which are great to integrate in master.

Note: Unfortunately, this also comes with some bug fixes they did not add in a 4.1.4 version, so there is no clean way to backport them in Odoo 12.0 (so if any is required at some point, we will have to use bootstrap_review.scss or anything else to bug fix).

closes odoo/odoo#29949
2019-01-10 13:58:21 +01:00
XavierDo 303220f214 [FIX] mail: only notify activity assignation on user change
The current implementatipon of write on mail.activity will
send a notification to the user every time a write is made
on user_id.

To avoid to send notification / mail if the user_id is given
but doesn't change, we can simply filter the records. This
will also avoid to check assignation rights in this case.

Task: 1905086

closes odoo/odoo#30055
2019-01-10 10:14:45 +00:00
qsm-odoo f87e56c571 [FIX] web, website: adapt accordion to bootstrap update
Some update to the accordion component made it incompatible with some of
our customization.
2019-01-09 14:03:48 +00:00
qsm-odoo 63a636e6d9 [FIX] website: adapt default theme font to new BS font 2019-01-09 14:03:48 +00:00
qsm-odoo 827f30abf1 [FIX] web: adapt the color-yiq BS function
Odoo overrides the color-yiq function of bootstrap to improve it. With
the last update, BS changed its signature so Odoo had to change it to.
2019-01-09 14:03:47 +00:00
qsm-odoo 0f6f108cbe [FIX] web: adapt BS import and assets to BS update 2019-01-09 14:03:47 +00:00
qsm-odoo f4503d09dc [FIX] web: remove bootstrap sourceMappingURL
Same as https://github.com/odoo/odoo/commit/8e17223c260add842d83b2549d7bdaa4c3cc4d6c
2019-01-09 14:03:47 +00:00
qsm-odoo 63e52e6acf [IMP] web: update bootstrap from 4.1.3 to 4.2.1
This commit only updates the existing bootstrap files and add the new
ones the update brings.
2019-01-09 14:03:47 +00:00
Martin Geubelle a55fd329ab [FIX] test_main_flows: make tour pass without all modules
With the current test_main_flows dependencies, the tour does not pass in community.
Since rev. odoo/odoo@32db86e the `extra_trigger` waiting for `payment_method_id` is
never reached because the onchange who is supposed to display this field hides it
because there is only one payment method on the journal.

The second payment method is added by the module account_check_printing but we don't
want to add it in the dependencies because this module is not very common.

Note that this `extra_trigger` was meant to wait for the onchange triggered by the journal
modification on the 'Register Payment' modal but this modification is not useful as the
journal is already 'Bank (USD)' by default.

closes odoo/odoo#30023
2019-01-08 11:42:39 +00:00
Christophe Simonis d7c5bc02cc [MERGE] forward port branch saas-12.1 up to 8aa8548d8a 2019-01-09 19:59:27 +01:00
Christophe Simonis 8aa8548d8a [MERGE] forward port branch 12.0 up to 3e4138deaa
closes odoo/odoo#30045
2019-01-09 15:56:53 +00:00
Romain Derie 37b518f174 [IMP] website, website_partner: use fields from mixin on res.partner
Currently, res.partner has:
1. `website_id` field hardcoded in website module
2. `website_published` field from website `website.published.mixin` in
   website_partner module.

At the end, the res.partner model has all the field of the mixin
`website.published.multi.mixin` without having the mixin.
As a result, we have all the multi-website fields but we don't have access to
the mixins methods & computes.

Now, we use the `website.published.multi.mixin` on res.partner in website
module even if `website_published` is not needed if website_partner is not
installed.

+ add tooltip to `website` field to prevent warning since 2 fields would have
  the same label

closes odoo/odoo#29711
2019-01-09 15:21:35 +00:00
Yannick Tivisse 55a48e3415 [FIX] hr_fleet: Make 'Claim Report' work for employee without users
If an employee is not linked to an user, the claim report feature won't work.

With this commit, the report can be printed base on the user's partner or
the private employee address.

closes odoo/odoo#30065
2019-01-09 10:48:39 +00:00
Christophe Simonis 3e4138deaa [MERGE] forward port branch saas-11.3 up to 2d824a5b7a 2019-01-08 17:08:48 +01:00
Christophe Simonis 2d824a5b7a [FIX] test_mail: bump expected query count
The prefetch hell patch [1] generate one more query.

[1] a07a076c45
2019-01-08 15:35:34 +01:00
Nicolas Martinelli 232675c49b [FIX] stock: translation of Traceability Report
opw-1908220

closes odoo/odoo#30012
2019-01-08 13:45:24 +00:00
Robot Odoo 671c45fbbf [REV] lunch: Revert changes introduced in f727b8f0b5
YOLO

closes odoo/odoo#30025
2019-01-08 14:02:06 +01:00
Yannick Tivisse 6ab800135f [REM] .tx/config: Remove 'lunch_hr' source terms 2019-01-08 13:15:46 +01:00
Yannick Tivisse d1c3948a05 Revert "[IMP] lunch: automatize lunch orders"
This reverts commit f727b8f0b5.
2019-01-08 13:12:33 +01:00
Yannick Tivisse 7eefa37583 Revert "[FIX] lunch_hr: remove deprecated pycompat helper"
This reverts commit 3671d41ab7.
2019-01-08 13:12:24 +01:00
Yannick Tivisse cb5541cacd Revert "[FIX] lunch: fix lunch_supplier test"
This reverts commit 37212fe655.
2019-01-08 13:11:03 +01:00
Yannick Tivisse 3729ebf34d Revert "[IMP] lunch: reintroduce lunch_alerts, change display of wizard"
This reverts commit 6f5dc5733f.
2019-01-08 13:10:55 +01:00
Julien (juc) Castiaux e02a05a724 [FIX] web_editor: left/right/center image for mail
When creating a banner using the web editor, the targeted image
appears centered in the editor but is aligned on the left in the
email.

The issue also happened with other alignment (left in a centered
widget, right, ...) for example on outlook 2007 and should be solved
with this changeset.

note: 12.0 version of #29214

opw-1904827
Co-authored-by: Nicolas Lempereur <nle@odoo.com>
closes #29954
2019-01-08 11:53:32 +00:00
Romain Derie fd80cf9e53 [FIX] portal: dont override list-group-item BS4 active color (white)
Before this commit, BS4 color for active list-group-item (white) would always
be overriden by our portal custom css to the BS4 color for inactive one.

Part of #29884
2019-01-08 12:50:24 +00:00
Romain Derie d3a7edaec4 [FIX] web, website: set correct order on modal footer button
Since 12.0, some modal footer button order were changed. The primary button
would not be the one in the modal footer corner.

This is against bootstrap but more annoyingly, users are intuitively clicking
on the secondary button, ending up closing the modal and losing form
information they entered.

This commit simply fix the regression from 12.0 as before 12.0 these buttons
were positionned correctly.

Note that a commit in master (saas-12.2) will fix all the other ones that were
wrongly positionned before 12.0.

Step to reproduce:
  - Go to an event having the possibility to register.
  - Click on 'Register Now', a modal is shown to write details (name, email..)
  - You intuitively click on 'Cancel' as it is the bottom right button
    |________________________________ CONFIRM _ CANCEL _|
  - The modal is closed, if you try to open it again your infos are lost

Closes #29884
task-1922120
2019-01-08 12:50:24 +00:00
Christophe Simonis b50883d17b [MERGE] forward port branch 11.0 up to c07b7200b2 2019-01-08 11:52:15 +01:00
Christophe Simonis c07b7200b2 [MERGE] forward port branch saas-15 up to e1c7fefe89 2019-01-07 18:19:25 +01:00
Christophe Simonis e1c7fefe89 [MERGE] forward port branch saas-14 up to cdb0c08cb9 2019-01-07 17:30:57 +01:00
Christophe Simonis cdb0c08cb9 [MERGE] forward port branch 10.0 up to d4024a713c 2019-01-07 17:30:11 +01:00
Francisco Fernández d4024a713c [CLA] PlanetaTIC signs Odoo CCLA 2019-01-07 15:34:10 +01:00
Thibault Delavallée 8ed2a7e68a [FIX] survey: allow debug parameter in testing route
Adding kwargs in test route of surveys allow notably to avoid crashing when
working in debug mode and testing surveys.

closes odoo/odoo#29996
2019-01-07 14:27:20 +00:00
Julien (juc) Castiaux fce729e65a [FIX] web_editor: banner not horizontaly centered
When creating a banner using the web editor, the targeted image
appears centered in the editor but is aligned on the left in the
email.

The issue also happened with other alignment (left in a centered
widget, right, ...) for example on outlook 2007 and should be solved
with this changeset.

opw-1904827
Co-authored-by: Nicolas Lempereur <nle@odoo.com>
closes #29985

closes odoo/odoo#29214
2019-01-07 13:49:33 +00:00
Antoine Prieels 2299d2563b [FIX] snailmail: Remove class on recipient's address
Layouts were not accepted by Pingen due to the fact that the class that we added to the recipient's address was not present in stable versions.
The format was therefore not adapted to Pingen.
We then remove this class to fix layouts in stable versions.

closes odoo/odoo#29976
2019-01-07 09:25:51 +00:00
Christophe Monniez 6366c24499 [FIX] test_main_flows: open operations menu in enterprise only
In community, when entering the Manufacturing app, the first view is the
Manufacturing orders list view as it's not the case in enterpise, the
two steps are only necessary in enterprise.

Note: even if it fix the tour, the main bug could still be there.

closes odoo/odoo#30016
2019-01-08 08:47:53 +00:00
Odoo Translation Bot 652cecffde [I18N] Update translation terms from Transifex 2019-01-06 01:32:05 +01:00
Humberto Arocha fe8e462822 [FIX] account: Wrong amount_currency on reconciling several lines
closes odoo/odoo#29966
2019-01-05 21:49:04 +00:00
Romain Derie 56243f4670 [FIX] website_gengo: override of static template was not working
The template `website_gengo.web_editor.TranslatorInfoDialog` was not used
anymore.
It is supposed to replace the one in `web_editor` module.

Among other things, 2972976 refactored the `web_editor` template to
contain only the modal body content. The bug might be coming from it.

closes odoo/odoo#29955
2019-01-04 16:43:19 +00:00
Romain Derie 30ed4c08cc [FIX] website_*: prevent record to be unpublished on website change
Before this commit, when changing the website field in a record form view,
the is_published field would be force to false, ending unpublishing the record
if it was published.

That behavior was coming from the fact that is_published field is missing from
the form view. Thus, onchange on website is triggering a recompute server side
without is_published as the JS framework is not sending the field.
The ORM is then fallbacking on default Boolean value (False) for is_published
when sending back the onchange result.

This would only appear on object with 'website.published.multi.mixin' and with
website_id in the form view.

Replacing website_published by is_published will fix the behavior and has more
sense has website_published is the 'is_published' state in a website context.
In the backend, we are not in a website context.

task-1919689
2019-01-04 15:50:45 +00:00
Andrea Ulliana 59cc261448 [IMP] website, *: allow creating anchor links
* portal, web_editor

Anchor Link:
- Some visual improvements of the link dialog.
- New 'Page Anchor' field.
    - System by default: top and bottom.
    - Shows existing anchors.

Creation of the anchor:
- New option 'Anchor Name' to be able to create an anchor.

task-1913458

closes odoo/odoo#29150
2019-01-09 16:16:01 +00:00
Yenthe666 2ee21d9938 [IMP] gamification: improve view layout and add names for easier xpaths
closes odoo/odoo#29948
2019-01-08 15:35:34 +00:00
Darshil Trivedi 6a8f9f3570 [IMP] payment, website_sale_delivery : payment acquirer and delivery method whole part should be clickable and cursor pointer on mouse hover.
Purpose: user click anywhere from panel box to select delivery method and payment method.

Related task ID 1918459

closes odoo/odoo#29604
2019-01-09 12:11:42 +00:00
Robot Odoo 4baae1f6f2 [IMP] mrp, sale_mrp: kits quantities
**Before this PR:**

- The quantities available when a kit was ordered was 0 even if enough components were available
- The quantities delivered when a kit was ordered were correct only if all move from the picking of its sale order were done. So the quantities delivered were correct only if all components were fully delivered.

**After this PR:**
- The number of kits available is computed based on the quantities available of the components needed to make the kit.
- The number of kits delivered is computed based on how many kits it's possible to make with the components already processed.
- Some test case are added the check the flows when kits are ordered.
Those test case make sure that:

  * Delivered quantities are accurate if :
     - kits in kit
     - backorders are made
     - returns are made
     - returns of returns are made
     - Multiple differents UoMs are setted on the components of a kit

  * Available quantities are accurate if:
     - Kits in kit
     - Multiple differents UoMs are setted on the components of a kit

TaskID : 1915370

closes odoo/odoo#29270
2019-01-09 16:28:07 +01:00