本文整理匯總了PHP中GerenciaComponentPage::addcomponent方法的典型用法代碼示例。如果您正苦於以下問題:PHP GerenciaComponentPage::addcomponent方法的具體用法?PHP GerenciaComponentPage::addcomponent怎麽用?PHP GerenciaComponentPage::addcomponent使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類GerenciaComponentPage
的用法示例。
在下文中一共展示了GerenciaComponentPage::addcomponent方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: FormatMoney
$table .= " <td></td>";
$table .= " <td style=\"border-bottom: 1px;border-bottom-color: black;border-style: solid;\">" . FormatMoney($total_efectivo_real) . "</td>";
$table .= " <td></td>";
$table .= " </tr>";
#------------------------------------
$table .= " <tr>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " <td></td>";
$table .= " </tr>";
#------------------------------------
$flujo_efectivo = $total_efectivo_real - $total_efectivo_disponible;
$color = $flujo_efectivo >= 0 ? "black" : "red";
$table .= " <tr style = \"background:#C4E8F8;\">";
$table .= " <td colspan = \"7\"><b>Flujo de efectivo (Corto):</b></td>";
$table .= " <td><b style = \"color:{$color};\">" . FormatMoney(abs($flujo_efectivo)) . "</b></td>";
$table .= " </tr>";
#------------------------------------
$table .= "</table>";
$page->addComponent($table);
$submit = new ApiActionComponent("api/sucursal/corte");
$submit->SetCaption("Realizar corte");
$submit->setSuccessRedirection("corte.lista.php");
$submit->setArguments(array("fecha_final" => time(), "id_sucursal" => $_GET["sid"], "total_efectivo" => 99));
$page->addcomponent($submit);
$page->render();