Changeset View
Changeset View
Standalone View
Standalone View
src/applications/calendar/util/CalendarTimeUtil.php
<?php | <?php | ||||
/** | /** | ||||
* This class is useful for generating various time objects, relative to the | * This class is useful for generating various time objects, relative to the | ||||
* user and their timezone. | * user and their timezone. | ||||
* | * | ||||
* For now, the class exposes two sets of static methods for the two main | * For now, the class exposes two sets of static methods for the two main | ||||
* calendar views - one for the conpherence calendar widget and one for the | * calendar views - one for the conpherence calendar widget and one for the | ||||
* user profile calendar view. These have slight differences such as | * user profile calendar view. These have slight differences such as | ||||
* conpherence showing both a three day "today 'til 2 days from now" *and* | * conpherence showing both a three day "today 'til 2 days from now" *and* | ||||
* a Sunday -> Saturday list, whilest the profile view shows a more simple | * a Sunday -> Saturday list, whilst the profile view shows a more simple | ||||
* seven day rolling list of events. | * seven day rolling list of events. | ||||
*/ | */ | ||||
final class CalendarTimeUtil extends Phobject { | final class CalendarTimeUtil extends Phobject { | ||||
public static function getCalendarEventEpochs( | public static function getCalendarEventEpochs( | ||||
PhabricatorUser $user, | PhabricatorUser $user, | ||||
$start_day_str = 'Sunday', | $start_day_str = 'Sunday', | ||||
$days = 9) { | $days = 9) { | ||||
▲ Show 20 Lines • Show All 71 Lines • Show Last 20 Lines |