Hide calendar doesn't work when same ID field mapping

Report bugs for any Extensible Components

Hide calendar doesn't work when same ID field mapping

Postby leclercb » Thu Nov 14, 2013 3:46 am

REQUIRED INFO

General description of problem:
When using calendar and model mappings, if both CalendarId and EventId use the same field name (in the code below I used "id", but tried with "abc", same problem), the calendar hide feature doesn't work anymore.

Timezone and locale (if applicable):
NA

Extensible version(s) tested:
  • 1.5.2
Ext JS version(s) tested:
  • 4.2.2
OS + Browser name/version(s) tested:
  • Safari
  • Chrome
  • Firefox
Detailed steps to reproduce:
  1. Initiliaze mappings as follow:
    Code: Select all
    Extensible.calendar.data.CalendarMappings = {
        CalendarId: {
            name: 'id',
            mapping: 'id',
            type: 'int'
        },
        Title: {
            name: 'title',
            type: 'string'
        },
        Description: {
            name: 'description',
            type: 'string'
        },
        ColorId: {
            name: 'color',
            type: 'int'
        },
        IsHidden: {
            name: 'hidden',
            type: 'boolean'
        },
        Type: {
            name: 'type',
            type: 'string'
        }
    };

    Extensible.calendar.data.CalendarModel.reconfigure();

    Extensible.calendar.data.EventMappings = {
        EventId: {
            name: 'id',
            mapping: 'id',
            type: 'int'
        },
        CalendarId: {
            name: 'calendar_id',
            type: 'int'
        },
        Title: {
            name: 'title',
            type: 'string'
        },
        StartDate: {
            name: 'start_date',
            type: 'date',
            dateFormat: 'timestamp'
        },
        EndDate: {
            name: 'end_date',
            type: 'date',
            dateFormat: 'timestamp'
        },
        RRule: {
            name: 'rrule',
            type: 'string'
        },
        Location: {
            name: 'location',
            type: 'string'
        },
        Notes: {
            name: 'notes',
            type: 'string'
        },
        Url: {
            name: 'url',
            type: 'string'
        },
        IsAllDay: {
            name: 'ad',
            type: 'boolean'
        },
        Reminder: {
            name: 'rem',
            type: 'string'
        }
    };

    Extensible.calendar.data.EventModel.reconfigure();
  2. Create a calendar and some events, then try to hide the calendar
leclercb
 
Posts: 11
Joined: Thu Nov 14, 2013 3:32 am

Re: Hide calendar doesn't work when same ID field mapping

Postby leclercb » Thu Nov 28, 2013 1:32 am

The problem doesn't occur in 1.6 RC1.
leclercb
 
Posts: 11
Joined: Thu Nov 14, 2013 3:32 am

Re: Hide calendar doesn't work when same ID field mapping

Postby zeeshan030 » Wed Apr 08, 2015 10:05 pm

Upon further inspection, I see you call the store's load method quite a lot - even for filtering events by date (rather than using the store's filtering which can be client-side or remote).
We provide guarantee to cert killer 70-462 gmat with online exam 400-051 training itil and you can also get best quality Palm Beach Atlantic University mcat along with Northwestern University mcat for your guaranteed success.
zeeshan030
 
Posts: 1
Joined: Wed Apr 08, 2015 9:51 pm


Return to Bugs

Who is online

Users browsing this forum: No registered users and 1 guest

cron