本文整理汇总了PHP中language::messageCopyUser方法的典型用法代码示例。如果您正苦于以下问题:PHP language::messageCopyUser方法的具体用法?PHP language::messageCopyUser怎么用?PHP language::messageCopyUser使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类language
的用法示例。
在下文中一共展示了language::messageCopyUser方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: showUsersList
function showUsersList($users)
{
$returnStr = '';
$returnStr .= "<form id=refreshform method=post>";
$returnStr .= '<input type=hidden name=page value="sysadmin.users">';
$returnStr .= '<input type=hidden name="usertype" id="usertype_hidden">';
$returnStr .= "</form>";
$usertypes = array(-1 => Language::labelAll(), USER_INTERVIEWER => Language::labelInterviewer(), USER_NURSE => Language::labelNurse(), USER_SUPERVISOR => Language::labelSupervisor(), USER_TRANSLATOR => Language::labelTranslator(), USER_RESEARCHER => Language::labelResearcher(), USER_SYSADMIN => Language::labelSysadmin(), USER_TESTER => Language::labelTester());
$usertype = loadvar('usertype', USER_INTERVIEWER);
$returnStr .= Language::labelUserFilter() . $this->displaySelectFromArray($usertypes, $usertype, 'usertype');
$returnStr .= "<script type='text/javascript'>";
$returnStr .= '$( document ).ready(function() {
$("#usertype").change(function (e) {
$("#usertype_hidden").val(this.value);
$("#refreshform").submit();
});
})';
$returnStr .= "</script>";
if (sizeof($users) > 0) {
$returnStr .= $this->displayDataTablesScripts(array("colvis", "rowreorder"));
$returnStr .= "<script type='text/javascript'>\n \$(document).ready(function(){\n \$('#usertable').dataTable(\n {\n \"iDisplayLength\": " . sizeof($users) . ",\n dom: 'C<\"clear\">lfrtip',\n paginate: false,\n colVis: {\n activate: \"mouseover\",\n exclude: [ 0 ]\n }\n } \n ); \n });</script>\n ";
//
$returnStr .= $this->displayPopoverScript();
$returnStr .= '<br/><br/><table id="usertable" class="table table-striped table-bordered pre-scrollable table-condensed table-hover">';
$returnStr .= '<thead><tr><th></td><th>' . Language::labelUserUserName() . '</th><th>' . Language::labelUserUserNameName() . '</th><th>' . Language::labelUserUserType() . '</th></tr></thead>';
$returnStr .= '<tbody>';
$usertypes = array(USER_INTERVIEWER => Language::labelInterviewer(), USER_NURSE => Language::labelNurse(), USER_SUPERVISOR => Language::labelSupervisor(), USER_TRANSLATOR => Language::labelTranslator(), USER_RESEARCHER => Language::labelResearcher(), USER_SYSADMIN => Language::labelSysadmin(), USER_TESTER => Language::labelTester());
foreach ($users as $user) {
$returnStr .= '<tr><td>';
$content = '<a id="' . $user->getUrid() . '_edit" title="' . Language::linkEditTooltip() . '" href="' . setSessionParams(array('page' => 'sysadmin.users.edituser', 'urid' => $user->getUrid())) . '"><span class="glyphicon glyphicon-edit"></span></a>';
$content .= ' <a id="' . $user->getUrid() . '_copy" title="' . Language::linkCopyTooltip() . '" href="' . setSessionParams(array('page' => 'sysadmin.users.copyuser', 'urid' => $user->getUrid())) . '" ' . confirmAction(language::messageCopyUser($user->getName()), 'COPY') . '><span class="glyphicon glyphicon-copyright-mark"></span></a>';
$content .= ' <a id="' . $user->getUrid() . '_remove" title="' . Language::linkRemoveTooltip() . '" href="' . setSessionParams(array('page' => 'sysadmin.users.removeuser', 'urid' => $user->getUrid())) . '" ' . confirmAction(language::messageRemoveUser($user->getName()), 'REMOVE') . '><span class="glyphicon glyphicon-remove"></span></a>';
$returnStr .= '<a rel="popover" id="' . $user->getUrid() . '_popover" data-placement="right" data-html="true" data-toggle="popover" data-trigger="hover" href="' . setSessionParams(array('page' => 'sysadmin.users.edituser', 'urid' => $user->getUrid())) . '"><span class="glyphicon glyphicon-hand-right"></span></a>';
$returnStr .= '<td>' . $user->getUsername() . '</td><td>' . $user->getName() . '</td>';
$returnStr .= '<td>' . $usertypes[$user->getUserType()] . '</td></tr>';
$returnStr .= $this->displayPopover("#" . $user->getUrid() . '_popover', $content);
}
$returnStr .= '</tbody>';
$returnStr .= '</table><br/><br/>';
} else {
$returnStr .= "<br/><br/>" . $this->displayWarning(Language::messageNoUsersYet());
}
return $returnStr;
}