get -> select

This commit is contained in:
yoon 2025-02-17 15:02:59 +09:00
parent 733389a2a3
commit 59d193733c
3 changed files with 16 additions and 14 deletions

View File

@ -23,19 +23,21 @@ import io.company.localhost.common.dto.MapDto;
@Mapper @Mapper
public interface commoncodMapper { public interface commoncodMapper {
List<MapDto> getWordCategory(); List<MapDto> selectWordCategory();
Long insertCategory(MapDto map); Long insertCategory(MapDto map);
List<MapDto> getColorList(String type); List<MapDto> selectColorList(String type);
List<MapDto> getMbtiList(); List<MapDto> selectMbtiList();
List<MapDto> getPwhintList(); List<MapDto> selectPwhintList();
int updateColorYon(MapDto map); int updateColorYon(MapDto map);
List<MapDto> getYearCategories(); int updateColorChange(MapDto map);
List<MapDto> getCategories(); List<MapDto> selectYearCategories();
List<MapDto> selectCategories();
} }

View File

@ -29,7 +29,7 @@ public class commoncodService {
private final commoncodMapper commoncodmapper; private final commoncodMapper commoncodmapper;
public List<MapDto> selectWordCategory() { public List<MapDto> selectWordCategory() {
return commoncodmapper.getWordCategory(); return commoncodmapper.selectWordCategory();
} }
public Long insertCategory(MapDto map) { public Long insertCategory(MapDto map) {
@ -37,22 +37,22 @@ public class commoncodService {
} }
public List<MapDto> selectColorList(String type) { public List<MapDto> selectColorList(String type) {
return commoncodmapper.getColorList(type); return commoncodmapper.selectColorList(type);
} }
public List<MapDto> selectMbtiList() { public List<MapDto> selectMbtiList() {
return commoncodmapper.getMbtiList(); return commoncodmapper.selectMbtiList();
} }
public List<MapDto> selectYearCategories() { public List<MapDto> selectYearCategories() {
return commoncodmapper.getYearCategories(); return commoncodmapper.selectYearCategories();
} }
public List<MapDto> selectPwhintList() { public List<MapDto> selectPwhintList() {
return commoncodmapper.getPwhintList(); return commoncodmapper.selectPwhintList();
} }
public List<MapDto> selectCategoryList() { public List<MapDto> selectCategoryList() {
return commoncodmapper.getCategories(); return commoncodmapper.selectCategories();
} }
} }

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="io.company.localhost.mapper.commoncodMapper"> <mapper namespace="io.company.localhost.mapper.commoncodMapper">
<select id="getWordCategory" resultType="Map"> <select id="selectWordCategory" resultType="Map">
select select
CMNCODVAL CMNCODVAL
,CMNCODNAM ,CMNCODNAM
@ -96,7 +96,7 @@
WHERE CMNCODVAL = #{color}; WHERE CMNCODVAL = #{color};
</update> </update>
<select id="getCategories" resultType="Map"> <select id="selectCategories" resultType="Map">
SELECT CMNCODVAL, CMNCODNAM FROM commoncod SELECT CMNCODVAL, CMNCODNAM FROM commoncod
WHERE CMNCODVAL BETWEEN 300101 AND 300103 WHERE CMNCODVAL BETWEEN 300101 AND 300103
</select> </select>