<?php $this->display(tpl('head',true)); ?>
	<style>
		.wap_news{
			margin-bottom: 10px;
		}
		.wap_news_list:first-child{
			margin-top: 0;
		}
		.wap_news_list_title{
			overflow: hidden;
			line-height: 45px;
			height: 45px;
		}
		.wap_news_list_title a{
			font-size: 1.2em;
			padding: 0 10px;
		}
		.wap_news_list_hack{
			height: 25px;
			font-size: 1em;
		}
		.pl10 {
			padding-left: 10px;
		}
		.wap_news_list_time div:first-child{
			padding-left: 10px;
		}
		.wap_news_list_time div:last-child{
			padding-right: 10px;
		}
		.wap_news_list_action{
			border-top: 1px solid #efefef;
			margin-top: 10px;
			text-align: center;
		}
		.wap_news_list_action .action_s{
			position: absolute;
			margin-top: -13px;
			font-size: 1.2em;
			left: 43%;
			background-color: #fff;
		}
		.action_a{
			margin-top: 15px;
			margin-bottom: 10px;
		}
	</style>
<div class="wap_news">
	<?php foreach($data AS $row){
		$row['posttime']=date('Y-m-d H:i:s',$row['posttime']);
		$state="<span class='red'>【待审】</span>";
		if($row[state]){
			$state="<span class='green'>【已审】</span>";
		}
		$is_recommend="<span class='red' style='padding-left: 5px;'>【未推】</span>";
		if($row['is_recommend']){
			$is_recommend="<span class='green' style='padding-left: 5px;'>【已推】</span>";
		}
		$row[all_title]=$row[title];
		$row[title]=Get_word_strpos($row[title],'20');
		$url=U(['aid'=>$row[aid],'cid'=>$row[cid]],M_MODULE);
		$curl=U(['cid'=>$row[cid]],M_MODULE);
	?>
		<div class="wap_news_list left w-100 bcf mt10">
			<div class="wap_news_list_title left w-100">
				<a href="<?php echo $url ?>" target="_blank"><?php echo $row[title] ?></a>
			</div>
			<div class="wap_news_list_hack left w-100">
				<div class="left pl10">
					浏览量:(<?php echo  $row[clicks]?>)
					评论:(<?php echo $row[comment_num] ?>)
				</div>
				<div class="right">状态:<?php echo $state; echo $is_recommend ?></div>
			</div>
			<div class="wap_news_list_time left w-100">
				<div>发布时间:<?php echo $row[posttime] ?></div>
			</div>
			<div class="wap_news_list_action left w-100">
				<div class="action_s">操&nbsp;&nbsp;&nbsp;&nbsp;作</div>
				<div class="action_a">
					<a class="layui-btn layui-btn-xs layui-btn-warm" href="/user/articles/edit/aid/<?php echo $row[aid] ?>">编辑</a>
					<a class="layui-btn layui-btn-xs layui-btn-danger" href="/user/articles/del/aid/<?php echo $row[aid] ?>">删除</a>
				</div>
			</div>
		</div>
	
	<?php } ?>
<?php if($Get_Page) { ?>
	<div class="w-100 left bcf mt10">
		<div class="layui-form-item mt10 center page">
			<?php echo $Get_Page ?>
		</div>
	</div>
<?php } ?>
</div>
<script>
	
	layui.use(['form','table'], function() {
		var form = layui.form;
		var table = layui.table;
		
	});
</script>

<?php $this->display(tpl('foot',true)); ?>
