Quantcast
Channel: SmartClient Forums
Viewing all articles
Browse latest Browse all 4756

bug in Calendar.addEventOrUpdateEventFields

$
0
0
SmartClient Version: v10.0p_2014-11-16/EVAL Deployment (expires 2015.01.15_12.11.41) Licensed to: Isomorphic Software (#ISC_EVAL_NIGHTLY)

Chrome on OSX

I think I've just found a bug in Calendar.addEventOrUpdateEventFields, at least for the case editStyle == "time" (line 12224 of modules-debug/ISC_Calendar.js), where the:
var sAMPM = values["startAMPM"]

is not used, so I can't change the date of an event from AM to PM.

If I change the code like this:
Code:

....
    } else if (editStyle == "time") {
        var sAMPM = values["startAMPM"],
            sHrs = cal.twentyFourHourTime ? cal._to24HourNotation(values["startHours"], sAMPM)
                    : values["startHours"],
            sMins = values["startMinutes"]
        ;

        if (!cal.twentyFourHourTime) {
            sHrs = cal._to24HourNotation(sHrs, sAMPM);
            // handle the case where end date is 12am, which is valid, as this
            // is considered the end of the current day
            if (sHrs == 0) sHrs = 24;
        }
....

the problem seems fixed.

Viewing all articles
Browse latest Browse all 4756

Trending Articles