本文整理汇总了PHP中Runalyze\Configuration::DataBrowser方法的典型用法代码示例。如果您正苦于以下问题:PHP Configuration::DataBrowser方法的具体用法?PHP Configuration::DataBrowser怎么用?PHP Configuration::DataBrowser使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Runalyze\Configuration
的用法示例。
在下文中一共展示了Configuration::DataBrowser方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
<?php
if ($this->DayCount < 25) {
$weekSeparator = ' top-separated';
$monthSeparator = ' top-separated-light';
} else {
$weekSeparator = ' top-separated-light';
$monthSeparator = ' top-separated';
}
$Context = new \Runalyze\Dataset\Context(new Runalyze\Model\Activity\Entity(), $this->AccountID);
$Table = new \Runalyze\View\Dataset\Table($this->DatasetConfig);
?>
<div id="data-browser-container">
<table class="zebra-style">
<?php
if (\Runalyze\Configuration::DataBrowser()->showLabels()) {
?>
<thead class="data-browser-labels">
<tr class="small">
<td colspan="<?php
echo 2 + $this->ShowEditLink + $this->ShowPublicLink;
?>
"></td>
<?php
echo $Table->codeForColumnLabels();
?>
</tr>
</thead>
<?php
}
?>
示例2: showNewTimerangeInDB
/**
* Reload data browser for new timerange
*/
public static function showNewTimerangeInDB()
{
$mode = \Runalyze\Configuration::DataBrowser()->mode();
$rel = $mode->showMonth() ? 'month-link' : 'week-link';
echo Ajax::wrapJSasFunction('$("#data-browser .panel-heading a[rel=\'' . $rel . '\']").click();');
}
示例3: allCategories
/**
* All categories
* @return ConfigurationCategory[]
*/
private function allCategories()
{
return array(Configuration::General(), Configuration::Privacy(), Configuration::ActivityView(), Configuration::ActivityForm(), Configuration::Design(), Configuration::DataBrowser(), Configuration::Vdot(), Configuration::Trimp(), Configuration::BasicEndurance(), Configuration::Misc());
}
示例4: initTimestamps
/**
* Init private timestamps from request
*/
protected function initTimestamps()
{
if (!isset($_GET['start']) || !isset($_GET['end'])) {
$Mode = Configuration::DataBrowser()->mode();
if ($Mode->showMonth()) {
$this->timestamp_start = mktime(0, 0, 0, date("m"), 1, date("Y"));
$this->timestamp_end = mktime(23, 59, 50, date("m") + 1, 0, date("Y"));
} else {
$this->timestamp_start = Time::weekstart(time());
$this->timestamp_end = Time::weekend(time());
}
} else {
$this->timestamp_start = $_GET['start'];
$this->timestamp_end = $_GET['end'];
}
$this->day_count = round(($this->timestamp_end - $this->timestamp_start) / 86400);
}
示例5: dateString
/**
* Get date string for given timestamp
* @param int $timestamp
* @return string
*/
protected function dateString($timestamp)
{
$date = date('d.m.', $timestamp);
$addLink = '';
$weekDay = Time::weekday(date('w', $timestamp), true);
if (Configuration::DataBrowser()->showCreateLink() && !FrontendShared::$IS_SHOWN) {
$addLink = ImporterWindow::linkForDate($timestamp);
}
if (Time::isToday($timestamp)) {
$weekDay = '<strong>' . $weekDay . '</strong>';
}
return $date . ' ' . $addLink . ' ' . $weekDay;
}
示例6: displayEditLink
/**
* Display edit link if used in DataBrowser
*/
public function displayEditLink()
{
if (Configuration::DataBrowser()->showEditLink()) {
if ($this->isSummary || FrontendShared::$IS_SHOWN) {
echo HTML::emptyTD();
} else {
echo HTML::td($this->Linker->smallEditLink());
}
}
}