용어집 수정
This commit is contained in:
parent
124562a267
commit
bfbe92016f
@ -71,6 +71,17 @@ public class worddictController {
|
||||
return ApiResponse.ok(WordCategoryList);
|
||||
}
|
||||
/**
|
||||
* 용어집 상세 조회
|
||||
* @param WRDDICSEQ 용어 번호
|
||||
* @return
|
||||
*/
|
||||
@Member
|
||||
@ParameterCheck
|
||||
@GetMapping("getWordDetail")
|
||||
public ApiResponse<MapDto> getWordDetail(@ReqMap MapDto map) {
|
||||
return ApiResponse.ok( worddictyservice.getWordDetail(map));
|
||||
}
|
||||
/**
|
||||
* 용어집 카테고리 등록
|
||||
* @param CMNCODNAM 용어집 등록 카테고리 이름
|
||||
* @return
|
||||
|
||||
@ -29,6 +29,8 @@ public interface worddictyMapper {
|
||||
|
||||
Long updateWord(MapDto map);
|
||||
|
||||
MapDto getWordDetail(MapDto map);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -45,6 +45,10 @@ public class worddictyService {
|
||||
return worddictymapper.updateWord(map);
|
||||
}
|
||||
|
||||
public MapDto getWordDetail(MapDto map) {
|
||||
return worddictymapper.getWordDetail(map);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -5,6 +5,7 @@
|
||||
select
|
||||
w.*
|
||||
,DATE_FORMAT(w.WRDDICRDT,'%y.%m.%d %H:%i') AS formatWRDDICRDT
|
||||
,DATE_FORMAT(w.WRDDICUDT,'%y.%m.%d %H:%i') AS formatWRDDICRDT
|
||||
,c.CMNCODNAM category
|
||||
from
|
||||
worddicty w
|
||||
@ -21,7 +22,130 @@
|
||||
</if>
|
||||
<!-- 색인표 조건 -->
|
||||
<if test="indexKeyword != null and indexKeyword != ''">
|
||||
and w.WRDDICTTL like CONCAT(#{indexKeyword}, '%')
|
||||
<choose>
|
||||
<!-- 한글 ㄱ ~ ㅎ에 대한 검색 -->
|
||||
<when test='indexKeyword == "ㄱ"'>
|
||||
and w.WRDDICTTL BETWEEN '가' AND '깋'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㄴ"'>
|
||||
and w.WRDDICTTL BETWEEN '나' AND '닣'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㄷ"'>
|
||||
and w.WRDDICTTL BETWEEN '다' AND '딷'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㄹ"'>
|
||||
and w.WRDDICTTL BETWEEN '라' AND '릿'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅁ"'>
|
||||
and w.WRDDICTTL BETWEEN '마' AND '맇'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅂ"'>
|
||||
and w.WRDDICTTL BETWEEN '바' AND '빟'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅅ"'>
|
||||
and w.WRDDICTTL BETWEEN '사' AND '싷'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅇ"'>
|
||||
and w.WRDDICTTL BETWEEN '아' AND '잏'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅈ"'>
|
||||
and w.WRDDICTTL BETWEEN '자' AND '짛'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅊ"'>
|
||||
and w.WRDDICTTL BETWEEN '차' AND '칳'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅋ"'>
|
||||
and w.WRDDICTTL BETWEEN '카' AND '킿'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅌ"'>
|
||||
and w.WRDDICTTL BETWEEN '타' AND '틷'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅍ"'>
|
||||
and w.WRDDICTTL BETWEEN '파' AND '핗'
|
||||
</when>
|
||||
<when test='indexKeyword == "ㅎ"'>
|
||||
and w.WRDDICTTL BETWEEN '하' AND '힣'
|
||||
</when>
|
||||
<!-- 알파벳 a ~ z에 대한 검색 -->
|
||||
<when test='indexKeyword == "a"'>
|
||||
and w.WRDDICTTL like "a%"
|
||||
</when>
|
||||
<when test='indexKeyword == "b"'>
|
||||
and w.WRDDICTTL like "b%"
|
||||
</when>
|
||||
<when test='indexKeyword == "c"'>
|
||||
and w.WRDDICTTL like "c%"
|
||||
</when>
|
||||
<when test='indexKeyword == "d"'>
|
||||
and w.WRDDICTTL like "d%"
|
||||
</when>
|
||||
<when test='indexKeyword == "e"'>
|
||||
and w.WRDDICTTL like "e%"
|
||||
</when>
|
||||
<when test='indexKeyword == "f"'>
|
||||
and w.WRDDICTTL like "f%"
|
||||
</when>
|
||||
<when test='indexKeyword == "g"'>
|
||||
and w.WRDDICTTL like "g%"
|
||||
</when>
|
||||
<when test='indexKeyword == "h"'>
|
||||
and w.WRDDICTTL like "h%"
|
||||
</when>
|
||||
<when test='indexKeyword == "i"'>
|
||||
and w.WRDDICTTL like "i%"
|
||||
</when>
|
||||
<when test='indexKeyword == "j"'>
|
||||
and w.WRDDICTTL like "j%"
|
||||
</when>
|
||||
<when test='indexKeyword == "k"'>
|
||||
and w.WRDDICTTL like "k%"
|
||||
</when>
|
||||
<when test='indexKeyword == "l"'>
|
||||
and w.WRDDICTTL like "l%"
|
||||
</when>
|
||||
<when test='indexKeyword == "m"'>
|
||||
and w.WRDDICTTL like "m%"
|
||||
</when>
|
||||
<when test='indexKeyword == "n"'>
|
||||
and w.WRDDICTTL like "n%"
|
||||
</when>
|
||||
<when test='indexKeyword == "o"'>
|
||||
and w.WRDDICTTL like "o%"
|
||||
</when>
|
||||
<when test='indexKeyword == "p"'>
|
||||
and w.WRDDICTTL like "p%"
|
||||
</when>
|
||||
<when test='indexKeyword == "q"'>
|
||||
and w.WRDDICTTL like "q%"
|
||||
</when>
|
||||
<when test='indexKeyword == "r"'>
|
||||
and w.WRDDICTTL like "r%"
|
||||
</when>
|
||||
<when test='indexKeyword == "s"'>
|
||||
and w.WRDDICTTL like "s%"
|
||||
</when>
|
||||
<when test='indexKeyword == "t"'>
|
||||
and w.WRDDICTTL like "t%"
|
||||
</when>
|
||||
<when test='indexKeyword == "u"'>
|
||||
and w.WRDDICTTL like "u%"
|
||||
</when>
|
||||
<when test='indexKeyword == "v"'>
|
||||
and w.WRDDICTTL like "v%"
|
||||
</when>
|
||||
<when test='indexKeyword == "w"'>
|
||||
and w.WRDDICTTL like "w%"
|
||||
</when>
|
||||
<when test='indexKeyword == "x"'>
|
||||
and w.WRDDICTTL like "x%"
|
||||
</when>
|
||||
<when test='indexKeyword == "y"'>
|
||||
and w.WRDDICTTL like "y%"
|
||||
</when>
|
||||
<when test='indexKeyword == "z"'>
|
||||
and w.WRDDICTTL like "z%"
|
||||
</when>
|
||||
</choose>
|
||||
</if>
|
||||
<!-- 카테고리 조건 -->
|
||||
<if test="category != null and category != ''">
|
||||
@ -72,4 +196,11 @@
|
||||
where
|
||||
WRDDICSEQ = #{WRDDICSEQ}
|
||||
</update>
|
||||
<select id="getWordDetail" parameterType="map" resultType="io.company.localhost.common.dto.MapDto">
|
||||
select *
|
||||
from
|
||||
worddicty
|
||||
where
|
||||
WRDDICSEQ = #{WRDDICSEQ}
|
||||
</select>
|
||||
</mapper>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user