IBOS open source
  • Namespace
  • Class

Namespaces

  • application
    • core
      • cache
        • driver
        • provider
      • components
      • controllers
      • engines
        • local
        • sae
      • model
      • modules
      • utils
      • widgets
    • modules
      • article
        • controllers
        • core
        • model
        • utils
      • calendar
        • controllers
        • model
        • utils
      • contact
        • controllers
        • model
        • utils
      • dashboard
        • controllers
        • model
        • utils
      • department
        • components
        • model
        • utils
      • diary
        • components
        • controllers
        • model
        • utils
        • widgets
      • email
        • controllers
        • core
        • model
        • utils
      • main
        • behaviors
        • components
        • controllers
        • model
        • utils
        • widgets
      • message
        • controllers
        • core
          • co
          • wx
            • callback
            • event
        • model
        • utils
      • mobile
        • components
        • controllers
        • utils
      • position
        • components
        • model
        • utils
      • recruit
        • components
        • controllers
        • core
        • model
        • utils
        • widgets
      • role
        • model
        • utils
      • user
        • components
        • controllers
        • model
        • utils
      • vote
        • components
        • controllers
        • model
        • utils
      • weibo
        • controllers
        • core
        • model
        • utils

Classes

  • Atme
  • Comment
  • Feed
  • FeedData
  • FeedDigg
  • Message
  • MessageContent
  • MessageList
  • MessageUser
  • Notify
  • NotifyEmail
  • NotifyMessage
  • NotifySms
  • UserData

Class MessageContent

CActiveRecord
Extended by application\core\model\Model
Extended by application\modules\message\model\MessageContent
Namespace: application\modules\message\model
Located at system/modules/message/model/MessageContent.php

Methods summary

public static
# model( $className = __CLASS__ )
public
# tableName( )
public array
# fetchAllMessageListByUid( integer $uid, integer $type = 1, integer $limit = 10, integer $offset = 0 )

获取私信列表 - 分页型

获取私信列表 - 分页型

Parameters

$uid
用户UID
$type
私信类型,1表示一对一私信,2表示多人聊天,默认为1
$limit
结果集数目,默认为10
$offset
结果偏移量,默认为0

Returns

array
私信列表信息
public array
# fetchAllMessageByListId( integer $listId, integer $uid, integer $sinceId = null, integer $maxId = null, integer $count = 20 )

获取指定私信列表中的私信内容

获取指定私信列表中的私信内容

Parameters

$listId
私信列表ID
$uid
用户ID
$sinceId
最早会话ID
$maxId
最新会话ID
$count
旧会话加载条数,默认为20

Returns

array
指定私信列表中的私信内容
public boolean
# postMessage( array $data, integer $fromUid )

发送私信

发送私信

Parameters

$data
私信信息,包括touid接受对象、title私信标题、content私信正文
$fromUid
发送私信的用户ID

Returns

boolean
是否发送成功
public integer
# getSinceMessageId( integer $listId, integer $nums )

获取指定私信列表,指定结果集的最早会话ID,用于动态加载

获取指定私信列表,指定结果集的最早会话ID,用于动态加载

Parameters

$listId
私信列表ID
$nums
结果集数目

Returns

integer
最早会话ID
public integer
# countUnreadList( integer $uid )

获取指定用户的未读的私信对话数目

获取指定用户的未读的私信对话数目

Parameters

$uid
用户ID

Returns

integer
指定用户未读的私信对话数目
public integer
# countUnreadMessage( integer $uid, integer $type = 0 )

获取指定用户未读的私信数目

获取指定用户未读的私信数目

Parameters

$uid
用户ID
$type
私信类型,1表示一对一私信,2表示多人聊天

Returns

integer
指定用户未读的私信数目
public integer
# countMessageListByUid( integer $uid, mixed $type = 1 )

获取指定用户的列表私信数,用于分页

获取指定用户的列表私信数,用于分页

Parameters

$uid
用户ID
$type
可用数组形式

Returns

integer
public mix
# replyMessage( integer $listId, string $content, integer $fromUid )

回复私信

回复私信

Parameters

$listId
回复的私信list_id
$content
回复内容
$fromUid
回复者ID

Returns

mix
回复失败返回false,回复成功返回本条新回复的messageid
public array
# isInList( integer $listId, integer $uid, boolean $showDetail = false )

验证指定用户是否是指定私信列表的成员

验证指定用户是否是指定私信列表的成员

Parameters

$listId
私信列表ID
$uid
用户ID
$showDetail
是否显示详细,默认为false

Returns

array
如果是成员返回相关信息,不是则返回空数组

Methods inherited from application\core\model\Model

add(), beforeDelete(), create(), deleteByPk(), fetch(), fetchAll(), fetchAllByAttributes(), fetchAllByPk(), fetchAllSortByPk(), fetchByAttributes(), fetchByPk(), fetchCache(), fetchCaches(), getCacheKey(), getIsAllowCache(), getMaxId(), getModelClass(), init(), modify(), remove(), updateAll(), updateByPk()

Constants summary

integer ONE_ON_ONE_CHAT
# 1
integer MULTIPLAYER_CHAT
# 2
integer SYSTEM_NOTIFY
# 3

Properties summary

Properties inherited from application\core\model\Model

$allowCache, $cacheLife

IBOS open source API documentation generated by ApiGen