<form action="news.manage.php" id="form_del" name="form_del" method="post">
	<input type="hidden" name="action" id="action" value="del_class" />
<table border="0" cellpadding="0" cellspacing="0" class="from_table2_one">
	  <thead>
	  <tr class="area_ajax_list_title">
	    <th width="50" class="pd-left" align="left">
	      <tpl> $langSysNSel </tpl>
	      </th>
	    <th width="565" align="left">
	      <tpl> $langSysNName </tpl>
	      </th>
	    <th width="70" align="left">
	      <tpl> $langSysNManage </tpl>
	      </th>
	  </tr>
	  </thead>
	  <tpl> if $class_array[0].news_c_id neq '' </tpl>
		  <tpl> section name=i loop=$class_array </tpl>
	 <tr>
	   <td  width="50" class="pd-left" align="left"><input name="news_c_id[]" type="checkbox" value="<tpl> $class_array[i].news_c_id </tpl>"/></td>
	   <td width="565" align="left"><tpl> $class_array[i].news_c_name </tpl></td>
		 <td width="70" align="left" ><a href="javascript:;" onclick="hideMessage();ajax_modi('<tpl> $class_array[i].news_c_id </tpl>');" title=" <tpl> $langSysNEdit </tpl>" class="edit_a_pic">
		  </a>	   </td>
	</tr>
		  <tpl> /section </tpl>

		  <tpl> else  </tpl>
		  <tr>
			<td colspan="6"><tpl> $langSysCNoThing </tpl></td>
		  </tr>
		<tpl> /if </tpl>
  </table>
   <tpl> if $class_array[0].news_c_id neq '' </tpl>
  <div class="table-5-bottom">
 <div style="float:left; padding-left:20px">
				<span class="btn_left">
				<input name="selectall" type="button" id="selectall" class="btn_submit" value="<tpl> $langSysNSelAll </tpl>" /></span>
				
				<span class="btn_left">
				<input name="negative" type="button" id="negative" class="btn_submit" value="<tpl> $langSysNSelNegative </tpl>" />
				</span>
					<span class="btn_left">
				<input type="button" id="delbutton" class="btn_submit" name="delbutton" value="<tpl> $langSysNDel </tpl>" />
				</span>
		  </div>
				<div style="float:right; padding-right:20px">
				<tpl> $page_list </tpl>		
				</div>
			</div>
			<tpl> /if </tpl>
	</form>
<div id="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> $langSysNConfirmationDel </tpl></b> <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>
<script>
$(document).ready(function() {
	$('#negative').click(
		function(){
			$('#form_del input[@type=checkbox]').each(function(){
				$(this).attr('checked',!$(this).attr('checked'))
			})
		}
		);
	$('#selectall').click(
		function(){
			$('#form_del input[@type=checkbox]').each(function(){
				$(this).attr('checked',true)
			})
		}
	);
	//删除操作
	var options_del = {
		beforeSubmit:  function(){showLoading(showText);},
		success:       function(msg){
						hideLoading();
						if(msg.type == '1'){
							showMessage(msg.message,msg.type);
							ShowDiv = "result_content";
							getPageContent("news.manage.php?action=ajax_class_list<tpl>if $class_array|@count neq 1</tpl>&curpage=<tpl>$curpage</tpl><tpl>/if</tpl>");
						}else if(msg.type == '2'){
							message = "<tpl> $langSysNMoveClassRemark </tpl><a href='javascript:;' onclick='hideMessage();ShowDiv=\"result_content\";getPageContent(\"news.manage.php?action=del_class_move_news&id_line="+msg.message+"\");'style='color:#FF0000'>这里</a>  <tpl> $langSysNMoveClassRemarkTwo </tpl>";
							showMessage(message,0);
						}
					},
		type:      'post',
		dataType:  'json'
	};
	var question = $('#question')[0];
	$("#delbutton").click(function(){
		$.blockUI(question, { width: '275px' });
	});
	
	$('#yes').click(function() {
			$.unblockUI();
			$('#form_del').ajaxSubmit(options_del);	
			return false;
		});
	$('#no').click($.unblockUI);
});	

//编辑
function ajax_modi(id){
	//载入页面
	ShowDiv = "result_content";
	getPageContent("news.manage.php?action=modi_class&id="+id+"&curpage=<tpl>$curpage</tpl>");
}
</script>