<? global $vis_language;?>
<table class="table table-hover b-t b-light m-b-none">
	<thead class="table_head">
		<tr>
			<th>
				<div class="btn-group">
					<label class="checkbox m-n m-r-sm i-checks"  style="float: left;"><input type="checkbox"><i></i></label>		
				</div>
			</th>
			<th class="txt_nowrap"><? echo $vis_language['TXTHOSTNAME']; ?></th>
			<th class="txt_nowrap"><? echo $vis_language['TXTDOMAIN']; ?></th>
			<th class="txt_nowrap"><? echo $vis_language['TXTPORT']; ?></th>				
			<th class="txt_nowrap"><? echo $vis_language['TXTBASEDN']; ?></th>
			<th class="txt_nowrap"><? echo $vis_language['TXTRDN']; ?></th>	
			<th class="txt_nowrap"><? echo $vis_language['TXTSTATUS']; ?></th>								
			<th></th>
		</tr>
	</thead>
	<tbody>			  
		
	 <? for($i=0;$i<count($active_dir_details);$i++) {
			$update_url = '#/setting/new_active_directory/'.$vis_language['TXTUPDATE'].' '.$vis_language['TXTACTIVEDIRECTORY'].'/'.$active_dir_details[$i]['single_login_id'];
			
			if($active_dir_details[$i]['is_enabled']==1){ 
				$status = $vis_language['TXTENABLED'];
				$lbl='vh-green-bg';
			} else {
				$status = $vis_language['TXTDISABLED'];
				$lbl='label-default';
			}
			
			echo '<tr><td width="30"><label class="checkbox m-n m-r-sm i-checks"><input type="checkbox"  name="vis_global_mass_chk_'.$i.'" id="vis_global_mass_chk_'.$i.'" value="'.$active_dir_details[$i]['single_login_id'].'" /><i></i></label></td>';
			echo '<td><a href="'.$update_url.'">'.$active_dir_details[$i]['host_name'].'</a></td>';
			echo '<td><a href="'.$update_url.'">'.$active_dir_details[$i]['domain_name'].'</a></td>';
			echo '<td><a href="'.$update_url.'">'.$active_dir_details[$i]['db_prefix'].'</a></td>';
			echo '<td><a href="'.$update_url.'">'.$active_dir_details[$i]['user_name'].'</a></td>';
			echo '<td><a href="'.$update_url.'">'.$active_dir_details[$i]['db_name'].'</a></td>';
			echo '<td><span class="label '.$lbl.'">'.$status.'</span></td>';?>

			<td align="center"> <a href="javascript:void(0);" title="<? echo$vis_language['TXTDELETE']; ?>" class="text-muted" data-toggle="ajaxModal" data-modal-arguments="vis_module=subsetting&vis_operation=get_active_directory_delete&vis_single_login_id=<? echo $active_dir_details[$i]['single_login_id']; ?>" ><i class="vh vh-delete-round"></a></td>
			
			<? echo '</tr>';
		}?>	  
    </tbody>
</table>