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


PHP erLhcoreClassChat::getPendingChats方法代码示例

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


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

示例1: array

    $ReturnMessages['closed_chats'] = array('list' => array_values($chats));
}
if ($pendingTabEnabled == true) {
    $additionalFilter = array('ignore_fields' => erLhcoreClassChat::$chatListIgnoreField);
    if ($showAllPending == 0) {
        $additionalFilter['filter']['user_id'] = $currentUser->getUserID();
    }
    if (is_array($Params['user_parameters_unordered']['pendingd']) && !empty($Params['user_parameters_unordered']['pendingd'])) {
        erLhcoreClassChat::validateFilterIn($Params['user_parameters_unordered']['pendingd']);
        $additionalFilter['filterin']['dep_id'] = $Params['user_parameters_unordered']['pendingd'];
    }
    $limitList = is_numeric($Params['user_parameters_unordered']['limitp']) ? (int) $Params['user_parameters_unordered']['limitp'] : 10;
    /**
     * Pending chats
     * */
    $pendingChats = erLhcoreClassChat::getPendingChats($limitList, 0, $additionalFilter);
    /**
     * Get last pending chat
     * */
    $lastPendingChatID = 0;
    $lastChatNick = erTranslationClassLhTranslation::getInstance()->getTranslation('chat/startchat', 'Visitor');
    $lastMessage = erTranslationClassLhTranslation::getInstance()->getTranslation('pagelayout/pagelayout', 'New chat request');
    if (!empty($pendingChats)) {
        $lastPendingChatID = max(array_keys($pendingChats));
        $chatRecent = reset($pendingChats);
        $lastChatNick = $chatRecent->nick . ' | ' . $chatRecent->department;
        $lastMessage = erLhcoreClassChat::getGetLastChatMessagePending($chatRecent->id);
    }
    erLhcoreClassChat::prefillGetAttributes($pendingChats, array('time_created_front', 'department_name', 'wait_time_pending', 'wait_time_seconds', 'plain_user_name'), array('department', 'time', 'status', 'user_id', 'user'));
    $ReturnMessages['pending_chats'] = array('list' => array_values($pendingChats), 'nick' => $lastChatNick, 'msg' => $lastMessage, 'last_id_identifier' => 'pending_chat', 'last_id' => $lastPendingChatID);
}
开发者ID:kenjiro7,项目名称:livehelperchat,代码行数:31,代码来源:syncadmininterface.php

示例2: array

<?php

$currentUser = erLhcoreClassUser::instance();
if (!$currentUser->isLogged() && !$currentUser->authenticate($_POST['username'], $_POST['password'])) {
    exit;
}
$activeChats = erLhcoreClassChat::getActiveChats(10);
$closedChats = erLhcoreClassChat::getClosedChats(10);
$pendingChats = erLhcoreClassChat::getPendingChats(10);
$transferedChats = erLhcoreClassTransfer::getTransferChats();
$unreadChats = erLhcoreClassChat::getUnreadMessagesChats(10, 0);
erLhcoreClassChat::prefillGetAttributes($activeChats, array('department_name'), array('updateIgnoreColumns', 'department'));
erLhcoreClassChat::prefillGetAttributes($closedChats, array('department_name'), array('updateIgnoreColumns', 'department'));
erLhcoreClassChat::prefillGetAttributes($pendingChats, array('department_name'), array('updateIgnoreColumns', 'department'));
erLhcoreClassChat::prefillGetAttributes($unreadChats, array('department_name'), array('updateIgnoreColumns', 'department'));
$onlineUsers = array();
if ($currentUser->hasAccessTo('lhchat', 'use_onlineusers')) {
    $filter = array('offset' => 0, 'limit' => 50, 'sort' => 'last_visit DESC', 'filtergt' => array('last_visit' => time() - 3600));
    $departmentParams = array();
    $userDepartments = erLhcoreClassUserDep::parseUserDepartmetnsForFilter($currentUser->getUserID());
    if ($userDepartments !== true) {
        $departmentParams['filterin']['id'] = $userDepartments;
        if (!$currentUser->hasAccessTo('lhchat', 'sees_all_online_visitors')) {
            $filter['filterin']['dep_id'] = $userDepartments;
        }
    }
    $onlineUsers = erLhcoreClassModelChatOnlineUser::getList($filter);
}
$columnsToHide = array('user_closed_ts', 'tslasign', 'reinform_timeout', 'unread_messages_informed', 'wait_timeout', 'wait_timeout_send', 'status_sub', 'timeout_message', 'nc_cb_executed', 'fbst', 'user_id', 'transfer_timeout_ts', 'operator_typing_id', 'transfer_timeout_ac', 'transfer_if_na', 'na_cb_executed', 'status', 'remarks', 'operation', 'operation_admin', 'screenshot_id', 'mail_send', 'online_user_id', 'dep_id', 'last_msg_id', 'hash', 'user_status', 'support_informed', 'support_informed', 'country_code', 'user_typing', 'user_typing_txt', 'lat', 'lon', 'chat_initiator', 'chat_variables', 'chat_duration', 'operator_typing', 'has_unread_messages', 'last_user_msg_time', 'additional_data');
$columnsName = array('id' => 'ID', 'user_tz_identifier' => 'User time zone', 'department_name' => 'Department', 'nick' => 'Nick', 'time' => 'Time', 'referrer' => 'Referrer', 'session_referrer' => 'Original referrer', 'ip' => 'IP', 'country_name' => 'Country', 'email' => 'E-mail', 'priority' => 'Priority', 'name' => 'Department', 'phone' => 'Phone', 'city' => 'City', 'wait_time' => 'Waited');
$onlineuserscolumnsToHide = array('requires_phone', 'lat_check_time', 'dep_id', 'requires_email', 'requires_username', 'invitation_seen_count', 'screenshot_id', 'operation', 'reopen_chat', 'vid', 'user_country_code', 'invitation_assigned', 'current_page', 'chat_id', 'operator_user_id', 'message_seen', 'operator_user_proactive', 'message_seen_ts', 'lat', 'lon', 'invitation_id', 'time_on_site', 'tt_time_on_site', 'invitation_count', 'store_chat');
开发者ID:Adeelgill,项目名称:livehelperchat,代码行数:31,代码来源:lists.php

示例3: array

    /**
     * Closed chats
     * */
    $chats = erLhcoreClassChat::getClosedChats(10, 0, array('ignore_fields' => erLhcoreClassChat::$chatListIgnoreField));
    erLhcoreClassChat::prefillGetAttributes($chats, array('time_created_front', 'department_name'), array('department', 'time', 'status', 'dep_id', 'user_id'));
    $ReturnMessages['closed_chats'] = array('list' => array_values($chats));
}
if ($pendingTabEnabled == true) {
    $additionalFilter = array('ignore_fields' => erLhcoreClassChat::$chatListIgnoreField);
    if ($showAllPending == 0) {
        $additionalFilter['filter']['user_id'] = $currentUser->getUserID();
    }
    /**
     * Pending chats
     * */
    $pendingChats = erLhcoreClassChat::getPendingChats(10, 0, $additionalFilter);
    /**
     * Get last pending chat
     * */
    $lastPendingChatID = 0;
    $lastChatNick = erTranslationClassLhTranslation::getInstance()->getTranslation('chat/startchat', 'Visitor');
    $lastMessage = erTranslationClassLhTranslation::getInstance()->getTranslation('pagelayout/pagelayout', 'New chat request');
    if (!empty($pendingChats)) {
        $lastPendingChatID = max(array_keys($pendingChats));
        $chatRecent = reset($pendingChats);
        $lastChatNick = $chatRecent->nick . ' | ' . $chatRecent->department;
        $lastMessage = erLhcoreClassChat::getGetLastChatMessagePending($chatRecent->id);
    }
    erLhcoreClassChat::prefillGetAttributes($pendingChats, array('time_created_front', 'department_name', 'user_name'), array('department', 'time', 'status', 'dep_id', 'user_id', 'user'));
    $ReturnMessages['pending_chats'] = array('list' => array_values($pendingChats), 'nick' => $lastChatNick, 'msg' => $lastMessage, 'last_id_identifier' => 'pending_chat', 'last_id' => $lastPendingChatID);
}
开发者ID:sudogitguy,项目名称:livehelperchat,代码行数:31,代码来源:syncadmininterface.php

示例4: array

    $tpl = erLhcoreClassTemplate::getInstance('lhchat/printchats.tpl.php');
    $items = erLhcoreClassChat::getPendingChats(10000, 0, $filterParams['filter']);
    $tpl->set('items', $items);
    $Result['content'] = $tpl->fetch();
    $Result['pagelayout'] = 'popup';
    return;
}
if (in_array($Params['user_parameters_unordered']['xls'], array(1, 2))) {
    erLhcoreClassChatExport::chatListExportXLS(erLhcoreClassChat::getPendingChats(10000, 0, $filterParams['filter']), array('type' => (int) $Params['user_parameters_unordered']['xls']));
    exit;
}
$append = erLhcoreClassSearchHandler::getURLAppendFromInput($filterParams['input_form']);
$pages = new lhPaginator();
$pages->items_total = erLhcoreClassChat::getPendingChatsCount($filterParams['filter']);
$pages->translationContext = 'chat/pendingchats';
$pages->serverURL = erLhcoreClassDesign::baseurl('chat/pendingchats') . $append;
$pages->paginate();
$tpl->set('pages', $pages);
if ($pages->items_total > 0) {
    $items = erLhcoreClassChat::getPendingChats($pages->items_per_page, $pages->low, $filterParams['filter']);
    $tpl->set('items', $items);
}
$filterParams['input_form']->form_action = erLhcoreClassDesign::baseurl('chat/pendingchats');
$tpl->set('input', $filterParams['input_form']);
$tpl->set('inputAppend', $append);
$tpl->set('can_delete_global', $currentUser->hasAccessTo('lhchat', 'deleteglobalchat'));
$tpl->set('can_delete_general', $currentUser->hasAccessTo('lhchat', 'deletechat'));
$tpl->set('current_user_id', $currentUser->getUserID());
$Result['content'] = $tpl->fetch();
$Result['path'] = array(array('url' => erLhcoreClassDesign::baseurl('chat/lists'), 'title' => erTranslationClassLhTranslation::getInstance()->getTranslation('chat/pendingchats', 'Chats list')), array('title' => erTranslationClassLhTranslation::getInstance()->getTranslation('chat/pendingchats', 'Pending chats')));
erLhcoreClassChatEventDispatcher::getInstance()->dispatch('chat.pendingchats_path', array('result' => &$Result));
开发者ID:niravpatel2008,项目名称:north-american-nemesis-new,代码行数:31,代码来源:pendingchats.php

示例5: is_numeric

     erLhcoreClassChat::validateFilterIn($Params['user_parameters_unordered']['pendingd']);
     $additionalFilter['filterin']['dep_id'] = $Params['user_parameters_unordered']['pendingd'];
 }
 if (is_array($Params['user_parameters_unordered']['pendingdprod']) && !empty($Params['user_parameters_unordered']['pendingdprod'])) {
     erLhcoreClassChat::validateFilterIn($Params['user_parameters_unordered']['pendingdprod']);
     $additionalFilter['filterin']['product_id'] = $Params['user_parameters_unordered']['pendingdprod'];
 }
 $limitList = is_numeric($Params['user_parameters_unordered']['limitp']) ? (int) $Params['user_parameters_unordered']['limitp'] : 10;
 $filterAdditionalMainAttr = array();
 if ($Params['user_parameters_unordered']['psort'] == 'asc') {
     $filterAdditionalMainAttr['sort'] = 'priority DESC, id ASC';
 }
 /**
  * Pending chats
  * */
 $pendingChats = erLhcoreClassChat::getPendingChats($limitList, 0, $additionalFilter, $filterAdditionalMainAttr);
 /**
  * Get last pending chat
  * */
 $lastPendingChatID = 0;
 $lastChatNick = erTranslationClassLhTranslation::getInstance()->getTranslation('chat/startchat', 'Visitor');
 $lastMessage = erTranslationClassLhTranslation::getInstance()->getTranslation('pagelayout/pagelayout', 'New chat request');
 if (!empty($pendingChats)) {
     $lastPendingChatID = max(array_keys($pendingChats));
     $chatRecent = reset($pendingChats);
     $lastChatNick = $chatRecent->nick . ' | ' . $chatRecent->department;
     $lastMessage = erLhcoreClassChat::getGetLastChatMessagePending($chatRecent->id);
 }
 erLhcoreClassChat::prefillGetAttributes($pendingChats, array('time_created_front', 'product_name', 'department_name', 'wait_time_pending', 'wait_time_seconds', 'plain_user_name'), array('product_id', 'product', 'department', 'time', 'status', 'user_id', 'user'));
 $ReturnMessages['pending_chats'] = array('list' => array_values($pendingChats), 'nick' => $lastChatNick, 'msg' => $lastMessage, 'last_id_identifier' => 'pending_chat', 'last_id' => $lastPendingChatID);
 $chatsList[] =& $ReturnMessages['pending_chats']['list'];
开发者ID:remdex,项目名称:livehelperchat,代码行数:31,代码来源:syncadmininterface.php

示例6: json_decode

<?php

$data = json_decode(file_get_contents("php://input"));
?>
<script>
               
        <?php 
$re = erLhcoreClassChat::getPendingChats();
?>
        <?php 
$endre = end($re);
?>
        var Id=   <?php 
echo $data->data;
?>
;
        angular.element(document.getElementById('cont')).scope().lhc.startChat( Id,'Visitor');
</script>
开发者ID:sajawalsz,项目名称:WebDealerSolutions,代码行数:18,代码来源:pending.php


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