[IMP] web_calendar: refresh event after fail

If an event is moved at another time, its appearance would only be
refreshed if it was successful. But in this particular instance, the
refresh may even be more useful when the change failed.

part of #9837

second half of:
opw-657863
This commit is contained in:
Nicolas Lempereur 2015-12-01 12:38:57 +01:00
parent b139c5819d
commit 73d5f62acd
1 changed files with 1 additions and 1 deletions

View File

@ -806,7 +806,7 @@ openerp.web_calendar = function(instance) {
var index = this.dataset.get_id_index(id);
if (index !== null) {
event_id = this.dataset.ids[index];
this.dataset.write(event_id, data, {}).done(function() {
this.dataset.write(event_id, data, {}).always(function() {
if (is_virtual_id(event_id)) {
// this is a virtual ID and so this will create a new event
// with an unknown id for us.