public function actionIndex()
 {
     $params = $this->getQuery();
     if (empty($params['memberId'])) {
         throw new BadRequestHttpException(Yii::t('common', 'parameters_missing'));
     }
     //get members openIds
     $member = Member::findByPk(new MongoId($params['memberId']));
     $openIds = empty($member->socials) ? [] : ArrayHelper::getColumn($member->socials, 'openId');
     $openIds[] = $member->openId;
     //get lastChatDate
     $lastConversation = ChatConversation::getLastByOpenIds($openIds);
     $lastChatDate = empty($lastConversation) ? '' : $lastConversation->date;
     //get conversations
     $params['openIds'] = $openIds;
     $accountId = $this->getAccountId();
     $conversations = ChatConversation::search($params, $accountId);
     $result = $this->serializeData($conversations);
     $result['lastChatDate'] = $lastChatDate;
     return $result;
 }