<!-- 今日 昨日 三日 本周 当月 本季 更长 -->
<form action="shopentity.manage.php?action=check" id="form1" name="form1" method="post" style="padding-bottom:20px">
	<input type="hidden" id="check_type" name="check_type" />
  <table  class="from_table2_one top-10">	
	<thead>
		<tr class="area_ajax_list_title">
		  <th class="pd-left" width="30"><tpl> $langSysEntitySelect </tpl></th>
          <th width="60"><tpl> $langSysEntityShopName </tpl></th>
          <th width="60"><tpl> $langSysEntityShopHost </tpl></th>
          <th width="120"><tpl> $langSysEntityFaceScan </tpl></th>
          <th width="120"><tpl> $langSysEntityContraryScan </tpl></th>
          <th width="120"><tpl> $langSysEntityBusinessScan </tpl></th>
          <th width="80"><tpl> $langSysEntityAuditingEstate </tpl></th>
          <th width="50"><tpl> $langCOperation </tpl></th>
       </tr>
    </thead>
		  <tpl> if $shop_array[0].shop_id neq '' </tpl>
		  	<tpl> section name=i loop=$shop_array </tpl>
			<tr>
			  <td class="pd-left" width="30"><input name="shop_id[]" type="checkbox" value="<tpl> $shop_array[i].shop_id </tpl>"/>
			  </td>
			  <td width="60">
			  <a href="javascript:;" onclick="ajax_view('<tpl> $shop_array[i].shop_id </tpl>');">
			  <tpl> $shop_array[i].shop_name </tpl></a>
			  </a>
			  </td>
			  <td width="60"><tpl> $shop_array[i].login_name </tpl></td>
			  <td width="120">
			  <a href="../<tpl> $shop_array[i].identity_card_copy_up </tpl>" title="" class="thickbox">
			  <tpl> $langSysEntityFace </tpl></a>
		      </td>
			  <td width="120">
			  <a href="../<tpl> $shop_array[i].identity_card_copy_back </tpl>" title="" class="thickbox">
			  <tpl> $langSysEntityContrary </tpl></a>
			  </td>
			  <td width="120">
			  <a href="../<tpl> $shop_array[i].license_copy </tpl>" title="" class="thickbox">
			  <tpl> $langSysEntityBusiness </tpl></a></td>
			  <td width="80"><tpl> $shop_array[i].audit_state </tpl></td>
			  <td width="50"><a href="shopentity.manage.php?action=downloadData&shop_id=<tpl>$shop_array[i].shop_id</tpl>" title="<tpl> $langSysEntityDataDownLoad </tpl>" class="down_a_pic">
		      </a></td>
			</tr>
			<tpl> /section </tpl>
			
		<tpl> else  </tpl>
			<tr>
				<td colspan="8" align="center"><tpl> $langCNull </tpl></td>
			</tr>
		<tpl> /if  </tpl>
  </table>
   <tpl> if $shop_array[0].shop_id neq '' </tpl>
  <div class="table-5-bottom">
  <div class="p-left">
  	
				<span class="btn_left"><input class="btn_submit" name="selectall" type="button" id="selectall" value="<tpl> $langSysEntityAllSelect </tpl>" /></span>
				<span class="btn_left"><input class="btn_submit" name="negative" type="button" id="negative" value="<tpl> $langSysEntityContrarySelect </tpl>" /></span>
				<span class="btn_left"><input  class="btn_submit" type="button" id="openbutton" name="openbutton" value="<tpl> $langSysEntityAuditing </tpl>" /></span>
				<span class="btn_left"><input  class="btn_submit" type="button" id="closebutton" name="closebutton" value="<tpl> $langSysEntityRefuse </tpl>" /></span>
				
				<div class="btn_marginright">
				<tpl> $shop_page </tpl></div></div>
				
  </div>
  <tpl> /if  </tpl>
</form>
<script language="JavaScript" type="text/javascript" src="../js/jquery/thickbox.js"></script>
<link rel="stylesheet" href="../js/jquery/thickbox.css" type="text/css" media="screen" />
<script>
$(document).ready(function(){
	
	$('#negative').click(
		function(){
			$('#form1 input[@type=checkbox]').each(function(){
				$(this).attr('checked',!$(this).attr('checked'))
			})
		}
	);
	$('#selectall').click(
		function(){
			$('#form1 input[@type=checkbox]').each(function(){
				$(this).attr('checked',true)
			})
		}
	);
	
	var options_close = {
		beforeSubmit:  function(){showLoading(showText);},
		success:       function(msg){
						hideLoading();
						showMessage(msg.message,msg.type);
						if(msg.type == '1'){
							ShowDiv = "result_content";
							getPageContent('shopentity.manage.php?action=ajax_list&audit_state=<tpl> $audit_state </tpl>');
						}
					},
		type:      'post',
		dataType:  'json'
	};
	//拒绝
	$("#closebutton").click(function(){
		$('#check_type').val('3');
		$('#form1').ajaxSubmit(options_close);	
	});
	//通过
	$("#openbutton").click(function(){
		$('#check_type').val('2');
		$('#form1').ajaxSubmit(options_close);	
	});
})

function ajax_view(id){
	ShowDiv='result_content';
	getPageContent('shoplink.manage.php?action=show&audit_state=<tpl> $audit_state </tpl>&curpage=<tpl> $curpage </tpl>&from_where=shopentity&shopid='+id);
}

</script>