Added Product Code To Grid But Alignment Is Split

I add the line:

{assign var="sku" value="sku_`$obj_id`"}{$smarty.capture.$sku nofilter}

in the grid_list template just under the product name, so the product code would show beneath the product name but it split the 'label' and 'sku' algnment, so it ends up looking like:

CODE: FWGEGW

instead of

CODE: FWGEGWY

With any overrun for a longer sku getting clipped. I can't figure out why it's splitting it... seems that there is a column layout as part of the grid and it's probably putting the 'label' in the left column and the 'sku' in the right, but I don't see where it's doing that.

The padding is caused by CSS. You can use the following code instead:

{if $product.product_code}
{__('sku')}: {$product.product_code}
{/if}

The padding is caused by CSS. You can use the following code instead:

{if $product.product_code}
{__('sku')}: {$product.product_code}
{/if}

I replaced my previously mentioned line with this and it doesn't seem to display anything... as if $product.product_code is returning false.

Add the following line to check in the product_code exists in the $product array

{$product|fn_print_r}

Add the following line to check in the product_code exists in the $product array

{$product|fn_print_r}

It shows the array with the code... weird thing is I can't get hardly anything else to show up. If I assign an arbitrary variable and give it a value then capture, nothing displays. Even just plain {$product.product_code} won't display.

It shows the array with the code... weird thing is I can't get hardly anything else to show up. If I assign an arbitrary variable and give it a value then capture, nothing displays. Even just plain {$product.product_code} won't display.

It is required to examine issue on your server. It works on my local installation