本文整理汇总了PHP中Num::percent_change方法的典型用法代码示例。如果您正苦于以下问题:PHP Num::percent_change方法的具体用法?PHP Num::percent_change怎么用?PHP Num::percent_change使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Num
的用法示例。
在下文中一共展示了Num::percent_change方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __
?>
" class="display-block">
<div class="p-a">
<span class="statcard-desc"><?php
echo __('Sales');
?>
</span>
<h2 class="statcard-number">
<?php
echo i18n::format_currency($sales_total);
?>
<small class="delta-indicator <?php
echo Num::percent_change($sales_total, $sales_total_past) < 0 ? 'delta-negative' : 'delta-positive';
?>
"><?php
echo Num::percent_change($sales_total, $sales_total_past);
?>
</small>
<small class="ago"><?php
echo sprintf(__('%s days ago'), $days_ago);
?>
</small>
</h2>
<hr class="statcard-hr">
</div>
<div>
<?php
echo Chart::line($sales, $chart_config, $chart_colors);
?>
</div>
</a>
示例2: __
<span class="statcard-desc"><?php
echo __('12 Months Ago');
?>
</span>
<h2 class="statcard-number">
<?php
if ($six_months_ago_total !== NULL) {
?>
<?php
echo Num::format($twelve_months_ago_total, 0);
?>
<small class="delta-indicator <?php
echo Num::percent_change($twelve_months_ago_total, $twelve_six_months_ago_total) < 0 ? 'delta-negative' : 'delta-positive';
?>
"><?php
echo Num::percent_change($twelve_months_ago_total, $twelve_six_months_ago_total);
?>
</small>
<?php
} else {
?>
--
<?php
}
?>
</h2>
</div>
</li>
</ul>
</div>
</div>
示例3: __
?>
" class="display-block">
<div class="p-a">
<span class="statcard-desc"><?php
echo __('Tickets Closed');
?>
</span>
<h2 class="statcard-number">
<?php
echo Num::format($tickets_closed_total, 0);
?>
<small class="delta-indicator <?php
echo Num::percent_change($tickets_closed_total, $tickets_closed_total_past) < 0 ? 'delta-negative' : 'delta-positive';
?>
"><?php
echo Num::percent_change($tickets_closed_total, $tickets_closed_total_past);
?>
</small>
<small class="ago"><?php
echo sprintf(__('%s days ago'), $days_ago);
?>
</small>
</h2>
<hr class="statcard-hr">
</div>
<div>
<?php
echo Chart::line($tickets_closed, $chart_config, $chart_colors);
?>
</div>
</a>