<table class="from_table2_one">	
	<thead>
		<tr class="area_ajax_list_title">
		  <th class="pd-left" width="220"><tpl> $langSysSQLBackFileName </tpl></th>
	<!-- <th align="center" valign="middle" bgcolor="#DBE6DE">备份时间</th> -->
	      <th width="80"><tpl> $langSysSQLBackSize </tpl></th>
	<!-- <th align="center" valign="middle" bgcolor="#DBE6DE">卷号</th> -->
	      <th width="180"><tpl> $langSysSQLAnnotate </tpl></th>
	      <th width="130"><tpl> $langCOperation </tpl></th>
      </tr>
  </thead>
  <tpl> section name=i loop=$file_array </tpl>
  <tr>
	<td class="pd-left"width="220" align="left"><tpl> $file_array[i].name </tpl></td>
	<!-- <td align="center" valign="middle" bgcolor="#FFFFFF"><tpl> $file_array[i].time </tpl></td> -->
	<td width="80" align="left"><tpl> $file_array[i].size </tpl></td>
	<!-- <td height="11" align="center" valign="middle" bgcolor="#FFFFFF"><tpl> $vol_array[i][3] </tpl></td> -->
	<tpl> assign var=one value=$vol_array[i]|@count </tpl>
	<tpl> assign var=one value=$one-1 </tpl>
	<td width="180" align="left"><tpl> if $vol_array[i][$one] eq 1 </tpl><tpl> $file_array[i].remark </tpl><tpl> /if </tpl></td>
	<td width="130" align="left">
		<tpl> if $vol_array[i][$one] eq 1 </tpl>
		<div style=" float:left;padding-top:5px; padding-bottom:5px;">
		<span class="btn_left"><input name="button2" type="button" class="btn_submit" onclick="ui_restor('action=restore_two&filename=<tpl> $file_array[i].name </tpl>');" value="<tpl> $langSysSQLRevert </tpl>" /></span>
		<span class="btn_left"><input name="button" type="button" class="btn_submit" onclick="ui_del('action=del&filename=<tpl> $file_array[i].name </tpl>');" value="<tpl> $langSysSQLDelete </tpl>" /></span>
		<br />
		<span class="btn_left"><input name="button" type="button" class="btn_submit" onclick="ShowDiv='result_content';getPageContent('sqlback.manage.php?action=file_list&filename=<tpl> $file_array[i].name </tpl>');" value="<tpl> $langSysSQLList </tpl>" /></span>
		<span class="btn_left"><input name="button" type="button" class="btn_submit" value="<tpl> $langSysSQLDownLoad </tpl>" onclick="location.href='sqlback.manage.php?action=make_zip&zip_name=<tpl> $file_array[i].zip_name </tpl>';" /></span>
		</div>
	<tpl> /if </tpl> </td>
  </tr>
  <tpl> /section </tpl>
</table>
     
	
<div id="ui_question" style="display:none; cursor: default; padding:10px"> 
        <b style=" font-size:14px; margin-top:10px; line-height:50px; height:50px;padding-top:10px; padding-bottom:10px"><tpl> $langCConfirmDelete </tpl></b> <br />
        <br />
        <input type="button" id="yes" value="<tpl> $langCYes </tpl>"  style=" border:1px solid #CCCCCC;width:80px; margin:5px; background-image:url(../templates/system_new/images/anniu.gif)"/> 
        <input type="button" id="no" value="<tpl> $langCNo </tpl>"  style="border:1px solid #CCCCCC;width:80px; margin:5px; background-image:url(../templates/system_new/images/anniu.gif)"/>
		<input type="hidden" id="del_value" />
</div>  
<div id="ui_re" style="display:none; cursor: default; padding:10px"> 
       <b style=" font-size:14px; margin-top:10px; line-height:50px; height:50px;padding-top:10px; padding-bottom:10px"><tpl> $langSysSQLConfirmRevert </tpl></b> <br />
        <br />
        <input type="button" id="yes_re" value="<tpl> $langCYes </tpl>" style=" border:1px solid #CCCCCC;width:80px; margin:5px; background-image:url(../templates/system_new/images/anniu.gif)"/> 
        <input type="button" id="no_re" value="<tpl> $langCNo </tpl>" style="border:1px solid #CCCCCC;width:80px; margin:5px; background-image:url(../templates/system_new/images/anniu.gif)"/>
		<input type="hidden" id="restor_value" />
</div> 

<script>
var ui_question = $("#ui_question")[0];
var ui_re = $("#ui_re")[0];
//删除
function ui_del(str){
	hideMessage();
	$.blockUI(ui_question, { width: '275px' }); 
	$('#del_value').val(str);
}
//还原
function ui_restor(str){
	hideMessage();
	$.blockUI(ui_re, { width: '275px' }); 
	$('#restor_value').val(str);
}
$(function() {
	$('#yes').click(function() {
		$.ajax({
			url: "sqlback.manage.php",
			data: $('#del_value').val(),
			type:'post',
			dataType:"json",
			beforeSubmit:  showLoading(showText),
			success: function(msg){
				hideLoading();
				showMessage(msg.message,msg.type);
				if(msg.type == 1){
					ShowDiv	= 'result_content';
					getPageContent("sqlback.manage.php?action=restore");
				}
				$.unblockUI(); 
			}
		});
		return false; 
	}); 
	$('#no').click($.unblockUI); 
	
	$('#yes_re').click(function() {
		$.ajax({
			url: "sqlback.manage.php",
			data: $('#restor_value').val(),
			type:'post',
			dataType:"json",
			beforeSubmit:  showLoading(showText),
			success: function(msg){
				hideLoading();
				showMessage(msg.message,msg.type);
				if(msg.type == 1){
					ShowDiv	= 'result_content';
					getPageContent("sqlback.manage.php?action=restore");
				}
				$.unblockUI(); 
			}
		});
		return false; 
	}); 
	$('#no_re').click($.unblockUI); 
	
}); 
</script>