public function actionDetail($id) { $model = Address::findOne($id); if (!$model) { throw new BadRequestHttpException('未找到该收货地址!'); } return $model; }