단속현황 검색필터 추가
parent
58c776513f
commit
b2fa46df9b
|
|
@ -83,6 +83,8 @@ public class CrackdownStatus extends CrackdownStatusBaseEntity {
|
|||
@Transient
|
||||
private String year;
|
||||
@Transient
|
||||
private String month;
|
||||
@Transient
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDate napoDate;
|
||||
@Transient
|
||||
|
|
|
|||
|
|
@ -7,7 +7,10 @@
|
|||
<sql id="selectCrackdownStatusListWhere">
|
||||
<where>
|
||||
<if test='year != null and year != ""'>
|
||||
And EXTRACT(YEAR FROM pr.wrt_dt) = EXTRACT(YEAR FROM CAST(#{year} AS DATE)::TIMESTAMP)
|
||||
And EXTRACT(YEAR FROM pr.wrt_dt) = #{year}::NUMERIC
|
||||
</if>
|
||||
<if test='month != null and month != ""'>
|
||||
And EXTRACT(MONTH FROM pr.wrt_dt) = #{month}::NUMERIC
|
||||
</if>
|
||||
<if test='caseNum != null and caseNum != ""'>
|
||||
AND caseNum = #{caseNum}
|
||||
|
|
|
|||
|
|
@ -26,7 +26,15 @@
|
|||
<select class="form-select form-select-sm" name="year">
|
||||
<option value="">연도</option>
|
||||
<th:block th:each="year : ${#numbers.sequence(2020, 2030)}">
|
||||
<option th:value="${year + '-01-01'}" th:text="${year}" th:selected="${searchParams.year eq year}"></option>
|
||||
<option th:value="${year}" th:text="${year}" th:selected="${searchParams.year eq year}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="month">
|
||||
<option value="">월</option>
|
||||
<th:block th:each="month : ${#numbers.sequence(1, 12)}">
|
||||
<option th:value="${month}" th:text="${month}" th:selected="${searchParams.month eq month}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue