<?php 
include_once(''.P.'/public/header.html');
?>

<script type="text/javascript" src="res/bootstrapplugin/jquery-bootstable.js"></script>
<script type="text/javascript" src="res/menu/jquery-rockmenu.js"></script>
<link rel="stylesheet" type="text/css" href="res/menu/jquery-rockmenu.css">


<script>

function initbody(){
	
	table = $('#viewshow').bootstable({
		url:'index.php?m=wenti&a=data',method:'get',fanye:true,
		celleditor:true,tablename:'2',cellurl:'index.php?m=agent&a=savecell',
		columns:[{
			text:'标题',dataIndex:'title',editor:true,align:'left'
		},{
			text:'关键词',dataIndex:'targ',editor:true
		},{
			text:'内容',dataIndex:'content',editor:true,type:'textarea',align:'left'
		},{
			text:'颜色',dataIndex:'color',editor:true
		},{
			text:'排序号',dataIndex:'sort',editor:true,sortable:true,type:'number'
		},{
			text:'类型',dataIndex:'type',sortable:true,renderer:function(v){
				if(v=='0')v='常用地址';
				if(v=='1')v='关键词';
				if(v=='2')v='快捷回复';
				return v;
			}
		},{
			text:'状态',dataIndex:'status',sortable:true,type:'checkbox',editor:true
		},{
			text:'对应应用',dataIndex:'agentid',sortable:true
		},{
			text:'ID',dataIndex:'id'
		},{
			text:'',dataIndex:'opts',renderer:function(s,d){
				return '<a class="zhu" href="?m=wenti&a=form&id='+d.id+'">编辑</a>&nbsp;<a class="zhu" href="javascript:;" onclick="deleterecord('+d.id+',2,false)">删</a>';
			}
		}]
		
		
	});
}
</script>
</head>

<body style="background:#f1f1f1">

<?php 
include_once(''.P.'/public/top.html');
?>

<div align="center">

<div style="width:<?=$maxwidth?>;margin:20px 0px" align="left">
	<div style="color:#cccccc">
		<a href="?m=index" class="zhu">平台首页</a> &gt;
		<a href="" class="zhu">常见问题</a>
	</div>
	<div style="background-color:white;margin:20px 0px;border:1px #eeeeee solid;min-height:500px;border-radius:5px">
		<div style="padding:10px">
			<div style="padding:5px 0px"><a class="webbtn" style="border-radius:5px" href="?m=wenti&a=form&id=0">新增</a></div>
			<div class="blank10"></div>
			<div id="viewshow"></div>
			<div class="blank10"></div>
			<div style="color:gray">常用地址：用于咨询页面右边显示快捷链接，关键词：咨询用户右边快捷回复，快捷回复：客服人员快捷回复了。</div>
		</div>
	</div>
</div>



<?php 
include_once(''.P.'/public/footer.html');
?>
</div>

</body>
</html>