Commit Graph
1181 Commits
Author SHA1 Message Date
Odoo Translation Bot 7fdbc66861 [I18N] Update translation terms from Transifex 2018-09-16 07:08:38 +02:00
Christophe Simonis f3fa5a5ef7 [MERGE] forward port branch saas-11.3 up to 1e0a92c996 2018-09-13 19:30:33 +02:00
Christophe Simonis 2b92f04289 [MERGE] forward port branch 11.0 up to cf7cb147f2 2018-09-11 19:50:13 +02:00
Nicolas Lempereur 3d09560ffc [FIX] calendar: keep recurring after edited one
Since 76b7242 if we have a recurring event with 3 occurences:

 [4th 4:00-4th 5:00] [14th 4:00-14th 5:00] [24th 4:00-24th 4:00]

And we detach the first one to modify it, then when getting the
info of reccurring events not detached the system get:

- starts: [14th 4:00] [24th 4:00]
- stops: [4th 5:00] [14th 5:00] [24th 5:00]

And wrongly apply the current filtering over:

 [14th 4:00-4th 5:00] [24th 4:00-14th 5:00]

So the issue hides recurrences of event wrongly if:

- they have not been detached
- they don't have a duration of 0
- one or several previous events have been detached
- the stop date of the nth previous event occurrence (nth equaling
  number of detached previous events) is not in the current filtering.

With this change, the stops are also filtered based on start of
occurrence + duration.

Without the change, the added test fails with:

 False != '27-20120301120100' : Last event should be found searching it by date range

note: 11.0 version of 10.0 #26887

opw-1866151
closes #26901
2018-09-11 16:27:58 +02:00
Odoo Translation Bot 5e4d4c305f [I18N] Update translation terms from Transifex 2018-09-09 07:07:47 +02:00
Odoo Translation Bot 01d853e295 [I18N] Update translation terms from Transifex 2018-09-09 04:11:03 +02:00
Christophe Simonis 49c3264ce0 [MERGE] forward port branch saas-11.3 up to 4850fb0838 2018-09-07 14:43:48 +02:00
Christophe Simonis f19e6ce561 [MERGE] forward port branch 11.0 up to 213759b03e 2018-09-05 18:52:27 +02:00
XavierDo 0c07ff7f41 [FIX] calendar: allow search on message_ids
When fixing calendar search for recurring events we assumed that
no autojoin field will be used in this search.

The filter unread messages is based on message_ids from mail thread.
The solution here is to redefine this field in calendar to remove the autojoin.
2018-09-03 11:11:39 +02:00
XavierDo 641fe7f34f [FIX] calendar: only make leaf evaluation when necessary
A little optimisation to avoid one more query when we have no
recuring event, and only evaluate leaf of recuring event.
2018-09-03 11:11:39 +02:00
Odoo Translation Bot a67c48b0b3 [I18N] Update translation terms from Transifex 2018-09-02 07:07:27 +02:00
Odoo Translation Bot d40145a42e [I18N] Update translation terms from Transifex 2018-09-02 04:09:57 +02:00
Nicolas Martinelli 93a586be7c [FIX] calendar: recurring events
Do not parse the rule with `rrulestr`, because converting back to string
will change the original rule.
2018-08-30 09:04:23 +02:00
Odoo Translation Bot f0ccdcb209 [I18N] Update translation terms from Transifex 2018-08-26 07:07:10 +02:00
Christophe Simonis ef6b574eda [MERGE] forward port branch saas-11.3 up to 6cc7d3f945 2018-08-21 18:48:13 +02:00
Christophe Simonis 70d0148d0d [MERGE] forward port branch 11.0 up to fbfb91799e 2018-08-21 16:58:17 +02:00
Christophe Simonis fbfb91799e [MERGE] forward port branch saas-15 up to 9cf0dbe226 2018-08-21 16:00:40 +02:00
Christophe Simonis e80f853ab3 [MERGE] forward port branch saas-14 up to aafa6e38c4 2018-08-21 12:06:23 +02:00
Christophe Simonis aafa6e38c4 [MERGE] forward port branch 10.0 up to 342d037373 2018-08-21 11:33:53 +02:00
Nicolas Martinelli b4cbf0bb61 [FIX] calendar: date start
When creating and editing a new calendar.event record from the calendar
view, the start_datetime field does not prefill from the day that was
selected on the calendar.

Introduced in e08f999468

opw-1875276
2018-08-17 13:38:32 +02:00
Martin Trigaux 86a25a68e7 [I18N] resynchronise all translations with .pot
Regenerate all child translations based on the .pot
Remove the terms that are either equal to the parent, either equal to the
source term.
Remove empty translation files
2018-08-17 01:29:55 +12:00
Odoo Translation Bot 566d1586bc [I18N] Update translation terms from Transifex 2018-08-12 07:14:34 +02:00
Odoo Translation Bot 75630e3d69 [I18N] Update translation terms from Transifex 2018-08-12 04:15:33 +02:00
Christophe Simonis 7717f082c0 [MERGE] forward port branch saas-11.3 up to af35aea6b0 2018-08-09 19:33:32 +02:00
Christophe Simonis 33e7479865 [MERGE] forward port branch saas-11.2 up to d7e2c767ce 2018-08-07 13:59:40 +02:00
Christophe Simonis d7e2c767ce [MERGE] forward port branch 11.0 up to 3513e599a7 2018-08-07 13:58:20 +02:00
Nicolas Martinelli b37416376b [FIX] google_calendar: rrule crash
Consider the following:
``` python
from datetime import datetime
from dateutil import rrule
import pytz

dt = pytz.UTC.localize(datetime(2016, 9, 2, 15, 42, 43, 205))
rset = rrule.rrulestr('FREQ=WEEKLY;INTERVAL=2;BYDAY=SU,FR,SA', dtstart=dt, forceset=True, tzinfos={})
test = [d for d in rset]
```

This will generate the following error:
```
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/dist-packages/dateutil/rrule.py", line 1164, in _iter
    advance_iterator(ritem)
  File "/usr/lib/python2.7/dist-packages/dateutil/rrule.py", line 1091, in __next__
    self.dt = advance_iterator(self.gen)
  File "/usr/lib/python2.7/dist-packages/dateutil/rrule.py", line 649, in _iter
    date = datetime.date.fromordinal(ii.yearordinal+i)
ValueError: year is out of range
```

If such an event is received from Google Calendar, the synchronization
crashes. To avoid this, we enforce a `COUNT` condition if the latter or
`UNTIL` is not explicitly specified. This gives:
``` python
rset = rrule.rrulestr('FREQ=WEEKLY;INTERVAL=2;BYDAY=SU,FR,SA;COUNT=100', dtstart=dt, forceset=True, tzinfos={})
```

Note that this was supposed to be fixed in
https://github.com/odoo/odoo/blob/9dcc32c3041e7ad3549a09c5ed68ee3ef22c7a26/addons/calendar/models/calendar.py#L1287
However, this was working with the old API. The new API and its computed
fields does something different:

1. create the calendar event with the provided `rrule`
2. trigger the inverse method `_inverse_rrule` => `count=100` is added
   to the computed parameters
3. however, doing so won't recompute `rrule` for obvious reasons (it was
   the initial value provided, so we don't recompute it)
4. the crash is met in `_get_recurrent_date_by_event` when using
   `self.rrule`

The fundamental issue is that `_inverse_rrule` is not strictly the
inverse of `_compute_rrule`.

Fixes #25189
opw-1861658
2018-08-07 09:02:44 +02:00
Christophe Simonis 32dce83618 [MERGE] forward port branch saas-11.3 up to ff80efd71e 2018-08-06 19:59:53 +02:00
Christophe Simonis 427f717d18 [MERGE] forward port branch saas-11.2 up to 932b229941 2018-08-06 13:44:01 +02:00
Christophe Simonis 932b229941 [MERGE] forward port branch 11.0 up to b29e053436 2018-08-06 11:46:10 +02:00
Lucas Perais (lpe) efa7f87cc8 [FIX] calendar: event from activity strip text from html
From a SO (for example), create an activity with type meeting
Create the calendar event

Access it as a guest with the route with the token

Before this commit, there was an error 500 because the description
of the event actually contained "\n" and was not parseable

After this commit, we strip the string at event creation, and no error occur

OPW 1867283
closes #25795
2018-08-06 09:31:06 +02:00
Odoo Translation Bot c1c5785e92 [I18N] Update translation terms from Transifex 2018-08-05 07:15:10 +02:00
Odoo Translation Bot 8aed99b0bd [I18N] Update translation terms from Transifex 2018-08-02 14:39:54 +02:00
Martin Trigaux 6b2dcd064d [I18N] export saas-11.4 source terms
For odoo-master transifex project
2018-08-02 13:32:24 +02:00
Odoo Translation Bot a465802b98 [I18N] Update translation terms from Transifex 2018-08-02 10:18:12 +02:00
Odoo Translation Bot 26aff789c9 [I18N] Update translation terms from Transifex 2018-07-29 07:17:30 +02:00
Christophe Simonis ba202dbe63 [MERGE] forward port branch saas-11.2 up to 3c521f6d05 2018-07-24 18:10:32 +02:00
Christophe Simonis 3c521f6d05 [MERGE] forward port branch 11.0 up to c51488c2f4 2018-07-24 16:43:26 +02:00
Martin Trigaux a425695e92 [I18N] remove es_AR translations
Courtesy of Juan José Scarafía, ADHOC
The quality of the Spanish (Argentina) translations is very poor.
Remove them all and will start from scratch, translating only when needed.
2018-07-24 10:45:46 +02:00
Odoo Translation Bot e6b570c898 [I18N] Update translation terms from Transifex 2018-07-22 04:09:21 +02:00
Odoo Translation Bot cf9ff55973 [I18N] Update translation terms from Transifex 2018-07-15 07:18:24 +02:00
Christophe Simonis 8285630ad2 [MERGE] forward port branch saas-11.3 up to 609491ad0e 2018-07-13 17:12:07 +02:00
Christophe Simonis f3929aa0f7 [MERGE] forward port branch saas-11.2 up to 87dadc5bc8 2018-07-13 14:32:05 +02:00
Christophe Simonis c952a11770 [MERGE] forward port branch 11.0 up to 6e6e3d4c96 2018-07-13 10:47:18 +02:00
Odoo Translation Bot e8fc62ec74 [I18N] Update translation terms from Transifex 2018-07-11 10:16:33 +02:00
XavierDo 1b323e8b17 [FIX] calendar: fix attendee status filter
An event was shown in today's meeting if another attendees wasn't
in decilned state, even if the current user declined the event.

Task: #1858076
PR: #25544
2018-07-11 10:11:14 +02:00
XavierDo dea80d7c9c [FIX] calendar: take user timezone into account for todays meeting
The end of day depends of the user timezone.

Task: #1858076
PR: #25544
2018-07-11 10:11:14 +02:00
XavierDo f74f5edc77 [FIX] calendar: correct domain computation for recurring events
The custom computation for domain applied on recurring event
was assuming that a leaf value was true. This can lead to miscomputation.

Context:
For a domain like
'|',
	('start', '>=', '2018-06-28 23:59:59'),
	('allday', '=', True),

the domain will be transformed into
'|',
	'|',
		('start', '>=', '2018-06-28 23:59:59'),
		'&',
			('recurrency', '=', 1),
			('final_date', '>=', '2018-06-28 23:59:59'),
	('allday', '=', True],
In order to fetch recurring event with date that COULD match the domain.

Then, the custom evaluation will filter the generated virtual ids with
the base domaine, replacing leaf not specific to bounds by true,
leading to a domain like:
'|',
	('start', '>=', '2018-06-28 23:59:59'),
	True,
Also well known as "True"
Therefore, all recurring event virtual ids will be kept.

Solution:
This fix proposes to fetch the leaf values from the database to ensure
the consistency of the domain.

Thanks to RLI for the help.
Task: #1858076
PR: #25544
2018-07-11 10:11:14 +02:00
Christophe Simonis e354142ce7 [MERGE] forward port branch saas-15 up to c22e479246 2018-07-10 13:21:06 +02:00
Christophe Simonis c22e479246 [MERGE] forward port branch saas-14 up to 5d8076c842 2018-07-10 12:22:55 +02:00