Commit Graph
126819 Commits
Author SHA1 Message Date
Odoo Translation Bot eaeb75a3fb [I18N] Update translation terms from Transifex 2019-06-23 06:15:20 +02:00
Christophe Simonis 78b2063b29 [MERGE] forward port branch saas-12.2 up to 8747d72f1e 2019-06-21 15:16:54 +02:00
Christophe Simonis 8747d72f1e [FIX] hr_{holidays,payroll}: force no validity start date for test leave types
Oversight of previous forward-port.
2019-06-21 12:21:36 +02:00
Christophe Simonis 355ef10a82 [FIX] website_slides: correctly forward-port cfa1e101e2 2019-06-21 11:55:09 +02:00
Christophe Simonis e6cf33bd32 [FIX] hr_holidays: force empty validity start date on data/demo leave types
Oversight of previous forward-port.
2019-06-21 11:45:54 +02:00
Christophe Simonis 02b6b4db4a [FIX] test_access_rights: adapt test to forward-ported changes 2019-06-21 11:24:25 +02:00
Christophe Simonis be780012bf [MERGE] forward port branch 12.0 up to 0e72b983c3 2019-06-21 11:06:04 +02:00
Christophe Simonis 0e72b983c3 [MERGE] forward port branch saas-11.3 up to 35aeabb647 2019-06-21 10:17:10 +02:00
Басхүү 290c92e46f [IMP] base: Add Mongolian states to res.country.state.csv
As we will move those from other localizations to base,
we add those for Mongolia to base already.

closes odoo/odoo#34281

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-20 10:12:29 +00:00
Басхүү badc246afc [FIX] l10n_mn: update account chart template data
We correct the income/expense account and add
the stock input/output/valuation accounts.
Mn also uses Anglo-Saxon accounting.

Closes #34002
2019-06-20 10:12:23 +00:00
Christophe Simonis 35aeabb647 [MERGE] forward port branch 11.0 up to cc3f45ae0b 2019-06-20 12:11:43 +02:00
Christophe Simonis cc3f45ae0b [MERGE] forward port branch saas-15 up to e7fb3e2f1a 2019-06-20 12:06:59 +02:00
Christophe Simonis e7fb3e2f1a [MERGE] forward port branch saas-14 up to a7ad19d7fd 2019-06-20 12:05:26 +02:00
Christophe Simonis a7ad19d7fd [MERGE] forward port branch 10.0 up to c5c955db7a 2019-06-20 12:04:52 +02:00
Xavier Morel c5c955db7a [FIX] core: work around ir_logging deadlock
DROP CONSTRAINT (even with IF EXISTS is specified) acquires an ACCESS
EXCLUSIVE lock on the table, preventing e.g. inserts in an other
transaction, so ir_logging would systematically deadlock if configured
to the same database and a warning would be triggered during install
or update (if that ran ir.logging's init).

1. hand-roll the "IF EXISTS" bit, to avoid taking an ACCESS EXCLUSIVE
lock on the table if the problematic constraint does not exist and
thus doesn't need to be dropped (which by now should be the vast
majority of cases).

Replacing DROP CONSTRAINT with DISABLE TRIGGER does not fix the
issue as *that* acquires SHARE ROW EXCLUSIVE. While that's less
constraitning than ACCESS EXCLUSIVE, it still conflicts with an
insert's ROW_EXCLUSIVE.

2. add a timeout to the logging INSERT anyway, the deadlock is still
an issue if we're updating a database which does have the
problematic constraint, and we want to preclude the possible
eventual introduction of new deadlocks in the future.

closes odoo/odoo#34243

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-06-19 13:43:53 +00:00
Thanh Dodeur f3e10f6980 [FIX] base, web: set 304 status in binary_content
Before this commit, the No Change status wasn't properly set because
the `filehash` wasn't passed to `_binary_set_headers` and because
the status was not changed to 304 if it was already set to 200 earlier.

This commit fixes this issue and also prevents images to be processed
in `content_image` if the status is 304.

opw-2008426

closes odoo/odoo#34032

Signed-off-by: Christophe Simonis <chs@odoo.com>
2019-06-19 12:31:07 +00:00
Gorash 82bf73fe30 [FIX] web_editor: avoid dialog error on email edition
Under certain unknown conditions, the range cannot be applied and
triggered an error. In order to allow the user to keep editing, we need
to prevent the dialog from showing, hence the use of `console.error`.
If this error appears, the carret is moved to the beginning of the focused
node.
If this error appears, then bullet can generate an error (I managed to
have the bug once or simulate it by manually breaking the dom and range)

closes odoo/odoo#34284

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-20 13:25:37 +00:00
Jeremy Kersten 2349cba9c0 [FIX] website_slides: remove duplicated code
closes odoo/odoo#34283

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-06-20 07:38:54 +00:00
Jeremy Kersten ac39b8f554 [FIX] website_slides: allow to edit completion_time 2019-06-19 18:23:48 +00:00
qsm-odoo 8401c6bfac [FIX] gamification: restore broken images in non-demo data
For some strange reasons, the e-learning ranks are created in data but
the demo data override their motivational message fields.
Unfortunately, the demo data were ok but the normal data had broken
images in them.

closes odoo/odoo#34282

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-06-20 12:42:06 +00:00
qsm-odoo 6f653ac6a6 [FIX] web_editor: allow fullscreen editor even when inside modal
The new editor of https://github.com/odoo/odoo/pull/29775 came with a
fullscreen option. When using the toggle when the editor is in inside
a modal, the editor stretched only to match the size of the modal
instead of the viewport.

This is because the 'position: fixed' rule which is used to achieve the
fullscreen layout cannot work if a parent of the element has a CSS
transform applied on it. Indeed in that case, that element acts like the
viewport for 'position: fixed' elements.

closes odoo/odoo#34272

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-06-20 12:52:34 +00:00
mgh-odoo 42413faf61 [FIX] point_of_sale: discount applied twice
* Setup an IoTBox connected to a receipt printer
* In POS Config:
- IoT Box: check "IoTBox", set the IP of the Box and check "Receipt Printer"
- Pricing: Select "Tax-Included Price"
* Start the POS, select any product
* Click on "Disc" on the virutal keyboard on the bottom left of the POS
* Enter the amount of the discount
* Validatate payment (Click "Payment" > "Cash" > Enter Amount > "Validate")
* A ticket should print on the receipt printer:
- The price in the rigth column is correct

Current behaviour:
* In the left column, it shows : Product name, Base price, Discount: X%, 1 x Price --> This price is not correct, it shows the price with the discount applied twice.

Expected behaviour:
* Discount applied once everywhere on ticket.

task-1978564

closes odoo/odoo#34278

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-20 11:23:39 +00:00
mgh-odoo 1f62977d5d [FIX] point_of_sale: wrong price on receipt fix
Before this commit, if a user select option 'tax-Included Price' in pricing
from pos.config and sale product with a discount, it is first displaying
price without tax instead of the price including tax.

Task-2002464
Closes #33733

closes odoo/odoo#34259

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-20 09:24:37 +00:00
qsm-odoo 684f14d8f4 [FIX] website_mass_mailing: restore basic edition of mailing popups
Following the new editor at https://github.com/odoo/odoo/pull/29775,
the html field to edit the mass mailing popups in the backend appeared
entirely broken.

This was because the editor css was not loaded for that field.

closes odoo/odoo#34250

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-06-19 16:04:02 +00:00
Lucas Lefèvre 7cbea1dcff [FIX] hr_holidays: Don't set all employees absent
When computing `is_absent` for multiple employees
(multiple records in `self`), if one employee is really absent
(leave), all employee in the recordset are also considered
absent.

Note: it never happens in saas-12.2 but in master
and possibly custo.

closes odoo/odoo#34241

Signed-off-by: Romain Libert (rli) <rli@odoo.com>
2019-06-19 12:53:42 +00:00
Басхүү f7f58b1062 [CLA] Add CLA for Baskhuu 2019-06-19 11:16:39 +00:00
Rémi Rahir 2ba7114047 [FIX] website_sale: multi-website
The fix added in 3a0f05f334 doesn't work if an already existing user in company A
trys to modify his address on a website linked to company B. The form will try to change the company_id
of the res.partner which will then conflit with the company_id of the associated res.user, ultimately leading
to a UserError and a 500 error on the website.

opw-2025457

closes odoo/odoo#34262

Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
2019-06-20 10:17:00 +00:00
Nicolas Martinelli b59f3e4f99 [FIX] account: fallback journal
Commit 6b14ceb225 introduced a smarter way to find the default
journal based on the currency. However, it missed the fallback if no
journal is found.

opw-2009934
opw-2024204
opw-2011321

closes odoo/odoo#34263

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-20 09:00:50 +00:00
Jigar Vaghela e416428669 [FIX] l10n_de: Fix wrong tag name
closes odoo/odoo#34239

Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-06-19 10:34:47 +00:00
Christophe Simonis 132e38beef [MERGE] forward port branch 11.0 up to b5a04fd29f 2019-06-19 12:07:56 +02:00
Goffin Simon cfd5c90652 [FIX] hr_holidays: Access error when requesting a new leave
Steps to reproduce the bug:
- Create an hr.leave.allocation with mode = 'By Employee Tag'
- Select Employee Tag = 'Employee'
- Set all the other required values
- Log with Demo User(Marc Demo)
- Go to Leaves > My Leaves > New Request

Bug:

An access right error was raised due to the record rule: "Allocations: employee: read own"
With this record rule the user can only read the hr.leave.allocation linked to his employee's user.
But with allocations in mode 'By Employee Tag', in the function get_days it tried to compute
the 'number_of_hours_display' of all the allocations linked to the current employee's user and
in the function _compute_number_of_hours_display, it also computes the parent_id of these allocations.
As the parent_id is not linked to the employee's user, it raised an access right error.

opw:2006686

closes odoo/odoo#34236

Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2019-06-19 09:14:47 +00:00
Nicolas Lempereur 97cd3dfdf9 [FIX] web: update moment ar locale for month
The months name in momentjs used an arabic translation with the month
then some crap (or the month said a second time) after.

This does not seem expected, and has been solved in moment.js library 2
years ago:
https://github.com/moment/moment/pull/4271

This PR apply this change in moment.js localization included in Odoo.

opw-2006265
closes #34248

Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2019-06-19 15:00:27 +00:00
Christophe Simonis 37e05d35d2 [MERGE] forward port branch saas-11.3 up to 132e38beef 2019-06-19 14:41:36 +02:00
Mathieu Duckerts-Antoine 92a1f215c0 [FIX] web: pie chart structure not modified by favorites
A pie chart widget aims to instantiate a graph view in mode
'pie', with a measure and a single groupby specified via some
attributes. It turns out that if a pie chart is instantiated
in a context in which the keys 'graph_mode', 'graph_measure',
and 'graph_groupbys' are present, that keys prevail over the
pie chart specification. This can produce a line chart for
instance. This fix corrects that situation.

A test has been added in a corresponding commit in enterprise
(historically, the pie chart widgets are tested in dashboard
views).

closes odoo/odoo#34234

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-06-19 08:36:44 +00:00
Nicolas Martinelli ba2c179c44 [FIX] hr_holidays: validity constraint
- Create a leave type valid from June 1st
- Create a leave in May using the created leave type

Nothing prevents the user to do it.

It is because the constraint is implemented only if there is a validity
start and end date.

Fixes #32107
opw-2009800

closes odoo/odoo#34225

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-19 09:55:56 +00:00
Goffin Simon 84b89555c0 [FIX] account_voucher: Wrong entries for account voucher transaction with VAT
Steps to reproduce the bug:
- Create a vendor receipt in a journal with a foreign currency with taxes
- Validate it

Bug:

A UserError was raised because it tried to create unbalanced entries

Technically: the debit and credit of the VAT account move line were not converted
in the currency of the of the voucher's company.

opw:2007760

closes odoo/odoo#34203

Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2019-06-19 09:51:21 +00:00
Nicolas Martinelli 32603da5ba [FIX] web: avatar on empty field
- Create a calendar event
- In debug mode, remove the responsible

The 'Avatar Undefined' string is displayed at the botton of the
responsibles' list.

Do no fetch an image for a falsy value (= falsy id)

opw-2010007

closes odoo/odoo#34215

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-06-18 13:09:28 +00:00
Olivier Colson 56cecc5b6e [FIX] l10n_be: add missing tags to repartition lines
Tax report line 88 has been modified in v10 by this commit in l10n_be_reports https://github.com/odoo/enterprise/commit/1fe60a9b35245dbdba7815f32ae9bdb4c2851a87 . It has not been forward-ported properly to the new tax model: a tag must be added on refund repartition lines of taxes referencing line 88.

closes odoo/odoo#34208

Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-06-18 11:07:00 +00:00
Jakub Hrubý 36abc4641c [FIX] web: keep the search options visibility state
The search buttons visibility is saved in the local storage. Rev.
6448420 changed the API of the LocalStorage servive (by JSON
parsing the values), and didn't adapt the calls done for the
search buttons.

Closes #33833

closes odoo/odoo#34206

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-06-18 10:13:39 +00:00
Christophe Simonis ec8cfd5624 [MERGE] forward port branch saas-14 up to 249d09068a 2019-06-18 10:56:48 +02:00
Christophe Simonis 249d09068a [MERGE] forward port branch 10.0 up to 455714c7bf 2019-06-18 10:56:06 +02:00
Priyanka Kakadiya e6bfad41f2 [FIX] website_slides: fix archived slides traceback
before this commit:
When a user tries to see an archived slide, it throws an internal server error
instead of 404 page

after this commit:
404 page will be shown if a slide is archived

task- 2018147

closes odoo/odoo#34198

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-06-18 05:58:56 +00:00
Yoshi Tashiro 455714c7bf [FIX] base: set cureency position "before" for JPY
As a convention, JPY currency symbol normally shows before the amount.

closes odoo/odoo#34113

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-06-17 14:16:42 +00:00
Gorash d6b32e6757 [FIX] web_editor: avoid dialog error on email edition
Under certain unknown conditions, the range cannot be applied and
triggered an error. In order to allow the user to keep editing, we need
to prevent the dialog from showing, hence the use of `console.error`.
If this error appears, the carret is moved to the beginning of the focused
node.
If this error appears, then bullet can generate an error (I managed to
have the bug once or simulate it by manually breaking the dom and range)

closes odoo/odoo#34188

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-06-17 14:16:21 +00:00
Gorash d6f824be63 [FIX] website: editor wysiwyg must remove edition flags
html is undefined then the content are not replaced by the cleaned dom.
Change the _onActivateSnippet method to fix the previous error generated
by the dom uncleaned.
Issue introduced by https://github.com/odoo/odoo/commit/2e8222dee737215cbad0dd3556d6ec0ffe60bf00#diff-0f47e7e6900726ed7c5d97ff649ae05bR228

closes odoo/odoo#34181

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-06-17 11:11:15 +00:00
Anshuman Sharma 696e31d307 [FIX] web: highlight clickable pivot cells on hover
After a recent reorganization of the web client's components tree, the
class 'o_enable_linking' was added on the wrong element. This made the
css rule responsible of the highlighting of the clickable pivot cells
impossible to satisfy.

This commit fixes the issue by adding the class directly in the template
'PivotView'.

Additionally, this commit also makes visually clear when a field
selection menu-items is disabled (because it is already used) using
a 'not-allowed' cursor (which was removed in bs4). It is now again
possible to open a list view by clicking on a cell with zero value
(like in Odoo 11).

task-1916889

closes odoo/odoo#34165

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-06-17 04:11:28 +00:00
mgh-odoo 669b224f66 [FIX] website_slides: large image thumbnail
When user uploads video and set thumbnail from Promote >
optimize SEO > social share, it shows a small image that
changed to a large resolution image

Task-2010019

closes odoo/odoo#34177

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-06-17 09:58:11 +00:00
sri-odoo 3817cd3f3b [FIX] website_slides: add missing #wrap id
The '#wrap' id is needed by website themes to correctly
handle layout options.

closes odoo/odoo#34209

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-06-18 11:57:10 +00:00
Patrick Hoste f0ec2a8fc8 [FIX] website_slides: fix various issues to eLearning platform
Including

* change h4 to h1 on the slide page;
* add the rel='canonical' link header on the fullscreen view in order to
improve SEO and links;
* add space between quiz questions;
* remove social share statistics as they are broken and not really useful;
* moved tabs before the Quiz on the slide page;
* allow to modify slide in backend by removing some readonly attributes;

Linked to task ID 2010024
Related to PR #34176

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-06-18 11:25:03 +00:00
Lucas Perais (lpe) 800a55c06f [FIX] web: Favorites checkboxes are mutually exclusive
Before this commit, one could activate the two checkboxes "use by default", and "share for all users"

After this commit, only one out of the two can be checked

OPW 2010458

closes odoo/odoo#34167

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2019-06-17 07:49:06 +00:00