[], 'join_with' => [], 'orderby' => CreditHistory::tableName() . '.date ASc', 'attribute_id_producer' => CreditHistory::tableName() . '.id_producer' ]; } public function getByOrder(Order $order) { return CreditHistory::find() ->where(['id_order' => $order->id]) ->all(); } }