当前位置: 首页>>代码示例>>PHP>>正文


PHP UsersHelper::getUsers方法代码示例

本文整理汇总了PHP中UsersHelper::getUsers方法的典型用法代码示例。如果您正苦于以下问题:PHP UsersHelper::getUsers方法的具体用法?PHP UsersHelper::getUsers怎么用?PHP UsersHelper::getUsers使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在UsersHelper的用法示例。


在下文中一共展示了UsersHelper::getUsers方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

                <div class="crmeryValue">
                    <div class='dropdown' id="person_owner" data-item="deal" data-field="owner_id" data-item-id="<?php 
echo $person['id'];
?>
">
                        <a href="#" class='dropdown-toggle update-toggle-html' role='button' data-toggle='dropdown' id='person_owner_link'><span id="owner_first_name_<?php 
echo $person['id'];
?>
"><?php 
echo $person['owner_first_name'] . " " . $person['owner_last_name'];
?>
</span></a>
                        <ul class="dropdown-menu pull-right" role="menu">
                            <?php 
$me = array(array('label' => TextHelper::_('COBALT_ME'), 'value' => UsersHelper::getLoggedInUser()->id));
$users = UsersHelper::getUsers(null, TRUE);
$users = array_merge($me, $users);
if (count($users)) {
    foreach ($users as $key => $user) {
        ?>
                                <li>
                                    <a href="javascript:void(0);" class="dropdown_item" data-field="owner_id" data-item="person" data-item-id="<?php 
        echo $person['id'];
        ?>
" data-value="<?php 
        echo $user['value'];
        ?>
">
                                        <?php 
        echo $user['label'];
        ?>
开发者ID:houzhenggang,项目名称:cobalt,代码行数:31,代码来源:person.php

示例2: foreach

    if ($user_role != 'basic') {
        ?>
                        <li><a href="javascript:void(0);" class="filter_user_all" onclick="Task.updateEventList('all',0)" >all users</a></li>
                    <?php 
    }
    ?>
                    <?php 
    if ($user_role == 'exec') {
        $teams = UsersHelper::getTeams();
        if (count($teams) > 0) {
            foreach ($teams as $team) {
                echo "<li><a href='javascript:void(0);' class='filter_team_" . $team['team_id'] . "' onclick='Task.updateEventList(0," . $team['team_id'] . ")'>" . $team['team_name'] . TextHelper::_('COBALT_TEAM_APPEND') . "</a></li>";
            }
        }
    }
    $users = UsersHelper::getUsers();
    if (count($users) > 0) {
        foreach ($users as $user) {
            echo "<li><a href='javascript:void(0);' class='filter_user_" . $user['id'] . "' onclick='Task.updateEventList(" . $user['id'] . ",0)'>" . $user['first_name'] . "  " . $user['last_name'] . "</a></li>";
        }
    }
    ?>
                </ul>
            </span>
        <?php 
}
?>
        </div>
        <div id="task_container">
            <div id="task_list">
                <?php 
开发者ID:houzhenggang,项目名称:cobalt,代码行数:31,代码来源:event_dock.php


注:本文中的UsersHelper::getUsers方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。