Commit ae213e20c5db61a635ded3c11528e48610ec9397
1 parent
810df68c
big commti
Showing
4 changed files
with
6 additions
and
6 deletions
Show diff stats
common/modules/product/models/Category.php
... | ... | @@ -165,12 +165,12 @@ class Category extends \yii\db\ActiveRecord |
165 | 165 | |
166 | 166 | |
167 | 167 | public function getImageFile() { |
168 | - return empty($this->image) ? '/images/no_photo.png' : Yii::getAlias('@imagesDir/categories/'. $this->image); | |
168 | + return empty($this->image) ? '/storage/no_photo.png' : Yii::getAlias('@imagesDir/categories/'. $this->image); | |
169 | 169 | } |
170 | 170 | |
171 | 171 | public function getImageUrl() |
172 | 172 | { |
173 | - return empty($this->image) ? '/images/no_photo.png' : Yii::getAlias('@imagesUrl/categories/' . $this->image); | |
173 | + return empty($this->image) ? '/storage/no_photo.png' : Yii::getAlias('@imagesUrl/categories/' . $this->image); | |
174 | 174 | } |
175 | 175 | |
176 | 176 | public function beforeSave($insert) | ... | ... |
common/modules/product/models/Product.php
... | ... | @@ -154,7 +154,7 @@ class Product extends \yii\db\ActiveRecord |
154 | 154 | public function getImageUrl() |
155 | 155 | { |
156 | 156 | $image = empty($this->variant) ? null : $this->variant->image; |
157 | - return !empty($image) ? $image->imageUrl : '/images/no_photo.png'; | |
157 | + return !empty($image) ? $image->imageUrl : '/storage/no_photo.png'; | |
158 | 158 | } |
159 | 159 | |
160 | 160 | /** | ... | ... |
common/modules/product/models/ProductVariant.php
... | ... | @@ -167,7 +167,7 @@ class ProductVariant extends \yii\db\ActiveRecord |
167 | 167 | public function getImageUrl() |
168 | 168 | { |
169 | 169 | // return a default image placeholder if your source image is not found |
170 | - return (!empty($this->image) && file_exists(Yii::getAlias('@productsDir') . "/" . $this->image->image )) ? $this->image->imageUrl : '/images/no_photo.png'; | |
170 | + return (!empty($this->image) && file_exists(Yii::getAlias('@productsDir') . "/" . $this->image->image )) ? $this->image->imageUrl : '/storage/no_photo.png'; | |
171 | 171 | } |
172 | 172 | |
173 | 173 | public function getFullname() { | ... | ... |
common/modules/product/widgets/views/submenu.php
... | ... | @@ -10,7 +10,7 @@ |
10 | 10 | <div class="content_item"><a href="<?= \yii\helpers\Url::to(['catalog/category', 'category' => $_item])?>"> |
11 | 11 | <div valign="top" class="picture"> |
12 | 12 | <?php if (empty($_item->image)) :?> |
13 | - <img valign="top" src="/images/no_photo.png"> | |
13 | + <img valign="top" src="/storage/no_photo.png"> | |
14 | 14 | <?php else :?> |
15 | 15 | <?= $_item->imageUrl ? \common\components\artboximage\ArtboxImageHelper::getImage($_item->imageUrl, 'mainmenu') : ''?> |
16 | 16 | <?php endif?> |
... | ... | @@ -32,7 +32,7 @@ |
32 | 32 | <div class="content_item"><a href="<?= \yii\helpers\Url::to(['catalog/category', 'category' => $_item['item']])?>"> |
33 | 33 | <div valign="top" class="picture"> |
34 | 34 | <?php if (empty($_item['item']->image)) :?> |
35 | - <img valign="top" src="/images/no_photo.png"> | |
35 | + <img valign="top" src="/storage/no_photo.png"> | |
36 | 36 | <?php else :?> |
37 | 37 | <?= $_item['item']->imageUrl ? \common\components\artboximage\ArtboxImageHelper::getImage($_item['item']->imageUrl, 'mainmenu') : ''?> |
38 | 38 | <?php endif?> | ... | ... |