Przeglądaj źródła

项目、合同时间范围查询修改

lamphua 5 dni temu
rodzic
commit
73cf1a7a75

+ 10
- 0
oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcContractController.java Wyświetl plik

140
                     Calendar calendar = Calendar.getInstance();
140
                     Calendar calendar = Calendar.getInstance();
141
                     calendar.set(Calendar.YEAR, Integer.parseInt(monthList.get(i).split("-")[0]));
141
                     calendar.set(Calendar.YEAR, Integer.parseInt(monthList.get(i).split("-")[0]));
142
                     calendar.set(Calendar.MONTH, Integer.parseInt(monthList.get(i).split("-")[1]) - 1);
142
                     calendar.set(Calendar.MONTH, Integer.parseInt(monthList.get(i).split("-")[1]) - 1);
143
+                    calendar.set(Calendar.DAY_OF_MONTH, 1);
143
                     String endTimeString = monthList.get(i) + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
144
                     String endTimeString = monthList.get(i) + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
144
                     Map<String, Object> params = new HashMap<>();
145
                     Map<String, Object> params = new HashMap<>();
145
                     params.put("beginTime", beginTimeString + " 00:00:00");
146
                     params.put("beginTime", beginTimeString + " 00:00:00");
181
                 Calendar calendar = Calendar.getInstance();
182
                 Calendar calendar = Calendar.getInstance();
182
                 calendar.set(Calendar.YEAR, Integer.parseInt(new SimpleDateFormat("yyyy").format(cmcContract.getSignDate())));
183
                 calendar.set(Calendar.YEAR, Integer.parseInt(new SimpleDateFormat("yyyy").format(cmcContract.getSignDate())));
183
                 calendar.set(Calendar.MONTH, i - 1);
184
                 calendar.set(Calendar.MONTH, i - 1);
185
+                calendar.set(Calendar.DAY_OF_MONTH, 1);
184
                 String endTimeString = new SimpleDateFormat("yyyy").format(cmcContract.getSignDate()) + "-" + month + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
186
                 String endTimeString = new SimpleDateFormat("yyyy").format(cmcContract.getSignDate()) + "-" + month + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
185
                 Map<String, Object> params = new HashMap<>();
187
                 Map<String, Object> params = new HashMap<>();
186
                 params.put("beginTime", beginTimeString + " 00:00:00");
188
                 params.put("beginTime", beginTimeString + " 00:00:00");
218
             yearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcContract.getSignDate()), totalAmount);
220
             yearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcContract.getSignDate()), totalAmount);
219
             paidYearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcContract.getSignDate()), paidTotalAmount);
221
             paidYearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcContract.getSignDate()), paidTotalAmount);
220
         }
222
         }
223
+        if (!endTime.equals("")) {
224
+            Calendar calendar = Calendar.getInstance();
225
+            calendar.set(Calendar.YEAR, Integer.parseInt(endTime.split("-")[0]));
226
+            calendar.set(Calendar.MONTH, Integer.parseInt(endTime.split("-")[1]) - 1);
227
+            calendar.set(Calendar.DAY_OF_MONTH, 1);
228
+            endTime = endTime.split("-")[0] + "-" + endTime.split("-")[1] + "-"
229
+                    + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
230
+        }
221
         getProjectSourceStatistic(cmcContract, sourceCountObject, paidSourceCountObject, sourceAmountObject, paidSourceAmountObject, totalCount, paidTotalCount, totalAmount, paidTotalAmount, beginTime, endTime);
231
         getProjectSourceStatistic(cmcContract, sourceCountObject, paidSourceCountObject, sourceAmountObject, paidSourceAmountObject, totalCount, paidTotalCount, totalAmount, paidTotalAmount, beginTime, endTime);
222
         yearCountArray.add(yearCountObject);
232
         yearCountArray.add(yearCountObject);
223
         monthCountArray.add(monthCountObject);
233
         monthCountArray.add(monthCountObject);

+ 3
- 0
oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcProjectController.java Wyświetl plik

307
                     Calendar calendar = Calendar.getInstance();
307
                     Calendar calendar = Calendar.getInstance();
308
                     calendar.set(Calendar.YEAR, Integer.parseInt(monthList.get(i).split("-")[0]));
308
                     calendar.set(Calendar.YEAR, Integer.parseInt(monthList.get(i).split("-")[0]));
309
                     calendar.set(Calendar.MONTH, Integer.parseInt(monthList.get(i).split("-")[1]) - 1);
309
                     calendar.set(Calendar.MONTH, Integer.parseInt(monthList.get(i).split("-")[1]) - 1);
310
+                    calendar.set(Calendar.DAY_OF_MONTH, 1);
310
                     String endTimeString = monthList.get(i) + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
311
                     String endTimeString = monthList.get(i) + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
311
                     Map<String, Object> params = new HashMap<>();
312
                     Map<String, Object> params = new HashMap<>();
312
                     params.put("beginTime", beginTimeString + " 00:00:00");
313
                     params.put("beginTime", beginTimeString + " 00:00:00");
383
                 Calendar calendar = Calendar.getInstance();
384
                 Calendar calendar = Calendar.getInstance();
384
                 calendar.set(Calendar.YEAR, Integer.parseInt(cmcProject.getProjectNumber()));
385
                 calendar.set(Calendar.YEAR, Integer.parseInt(cmcProject.getProjectNumber()));
385
                 calendar.set(Calendar.MONTH, i - 1);
386
                 calendar.set(Calendar.MONTH, i - 1);
387
+                calendar.set(Calendar.DAY_OF_MONTH, 1);
386
                 String endTimeString = cmcProject.getProjectNumber() + "-" + month + "-"
388
                 String endTimeString = cmcProject.getProjectNumber() + "-" + month + "-"
387
                         + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
389
                         + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
388
                 String monthKey = cmcProject.getProjectNumber() + "-" + month;
390
                 String monthKey = cmcProject.getProjectNumber() + "-" + month;
509
             Calendar calendar = Calendar.getInstance();
511
             Calendar calendar = Calendar.getInstance();
510
             calendar.set(Calendar.YEAR, Integer.parseInt(endTime.split("-")[0]));
512
             calendar.set(Calendar.YEAR, Integer.parseInt(endTime.split("-")[0]));
511
             calendar.set(Calendar.MONTH, Integer.parseInt(endTime.split("-")[1]) - 1);
513
             calendar.set(Calendar.MONTH, Integer.parseInt(endTime.split("-")[1]) - 1);
514
+            calendar.set(Calendar.DAY_OF_MONTH, 1);
512
             endTime = endTime.split("-")[0] + "-" + endTime.split("-")[1] + "-"
515
             endTime = endTime.split("-")[0] + "-" + endTime.split("-")[1] + "-"
513
                     + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
516
                     + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
514
         }
517
         }

+ 10
- 0
oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcSubContractController.java Wyświetl plik

160
                     Calendar calendar = Calendar.getInstance();
160
                     Calendar calendar = Calendar.getInstance();
161
                     calendar.set(Calendar.YEAR, Integer.parseInt(monthList.get(i).split("-")[0]));
161
                     calendar.set(Calendar.YEAR, Integer.parseInt(monthList.get(i).split("-")[0]));
162
                     calendar.set(Calendar.MONTH, Integer.parseInt(monthList.get(i).split("-")[1]) - 1);
162
                     calendar.set(Calendar.MONTH, Integer.parseInt(monthList.get(i).split("-")[1]) - 1);
163
+                    calendar.set(Calendar.DAY_OF_MONTH, 1);
163
                     String endTimeString = monthList.get(i) + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
164
                     String endTimeString = monthList.get(i) + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
164
                     Map<String, Object> params = new HashMap<>();
165
                     Map<String, Object> params = new HashMap<>();
165
                     params.put("beginTime", beginTimeString + " 00:00:00");
166
                     params.put("beginTime", beginTimeString + " 00:00:00");
201
                 Calendar calendar = Calendar.getInstance();
202
                 Calendar calendar = Calendar.getInstance();
202
                 calendar.set(Calendar.YEAR, Integer.parseInt(new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate())));
203
                 calendar.set(Calendar.YEAR, Integer.parseInt(new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate())));
203
                 calendar.set(Calendar.MONTH, i - 1);
204
                 calendar.set(Calendar.MONTH, i - 1);
205
+                calendar.set(Calendar.DAY_OF_MONTH, 1);
204
                 String endTimeString = new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate()) + "-" + month + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
206
                 String endTimeString = new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate()) + "-" + month + "-" + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
205
                 Map<String, Object> params = new HashMap<>();
207
                 Map<String, Object> params = new HashMap<>();
206
                 params.put("beginTime", beginTimeString + " 00:00:00");
208
                 params.put("beginTime", beginTimeString + " 00:00:00");
238
             yearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate()), totalAmount);
240
             yearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate()), totalAmount);
239
             paidYearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate()), paidTotalAmount);
241
             paidYearAmountObject.put(new SimpleDateFormat("yyyy").format(cmcSubContract.getSignDate()), paidTotalAmount);
240
         }
242
         }
243
+        if (!endTime.equals("")) {
244
+            Calendar calendar = Calendar.getInstance();
245
+            calendar.set(Calendar.YEAR, Integer.parseInt(endTime.split("-")[0]));
246
+            calendar.set(Calendar.MONTH, Integer.parseInt(endTime.split("-")[1]) - 1);
247
+            calendar.set(Calendar.DAY_OF_MONTH, 1);
248
+            endTime = endTime.split("-")[0] + "-" + endTime.split("-")[1] + "-"
249
+                    + calendar.getActualMaximum(Calendar.DAY_OF_MONTH);
250
+        }
241
         getProjectSourceStatistic(cmcSubContract, sourceCountObject, paidSourceCountObject, sourceAmountObject, paidSourceAmountObject, totalCount, paidTotalCount, totalAmount, paidTotalAmount, beginTime, endTime);
251
         getProjectSourceStatistic(cmcSubContract, sourceCountObject, paidSourceCountObject, sourceAmountObject, paidSourceAmountObject, totalCount, paidTotalCount, totalAmount, paidTotalAmount, beginTime, endTime);
242
         yearCountArray.add(yearCountObject);
252
         yearCountArray.add(yearCountObject);
243
         monthCountArray.add(monthCountObject);
253
         monthCountArray.add(monthCountObject);

+ 0
- 6
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcBorrowMapper.xml Wyświetl plik

142
             <if test="lendTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', lendTime) == '2000' "> and b.lend_time is not null</if>
142
             <if test="lendTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', lendTime) == '2000' "> and b.lend_time is not null</if>
143
             <if test="lendTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', lendTime) != '2000' "> and YEAR(b.lend_time) = YEAR(#{lendTime})</if>
143
             <if test="lendTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', lendTime) != '2000' "> and YEAR(b.lend_time) = YEAR(#{lendTime})</if>
144
             <if test="params.beginTime != null and params.beginTime != '' and lendTime != null"> and MONTH(b.lend_time) = MONTH(#{lendTime})</if>
144
             <if test="params.beginTime != null and params.beginTime != '' and lendTime != null"> and MONTH(b.lend_time) = MONTH(#{lendTime})</if>
145
-            <if test="params.beginTime != null and params.beginTime != '' and lendTime == null">
146
-                and date_format(b.apply_date,'%y%m%d') &gt;= date_format(#{params.beginTime},'%y%m%d')
147
-            </if>
148
-            <if test="params.endTime != null and params.endTime != '' and lendTime == null">
149
-                and date_format(b.apply_date,'%y%m%d') &lt;= date_format(#{params.endTime},'%y%m%d')
150
-            </if>
151
             <if test="unionTime != null "> and b.union_time = #{unionTime}</if>
145
             <if test="unionTime != null "> and b.union_time = #{unionTime}</if>
152
         </where>
146
         </where>
153
         order by b.apply_date desc
147
         order by b.apply_date desc

+ 1
- 9
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcCarApprovalMapper.xml Wyświetl plik

139
             <if test="passengers != null "> and ca.passengers = #{passengers}</if>
139
             <if test="passengers != null "> and ca.passengers = #{passengers}</if>
140
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) == '2000' "> and ca.apply_date is not null</if>
140
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) == '2000' "> and ca.apply_date is not null</if>
141
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) != '2000' "> and YEAR(ca.apply_date) = YEAR(#{applyDate})</if>
141
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) != '2000' "> and YEAR(ca.apply_date) = YEAR(#{applyDate})</if>
142
-            <if test="params.beginTime != null and params.beginTime != ''"> and MONTH(ca.apply_date) = MONTH(#{applyDate})</if>
142
+            <if test="params.beginTime != null and params.beginTime != '' and applyDate != null"> and MONTH(ca.apply_date) = MONTH(#{applyDate})</if>
143
             <if test="beginDate != null "> and ca.begin_date = #{beginDate}</if>
143
             <if test="beginDate != null "> and ca.begin_date = #{beginDate}</if>
144
             <if test="endDate != null "> and ca.end_date = #{endDate}</if>
144
             <if test="endDate != null "> and ca.end_date = #{endDate}</if>
145
             <if test="days != null "> and ca.days = #{days}</if>
145
             <if test="days != null "> and ca.days = #{days}</if>
276
         </foreach>
276
         </foreach>
277
     </delete>
277
     </delete>
278
 
278
 
279
-    <select id="selectCmcCarApprovalListByRange" parameterType="CmcCarApproval" resultMap="CmcCarApprovalResult">
280
-        <include refid="selectCmcCarApprovalVo"/>
281
-        <where>
282
-            <if test="params.beginTime != null and params.beginTime != ''"> and ca.apply_date &gt;= #{params.beginTime}</if>
283
-            <if test="params.endTime != null and params.endTime != ''"> and ca.apply_date &lt;= #{params.endTime}</if>
284
-        </where>
285
-        order by ca.apply_date desc
286
-    </select>
287
 </mapper>
279
 </mapper>

+ 1
- 9
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcCheckMapper.xml Wyświetl plik

81
             <if test="zjlUserId != null "> and c.zjl_user_id = #{zjlUserId}</if>
81
             <if test="zjlUserId != null "> and c.zjl_user_id = #{zjlUserId}</if>
82
             <if test="checkTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', checkTime) == '2000' "> and c.check_time is not null</if>
82
             <if test="checkTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', checkTime) == '2000' "> and c.check_time is not null</if>
83
             <if test="checkTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', checkTime) != '2000' "> and YEAR(c.check_time) = YEAR(#{checkTime})</if>
83
             <if test="checkTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', checkTime) != '2000' "> and YEAR(c.check_time) = YEAR(#{checkTime})</if>
84
-            <if test="params.beginTime != null and params.beginTime != ''"> and MONTH(c.check_time) = MONTH(#{checkTime})</if>
84
+            <if test="params.beginTime != null and params.beginTime != '' and checkTime != null"> and MONTH(c.check_time) = MONTH(#{checkTime})</if>
85
             <if test="zjlComment != null  and zjlComment != ''"> and c.zjl_comment = #{zjlComment}</if>
85
             <if test="zjlComment != null  and zjlComment != ''"> and c.zjl_comment = #{zjlComment}</if>
86
         </where>
86
         </where>
87
     </select>
87
     </select>
164
         </foreach>
164
         </foreach>
165
     </delete>
165
     </delete>
166
 
166
 
167
-    <select id="selectCmcCheckListByRange" parameterType="CmcCheck" resultMap="CmcCheckResult">
168
-        <include refid="selectCmcCheckVo"/>
169
-        <where>
170
-            <if test="params.beginTime != null and params.beginTime != ''"> and c.check_time &gt;= #{params.beginTime}</if>
171
-            <if test="params.endTime != null and params.endTime != ''"> and c.check_time &lt;= #{params.endTime}</if>
172
-        </where>
173
-        order by c.check_time desc
174
-    </select>
175
 </mapper>
167
 </mapper>

+ 0
- 4
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcContractMapper.xml Wyświetl plik

166
             <if test="projectSource != null  and projectSource != ''"> and p.project_source = #{projectSource}</if>
166
             <if test="projectSource != null  and projectSource != ''"> and p.project_source = #{projectSource}</if>
167
             <if test="projectName != null  and projectName != ''"> and p.project_name like concat('%', #{projectName}, '%')</if>
167
             <if test="projectName != null  and projectName != ''"> and p.project_name like concat('%', #{projectName}, '%')</if>
168
             <if test="partyAName != null  and partyAName != ''"> and pa.party_a_name like concat('%', #{partyAName}, '%')</if>
168
             <if test="partyAName != null  and partyAName != ''"> and pa.party_a_name like concat('%', #{partyAName}, '%')</if>
169
-<<<<<<< HEAD
170
-=======
171
-            
172
->>>>>>> 2790a39d2f9879e185c89178e7033c6745b4bae9
173
         </where>
169
         </where>
174
         group by t1.contract_id
170
         group by t1.contract_id
175
         order by t1.draft_time desc
171
         order by t1.draft_time desc

+ 0
- 12
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcDeviceApprovalMapper.xml Wyświetl plik

84
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) == '2000' "> and da.apply_date is not null</if>
84
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) == '2000' "> and da.apply_date is not null</if>
85
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) != '2000' "> and YEAR(da.apply_date) = YEAR(#{applyDate})</if>
85
             <if test="applyDate != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', applyDate) != '2000' "> and YEAR(da.apply_date) = YEAR(#{applyDate})</if>
86
             <if test="params.beginTime != null and params.beginTime != '' and applyDate != null"> and MONTH(da.apply_date) = MONTH(#{applyDate})</if>
86
             <if test="params.beginTime != null and params.beginTime != '' and applyDate != null"> and MONTH(da.apply_date) = MONTH(#{applyDate})</if>
87
-            <if test="params.beginTime != null and params.beginTime != '' and params.endTime != null and params.endTime != '' and applyDate == null">
88
-                and date_format(da.apply_date,'%y%m%d') &lt;= date_format(#{params.endTime},'%y%m%d')
89
-                and date_format(da.apply_date,'%y%m%d') &gt;= date_format(#{params.beginTime},'%y%m%d')
90
-            </if>
91
             <if test="returnDate != null "> and da.return_date = #{returnDate}</if>
87
             <if test="returnDate != null "> and da.return_date = #{returnDate}</if>
92
             <if test="beginDate != null "> and da.begin_date = #{beginDate}</if>
88
             <if test="beginDate != null "> and da.begin_date = #{beginDate}</if>
93
             <if test="endDate != null "> and da.end_date = #{endDate}</if>
89
             <if test="endDate != null "> and da.end_date = #{endDate}</if>
197
         </foreach>
193
         </foreach>
198
     </delete>
194
     </delete>
199
 
195
 
200
-    <select id="selectCmcDeviceApprovalListByRange" parameterType="CmcDeviceApproval" resultMap="CmcDeviceApprovalResult">
201
-        <include refid="selectCmcDeviceApprovalVo"/>
202
-        <where>
203
-            <if test="params.beginTime != null and params.beginTime != ''"> and da.apply_date &gt;= #{params.beginTime}</if>
204
-            <if test="params.endTime != null and params.endTime != ''"> and da.apply_date &lt;= #{params.endTime}</if>
205
-        </where>
206
-        order by da.apply_date desc
207
-    </select>
208
 </mapper>
196
 </mapper>

+ 1
- 7
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcProjectMapper.xml Wyświetl plik

131
             <if test="entryTime != null "> and p.entry_time = #{entryTime}</if>
131
             <if test="entryTime != null "> and p.entry_time = #{entryTime}</if>
132
             <if test="exitTime != null "> and p.exit_time = #{exitTime}</if>
132
             <if test="exitTime != null "> and p.exit_time = #{exitTime}</if>
133
             <if test="participates != null  and participates != ''"> and find_in_set(#{participates}, p.participates)</if>
133
             <if test="participates != null  and participates != ''"> and find_in_set(#{participates}, p.participates)</if>
134
-            <if test="params.beginTime != null and params.beginTime != ''">
135
-                and date_format(p.register_time,'%y%m%d') &gt;= date_format(#{params.beginTime},'%y%m%d')
136
-            </if>
137
-            <if test="params.endTime != null and params.endTime != ''">
138
-                and date_format(p.register_time,'%y%m%d') &lt;= date_format(#{params.endTime},'%y%m%d')
139
-            </if>
140
         </where>
134
         </where>
141
         group by p.project_id
135
         group by p.project_id
142
         order by p.register_time desc, p.project_number desc
136
         order by p.register_time desc, p.project_number desc
320
         union
314
         union
321
         select p.project_id, p.project_number, p.project_name, p.project_leader, p.register_time from cmc_declare d
315
         select p.project_id, p.project_number, p.project_name, p.project_leader, p.register_time from cmc_declare d
322
         left join cmc_project as p on p.project_id = d.project_id
316
         left join cmc_project as p on p.project_id = d.project_id
323
-        where d.user_id = #{participates}) as t
317
+        where d.user_id = #{participates} and p.project_number is not null) as t
324
         group by t.project_id
318
         group by t.project_id
325
         order by t.register_time desc, t.project_number desc
319
         order by t.register_time desc, t.project_number desc
326
     </select>
320
     </select>

+ 1
- 10
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcSettleMapper.xml Wyświetl plik

153
             <if test="gmUserId != null "> and s.gm_user_id = #{gmUserId}</if>
153
             <if test="gmUserId != null "> and s.gm_user_id = #{gmUserId}</if>
154
             <if test="gmTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', gmTime) == '2000' "> and s.gm_time is not null</if>
154
             <if test="gmTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', gmTime) == '2000' "> and s.gm_time is not null</if>
155
             <if test="gmTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', gmTime) != '2000' "> and YEAR(s.gm_time) = YEAR(#{gmTime})</if>
155
             <if test="gmTime != null and @com.ruoyi.common.utils.DateUtils@parseDateToStr('yyyy', gmTime) != '2000' "> and YEAR(s.gm_time) = YEAR(#{gmTime})</if>
156
-            <if test="params.beginTime != null and params.beginTime != ''"> and MONTH(s.gm_time) = MONTH(#{gmTime})</if>
156
+            <if test="params.beginTime != null and params.beginTime != '' and gmTime != null"> and MONTH(s.gm_time) = MONTH(#{gmTime})</if>
157
             <if test="gmComment != null  and gmComment != ''"> and s.gm_comment = #{gmComment}</if>
157
             <if test="gmComment != null  and gmComment != ''"> and s.gm_comment = #{gmComment}</if>
158
         </where>
158
         </where>
159
         group by s.settle_id
159
         group by s.settle_id
287
         </foreach>
287
         </foreach>
288
     </delete>
288
     </delete>
289
 
289
 
290
-    <select id="selectCmcSettleListByRange" parameterType="CmcSettle" resultMap="CmcSettleResult">
291
-        <include refid="selectCmcSettleVo"/>
292
-        <where>
293
-            ss.content = '实际结算总金额'
294
-            <if test="params.beginTime != null and params.beginTime != ''"> and s.gm_time &gt;= #{params.beginTime}</if>
295
-            <if test="params.endTime != null and params.endTime != ''"> and s.gm_time &lt;= #{params.endTime}</if>
296
-        </where>
297
-        order by s.gm_time desc
298
-    </select>
299
 </mapper>
290
 </mapper>

+ 1
- 1
oa-ui/src/api/oa/contract/contract.js Wyświetl plik

60
 // 合同统计
60
 // 合同统计
61
 export function getContractStatistic(query) {
61
 export function getContractStatistic(query) {
62
   return request({
62
   return request({
63
-    url: '/oa/contract/statistic/',
63
+    url: '/oa/contract/statistic',
64
     method: 'get',
64
     method: 'get',
65
     params: query
65
     params: query
66
   })
66
   })

Ładowanie…
Anuluj
Zapisz