From 5a63b97543199cc6fdeb1a94c33b75250e39af4c Mon Sep 17 00:00:00 2001 From: Anastasia Date: Mon, 4 Jun 2018 12:21:46 +0300 Subject: [PATCH] - blog view --- frontend/controllers/BlogController.php | 26 +++++++++++++------------- frontend/views/blog/view.php | 213 ++++++++------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 2 files changed, 21 insertions(+), 218 deletions(-) diff --git a/frontend/controllers/BlogController.php b/frontend/controllers/BlogController.php index 4838273..a08c487 100755 --- a/frontend/controllers/BlogController.php +++ b/frontend/controllers/BlogController.php @@ -77,21 +77,21 @@ ); } - public function actionView($id) + public function actionView() { - $model = $this->findModel($id); - - $tags = Tag::find() - ->with([ 'language' ]) - ->orderBy([ 'sort' => SORT_ASC ]) - ->all(); - +// $model = $this->findModel($id); +// +// $tags = Tag::find() +// ->with([ 'language' ]) +// ->orderBy([ 'sort' => SORT_ASC ]) +// ->all(); +// return $this->render( - 'view', - [ - 'tags' => $tags, - 'model' => $model, - ] + 'view' +// [ +// 'tags' => $tags, +// 'model' => $model, +// ] ); } diff --git a/frontend/views/blog/view.php b/frontend/views/blog/view.php index a1a0caf..1afbb91 100755 --- a/frontend/views/blog/view.php +++ b/frontend/views/blog/view.php @@ -11,213 +11,16 @@ * @var Article $model * @var Tag[] $tags */ - - $this->params[ 'breadcrumbs' ][] = [ - 'label' => \Yii::t('app', 'Блог'), - 'url' => [ 'blog/index' ], - ]; - - $this->params[ 'breadcrumbs' ][] = $model->title; +// +// $this->params[ 'breadcrumbs' ][] = [ +// 'label' => \Yii::t('app', 'Блог'), +// 'url' => [ 'blog/index' ], +// ]; +// +// $this->params[ 'breadcrumbs' ][] = $model->title; ?> -
-
- -
- - - -
- -

title; ?>

- - tags)) { ?> - - - -

formatter->asDate( - $model->created_at - ); ?>

- -
- - body; ?> - -
- - - -

2 comments

- - -
-
-

- -

-
-
-
Julie Alma
-

September 23, 2011 в 12:00

-

Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. - Aenean ultricies mi vitae est. Mauris placerat eleifend leo.

-

Ответить -

-
-
- - - -
- -
-

- -

-
- -
-
Louise Armero
-

23 сентября 2012 в 12:00

-

Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. - Aenean ultricies mi vitae est. Mauris placerat eleifend leo.

-

Ответить -

-
- -
- -
- - - -
- -

Leave comment

- -
-
- -
-
- - -
-
- -
- -
-
-
- - -
-
-
- -
-
-
- - -
-
-
- -
-
- -
-
- - -
- -
- - */ - ?> -
- - - - - - -
- - - - - - - - - - -
- - - - -
- - -
- - + \ No newline at end of file -- libgit2 0.21.4