Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2871125
D25793.1736838231.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
D25793.1736838231.diff
View Options
diff --git a/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php b/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php
--- a/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php
+++ b/src/applications/calendar/query/PhabricatorCalendarEventSearchEngine.php
@@ -525,6 +525,10 @@
}
}
+ /**
+ * @param PhabricatorSavedQuery $saved
+ * @return AphrontFormDateControlValue
+ */
private function getQueryDateFrom(PhabricatorSavedQuery $saved) {
if ($this->calendarYear && $this->calendarMonth) {
$viewer = $this->requireViewer();
diff --git a/src/view/form/control/AphrontFormDateControlValue.php b/src/view/form/control/AphrontFormDateControlValue.php
--- a/src/view/form/control/AphrontFormDateControlValue.php
+++ b/src/view/form/control/AphrontFormDateControlValue.php
@@ -209,6 +209,12 @@
);
}
+ /**
+ * Create a DateTime object including timezone
+ * @param string $date Date, like "2024-08-20" or "2024-07-1" or such
+ * @param string|null $time Time, like "12:00 AM" or such
+ * @return DateTime|null
+ */
private function newDateTime($date, $time) {
$date = $this->getStandardDateFormat($date);
$time = $this->getStandardTimeFormat($time);
@@ -280,10 +286,16 @@
}
}
+ /**
+ * @return DateTime|null
+ */
public function getDateTime() {
return $this->newDateTime($this->valueDate, $this->valueTime);
}
+ /**
+ * @return DateTimeZone
+ */
private function getTimezone() {
if ($this->zone) {
return $this->zone;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Jan 14, 07:03 (2 w, 2 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1113931
Default Alt Text
D25793.1736838231.diff (1 KB)
Attached To
Mode
D25793: Add some DateTime handling related PHPDocs
Attached
Detach File
Event Timeline
Log In to Comment