[Trunk/7.0] Calendar month view does not show events starting in previous month

Bug #1163912 reported by Martin
30
This bug affects 6 people
Affects Status Importance Assigned to Milestone
Odoo Web (MOVED TO GITHUB)
Fix Released
Medium
Christophe Matthieu (OpenERP)

Bug Description

Server: OE 7.0 nightly on Debian wheezy
Client: Firefox/Iceweasel 10 ESR

When I create an event spanning two months, e.g. from 2013-03-13 to 2013-04-13, one cannot see the event in April, only in March.

Related branches

summary: - Calendar month view does not show events starting in previous month
+ [Trunk/7.0] Calendar month view does not show events starting in
+ previous month
Changed in openerp-web:
status: New → Confirmed
importance: Undecided → Medium
assignee: nobody → OpenERP R&D Web Team (openerp-dev-web)
Changed in openerp-web:
assignee: OpenERP R&D Web Team (openerp-dev-web) → Fabien Meghazi (OpenERP) (fme)
Revision history for this message
Bill Ennals (bennals) wrote :

I'd just like to add my voice that I think this is a really significant bug.

 I'm on the verge of implementing OpenERP at the not-for-profit enterprise I work for and the organisational calendar is a core feature as far as we are concerned. Having recurring engagements with partners (particularly customers) not displayed in calendar view is, in my view, worthy of high importance.

Bill.

Revision history for this message
Nicolas JEUDY (njeudy) wrote :

I think this bug has high importance to ..

When you have recuring event, same things appear ... Only event that are create in current month are shown ..

Revision history for this message
Hoffmann Loïc (loic-hoffmann) wrote :

I solved this bug with this solution :

File : web_calendar/static/src/js/calendar.js
Line : 398

Change the get_range_domain function by that :

get_range_domain: function() {
        var format = openerp.web.date_to_str,
            domain = this.last_search[0].slice(0);
        domain.push('|');
        domain.push(([this.date_start, '>=', format(this.range_start.clone().addDays(-6))],
              [this.date_start, '<=', format(this.range_stop.clone().addDays(6))]));
        domain.push(([this.date_stop, '<=', format(this.range_stop.clone())],
            [this.date_stop, '>=', format(this.range_start.clone())]));
        return domain;
}

Revision history for this message
Bill Ennals (bennals) wrote :

That's good news! I haven't tested it yet but I'm very appreciative that someone has made an attempt to fix it.

Thanks,

Bill.

Revision history for this message
Bill Ennals (bennals) wrote :

Hi Hoffman Loîc.

I just tried changing the code with your suggestions above and it didn't work. In fact, it stopped the meetings being displayed in the calendar at all and seemed to create buggy behaviour when clicking the back and forward buttons to move to other months.

I suspect I might have edited the code incorrectly so is there any chance you could post the complete js. file to download? Not sure if you can do it here or if there is another way. I'd be happy to receive it by email

Thanks

Bill.

Revision history for this message
Hoffmann Loïc (loic-hoffmann) wrote :

Hi Bill Ennals,

Here is my file after modification, it works well for me.

Loïc.

Revision history for this message
Bill Ennals (bennals) wrote :

Hi Hoffmann,

I tried replacing the calendar.js file that comes with the nightly build from June 17 with the file that you posted but all I get is a blank white screen after restarting the server and loading the login page. Changing back to the official file fixes the problem but of course the calendar bug is still there. Is there something other modification you might have made to your installation that is required for your fix to work?

Thanks again,

Bill.

Changed in openerp-web:
status: Confirmed → Fix Committed
status: Fix Committed → Fix Released
Revision history for this message
Bill Ennals (bennals) wrote :

Hi Christophe,

When the status is listed as Fix Released, does that mean the fix has been merged into the nightly build? I only ask because I just installed the latest nightly build (20130701-231330) and the problem seems to still be there.

Thanks,

Bill.

Revision history for this message
Bill Ennals (bennals) wrote :

I just checked this on latest runbot build for 7.0 (15165) and the problem still exists. In fact, now if you make an appointment recurrent and then refresh the page the appointment doesn't appear at all, even in the month that it first appears in. That's on Firefox 22 on Mac OS X 10.6.8.

Bill.

Changed in openerp-web:
assignee: Fabien Meghazi (OpenERP) (fme) → Christophe Matthieu (OpenERP) (chm-openerp)
Revision history for this message
Bill Ennals (bennals) wrote :

I hope that this re-assigning means that the bug will be re-opened. The 'fix released' status was certainly not accurate from what I could see.

Revision history for this message
Cedric Le Brouster(OpenFire) (cedric-lebrouster) wrote :

Hello, I re-open the bug as the fix only solves it in calendars using date_stop parameter.
Calendars unsing date_delay parameter instead still show the bug (can only be seen in the first month of the event).
Example of calendars using date_delay : base_calendar at Sales/Configuration/Calendar/Events.

Revision history for this message
Cedric Le Brouster(OpenFire) (cedric-lebrouster) wrote :

Sorry, seems I can't re-open it ... I'll send merge proposals anyway

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.