From 9867f6d5c5bccfe52b878c344c536905dd6b309e Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期四, 09 六月 2022 08:48:06 +0800
Subject: [PATCH] 1. 接口文档自动输出

---
 src/main/kotlin/cn/flightfeather/supervision/common/score/item/ScoreItem_6.kt |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/main/kotlin/cn/flightfeather/supervision/common/score/item/ScoreItem_6.kt b/src/main/kotlin/cn/flightfeather/supervision/common/score/item/ScoreItem_6.kt
index 02e381c..d4557b5 100644
--- a/src/main/kotlin/cn/flightfeather/supervision/common/score/item/ScoreItem_6.kt
+++ b/src/main/kotlin/cn/flightfeather/supervision/common/score/item/ScoreItem_6.kt
@@ -6,6 +6,8 @@
 import org.springframework.beans.factory.annotation.Autowired
 import org.springframework.stereotype.Component
 import tk.mybatis.mapper.entity.Example
+import java.time.LocalDate
+import java.time.ZoneId
 import javax.annotation.PostConstruct
 
 @Component
@@ -32,6 +34,8 @@
     override var maxScore: Int = 10
 
     override fun calScore(): Pair<Int, Int> {
+        val startTime = LocalDate.of(info.year, sMonth, 1).atStartOfDay(ZoneId.systemDefault())
+        val lastTime = LocalDate.of(info.year, eMonth, 1).plusMonths(1).atStartOfDay(ZoneId.systemDefault())
         // FIXME: 2021/4/26 娑夋墽娉曟剰瑙併�佽矗浠ゆ暣鏀规垨琛屾斂澶勭綒,鎵i櫎鍏ㄩ儴鍒嗘暟
         val r5 = scoreItem5.execute(info)
         if (r5.first != 0) {
@@ -40,6 +44,8 @@
 
         val complaints = complaintMapper.selectByExample(Example(Complaint::class.java).apply {
             createCriteria().andEqualTo("cpSceneid", info.userId)
+                .andGreaterThanOrEqualTo("cpTime", startTime)
+                .andLessThan("cpTime", lastTime)
         })
         
         return if (condition1(complaints)) {

--
Gitblit v1.9.3