<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head th:replace="admin/common/html/head :: head_Normal(~{::title},~{::link},~{::style})">

<title th:text=${title}></title>

<link rel="stylesheet" th:href="@{/static/admin/assets/js/button/ladda/ladda.min.css}">
<!-- bootstrap-table表单样式 -->
<link th:href="@{/static/admin/assets/js/bootstrap/css/bootstrap-table/bootstrap-table.min.css}" rel="stylesheet"/>

<style type="text/css">
.select-list ul li{
	list-style-type: none;
	float: left;
}

</style>

</head>

<body id="listbody">
<!-- 右边内容 -->
<div class="wrap-fluid">
    <div class="container-fluid paper-wrap bevel tlbr">
        <!-- 内容 -->

        <div th:replace="admin/common/html/title">
        </div>
        <!-- 结束标题 通用-->
        <div class="content-wrap">
            <!-- 结束内容 -->
            <div class="row">
                <div class="col-sm-12">

                    <!-- 空白页开始-->
                    <div class="nest" id="Blank_PageClose">

                        <div class="body-nest" id="Blank_Page_Content">
                            <!-- 工具条 -->
                            <!--<div class="btn-group hidden-xs" id="exampleTableEventsToolbar" role="group">
                            	<button onclick="$.operate.add()" type="button" class="btn btn-primary">
                                    <span class="entypo-plus-squared"></span>&nbsp;&nbsp;新增
                                </button>
                           </div>-->
                            <!-- 工具条 end-->
                           <table id="dataTable" class="table-striped footable-res footable metro-blue" data-page-size="6">

                           </table>
                        </div>
                    </div>
                </div>
                <!-- 空白页结束 -->
            </div>
            <!-- 结束内容 -->
        </div>
    </div>
</div>
<!-- 结束右边内容 -->

<!-- 通用js -->
<div th:include="admin/common/html/js :: onload_js">
   
</div>
<!-- bootstarp 表格 -->
<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/bootstrap-table.min.js}" type="text/javascript"></script>
<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/locale/bootstrap-table-zh-CN.min.js}" type="text/javascript"></script>
<script th:src="@{/static/admin/assets/js/bootstrap/js/base_list.js}" type="text/javascript"></script>
    <!-- 弹窗 -->
<script th:src="@{/static/admin/assets/js/layer/layer.js}" type="text/javascript"></script>
<!-- 遮罩层 -->
<script th:src="@{/static/admin/assets/js/blockUI/jquery.blockUI.js}" type="text/javascript"></script>

<script type="text/javascript">
var dataUrl="/worker/list";
var removeUrl="/worker/remove";
var createUrl="/worker/add";
var updateUrl="/worker/edit/{id}";
var options = {
		dataUrl: dataUrl,
        createUrl: createUrl,
        updateUrl: updateUrl,
        removeUrl:removeUrl,
        modalName: "节点",
        search: false,
	    dataColumns: [
			{
			    checkbox: true
			},{
			    field: 'name',
			    title: 'worker名称'
			},{
			    field: 'ip',
			    title: 'IP'
			},{
                field: 'port',
                title: 'PORT'
            },{
                field: 'cliCount',
                title: '客户端连接数'
            },{
                field: 'caffeineCount',
                title: '当前缓存key数量',
            },{
                field: 'state',
                title: '状态',
                formatter:function (val,row,index) {
                    if(val == 1){
                        return "在线";
                    }else{
                        return "下线";
                    }
                }
            }
			]
  };
$(function(){
	var oTab=$.table.oTableInit(options);
	oTab.Init();
})
</script>

</body>

</html>
