Browse Source

统计修改

v4
zouyx 2 years ago
parent
commit
790569e762
  1. 2
      lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/complaintStatic/complaintB.html
  2. 91
      lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/registration/registration.html
  3. 12
      lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/ComplaintStaticController.java
  4. 18
      lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/service/impl/StatisticalPaneServiceImpl.java
  5. 1
      lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/ComplaintStatisticsMapper.xml

2
lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/complaintStatic/complaintB.html

@ -3,7 +3,7 @@
<head>
<meta charset="UTF-8">
<li id="complaintB" th:fragment="complaintB">
<p th:text="|${year}年:|"></p>
<p><span th:text="|${year}年:|"></span></p>
<p><label th:text="投诉数量"></label><b th:text="${Number3}"></b></p>
<p></i><label th:text="占比总计"></label><b th:text="${dou}"></b></p>
</li>

91
lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/registration/registration.html

@ -148,9 +148,14 @@
</div>
</div>
</form>
<div class="col-sm-12 select-table table-bordered">
<div class="col-sm-12 select-table table-bordered">
<div id="detail" class="detail-list">
<span id="closeButton" class="detail-close" onclick="closeC()">×</span>
<table id="bootstrap-table2"></table>
</div>
<table id="bootstrap-table"></table>
</div>
</div>
<div id="one-tab2" class="tab-content">
<form id="formId2">
@ -219,7 +224,9 @@
var detailFlag = [[${@permission.hasPermi('code:registration:datail')}]];
var checkCategory=[[${@dict.getType('check_category')}]];
var reson=[[${@dict.getType('no-scan-reason')}]];
var caseType=[];
var prefix = ctx + "code/registration";
var prefixC= ctx+"code/complaintStatic";
var quarterBoolean=/*[[${quarterBoolean}]]*/{};
var monthBoolean=/*[[${monthBoolean}]]*/{};
var unite=/*[[${unite}]]*/{};
@ -250,6 +257,17 @@
echarts2();
echarts3();
echarts4();
$('#detail').hide();
$.ajax({
url:"/system/dict/data"+'/queryDict',
type:'GET',
data:{
dictType:"caseType",
},
success: function (response) {
caseType.push(response);
}
})
};
$(function() {
var options = {
@ -353,7 +371,8 @@
if(value == 0){
return "<span>否</span>";
}else{
return "<span>是</span>";
/*return "<span>是</span>";*/
return '<span style="cursor: pointer;color: blue;" ONCLICK="selectC(\'' + row.id + '\')">'+'是'+'</span>';
}
}
},
@ -558,7 +577,57 @@
}
})
}
$(function() {
var options2 = {
modalName: "执法记录统计",
showHeader: true,
showFooter: true,
showColumns: false,
showRefresh: false,
showToggle: false,
pagination: true,
pageSize: 10,
pageList: [10, 25, 50],
//quarterBoolean:quarterBoolean,
columns: [
{
field: 'complaintDepartment',
title: '被投诉对象'
},
{
field: 'enterpriseName',
title: '企业名称'
},
{
field: 'complaintType',
title: '投诉类型',
formatter:function (value,row,index) {
debugger
for(i=0;i<caseType[0].data.length;i++){
debugger
if(caseType[0].data[i].dictValue==value){
debugger
return caseType[0].data[i].dictLabel;
}
}
}
},
{
field: 'problemDescription',
title: '问题描述'
},
{
field: 'linkman',
title: '联系人'
},
{
field: 'linkman_tel',
title: '联系电话'
}
],
}
$("#bootstrap-table2").bootstrapTable(options2);
})
function search2(){
echarts1();
}
@ -765,6 +834,22 @@
return"第四季度";
}
}
function selectC(rid) {
$.ajax({
url:prefixC+'/complaintByRid',
type:'GET',
data:{
rid:rid,
},
success: function (response) {
$('#detail').show();
$('#bootstrap-table2').bootstrapTable('load', response);
}
})
}
function closeC(){
$('#detail').hide();
}
</script>
</body>
</html>

12
lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/ComplaintStaticController.java

@ -65,8 +65,7 @@ public class ComplaintStaticController extends BaseController {
@RequiresPermissions("code:complaintStatic:list")
@GetMapping("/searchType1")
public String searchType1(SearchType searchType,Model model){
LocalDate localDate=LocalDate.now();
model.addAttribute("year",localDate.getYear());
model.addAttribute("year",searchType.getYear());
ComplaintStatistics complaintStatistics=dateMake(searchType);
if(searchType.getCType()!=null&&!"".equals(searchType.getCType())) {
complaintStatistics.setComplaintType(Integer.parseInt(searchType.getCType()));
@ -201,6 +200,15 @@ public class ComplaintStaticController extends BaseController {
}
return complaintStatistics;
}
@GetMapping("/complaintByRid")
@ResponseBody
public TableDataInfo complaintByRid(String rid){
startPage();
ComplaintStatistics complaintStatistics=new ComplaintStatistics();
complaintStatistics.setRid(rid);
List<ComplaintStatistics> list=complaintStatisticsService.selectComplaintStatisticsList(complaintStatistics);
return getDataTable(list);
}
public List<Integer> yearMake(){
int current=LocalDate.now().getYear();
List<Integer> yearList=new ArrayList<>();

18
lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/service/impl/StatisticalPaneServiceImpl.java

@ -137,8 +137,13 @@ public class StatisticalPaneServiceImpl implements StatisticalPaneService {
List<EnforcementRegistration> qxNow = enforcementRegistrationService.selectEnforcementRegistrationList1(enforcementRegistrationNow);
List<EnforcementRegistration> qxLast = enforcementRegistrationService.selectEnforcementRegistrationList1(enforcementRegistrationLast);
p3.setName("本单位检查数量");
p3.setTotal(qxNow.size());
p3.setHuan(qxNow.size()-qxLast.size());
if(deptId==null){
p3.setTotal(0);
p3.setHuan(0);
}else {
p3.setTotal(qxNow.size());
p3.setHuan(qxNow.size() - qxLast.size());
}
StatisticsIndicatorPart p=new StatisticsIndicatorPart();
List<StatisticsIndicatorPart> statisticsIndicatorPartList=new ArrayList<>();
p.setName("执法检查");
@ -182,8 +187,13 @@ public class StatisticalPaneServiceImpl implements StatisticalPaneService {
List<LawEnforcementWarningList> qxNow=iLawEnforcementWarningListService.selectLawEnforcementWarningListList2(warningStatisticsNow);
List<LawEnforcementWarningList> qxLast=iLawEnforcementWarningListService.selectLawEnforcementWarningListList2(warningStatisticsLast);
p3.setName("本单位发布预警数量");
p3.setTotal(qxNow.size());
p3.setHuan(qxNow.size()-qxLast.size());
if(deptId==null){
p3.setTotal(0);
p3.setHuan(0);
}else {
p3.setTotal(qxNow.size());
p3.setHuan(qxNow.size() - qxLast.size());
}
StatisticsIndicatorPart p=new StatisticsIndicatorPart();
List<StatisticsIndicatorPart> statisticsIndicatorPartList=new ArrayList<>();
p.setName("执法预警");

1
lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/ComplaintStatisticsMapper.xml

@ -34,6 +34,7 @@
#{complaintDepartmentIdList}
</foreach>
</if>
<if test="rid != null and rid != ''">and rid=#{rid}</if>
<if test="complaintType != null and complaintType != ''">and complaint_type=#{complaintType}</if>
<if test="beginTime != null and beginTime != ''"><!-- 开始时间检索 -->
and DATE_FORMAT(complaint_time,'%Y-%m-%d') &gt;= STR_TO_DATE(#{beginTime},'%Y-%m-%d')

Loading…
Cancel
Save