Commit 8a7996ea2251f5b44dc536a445d7ad825f1cb7c8
1 parent
97edb6ce
big commti
Showing
1 changed file
with
5 additions
and
1 deletions
Show diff stats
frontend/views/catalog/_product_item.php
@@ -42,7 +42,11 @@ use yii\helpers\Url; | @@ -42,7 +42,11 @@ use yii\helpers\Url; | ||
42 | ]) ?> | 42 | ]) ?> |
43 | </a> | 43 | </a> |
44 | <div class="info_icons"> | 44 | <div class="info_icons"> |
45 | - <a href="#" class="btn buy_button" data-toggle="modal" data-target="#buyForm" data-id="<?=$model->variant->product_variant_id; ?>" lang="145">Купить</a> | 45 | + <?php if($model->variant->status != 1){?> |
46 | + <a href="#" class="btn buy_button" data-toggle="modal" data-target="#buyForm" data-id="<?=$model->variant->product_variant_id; ?>" lang="145">Купить</a> | ||
47 | + <?php }else { ?> | ||
48 | + <a href="#" style="background-color:dimgrey; background-image:linear-gradient(to bottom, #9d9fa0, #abafb2);cursor:default !important;color:#fff!important;box-shadow: none !important;border-top: 1px solid #256caf !important;border-bottom: 1px solid #256caf !important;" class="btn btn-large btn-default " data-id="<?=$model->variant->product_variant_id; ?>" lang="145">Снят с производства</a> | ||
49 | + <?php } ?> | ||
46 | <ul class="ul wishlike_block hidden"> | 50 | <ul class="ul wishlike_block hidden"> |
47 | <li class="compare hidden"> | 51 | <li class="compare hidden"> |
48 | <a onclick="add2compare(); return false;" class="compare compare_text_link_3631483" href="#">К сравнению</a> | 52 | <a onclick="add2compare(); return false;" class="compare compare_text_link_3631483" href="#">К сравнению</a> |