本文整理汇总了PHP中Adherent::datatablesFnRender方法的典型用法代码示例。如果您正苦于以下问题:PHP Adherent::datatablesFnRender方法的具体用法?PHP Adherent::datatablesFnRender怎么用?PHP Adherent::datatablesFnRender使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Adherent
的用法示例。
在下文中一共展示了Adherent::datatablesFnRender方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
print '<thead>';
print '<tr>';
print '<th>';
print '</th>';
$obj->aoColumns[$i]->mDataProp = "_id";
$obj->aoColumns[$i]->bUseRendered = false;
$obj->aoColumns[$i]->bSearchable = false;
$obj->aoColumns[$i]->bVisible = false;
$i++;
print '<th class="essential">';
print $langs->trans("Id");
print '</th>';
$obj->aoColumns[$i]->mDataProp = "login";
$obj->aoColumns[$i]->bUseRendered = false;
$obj->aoColumns[$i]->bSearchable = true;
$obj->aoColumns[$i]->fnRender = $object->datatablesFnRender("login", "url");
$i++;
print '<th class="essential">';
print $langs->trans('Name');
print '</th>';
$obj->aoColumns[$i]->mDataProp = "Lastname";
$obj->aoColumns[$i]->sDefaultContent = "";
//$obj->aoColumns[$i]->sClass = "edit";
$i++;
print '<th class="essential">';
print $langs->trans('Firstname');
print '</th>';
$obj->aoColumns[$i]->mDataProp = "Firstname";
$obj->aoColumns[$i]->sDefaultContent = "";
//$obj->aoColumns[$i]->sClass = "edit";
$i++;
示例2:
print '<thead>';
print '<tr>';
print '<th>';
print '</th>';
$obj->aoColumns[$i]->mDataProp = "_id";
$obj->aoColumns[$i]->bUseRendered = false;
$obj->aoColumns[$i]->bSearchable = false;
$obj->aoColumns[$i]->bVisible = false;
$i++;
print '<th class="essential">';
print $langs->trans("Id");
print '</th>';
$obj->aoColumns[$i]->mDataProp = "login";
$obj->aoColumns[$i]->bUseRendered = false;
$obj->aoColumns[$i]->bSearchable = true;
$obj->aoColumns[$i]->fnRender = $adherent->datatablesFnRender("login", "url");
$i++;
print '<th class="essential">';
print $langs->trans('Firstname');
print '</th>';
$obj->aoColumns[$i]->mDataProp = "Firstname";
$obj->aoColumns[$i]->sDefaultContent = "";
//$obj->aoColumns[$i]->sClass = "edit";
$i++;
print '<th class="essential">';
print $langs->trans('Lastname');
print '</th>';
$obj->aoColumns[$i]->mDataProp = "Lastname";
$obj->aoColumns[$i]->sDefaultContent = "";
//$obj->aoColumns[$i]->sClass = "edit";
$i++;
示例3: array
print '<thead>';
print '<tr>';
print '<th>';
print '</th>';
$obj->aoColumns[$i]->mDataProp = "_id";
$obj->aoColumns[$i]->bUseRendered = false;
$obj->aoColumns[$i]->bSearchable = false;
$obj->aoColumns[$i]->bVisible = false;
$i++;
print '<th class="essential">';
print $langs->trans("Id");
print '</th>';
$obj->aoColumns[$i]->mDataProp = "tag";
$obj->aoColumns[$i]->bUseRendered = false;
$obj->aoColumns[$i]->bSearchable = true;
$obj->aoColumns[$i]->fnRender = $object->datatablesFnRender("tag", "url", array("url" => $_SERVER["PHP_SELF"] . '?id='));
$i++;
print '<th class="essential">';
print $langs->trans('Total');
print '</th>';
$obj->aoColumns[$i]->mDataProp = "nb";
$obj->aoColumns[$i]->sDefaultContent = 0;
$i++;
print '</tr>';
print '</thead>';
print '<tfoot>';
print '</tfoot>';
print '<tbody>';
$result = $object->getView('tag', array("group" => true));
if (count($result->rows) > 0) {
foreach ($result->rows as $aRow) {