/** * Get date filter control's base ControlsMap array * @return array */ protected function getBaseContolsMapParams() { $ctrlsMap = parent::getBaseContolsMapParams(); $timeZone = date_default_timezone_get(); date_default_timezone_set(UTC); $ctrlsMap['stepType'] = $this->stepType; if ($this->stepType == FSST_SECONDS || $this->stepType == FSST_MINUTES) { $ctrlsMap['realMinValue'] = $this->getAdjustedRealDate($this->minValue); $ctrlsMap['realMaxValue'] = $this->getAdjustedRealDate($this->maxValue); } //the min, max formated dates $ctrlsMap['minValue'] = $this->getRoundedDate($this->minValue, true); $ctrlsMap['maxValue'] = $this->getRoundedDate($this->maxValue, false); //the min, max slider values (numbers) $ctrlsMap['roundedMin'] = 0; $ctrlsMap['roundedMax'] = $this->round($this->maxValue, false); $ctrlsMap['roundedMinKnobValue'] = $this->round($this->minKnobValue, true, true); $ctrlsMap['roundedMaxKnobValue'] = $this->round($this->maxKnobValue, false, true); if ($this->filtered) { $ctrlsMap['defaultValuesArray'] = $this->filteredFields[$this->fName]["values"]; $ctrlsMap['minKnobValue'] = $ctrlsMap['minValue']; $ctrlsMap['maxKnobValue'] = $ctrlsMap['maxValue']; if ($this->knobsType != FS_MAX_ONLY) { $ctrlsMap['minKnobValue'] = $this->getRoundedDate($this->minKnobFormatValue, true, true); } if ($this->knobsType != FS_MIN_ONLY) { $ctrlsMap['maxKnobValue'] = $this->getRoundedDate($this->maxKnobFormatValue, false, true); } } date_default_timezone_set($timeZone); if ($this->stepType == FSST_SECONDS) { $ctrlsMap['showSeconds'] = true; } if ($this->stepType == FSST_SECONDS || $this->stepType == FSST_MINUTES || $this->stepType == FSST_HOURS) { global $locale_info; $ctrlsMap['showTime'] = true; $ctrlsMap['timeDelimiter'] = $locale_info["LOCALE_STIME"]; $ctrlsMap['timeFormat'] = $locale_info["LOCALE_STIMEFORMAT"]; $ctrlsMap['is24hoursFormat'] = $locale_info["LOCALE_ITIME"] == "1"; $ctrlsMap['leadingZero'] = $locale_info["LOCALE_ITLZERO"] == "1"; if ($locale_info["LOCALE_ITIME"] == "0") { $ctrlsMap['designators'] = array("am" => $locale_info["LOCALE_S1159"], "pm" => $locale_info["LOCALE_S2359"]); } } return $ctrlsMap; }