diff --git a/src/main/java/com/cm/bigdata/controller/apis/partyscore/PartyScoreController.java b/src/main/java/com/cm/bigdata/controller/apis/partyscore/PartyScoreController.java index dd05372..4bd617d 100644 --- a/src/main/java/com/cm/bigdata/controller/apis/partyscore/PartyScoreController.java +++ b/src/main/java/com/cm/bigdata/controller/apis/partyscore/PartyScoreController.java @@ -326,14 +326,14 @@ public class PartyScoreController extends AbstractController { if(resultScore > scoreProperties.getMeetingGrossscore()) { resultScore = scoreProperties.getMeetingGrossscore(); } - partyMeetingScoreDTO.setScore(resultScore); + partyMeetingScoreDTO.setScore(Double.valueOf(String.format("%.2f", resultScore))); }else { partyMeetingScoreDTO.setQuarter("全年"); double resultScore = trueCount / baseCount * scoreProperties.getMeetingGrossscore(); if(resultScore > scoreProperties.getMeetingGrossscore()) { resultScore = scoreProperties.getMeetingGrossscore(); } - partyMeetingScoreDTO.setScore(resultScore); + partyMeetingScoreDTO.setScore(Double.valueOf(String.format("%.2f", resultScore))); } } } diff --git a/src/main/java/com/cm/bigdata/pojo/dtos/configforscore/ConfigForScoreDTO.java b/src/main/java/com/cm/bigdata/pojo/dtos/configforscore/ConfigForScoreDTO.java index 979d8da..f2d0f66 100644 --- a/src/main/java/com/cm/bigdata/pojo/dtos/configforscore/ConfigForScoreDTO.java +++ b/src/main/java/com/cm/bigdata/pojo/dtos/configforscore/ConfigForScoreDTO.java @@ -26,6 +26,8 @@ public class ConfigForScoreDTO { private String unit; @ApiModelProperty(name = "type", value = "配置类型") private String type; + @ApiModelProperty(name = "typeName", value = "配置类型名称") + private String typeName; public String getConfigForScoreId() { return configForScoreId == null ? "" : configForScoreId.trim(); @@ -74,4 +76,12 @@ public class ConfigForScoreDTO { public void setType(String type) { this.type = type; } + + public String getTypeName() { + return typeName == null ? "" : typeName; + } + + public void setTypeName(String typeName) { + this.typeName = typeName; + } } diff --git a/src/main/java/com/cm/bigdata/pojo/vos/configforscore/ConfigForScoreVO.java b/src/main/java/com/cm/bigdata/pojo/vos/configforscore/ConfigForScoreVO.java index df162a7..3fc8bbd 100644 --- a/src/main/java/com/cm/bigdata/pojo/vos/configforscore/ConfigForScoreVO.java +++ b/src/main/java/com/cm/bigdata/pojo/vos/configforscore/ConfigForScoreVO.java @@ -25,8 +25,10 @@ public class ConfigForScoreVO { private String areaName; @ApiModelProperty(name = "unit", value = "单位") private String unit; - @ApiModelProperty(name = "type", value = "配置类型") + @ApiModelProperty(name = "type", value = "配置类型ID") private String type; + @ApiModelProperty(name = "typeName", value = "配置类型名称") + private String typeName; public String getCount() { return count == null ? "" : count.trim(); @@ -67,4 +69,12 @@ public class ConfigForScoreVO { public void setType(String type) { this.type = type; } + + public String getTypeName() { + return typeName == null ? "" : typeName; + } + + public void setTypeName(String typeName) { + this.typeName = typeName; + } } diff --git a/src/main/java/com/cm/bigdata/service/configforscore/impl/ConfigForScoreServiceImpl.java b/src/main/java/com/cm/bigdata/service/configforscore/impl/ConfigForScoreServiceImpl.java index 01e5871..00087fa 100644 --- a/src/main/java/com/cm/bigdata/service/configforscore/impl/ConfigForScoreServiceImpl.java +++ b/src/main/java/com/cm/bigdata/service/configforscore/impl/ConfigForScoreServiceImpl.java @@ -81,7 +81,7 @@ public class ConfigForScoreServiceImpl extends AbstractService implements IConfi Integer count = countNumberConfigForScore(params); if(!count.equals(0)) { if(StringUtils.isEmpty(params.get("area"))) { - throw new SearchException(params.get("type") + "数据已存在,请进行修改"); + throw new SearchException(params.get("typeName") + "数据已存在,请进行修改"); }else { throw new SearchException(params.get("areaName") + "数据已存在,请进行修改"); } diff --git a/src/main/resources/mybatis/mapper/configforscore/configforscore-mapper.xml b/src/main/resources/mybatis/mapper/configforscore/configforscore-mapper.xml index 133fce8..98b5320 100644 --- a/src/main/resources/mybatis/mapper/configforscore/configforscore-mapper.xml +++ b/src/main/resources/mybatis/mapper/configforscore/configforscore-mapper.xml @@ -9,6 +9,7 @@ + @@ -20,6 +21,7 @@ area_name, unit, type, + type_name, creator, gmt_create, modifier, @@ -32,6 +34,7 @@ #{areaName}, #{unit}, #{type}, + #{typeName}, #{creator}, #{gmtCreate}, #{modifier}, @@ -85,6 +88,9 @@ type = #{type}, + + + type_name = #{typeName}, modifier = #{modifier}, gmt_modified = #{gmtModified} @@ -100,6 +106,7 @@ t1.area_name, t1.unit, t1.type, + t1.type_name, t1.config_for_score_id FROM gen_config_for_score t1 @@ -127,6 +134,7 @@ t1.area_name, t1.unit, t1.type, + t1.type_name, t1.config_for_score_id FROM gen_config_for_score t1 diff --git a/src/main/resources/static/route/areascoreaddminus/list-areascoreaddminus.html b/src/main/resources/static/route/areascoreaddminus/list-areascoreaddminus.html index f5efc7b..94e77fd 100644 --- a/src/main/resources/static/route/areascoreaddminus/list-areascoreaddminus.html +++ b/src/main/resources/static/route/areascoreaddminus/list-areascoreaddminus.html @@ -77,7 +77,6 @@ height: $win.height() - 90, limit: 20, limits: [20, 40, 60, 80, 100, 200], - toolbar: '#headerToolBar', request: { pageName: 'page', limitName: 'rows' diff --git a/src/main/resources/static/route/bossscore/list-bossscore.html b/src/main/resources/static/route/bossscore/list-bossscore.html index ce81c62..7b29d77 100644 --- a/src/main/resources/static/route/bossscore/list-bossscore.html +++ b/src/main/resources/static/route/bossscore/list-bossscore.html @@ -18,17 +18,12 @@
-
- -
- -
+
+
-
- -
+
+
@@ -72,25 +67,21 @@ } var month = date.getMonth() + 1; if(month >= 1 && month <=3) { - $("#quarter").append(""); $("#quarter").append(""); form.render(); } if(month >= 4 && month <=6) { - $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); form.render(); } if(month >= 7 && month <=9) { - $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); form.render(); } if(month >= 10 && month <=12) { - $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); @@ -156,7 +147,7 @@ return '-'; } } - rowData = rowData.toFixed(2); + rowData = Math.floor(rowData * 100) / 100 return rowData; } }, @@ -200,6 +191,7 @@ laydate.render({ elem: '#year' ,type: 'year' + ,value:new Date() ,done:function(value,date){ quarterFun(value); } diff --git a/src/main/resources/static/route/casesupervise/list-casesupervise.html b/src/main/resources/static/route/casesupervise/list-casesupervise.html index 30cec9f..8da4140 100644 --- a/src/main/resources/static/route/casesupervise/list-casesupervise.html +++ b/src/main/resources/static/route/casesupervise/list-casesupervise.html @@ -17,17 +17,12 @@
-
- -
- -
+
+
-
- -
+
+
@@ -71,25 +66,21 @@ } var month = date.getMonth() + 1; if(month >= 1 && month <=3) { - $("#quarter").append(""); $("#quarter").append(""); form.render(); } if(month >= 4 && month <=6) { - $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); form.render(); } if(month >= 7 && month <=9) { - $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); form.render(); } if(month >= 10 && month <=12) { - $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); $("#quarter").append(""); @@ -110,7 +101,6 @@ height: $win.height() - 90, limit: 20, limits: [20, 40, 60, 80, 100, 200], - toolbar: '#headerToolBar', request: { pageName: 'page', limitName: 'rows' @@ -120,6 +110,7 @@ {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, {field: 'areaName', width: 150, title: '街镇村', align:'center', templet: function(row) { + console.log(row) var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; @@ -172,6 +163,16 @@ return rowData; } }, + {field: 'score', width: 150, title: '总得分', align:'center', + templet: function(row) { + var rowData = row[this.field]; + if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + return '0'; + } + rowData = Math.floor(rowData * 100) / 100 + return rowData; + } + }, {field: 'year', width: 150, title: '督察年', align:'center', templet: function(row) { var rowData = row[this.field]; @@ -190,7 +191,7 @@ return rowData; } }, - {field: 'superviseTime', width: 150, title: '督察时间', align:'center', + {field: 'superviseTime', width: 180, title: '督察时间', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -233,6 +234,7 @@ laydate.render({ elem: '#year' ,type: 'year' + ,value:new Date() ,done:function(value,date){ quarterFun(value); } diff --git a/src/main/resources/static/route/configforscore/list-configforscore.html b/src/main/resources/static/route/configforscore/list-configforscore.html index 11b1f96..996cac4 100644 --- a/src/main/resources/static/route/configforscore/list-configforscore.html +++ b/src/main/resources/static/route/configforscore/list-configforscore.html @@ -85,7 +85,7 @@ cols: [[ {type:'checkbox', fixed: 'left'}, {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'count', width: 150, title: '数量', align:'center', + {field: 'typeName', width: 150, title: '类型', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -103,6 +103,15 @@ return rowData; } }, + {field: 'count', width: 150, title: '数量', align:'center', + templet: function(row) { + var rowData = row[this.field]; + if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + return '-'; + } + return rowData; + } + }, {field: 'unit', width: 150, title: '单位', align:'center', templet: function(row) { var rowData = row[this.field]; diff --git a/src/main/resources/static/route/configforscore/save-configforscore.html b/src/main/resources/static/route/configforscore/save-configforscore.html index e0b6475..80196f5 100644 --- a/src/main/resources/static/route/configforscore/save-configforscore.html +++ b/src/main/resources/static/route/configforscore/save-configforscore.html @@ -39,7 +39,7 @@
-
+