钱惠东 1 hete
szülő
commit
b829cd794a

+ 2 - 2
RuoYi-Vue-fast-master/src/main/java/com/ruoyi/project/business/domain/vo/board/AgentProjectStatisticsVo.java

@@ -58,10 +58,10 @@ public class AgentProjectStatisticsVo {
     private String sumProjectPrice;
     /** 成单率 */
     @Excel(name = "成单率%")
-    private Integer completionRate;
+    private BigDecimal completionRate;
     /** 丢单率 */
     @Excel(name = "丢单率%")
-    private Integer lostOrderRate;
+    private BigDecimal lostOrderRate;
 
     /** 年份 */
     private String yearParam;

+ 3 - 3
RuoYi-Vue-fast-master/src/main/resources/mybatis/business/TcProjectMapper.xml

@@ -1071,8 +1071,8 @@
                count(t.project_id) as sumProjectQty,
                sum(t.deviceTotal) as sumProjectEquipmentQty,
                FORMAT(sum(t.priceTotal),2) AS sumProjectPrice,
-               (count(t.progress = '100%' or null) / count(t.project_id) * 100) as completionRate,
-               (count(t.progress like '0% ' or null) / count(t.project_id) * 100) as lostOrderRate
+               ROUND(count(t.progress = '100%' or null) / count(t.project_id) * 100, 2) as completionRate,
+               ROUND(count(t.progress like '0% ' or null) / count(t.project_id) * 100, 2) as lostOrderRate
         from (
             select p.*,
                    ta.account_name    as account_name,
@@ -1181,7 +1181,7 @@
                                 on permission.premession_char = p.permission_char
             <where>
                 DATE_FORMAT(p.create_time, '%Y') = #{yearParam}
-                and p.del_flag = '0'
+                and p.del_flag = '0' and p.status = '03'
                 <if test="accountName != null  and accountName != ''">and ta.account_name like concat('%',#{accountName},'%') escape '/'</if>
                 <if test="areaId != null and areaId.size() > 0">
                     and p.area_id in