@ -350,7 +350,8 @@
changeArea(datas[0].deptId, datas[0].deptName,'1')
changeArea(datas[0].deptId, datas[0].deptName,'1')
}
}
for(var i=0; i< datas.length ; i + + ) {
for(var i=0; i< datas.length ; i + + ) {
html += '< dd class = "check_label" onclick = "changeArea(\''+datas[i].deptId+'\',\''+datas[i].deptName+'\',\'1\')" > '+datas[i].deptName+'< i class = "fa fa-angle-right" > < / i > < / dd > '
html += '< dd class = "check_label" dpId = "'+datas[i].deptId+'" dpName = "'+datas[i].deptName+'" ' +
'onclick="changeArea(\''+datas[i].deptId+'\',\''+datas[i].deptName+'\',\'1\')">'+datas[i].deptName+'< i class = "fa fa-angle-right" > < / i > < / dd > '
}
}
$("#depts").html(html);
$("#depts").html(html);
@ -449,13 +450,32 @@
queryStreetAndDistrict(id,name);
queryStreetAndDistrict(id,name);
}
}
if (type === "2"){
if (type === "2"){
//gouxuan
var checkFlag = 1;
//勾选
var streetChildren = $('#streetDetail').children();
var districtChildren = $('#districtDetail').children();
//bgouxuan
// 遍历子元素
districtChildren.each(function() {
if (this.className === "selitem selected active") {
checkFlag = 0;
}
});
streetChildren.each(function() {
if (this.className === "selitem selected active") {
checkFlag = 0;
}
});
//如果checkFlag=0代表刚刚是取消勾选操作
if (checkFlag ===0) {
var deptChildren = $('#depts').children();
deptChildren.each(function() {
if (this.className === "check_label selchk selnext") {
deptId = this.getAttribute('dpId');
deptName = this.getAttribute('dpName');
$("#dept_flag").html(deptName+"< a > < / a > ")
}
});
}
}
}
sixIndicators(deptId, deptName,beginTime,endTime)
sixIndicators(deptId, deptName,beginTime,endTime)
sixIndicators_area(deptId, deptName,beginTime,endTime);
sixIndicators_area(deptId, deptName,beginTime,endTime);
@ -465,9 +485,8 @@
reg_order(deptId,beginTime,endTime);
reg_order(deptId,beginTime,endTime);
complaint_order(deptId,beginTime,endTime);
complaint_order(deptId,beginTime,endTime);
bureau_order(deptId,beginTime,endTime);
bureau_order(deptId,beginTime,endTime);
if (null == name) name = "全区< a > < / a > "
if (null == deptName) deptName = "全区< a > < / a > "
$("#dept_flag").html(name+"< a > < / a > ")
$("#dept_flag").html(deptName+"< a > < / a > ")
console.log()
}
}
function searchDate(time1, time2) {
function searchDate(time1, time2) {
@ -481,8 +500,8 @@
reg_order(deptId,beginTime,endTime);
reg_order(deptId,beginTime,endTime);
complaint_order(deptId,beginTime,endTime);
complaint_order(deptId,beginTime,endTime);
bureau_order(deptId,beginTime,endTime);
bureau_order(deptId,beginTime,endTime);
if (null == name) n ame = "全区< a > < / a > "
if (null == deptName) deptN ame = "全区< a > < / a > "
$("#dept_flag").html(n ame+"< a > < / a > ")
$("#dept_flag").html(deptN ame+"< a > < / a > ")
}
}
function sixIndicators(deptId, area,beginTime,endTime) {
function sixIndicators(deptId, area,beginTime,endTime) {