Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    [bug] Calendar.eventEditorLayoutProperties

    SmartClient Version: v10.0p_2015-03-09/EVAL Development Only (expires 2015.05.08_05.58.49) Licensed to: Isomorphic Software (#ISC_EVAL_NIGHTLY)

    Please modify the #databoundCalendar sample like this:

    Code:
    // using a client-only dataSource so that test data is always relative to the current date
    isc.DataSource.create({
        ID: "eventDS",
        fields:[
            {name:"eventId", primaryKey: true, type: "sequence"},
            {name:"name"},
            {name:"description"},
            {name:"startDate", type: "datetime"},
            {name:"endDate", type: "datetime"}
        ],
        clientOnly: true,
        testData: eventData
            
    });     
    
    isc.Calendar.create({
        ID: "eventCalendar", 
        dataSource: eventDS, autoFetchData: true,
        eventEditorLayoutProperties: {
            initWidget: function () {
                this.Super("initWidget", arguments);
            }
        }
    });
    (In my actual use case I need to set up an 'observe' in the initWidget method.)

    Then click on an event, and then click 'Edit Details'. You'll see this error:
    Code:
    15:29:42.540:MUP1:WARN:Log:TypeError: Cannot read property '0' of undefined
    Stack from error.stack:
    	[a]Window.setEvent(<no args: exited>) on [Window ID:eventCalendar_eventEditorLayout] @ ISC_Calendar.js:496:1101
    	Calendar.showEventEditor(<no args: exited>) on [Calendar ID:eventCalendar] @ ISC_Calendar.js:523:368
    	Calendar.showEventEditor(<no args: exited>) on [Calendar ID:eventCalendar] @ ISC_Calendar.js:522:453
    	[a]ButtonItem.click(<no args: exited>) on [ButtonItem ID:isc_ButtonItem_0 name:details] @ ISC_Calendar.js:485:4
    	ButtonItem.fireStandardHandler(<no args: exited>) on [ButtonItem ID:isc_ButtonItem_0 name:details] @ ISC_Forms.js:1062:143
    	ButtonItem.handleClick(<no args: exited>) on [ButtonItem ID:isc_ButtonItem_0 name:details] @ ISC_Forms.js:1064:41
    	[o]IButton.handleActivate(<no args: exited>) on [IButton ID:isc_ButtonItem_0_button] @ ISC_Forms.js:1388:114
    	IButton.handleClick(<no args: exited>) on [IButton ID:isc_ButtonItem_0_button] @ ISC_Foundation.js:229:13
    	[a][c]Class.invokeSuper(<no args: exited>) on [IButton ID:isc_ButtonItem_0_button] @ ISC_Core.js:281:93
    	[a][c]Class.Super(<no args: exited>) on [IButton ID:isc_ButtonItem_0_button] @ ISC_Core.js:273:170

    #2
    By the way, I need the observe method to hide the eventEditorLayout if I hide the Calendar programmatically.

    Is it possible to do have this effect automatically?

    Comment


      #3
      The first issue, where overriding initWidget() caused crashes, is now fixed - the second issue you mentioned turned out to also be a bug - the eventEditorLayout should have been hidden when the calendar was hidden.

      You can test both fixes in builds dated March 10 and later.

      Comment


        #4
        SmartClient Version: v10.0p_2015-03-11/EVAL Development Only (expires 2015.05.10_05.59.24) Licensed to: Isomorphic Software (#ISC_EVAL_NIGHTLY)

        verified, thanks.

        Comment

        Working...
        X