{if $tableName == 'regions'}
<table  class="table table-bordered rtl"  id="regionTable_{$data->id}">
    <tbody>
        <tr>
            <th class="txtc wds15">المنطقة الرئيسية  </th>
            <td>
                <input type="text" class="form-control updateElement"    data-tableName="{$tableName}"
                       data-colName="name" data-id="{$data->id}"   value='{$data->name}'>
            </td>
            <td  class="txtc wds4">
                <a href="#" class="btn red fleft delTarget" data-id="{$data->id}" 
                   data-link="regions"  data-tableName="{$tableName}" data-container="regionTable_{$data->id}"
                   data-fun="del" style="padding: 2px 0px;width: 100%">
                    <i class="fa fa-times" ></i>
                </a>
            </td>
        </tr>
        <tr>
            <th class="txtc">المناطق الفرعية 
                <a href="#" class="btn green-haze btn-sm addSubRegion"  
                   data-regionId="{$data->id}"  > + </a>
            </th>
            <td class="txtc" colspan="2" style="padding: 5px;">
                <div  class="row"   id="subRegionContainer_{$data->id}"></div>
            </td>
        </tr>
    </tbody>
</table>

{else if $tableName == 'sub_regions'}
<div class="col-md-3" id="subRegionDiv{$data->id}">
    <a class="btn red btn-xs wds7 delTarget "  data-id="{$data->id}" 
       data-link="regions"  data-tableName="{$tableName}"    data-fun="del"
       style="padding: 0; margin-left: -25px; margin-top: -11px;"  href="#"   
       data-container="subRegionDiv{$data->id}">
        <i class="fa fa-close"></i> 
    </a>
    <input type="text" class="form-control wds90 updateElement"    
           data-tableName="{$tableName}"   data-colName="name" 
           data-id="{$data->id}"   value="{$data->name}" style="display: inline;">
</div>
{/if}



