Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

sonething about listener

I want to listener the function

    $result = $this->builder()
        ->from(array('tw'=>'Aops\Apps\Admin\Models\AuthUserWechats'))
        ->columns(array('tw.uid','tw.wechatid','tw.status'))
        ->where('tw.uid = :uid:',array('uid'=>intval($uid)))
        ->getQuery()
        ->execute()
        ->toArray();

I want to do something after toArray(),every builders run toarray,i hope it will show 1231 after running toarray()?? such as aftertoArray(),can phalcon listen it?



114.4k
Accepted
answer
edited Oct '16

What you mean ? Maybe just use CONCAT_WS in query ? And it will return concated 1231. Also if you want to select only one row use getSingleResult instead of execute. Then it will just returns ["1231"]