Merge branch 'main' of http://192.168.0.251:3000/localnet/localhost-back.git into main
This commit is contained in:
commit
ca947c62bb
@ -203,9 +203,6 @@ public class BoardController {
|
|||||||
@ParameterCheck
|
@ParameterCheck
|
||||||
@PostMapping("/{LOCBRDSEQ}/comment")
|
@PostMapping("/{LOCBRDSEQ}/comment")
|
||||||
public ApiResponse<String> addCommentOrReply(@ReqMap MapDto map) {
|
public ApiResponse<String> addCommentOrReply(@ReqMap MapDto map) {
|
||||||
Long userId = AuthUtil.getUser().getId();
|
|
||||||
map.put("MEMBERSEQ", userId);
|
|
||||||
|
|
||||||
if (map.containsKey("LOCCMTPWD") && !map.getString("LOCCMTPWD").trim().isEmpty()) { // 빈 값 체크
|
if (map.containsKey("LOCCMTPWD") && !map.getString("LOCCMTPWD").trim().isEmpty()) { // 빈 값 체크
|
||||||
String rawPassword = map.getString("LOCCMTPWD");
|
String rawPassword = map.getString("LOCCMTPWD");
|
||||||
String hashedPassword = passwordEncoder.encode(rawPassword);
|
String hashedPassword = passwordEncoder.encode(rawPassword);
|
||||||
|
|||||||
@ -134,6 +134,13 @@ public class localbordService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void insertCommentOrReply(MapDto map) {
|
public void insertCommentOrReply(MapDto map) {
|
||||||
|
// 익명게시판이면 회원 정보를 null로 설정
|
||||||
|
if ("300102".equals(String.valueOf(map.get("LOCBRDTYP")))) {
|
||||||
|
map.put("MEMBERSEQ", null);
|
||||||
|
}else {
|
||||||
|
Long userId = AuthUtil.getUser().getId();
|
||||||
|
map.put("MEMBERSEQ", userId);
|
||||||
|
}
|
||||||
if (map.get("LOCCMTPNT") == null) {
|
if (map.get("LOCCMTPNT") == null) {
|
||||||
map.put("LOCCMTPNT", null);
|
map.put("LOCCMTPNT", null);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -23,7 +23,7 @@
|
|||||||
|
|
||||||
<!-- 사용자가 사용한 연차 목록 조회 -->
|
<!-- 사용자가 사용한 연차 목록 조회 -->
|
||||||
<select id="selectUsedVacations" resultType="io.company.localhost.common.dto.MapDto">
|
<select id="selectUsedVacations" resultType="io.company.localhost.common.dto.MapDto">
|
||||||
SELECT LOCVACUDT AS date, LOCVACTYP AS type, LOCVACRMM AS receiverId,
|
SELECT LOCVACSEQ AS id, LOCVACUDT AS date, LOCVACTYP AS type, LOCVACRMM AS receiverId,
|
||||||
-- 반차(700101, 700102)는 0.5, 연차(700103)는 1로 계산
|
-- 반차(700101, 700102)는 0.5, 연차(700103)는 1로 계산
|
||||||
SUM(CASE
|
SUM(CASE
|
||||||
WHEN LOCVACTYP IN ('700101', '700102') THEN 0.5
|
WHEN LOCVACTYP IN ('700101', '700102') THEN 0.5
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user