Announcement

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

    9.1d: calendar getworkdaystart/end, refresh of rowstyle

    Hi,
    I noticed that when i move the calendar from one day to another (or one week or another in weekview), that the row styles do not seem to be recomputed.

    So when moving from one week to another I still see the workdays/workhours of the previous week. Only if I move over the rows with my mouse do the row styles get recomputed.

    Can I somehow force the recomputation of the styles? Or is there another solution?

    gr. Martin

    #2
    This looks to be working for us - our test code overrides dateIsWorkday() and getWorkdayStart() and getWorkdayEnd().

    If your code doesn't do this, please show the code you're using to achieve the same thing.

    Comment


      #3
      Hi,
      I found a way to reproduce by making some small changes to the feature explorer code. I think it is related to the daylanes feature.

      I adapted the simpledaylanes example, adding getWorkdayStart/getWorkdayEnd functions.

      http://localhost:8080/isomorphic/system/reference/SmartClient_Explorer.html#simpleDayLanes

      To reproduce, paste the code in the feature explorer, then try it. The calendar opens without showing the workdaystyle (that's also a possible bug maybe?), see image 1. Then move to the next day and move your mouse over rows, you see the style changing of rows while moving the mouse over the rows (image 2).

      Code:
      var lanes = [
          { name: "charlesMadigen", title: "Charles Madigen", width: 200 },
          { name: "tamaraKane", title: "Tamara Kane", width: 200 },
          { name: "darcyFeeney", title: "Darcy Feeney", width: 200 },
          { name: "kaiKong", title: "Kai Kong", width: 200 },
          { name: "shellyFewel", title: "Shelly Fewel", width: 200 }
      ];
      
      isc.Calendar.create({
          ID: "calendar", 
          top: 40,
          data: dayLaneData,
          lanes: lanes,
          showWeekView: false,
          showMonthView: false,
          showTimelineView: false,
            showWorkday: true,
            scrollToWorkday: true,
      
          chosenDate: new Date(),
      
          showDayLanes: true,
          canEditLane: true,
      
       getWorkdayStart: function(dt, lane) {
      var dt = new Date();
      dt.setHours(9);
      dt.setMinutes(0);
      return dt;
      },
       getWorkdayEnd: function(dt, lane) {
      var dt = new Date();
      dt.setHours(23);
      dt.setMinutes(0);
      return dt;
      },
      dateIsWorkday: function(dt, lane)  {
      return true;
      }
      });
      Attached Files

      Comment


        #4
        Thanks for the test case.
        We've made a change to address this issue - please try the next nightly build dated Oct 22 and let us know if you continue to see it.

        By the way on the first issue - whereby the calendar doesn't show your initial work-day styling when you first open it - this appears to be because you were testing with a weekend day, which shows up disabled by default.
        Setting disableWeekends to false on your calendar should get rid of that problem.

        Regards
        Isomorphic Software

        Comment


          #5
          Thanks this seems to work fine now.

          gr. Martin

          Comment

          Working...
          X