color, mbti, 등록신청 시 사용한 color 업데이트

This commit is contained in:
yoon 2025-01-21 15:12:14 +09:00
parent ddefb2c3dc
commit e7c4984c53
3 changed files with 49 additions and 1 deletions

View File

@ -27,4 +27,9 @@ public interface commoncodMapper {
Long insertCategory(MapDto map);
List<MapDto> getColorList();
List<MapDto> getMbtiList();
int updateColorYon(String color);
}

View File

@ -36,4 +36,13 @@ public class commoncodService {
return commoncodmapper.insertCategory(map);
}
public List<MapDto> getColorList() {
return commoncodmapper.getColorList();
}
public List<MapDto> getMbtiList() {
return commoncodmapper.getMbtiList();
}
}

View File

@ -29,4 +29,38 @@
WHERE
CMNCODLV1 = 600;
</insert>
<select id="getColorList" resultType="Map">
SELECT
CMNCODVAL
,CMNCODNAM
FROM
commoncod
WHERE
CMNCODLV1 = 100
AND
CMNCODODR != 0
AND
CMNCODYON = 0
</select>
<select id="getMbtiList" resultType="Map">
SELECT
CMNCODVAL
,CMNCODNAM
FROM
commoncod
WHERE
CMNCODLV1 = 200
AND
CMNCODODR != 0
</select>
<update id="updateColorYon" parameterType="String">
UPDATE commoncod
SET CMNCODYON = 1
WHERE CMNCODVAL = #{color};
</update>
</mapper>