<style type="text/css">
    .text
    {
        color: #FFF;
    }
    .text
    {
        font-weight: bold;
    }
</style>
<table cellpadding="5" cellspacing="0" border="0"  id="" class="table-black">
    <thead>
        <tr align="center" bgcolor="#ebebeb">
            <td height="67" bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#666666" class="text"><span class="text">{$totalQty}</span></td>
            <td bgcolor="#666666" class="text" dir="rtl"><span class="text">{$totalPrice} {$currency}</span></td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
        </tr>
        </tr>

        <tr align="center" bgcolor="#ebebeb">
            <td height="47" bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
            <td bgcolor="#FFFFFF">&nbsp;</td>
        </tr>
        <tr>
            <th>م</th>
            <th>اسم المنتج</th>
            <th>السعر </th>
            <th>الكمية المباعة</th>
            <th>تفاصيل العملية </th>
        </tr>
    </thead>
    <tbody>
        {assign var=j value=1}
        {foreach $shownData as $data}
        <tr class="gradeA">
            <td>{$j}</td>
            <td>{$data->productName}</td>
            <td>{$data->totQty * $data->sellbilldetailprice}</td>
            <td>{$data->totQty}</td>
            <td><a onclick="showDetails({$data - > sellbilldetailproductid})">التفاصيل</a></td>
        </tr>
        {capture assign=j}{$j+1}{/capture}
        {/foreach}

    </tbody>

</table>