public function orderByCreatedAt($sort = SORT_ASC)
    {
        /* @var $this ActiveQuery */
        $model = $this->noInitModel;
        if (!is_string($model->createdAtAttribute) || empty($model->createdAtAttribute)) {
            return $this;
        }
        return $this->addOrderBy([$model->createdAtAttribute => $sort]);
    }
public function orderByCreatedAt($sort = SORT_ASC)
    {
        /* @var $this ActiveQuery */
        $model = $this->noInitModel;
        if (!is_string($model->createdAtAttribute) || empty($model->createdAtAttribute)) {
            return $this;
        }
        return $this->addOrderBy([$model->createdAtAttribute => $sort]);
    }
public function orderByCreatedAt ( $ sort = SORT_ASC ) { /* @var $this ActiveQuery */ $ model = $ this -> noInitModel ; if ( ! is_string ( $ model -> createdAtAttribute ) || empty ( $ model -> createdAtAttribute ) ) { return $ this ; } return $ this -> addOrderBy ( [ $ model -> createdAtAttribute => $ sort ] ) ; }
Specify order by creation time.
@param string $sort only 'SORT_ASC' and 'SORT_DESC' are acceptable.
@return $this
Specify order by creation time .