ss 309 краткое описание продукта в модальном окне Есть решение
Здравствуйте дорогие товарищи, сразу перейду к вопросу, ссылка на сайт, проблема в том что при открытии модального окна, краткое описание продукта берется с первого продукта и предается всем остальным продуктам, я понимаю CMS старая - ss 309, но мне нужна именно она. Может быть, кто то может подсказать решение.
ссылка на виде
это мой product_brief.html
{* product brief view (from a category or search) *} {if $product_info ne NULL} {if $product_info.slug} {assign var=_product_url value="?ukey=product&productID=`$product_info.productID`&product_slug=`$product_info.slug`"|set_query_html} {else} {assign var=_product_url value="?ukey=product&productID=`$product_info.productID`"|set_query_html} {/if} {if $widget}{assign var=_form_action_url value="&view=noframe&external=1"}{/if} <!-- start product_brief.html --> <div class="custom-card gallery-item"> <form class="product_brief_block" action='{"?ukey=cart`$_form_action_url`"|set_query_html}' method="post" rel="{$product_info.productID}" {if $widget}target="_blank"{/if}> <input name="action" value="add_product" type="hidden"> <input name="productID" value="{$product_info.productID}" type="hidden"> <input class="product_price" value="{$product_info.PriceWithOutUnit|escape:'html'}" type="hidden"> {assign var=_cnt value=''} {if $product_info.thumbnail || $product_info.picture} <div class="prdbrief_thumbnail card-img-box"> <!-- Thumbnail --> <a {$target} href='{$_product_url}'> {if $product_info.thumbnail} <img class="card-img" src="{$smarty.const.URL_PRODUCTS_PICTURES}/{$product_info.thumbnail|escape:'url'}" alt="{$product_info.name|escape:'html'}" title="{$product_info.name|escape:'html'}"> {elseif $product_info.picture} <img class="card-img" src="{$smarty.const.URL_PRODUCTS_PICTURES}/{$product_info.picture|escape:'url'}" alt="{$product_info.name|escape:'html'}" title="{$product_info.name|escape:'html'}"> {/if} </a> </div> {/if} <div class="product-content card-body card-content"> {if $product_info.brief_description} <!-- Button trigger modal --> <button type="button" class="btn-outline-primary info_btn" data-toggle="modal" data-target="#exampleModalCenter"> <i class="fas fa-info-circle"></i> </button> <!-- Modal --> <div class="modal fade" id="exampleModalCenter" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true"> <div class="modal-dialog modal-dialog-centered" role="document"> <div class="modal-content"> <div class="modal-header"> <h5 class="modal-title" id="exampleModalLongTitle">Краткое описание продукта</h5> <button type="button" class="close" data-dismiss="modal" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> <div class="modal-body"> <span class="prdbrief_brief_description">{$product_info.brief_description}</span> </div> <div class="modal-footer"> </div> </div> </div> </div> {/if} <!--{if $currencies_count ne 0 && $product_info.Price > 0} <div class="prdbrief_price mx-auto price"> <span class="totalPrice">{$product_info.PriceWithUnit}</span> </div> {/if}--> {if $product_info.ordering_available && $product_info.Price>0 && ( $smarty.const.CONF_SHOW_ADD2CART eq 1 ) && ( $smarty.const.CONF_CHECKSTOCK==0 || $product_info.in_stock > 0 ) } <div class="prdbrief_add2cart mx-auto"> <input type="hidden" name="add2cart"> <a href=""{if $smarty.const.CONF_SHOPPING_CART_VIEW ne $smarty.const.SHCART_VIEW_PAGE } class="add2cart_handler" rel="{if $widget}widget{/if}" {/if} onclick="getFormByElem(this).submit(); return false;"><button class="btn btn-outline-primary add_1"> <span><i class="fa fa-cart-plus" aria-hidden="true"></i> {lbl_btn_add2cart}</span></button></a> <!-- <input {if ($PAGE_VIEW eq 'facebook')||($PAGE_VIEW eq 'vkontakte')}type="submit" value="{"str_add_to_cart_string"|transcape}" {else}type="image" src="{$button_add2cart_small}" alt="{'str_add_to_cart_string'|translate}"{/if} title="{"str_add_to_cart_string"|translate}" {if $smarty.const.CONF_SHOPPING_CART_VIEW ne $smarty.const.SHCART_VIEW_PAGE && !$widget} class="add2cart_handler" rel="{if $widget}widget{/if}" {/if}> --> </div> {elseif $smarty.const.CONF_SHOW_ADD2CART eq 1 && $smarty.const.CONF_CHECKSTOCK && !$product_info.in_stock && $product_info.ordering_available} <div class="prd_out_of_stock mx-auto">{lbl_prd_out_of_stock}</div> {/if} {if $smarty.const.CONF_VOTING_FOR_PRODUCTS eq 'True'} {if $PAGE_VIEW ne 'mobile' && $product_info.customer_votes > 0} {* rating *} <div class="sm-current-rating1 mx-auto"> <div class="sm-current-rating1-back"><i class="fas fa-star"></i></div> <div class="sm-current-rating1-front" style="width: {$product_info.customers_rating*13}px;"><i class="fas fa-star"></i></div> </div> {/if} {/if} {if $PAGE_VIEW ne 'mobile' && ($PAGE_VIEW ne 'vkontakte') && ($PAGE_VIEW ne 'facebook') && $product_info.allow_products_comparison && $show_comparison} {* removed ' && $categoryID == $product_info.categoryID' *} <div class="prdbrief_comparison mx-auto"> <input id="ctrl-prd-cmp-{$product_info.productID}" class="checknomarging ctrl_products_cmp" type="checkbox" value='{$product_info.productID}'> <label for="ctrl-prd-cmp-{$product_info.productID}">{"prd_select_to_comparison"|translate}</label> </div> {/if} <span class="all-deals"><a href=""><i class="fab fa-facebook-square soc_card"> </i> </a><span><a href=""><i class="fab fa-vk soc_card"> </i> </a> </span><span> <a href=""><i class="fab fa-instagram soc_card"> </i> </a> </span></span> </div> </form> <!-- end product_brief.html --> </div> {if $currencies_count ne 0 && $product_info.Price > 0} <div class="prdbrief_price mx-auto price"> <span class="totalPrice">{$product_info.PriceWithUnit}</span> </div> {/if} <div class="prdbrief_name card-title title text-center"> <a {$target} href='{$_product_url}'>{$product_info.name|escape:'html'}</a> {* product code (SKU) *} {if $product_info.product_code && $smarty.const.CONF_ENABLE_PRODUCT_SKU} <br><i>{$product_info.product_code|escape:'html'}</i> {/if} </div> {/if}
1 ответ
Разобрался, если кому интересно решение, вот оно -