{include file="$admin_template_path/html/header.html"}
</head>
<body>
{include file="$admin_template_path/html/pagetops.html"}
{if $errorMessage}
<div id="errormsg">
<div class="msg">
  <div class="closebtn"><i data-icon="" class="icon-close"></i></div>
  {$errorMessage}
</div>
</div>
{literal}
<script type="text/javascript">
seajs.use(["modules/pageui/msg"], function(msg){
    msg.msginit("#errormsg");
});
</script>
{/literal}
{/if}

<div class="pagebg">
	<div class="mcontent pagemain clr">
	    {include file="$admin_template_path/html/leftmenu.html"}
	    <div class="pagemainconent headtools{if $paging !=""} paging{/if}">

		<div class="headtool b-b clr">
			<div class="toolbtns clr">
				<button class="btns btntheme btnsize" onclick="window.location='?m={$smarty.get.m}&c=addservice';" type="button"><i class="fa fa-plus"></i> {$lang.add_new}</button>
			</div>
			<div class="toolsearch clr rf">
				<form class="sort-control" method="post" action="?m={$smarty.get.m}&c={$smarty.get.c}">
					<button type="submit" class="btntheme btnsize rf">搜索</button>
					<input class="ipttheme rf" type="text" id="q" name="q" placeholder="开始搜索...">
				</form>
			</div>
		</div>
		{if $paging !=""}
		<div class="page-controls">
			{$paging}
		</div>
		{/if}
		<div class="rightdetail_admin">
			{if is_array($data)}
			<div class="general_table_border">
				<table class="general_table" cellspacing="0" cellpadding="0" border="0">
					<thead>
						<tr>
							<th><a href="">客服ID</a></th>
							<th><a href="">客服姓名</a></th>
							<th><a href="">客服邮箱</a></th>
							<th><a href="">备注</a></th>
							<th><a href="">用户列表</a></th>
							<th><a href="">客服状态</a></th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>
						{foreach from=$data item=i}
						<tr>
							<td>{$i.id}</td>
							<td>{$i.user_name}</td>
							<td>{$i.email}</td>
							<td>{$i.info}</td>
							<td><a href="?m={$smarty.get.m}&c=servicelist&id={$i.id}">查看用户列表</a></td>
							<td>{if $i.status=='true'}<img src="{$template_data}admin/images/icons/24x24/accept.png" alt="" class="middle" />
								{else}<img src="{$template_data}admin/images/icons/24x24/delete.png" alt="" class="middle" />
								{/if}
							</td>
							<td><a href="?m={$smarty.get.m}&c=editservice&id={$i.id}" title="编辑"><i class="fa fa-edit text-success m-r-xs"></i>编辑</a></td>
						</tr>
						{/foreach}
					</tbody>
				</table>
			</div>
			{else}
				暂无记录
			{/if}
		</div>
		
		</div>
	</div>
</div>
</body>
</html>