Good day,
can list of active promotions be presented in homepage, block?
hi,
additional customization is needed so we are at your service.
best regards,
WSA team
[quote name='Darius' timestamp='1432635375' post='215799']
Good day,
can list of active promotions be presented in homepage, block?
[/quote]
Yes, it is possible. Just create a new block with SMARTY support and the following content:
{$params= ['active' => true, 'get_hidden' => false]}
{$promotions = $params|fn_get_promotions}
{include file="views/promotions/list.tpl" promotions=$promotions.0}
Thanks a million! Works flawless!
[quote name='eComLabs' timestamp='1432640840' post='215813']
Yes, it is possible. Just create a new block with SMARTY support and the following content:
{$params= ['active' => true, 'get_hidden' => false]}
{$promotions = $params|fn_get_promotions}
{include file="views/promotions/list.tpl" promotions=$promotions.0}
[/quote]
I guess this should be available by default.
You are welcome!
Hi, this loads a detailed promotion description, can this load short description instead?
Yes, it is possible. Just create a new block with SMARTY support and the following content:
{$params= ['active' => true, 'get_hidden' => false]} {$promotions = $params|fn_get_promotions} {include file="views/promotions/list.tpl" promotions=$promotions.0}
design/themes/TEMA/templates/views/promotions/list.tpl
replace
{$promotion.detailed_description|default:$promotion.short_description nofilter}
with
{$promotion.short_description|default:$promotion.detailed_description nofilter}
Note that it will be displayed on all promotions list
This works for the text but the image of the promotion is not shown.
Is there a solution for?
Do you mean block or list.tpl template?
We use it in block template.
In the meantime we found the solution.
We’ve added the ‘extend’ parameter to the code so it looks now like this:
{$params= ['active' => true, 'get_hidden' => false, 'extend' => ['get_images'] ]}
{$promotions = $params|fn_get_promotions}
{include file="views/promotions/list.tpl" promotions=$promotions.0}
Still, thanks for the quick response.