/**
* @param $id
* @throws CHttpException
*/
public function actionView($id)
{
$model = Client::model()->findByPk($id);
if (null === $model) {
throw new CHttpException(404);
}
$this->render('view', ['model' => $model, 'order' => new Order(), 'orders' => $model->getOrders()]);
}