feat: 관리자 - 위원회관리 - 위원회 일정관리 추가 건

thkim
thkim 2024-01-22 10:28:12 +09:00
parent 8f6aa05847
commit 1f20255dd9
2 changed files with 16 additions and 2 deletions

View File

@ -17,6 +17,7 @@ import org.egovframe.rte.fdl.cmmn.EgovAbstractServiceImpl;
import org.springframework.stereotype.Service;
import javax.servlet.http.HttpServletRequest;
import java.time.format.DateTimeFormatter;
import java.util.*;
import java.util.stream.Collectors;
@ -246,8 +247,21 @@ public class EgovIndvdlSchdulManageServiceImpl extends EgovAbstractServiceImpl i
commandMap.put("searchMonth", sSearchDate);
commandMap.put("searchMode", "MONTH");
List<Map<String, Object>> resultList = tnCmtEventRepository.getByYyyyMm(sSearchDate)
.stream()
.map(item -> {
Map<String, Object> mapDto = new HashMap<>();
mapDto.put("evt_start_dt", item.getEvtStartDt().format(DateTimeFormatter.ofPattern("yyyyMMdd HH:mm:ss.SSS")));
mapDto.put("evt_end_dt", item.getEvtEndDt().format(DateTimeFormatter.ofPattern("yyyyMMdd HH:mm:ss.SSS")));
mapDto.put("schdulId", item.getEvtSeq());
mapDto.put("schdulNm", item.getEvtTitle());
return mapDto;
})
.collect(Collectors.toList());
dto.put("prevRequest", commandMap);
dto.put("resultList", tnCmtEventRepository.getByYyyyMm(sSearchDate));
dto.put("resultList", resultList);
resultVO.setResult(dto);

View File

@ -83,7 +83,7 @@ public interface TnCmtEventRepository extends JpaRepository<TnCmtEvent, TnCmtEve
" 'YYYYMM'" + " \n" +
" ) + INTERVAL '1 MONTH';\n",
nativeQuery = true)
List<Map<String, Object>> getByYyyyMm(
List<TnCmtEvent> getByYyyyMm(
@Param("sSearchDate") String sSearchDate
);