<!doctype html>
|
<html>
|
<head>
|
[#include "/business/wechat/include/title.html" /]
|
[#include "/business/wechat/include/wheader.html" /]
|
</head>
|
|
<body>
|
<header class="kltit"><a href="javascript:history.go(-1);"><span></span></a>配置</header>
|
<nav class="kltwo clearfix">
|
<div class="kltwowrap2">
|
<a href="#" hidefocus="true" class="active">配置分类</a>
|
<a href="#" hidefocus="true">配置列表 </a>
|
<a href="#" hidefocus="true">统计分析</a>
|
</div>
|
</nav>
|
<div class="swiper-container" id="swiper-pages">
|
<div [#if RequestParameters.t?? && RequestParameters.t==1]class="swiper-wrapper swiper-wrapper_another"[#else]class="swiper-wrapper"[/#if]>
|
<div class="swiper-slide kltypebg">
|
<section>
|
[#if cateList?? && cateList?size>0]
|
[#list cateList as lv1]
|
<section class="tasktype">
|
<a class="firstCate"><p>
|
<label>${lv1.num}个</label><span class="tpye1"></span>${lv1.name}
|
</p></a>
|
<div class="secondCate">
|
[#if lv1.children?? && lv1.children?size>0]
|
[#list lv1.children as lv2]
|
<a href="${base}/ewyw/ewconfig/econfigThirdCate.html?lv2_id=${lv2.id}"><p class="tasksubtype"><em></em><label>${lv2.num}个</label>${lv2.name}</p></a>
|
[/#list]
|
[/#if]
|
</div>
|
</section>
|
[/#list]
|
[/#if]
|
</section>
|
</div>
|
<div class="swiper-slide">
|
<div id="main"></div>
|
<div id="pagination" class="loadmore"></div>
|
</div>
|
<div class="swiper-slide">
|
<section class="taskstatiimgwrap">
|
<div id="pie"></div>
|
</section>
|
</div>
|
</div>
|
</div>
|
|
|
<script type="text/javascript">
|
function query(index) {
|
if(index==1) {
|
if($.util.isEmpty($("#main").html())) {
|
queryDevice();
|
}
|
} else if(index==2) {
|
if($.util.isEmpty($("#pie").html())) {
|
queryPie();
|
}
|
}
|
}
|
|
function loadPie(data) {
|
$('#pie').highcharts({
|
title: {
|
text: '配置一级分类占比'
|
},
|
tooltip: {
|
pointFormat: '<b>{point.y}个</b>'
|
},
|
plotOptions: {
|
pie: {
|
allowPointSelect: true,
|
cursor: 'pointer',
|
dataLabels: {
|
enabled: true,
|
color: '#000000',
|
connectorColor: '#000000',
|
format: '<b>{point.name}</b>: {point.percentage:.1f} %'
|
}
|
}
|
},
|
series: [{
|
type: 'pie',
|
data: data
|
}]
|
});
|
}
|
|
function queryPie() {
|
loading($("#pie"));
|
$.post("${base}/ewyw/ewconfig/catePie.html",{},function(data,textStatus) {
|
loadPie(data);
|
},"json");
|
|
}
|
|
function queryDevice() {
|
var param = {};
|
$("#pagination").pagination({
|
durl:"${base}/ewyw/ewconfig/econfigData.html",
|
curl:"${base}/ewyw/ewconfig/econfigCount.html",
|
pdiv:"pagination",
|
mdiv:"main",
|
perPage : 5,
|
param:param
|
});
|
}
|
|
$(function() {
|
n=$('.kltwowrap2 a').size();
|
var wh=100*n+"%";
|
$('.kltwowrap2').width(wh);
|
var lt=(100/n/3);
|
var lt_li=lt+"%";
|
$('.kltwowrap2 a').width(lt_li);
|
$(".kltwowrap2 a").on('touchstart mousedown',function(e){
|
e.preventDefault()
|
$(".kltwowrap2 .active").removeClass('active');
|
$(this).addClass('active');
|
tabsSwiper.slideTo($(this).index());
|
});
|
|
$(".kltwowrap2 a").click(function(e){
|
e.preventDefault();
|
});
|
|
window.onload=function(){
|
var pages = document.getElementById("swiper-pages");
|
var scale = window.screen.height / window.screen.width;
|
pages.style.height = document.body.clientWidth * scale -$('.kltit').height()-$('.kltwo').height() - 20 + "px";
|
}
|
|
var tabsSwiper = new Swiper(".swiper-container",{
|
setWrapperSize :true,
|
onSlideChangeStart: function(sw){
|
$(".kltwowrap2 .active").removeClass('active');
|
var panelIndex = tabsSwiper.activeIndex;
|
var $kltwowrapA = $(".kltwowrap2 a").eq(panelIndex);
|
$kltwowrapA.addClass('active');
|
$kltwowrapA.parent().css("left",-parseInt(sw.activeIndex/4)*sw.width);
|
query(panelIndex);
|
}
|
});
|
|
})
|
|
|
/*标签切换屏幕左右滑动导航字数过多*/
|
</script>
|
|
[#assign label="device"]
|
[#include "/business/wechat/include/wfooter.html" /]
|
</body>
|
</html>
|