From 5a6d4547e7c39507926698a02802163553f1236d Mon Sep 17 00:00:00 2001
From: lrj <386002446@qq.com>
Date: 星期五, 25 十月 2024 11:01:02 +0800
Subject: [PATCH] bug

---
 src/test/java/org/example/test.groovy |   22 +++++++++++-----------
 1 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/src/test/java/org/example/test.groovy b/src/test/java/org/example/test.groovy
index 9c3e396..73c0819 100644
--- a/src/test/java/org/example/test.groovy
+++ b/src/test/java/org/example/test.groovy
@@ -13,18 +13,18 @@
     void run(Map<String,Parameter> pars,SchemeService service){
         super.parameters.putAll(pars);
         this.service = service;
-        if(func_0() && func_1() ){
+        if(func_0() &&func_1() ){
             service.doAction(1)
         }
     }
 
     def func_0(){
-        Map<String,Object> pars = new HashMap<>();
+        Map<String,Object> pars = super.getSqlParameters();
         def sql= "select count(*) from t_info where create_time between :beginTime and :endTime  and  content like '%鎶㈠ず%'  and address like '%閲戠墰澶ч亾%' ";
-        def p_beginTime = LocalDateTime.now();
-        pars.put('beginTime',p_beginTime);
-        def p_endTime = LocalDateTime.now().minusDays(5);
+        def p_endTime = LocalDateTime.now();
         pars.put('endTime',p_endTime);
+        def p_beginTime = LocalDateTime.now().minusDays(5);
+        pars.put('beginTime',p_beginTime);
         def rs = service.execQuery(sql,pars);
         if(rs > 2){
             return true;
@@ -33,14 +33,14 @@
         }
     }
     def func_1(){
-        Map<String,Object> pars = new HashMap<>();
-        def sql= "select  from t_case where create_time between :beginTime and :endTime  and  content like '%鍛芥%'  and address like '%閲戠墰澶ч亾%' ";
-        def p_beginTime = LocalDateTime.now();
-        pars.put('beginTime',p_beginTime);
-        def p_endTime = LocalDateTime.now().minusDays(5);
+        Map<String,Object> pars = super.getSqlParameters();
+        def sql= "select sum(amt) from t_case where create_time between :beginTime and :endTime  and  content like '%璇堥獥%'  and address like '%閾剁墰澶ч亾%' ";
+        def p_endTime = LocalDateTime.now();
         pars.put('endTime',p_endTime);
+        def p_beginTime = LocalDateTime.now().minusDays(5);
+        pars.put('beginTime',p_beginTime);
         def rs = service.execQuery(sql,pars);
-        if(rs >=2){
+        if(rs >=100000){
             return true;
         }else{
             return false;

--
Gitblit v1.8.0