本文整理汇总了PHP中sms::get_credit_usages方法的典型用法代码示例。如果您正苦于以下问题:PHP sms::get_credit_usages方法的具体用法?PHP sms::get_credit_usages怎么用?PHP sms::get_credit_usages使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sms
的用法示例。
在下文中一共展示了sms::get_credit_usages方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: define
define('sugarEntry', true);
}
include_once 'modules/Configurator/Configurator.php';
require_once 'custom/sms/sms.php';
include_once 'sugar_version.php';
if (!defined("MSG_UNVERIFIED")) {
define("MSG_UNVERIFIED", "Невозможно подключить ваш аккаунт. Пожалуйста, повторите попытку или свяжитесь с провайдером для проверки.");
}
$sms = new sms();
$parent_link = "<a href='index.php?module=Administration&action=index'>Administration</a><span class='pointer'>»</span>";
if (isset($_GET['option'])) {
switch ($_GET['option']) {
case "smsUsage":
require_once "custom/sms/sms.php";
$sms = new sms();
$usages = $sms->get_credit_usages();
arsort($usages);
if (sizeof($usages)) {
echo "<div class='moduleTitle'><h2>{$parent_link}SMS Credit Usages</h2></div>";
echo "<div class='dashletPanelMenu'>";
echo "<div class='hd'><div class='tl'></div><div class='hd-center'></div><div class='tr'></div></div>";
echo "<div class='bd'><div class='ml'></div><div class='bd-center'><div class='screen'>";
echo "<table border='0' cellspacing='1' cellpadding='0' class='list view' width='100%'>";
echo "<tr><th>Date</th><td scope='col'>Description</td><td scope='col'>Amount</td></tr>";
foreach ($usages as $val) {
echo "<tr><td>" . date("M d, Y", strtotime($val['date'])) . "</td>";
echo "<td>{$val['description']}</td>";
echo "<td>{$val['amount']}</td></tr>";
}
echo "</table>";
echo "</div><div class='mr'></div></div></div>";