guntaek 07-31
240731 김건택 사진 및 단원 목록 조회 기능 수정, 주석 처리
@c54f11a6804b7d500dc3cf8add4e8239dffdfc44
src/main/java/com/takensoft/ai_lms/common/confing/SecurityConfig.java
--- src/main/java/com/takensoft/ai_lms/common/confing/SecurityConfig.java
+++ src/main/java/com/takensoft/ai_lms/common/confing/SecurityConfig.java
@@ -70,8 +70,9 @@
                 .requestMatchers("/file/**").permitAll() // 파일 정보 진입 허용
                 .requestMatchers("/classes/**").permitAll() // 반 정보 진입 허용
                 .requestMatchers("/classBook/**").permitAll() // 반 - 책 정보 진입 허용
-                .requestMatchers("/unit/**").permitAll()
-                .requestMatchers("/photo/**").permitAll()
+                .requestMatchers("/unit/**").permitAll() // 단원 정보 진입 허용
+                .requestMatchers("/photo/**").permitAll() // 사진 정보 진입 허용
+                .requestMatchers("/photoMng/**").permitAll() // 사진첩 정보 진입 허용
                 .requestMatchers("/wordbook/**").permitAll()
                 .requestMatchers("/survey/**").permitAll()
                 .anyRequest().authenticated()); // 나머지 경로는 인증 필요
src/main/java/com/takensoft/ai_lms/lms/photo/dao/PhotoDAO.java
--- src/main/java/com/takensoft/ai_lms/lms/photo/dao/PhotoDAO.java
+++ src/main/java/com/takensoft/ai_lms/lms/photo/dao/PhotoDAO.java
@@ -5,15 +5,52 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진 관련 Mapper
+ */
 @Mapper("photoDAO")
 public interface PhotoDAO {
-    List<PhotoVO> photoList () throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 목록 출력
+     */
+    List<PhotoVO> photoList (PhotoVO photoVO) throws Exception;
+
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 등록
+     */
     int insertPhoto(PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 수정
+     */
     int updatePhoto(PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 삭제
+     */
     int deletePhoto(PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 상세 정보
+     */
     List<PhotoVO> photoDetail (PhotoVO photoVO) throws Exception;
 }
src/main/java/com/takensoft/ai_lms/lms/photo/service/Impl/PhotoServiceImpl.java
--- src/main/java/com/takensoft/ai_lms/lms/photo/service/Impl/PhotoServiceImpl.java
+++ src/main/java/com/takensoft/ai_lms/lms/photo/service/Impl/PhotoServiceImpl.java
@@ -12,6 +12,12 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진 관련 ServiceImpl 클래스
+ */
 @Service("photoService")
 @RequiredArgsConstructor
 public class PhotoServiceImpl extends EgovAbstractServiceImpl implements PhotoService {
@@ -19,11 +25,23 @@
     private final PhotoDAO photoDAO;
     private final IdgenService photoIdgn;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 목록 출력
+     */
     @Override
-    public List<PhotoVO> photoList() throws Exception {
-        return photoDAO.photoList();
+    public List<PhotoVO> photoList(PhotoVO photoVO) throws Exception {
+        return photoDAO.photoList(photoVO);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 등록
+     */
     @Override
     public int insertPhoto(PhotoVO photoVO) throws Exception {
         String photoId = photoIdgn.getNextStringId();
@@ -32,18 +50,36 @@
         return result;
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 수정
+     */
     @Override
     public int updatePhoto(PhotoVO photoVO) throws Exception {
         int result = photoDAO.updatePhoto(photoVO);
         return result;
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 삭제
+     */
     @Override
     public int deletePhoto(PhotoVO photoVO) throws Exception {
         int result = photoDAO.deletePhoto(photoVO);
         return result;
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 상세 정보
+     */
     @Override
     public List<PhotoVO> photoDetail(PhotoVO photoVO) throws Exception {
         return photoDAO.photoDetail(photoVO);
src/main/java/com/takensoft/ai_lms/lms/photo/service/PhotoService.java
--- src/main/java/com/takensoft/ai_lms/lms/photo/service/PhotoService.java
+++ src/main/java/com/takensoft/ai_lms/lms/photo/service/PhotoService.java
@@ -4,15 +4,51 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진 관련 Service 클래스
+ */
 public interface PhotoService {
 
-    List<PhotoVO> photoList () throws Exception;
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 목록 출력
+     */
+    List<PhotoVO> photoList (PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 등록
+     */
     int insertPhoto(PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 수정
+     */
     int updatePhoto(PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 삭제
+     */
     int deletePhoto(PhotoVO photoVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 상세 정보
+     */
     List<PhotoVO> photoDetail (PhotoVO photoVO) throws Exception;
 }
src/main/java/com/takensoft/ai_lms/lms/photo/vo/PhotoVO.java
--- src/main/java/com/takensoft/ai_lms/lms/photo/vo/PhotoVO.java
+++ src/main/java/com/takensoft/ai_lms/lms/photo/vo/PhotoVO.java
@@ -5,6 +5,12 @@
 import lombok.NoArgsConstructor;
 import lombok.Setter;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진 관련 VO
+ */
 @Getter
 @Setter
 @AllArgsConstructor
@@ -18,7 +24,7 @@
     // 등록 일자
     private String photoDate;
     // 좋아요 데이터
-    private int likeCount;
+    private int likeData;
     // 단원 아이디
     private String unitId;
     //학생 아이디
src/main/java/com/takensoft/ai_lms/lms/photo/web/PhotoController.java
--- src/main/java/com/takensoft/ai_lms/lms/photo/web/PhotoController.java
+++ src/main/java/com/takensoft/ai_lms/lms/photo/web/PhotoController.java
@@ -13,6 +13,12 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진 관련 Controller 클래스
+ */
 @RestController
 @RequiredArgsConstructor
 @Slf4j
@@ -21,31 +27,60 @@
 
     private final PhotoService photoService;
 
-
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 목록 출력
+     */
     @PostMapping(path = "/photoList.json")
-    public ResponseEntity<?> unitList() throws Exception {
-        List<PhotoVO> result = photoService.photoList();
+    public ResponseEntity<?> unitList(@RequestBody PhotoVO photoVO) throws Exception {
+        List<PhotoVO> result = photoService.photoList(photoVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 등록
+     */
     @PostMapping(path = "/insertPhoto.json")
     public ResponseEntity<?> insertUnit(@RequestBody PhotoVO photoVO) throws Exception {
         int result = photoService.insertPhoto(photoVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 수정
+     */
     @PostMapping(path = "/updatePhoto.json")
     public ResponseEntity<?> updateUnit(@RequestBody PhotoVO photoVO) throws Exception {
         int result = photoService.updatePhoto(photoVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 삭제
+     */
     @PostMapping(path = "/deletePhoto.json")
     public ResponseEntity<?> deleteUnit(@RequestBody PhotoVO photoVO) throws Exception {
         int result = photoService.deletePhoto(photoVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진 상세 정보
+     */
     @PostMapping(path = "/photoDetail.json")
     public ResponseEntity<?> unitDetail(@RequestBody PhotoVO photoVO) throws Exception {
         List<PhotoVO> result = photoService.photoDetail(photoVO);
src/main/java/com/takensoft/ai_lms/lms/photoMng/dao/PhotoMngDAO.java
--- src/main/java/com/takensoft/ai_lms/lms/photoMng/dao/PhotoMngDAO.java
+++ src/main/java/com/takensoft/ai_lms/lms/photoMng/dao/PhotoMngDAO.java
@@ -5,15 +5,52 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진첩 관련 Mapper
+ */
 @Mapper("photoMngDAO")
 public interface PhotoMngDAO {
+
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 목록 출력
+     */
     List<PhotoMngVO> photoMngList () throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 등록
+     */
     int insertPhotoMng(PhotoMngVO photoMngVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 수정
+     */
     int updatePhotoMng(PhotoMngVO photoMngVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 삭제
+     */
     int deletePhotoMng(PhotoMngVO photoMngVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 상세 정보
+     */
     List<PhotoMngVO> photoMngDetail (PhotoMngVO photoMngVO) throws Exception;
 }
src/main/java/com/takensoft/ai_lms/lms/photoMng/service/Impl/PhotoMngServiceImpl.java
--- src/main/java/com/takensoft/ai_lms/lms/photoMng/service/Impl/PhotoMngServiceImpl.java
+++ src/main/java/com/takensoft/ai_lms/lms/photoMng/service/Impl/PhotoMngServiceImpl.java
@@ -10,6 +10,12 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진첩 관련 ServiceImpl 클래스
+ */
 @Service("photoMngService")
 @RequiredArgsConstructor
 public class PhotoMngServiceImpl extends EgovAbstractServiceImpl implements PhotoMngService {
@@ -17,11 +23,23 @@
     private final PhotoMngDAO photoMngDAO;
     private final IdgenService photoMngIdgn;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 목록 출력
+     */
     @Override
     public List<PhotoMngVO> photoMngList() throws Exception {
         return photoMngDAO.photoMngList();
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 등록
+     */
     @Override
     public int insertPhotoMng(PhotoMngVO photoMngVO) throws Exception {
         String photoMngId = photoMngIdgn.getNextStringId();
@@ -30,18 +48,36 @@
         return result;
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 수정
+     */
     @Override
     public int updatePhotoMng(PhotoMngVO photoMngVO) throws Exception {
         int result = photoMngDAO.updatePhotoMng(photoMngVO);
         return result;
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 삭제
+     */
     @Override
     public int deletePhotoMng(PhotoMngVO photoMngVO) throws Exception {
         int result = photoMngDAO.deletePhotoMng(photoMngVO);
         return result;
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 상세 정보
+     */
     @Override
     public List<PhotoMngVO> photoMngDetail(PhotoMngVO photoMngVO) throws Exception {
         return photoMngDAO.photoMngDetail(photoMngVO);
src/main/java/com/takensoft/ai_lms/lms/photoMng/service/PhotoMngService.java
--- src/main/java/com/takensoft/ai_lms/lms/photoMng/service/PhotoMngService.java
+++ src/main/java/com/takensoft/ai_lms/lms/photoMng/service/PhotoMngService.java
@@ -4,15 +4,51 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진첩 관련 Service 클래스
+ */
 public interface PhotoMngService {
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 목록 출력
+     */
     List<PhotoMngVO> photoMngList () throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 등록
+     */
     int insertPhotoMng(PhotoMngVO photoMngVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 수정
+     */
     int updatePhotoMng(PhotoMngVO photoMngVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 삭제
+     */
     int deletePhotoMng(PhotoMngVO photoMngVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 상세 정보
+     */
     List<PhotoMngVO> photoMngDetail (PhotoMngVO photoMngVO) throws Exception;
 }
src/main/java/com/takensoft/ai_lms/lms/photoMng/vo/PhotoMngVO.java
--- src/main/java/com/takensoft/ai_lms/lms/photoMng/vo/PhotoMngVO.java
+++ src/main/java/com/takensoft/ai_lms/lms/photoMng/vo/PhotoMngVO.java
@@ -5,6 +5,12 @@
 import lombok.NoArgsConstructor;
 import lombok.Setter;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진첩 관련 VO
+ */
 @Getter
 @Setter
 @AllArgsConstructor
src/main/java/com/takensoft/ai_lms/lms/photoMng/web/PhotoMngController.java
--- src/main/java/com/takensoft/ai_lms/lms/photoMng/web/PhotoMngController.java
+++ src/main/java/com/takensoft/ai_lms/lms/photoMng/web/PhotoMngController.java
@@ -1,7 +1,5 @@
 package com.takensoft.ai_lms.lms.photoMng.web;
 
-import com.takensoft.ai_lms.lms.photo.service.PhotoService;
-import com.takensoft.ai_lms.lms.photo.vo.PhotoVO;
 import com.takensoft.ai_lms.lms.photoMng.service.PhotoMngService;
 import com.takensoft.ai_lms.lms.photoMng.vo.PhotoMngVO;
 import lombok.RequiredArgsConstructor;
@@ -15,6 +13,12 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 사진첩 관련 Controller 클래스
+ */
 @RestController
 @RequiredArgsConstructor
 @Slf4j
@@ -23,31 +27,60 @@
 
     private final PhotoMngService photoMngService;
 
-
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 목록 출력
+     */
     @PostMapping(path = "/photoMngList.json")
     public ResponseEntity<?> photoMngList() throws Exception {
         List<PhotoMngVO> result = photoMngService.photoMngList();
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 등록
+     */
     @PostMapping(path = "/insertPhotoMng.json")
     public ResponseEntity<?> insertPhotoMng(@RequestBody PhotoMngVO photoMngVO) throws Exception {
         int result = photoMngService.insertPhotoMng(photoMngVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 수정
+     */
     @PostMapping(path = "/updatePhotoMng.json")
     public ResponseEntity<?> updatePhotoMng(@RequestBody PhotoMngVO photoMngVO) throws Exception {
         int result = photoMngService.updatePhotoMng(photoMngVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 삭제
+     */
     @PostMapping(path = "/deletePhotoMng.json")
     public ResponseEntity<?> deletePhotoMng(@RequestBody PhotoMngVO photoMngVO) throws Exception {
         int result = photoMngService.deletePhotoMng(photoMngVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 사진첩 상세 정보
+     */
     @PostMapping(path = "/photoMngDetail.json")
     public ResponseEntity<?> photoMngDetail(@RequestBody PhotoMngVO photoMngVO) throws Exception {
         List<PhotoMngVO> result = photoMngService.photoMngDetail(photoMngVO);
src/main/java/com/takensoft/ai_lms/lms/unit/dao/UnitDAO.java
--- src/main/java/com/takensoft/ai_lms/lms/unit/dao/UnitDAO.java
+++ src/main/java/com/takensoft/ai_lms/lms/unit/dao/UnitDAO.java
@@ -5,20 +5,52 @@
 
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 단원 관련 Mapper
+ */
 @Mapper("unitDAO")
 public interface UnitDAO {
-    // 단원 전체 조회
-    List<UnitVO> unitList() throws Exception;
 
-    // 단원 등록
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 목록 출력
+     */
+    List<UnitVO> unitList(UnitVO unitVO) throws Exception;
+
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 등록
+     */
     int insertUnit(UnitVO unitVO) throws Exception;
 
-    // 단원 수정
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 수정
+     */
     int updateUnit(UnitVO unitVO) throws Exception;
 
-    // 단원 삭제
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 삭제
+     */
     int deleteUnit(UnitVO unitVO) throws Exception;
 
-    // 단원 상세
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 상세 정보
+     */
     List<UnitVO> unitDetail(UnitVO unitVO) throws Exception;
 }
src/main/java/com/takensoft/ai_lms/lms/unit/service/Impl/UnitServiceImpl.java
--- src/main/java/com/takensoft/ai_lms/lms/unit/service/Impl/UnitServiceImpl.java
+++ src/main/java/com/takensoft/ai_lms/lms/unit/service/Impl/UnitServiceImpl.java
@@ -11,6 +11,12 @@
 import java.util.HashMap;
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 단원 관련 ServiceImpl 클래스
+ */
 @Service("unitService")
 @RequiredArgsConstructor
 public class UnitServiceImpl extends EgovAbstractServiceImpl implements UnitService {
@@ -19,13 +25,23 @@
 
     private final IdgenService unitIdgn;
 
-    // 단원 전체 조회
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 목록 출력
+     */
     @Override
-    public List<UnitVO> unitList() throws Exception {
-        return unitDAO.unitList();
+    public List<UnitVO> unitList(UnitVO unitVO) throws Exception {
+        return unitDAO.unitList(unitVO);
     }
 
-    // 단원 등록
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 등록
+     */
     @Override
     public int insertUnit(UnitVO unitVO) throws Exception {
         String unitId = unitIdgn.getNextStringId();
@@ -34,21 +50,36 @@
         return result;
     }
 
-    // 단원 수정
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 수정
+     */
     @Override
     public int updateUnit(UnitVO unitVO) throws Exception {
         int result = unitDAO.updateUnit(unitVO);
         return result;
     }
 
-    // 단원 삭제
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 삭제
+     */
     @Override
     public int deleteUnit(UnitVO unitVO) throws Exception {
         int result = unitDAO.deleteUnit(unitVO);
         return result;
     }
 
-    // 단원 상세
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 상세 정보
+     */
     @Override
     public List<UnitVO> unitDetail(UnitVO unitVO) throws Exception {
         return unitDAO.unitDetail(unitVO);
src/main/java/com/takensoft/ai_lms/lms/unit/service/UnitService.java
--- src/main/java/com/takensoft/ai_lms/lms/unit/service/UnitService.java
+++ src/main/java/com/takensoft/ai_lms/lms/unit/service/UnitService.java
@@ -5,15 +5,52 @@
 import java.util.HashMap;
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 단원 관련 Service 클래스
+ */
 public interface UnitService {
-    List<UnitVO> unitList () throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 목록 출력
+     */
+    List<UnitVO> unitList (UnitVO unitVO) throws Exception;
+
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 등록
+     */
     int insertUnit(UnitVO unitVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 수정
+     */
     int updateUnit(UnitVO unitVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 삭제
+     */
     int deleteUnit(UnitVO unitVO) throws Exception;
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 상세 정보
+     */
     List<UnitVO> unitDetail (UnitVO unitVO) throws Exception;
 
 }
src/main/java/com/takensoft/ai_lms/lms/unit/vo/UnitVO.java
--- src/main/java/com/takensoft/ai_lms/lms/unit/vo/UnitVO.java
+++ src/main/java/com/takensoft/ai_lms/lms/unit/vo/UnitVO.java
@@ -5,6 +5,12 @@
 import lombok.NoArgsConstructor;
 import lombok.Setter;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 단원 관련 VO
+ */
 @Setter
 @Getter
 @NoArgsConstructor
src/main/java/com/takensoft/ai_lms/lms/unit/web/UnitController.java
--- src/main/java/com/takensoft/ai_lms/lms/unit/web/UnitController.java
+++ src/main/java/com/takensoft/ai_lms/lms/unit/web/UnitController.java
@@ -14,6 +14,12 @@
 import java.util.HashMap;
 import java.util.List;
 
+/**
+ * @author  : 김건택
+ * @since   : 2024.07.25
+ *
+ * 단원 관련 Controller 클래스
+ */
 @RestController
 @RequiredArgsConstructor
 @Slf4j
@@ -22,31 +28,60 @@
 
     private final UnitService unitService;
 
-
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 목록 출력
+     */
     @PostMapping(path = "/unitList.json")
-    public ResponseEntity<?> unitList() throws Exception {
-        List<UnitVO> result = unitService.unitList();
+    public ResponseEntity<?> unitList(@RequestBody UnitVO unitVO) throws Exception {
+        List<UnitVO> result = unitService.unitList(unitVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 등록
+     */
     @PostMapping(path = "/insertUnit.json")
     public ResponseEntity<?> insertUnit(@RequestBody UnitVO unitVO) throws Exception {
         int result = unitService.insertUnit(unitVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 수정
+     */
     @PostMapping(path = "/updateUnit.json")
     public ResponseEntity<?> updateUnit(@RequestBody UnitVO unitVO) throws Exception {
         int result = unitService.updateUnit(unitVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 삭제
+     */
     @PostMapping(path = "/deleteUnit.json")
     public ResponseEntity<?> deleteUnit(@RequestBody UnitVO unitVO) throws Exception {
         int result = unitService.deleteUnit(unitVO);
         return new ResponseEntity<>(result, HttpStatus.OK);
     }
 
+    /**
+     * @author  : 김건택
+     * @since   : 2024.07.25
+     *
+     * 단원 상세 정보
+     */
     @PostMapping(path = "/unitDetail.json")
     public ResponseEntity<?> unitDetail(@RequestBody UnitVO unitVO) throws Exception {
         List<UnitVO> result = unitService.unitDetail(unitVO);
src/main/resources/mybatis/mapper/lms/photo-SQL.xml
--- src/main/resources/mybatis/mapper/lms/photo-SQL.xml
+++ src/main/resources/mybatis/mapper/lms/photo-SQL.xml
@@ -7,51 +7,97 @@
         <result property="photoId" column="photo_id"/>
         <result property="photoMngId" column="photo_mng_id"/>
         <result property="photoDate" column="photo_dt"/>
-        <result property="likeCount" column="like_data"/>
+        <result property="likeData" column="like_data"/>
         <result property="unitId" column="unit_id"/>
         <result property="stdId" column="std_id"/>
         <result property="fileMngId" column="file_mng_id"/>
     </resultMap>
 
-    <select id="photoList" resultType="com.takensoft.ai_lms.lms.photo.vo.PhotoVO">
-        SELECT unit_id
-            , book_id
-            , unit_nm
-        FROM unit
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진 목록 출력
+-->
+    <select id="photoList" parameterType="PhotoVO" resultType="com.takensoft.ai_lms.lms.photo.vo.PhotoVO">
+        SELECT photo_id
+            , photo_mng_id
+            , photo_dt
+            , like_data
+            , unit_id
+            , std_id
+            , file_mng_id
+        FROM photo
+        WHERE photo_mng_id =#{photoMngId}
     </select>
 
-    <insert id="insertphoto" parameterType="PhotoVO">
-        INSERT INTO unit (
-            unit_id
-            , book_id
-            , unit_nm
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진 등록
+-->
+    <insert id="insertPhoto" parameterType="PhotoVO">
+        INSERT INTO photo (
+            photo_id
+            , photo_mng_id
+            , photo_dt
+            , like_data
+            , unit_id
+            , std_id
+            , file_mng_id
         ) VALUES (
-              #{unitId}
-            , #{bookId}
-            , #{unitName}
+              #{photoId}
+            , #{photoMngId}
+            , now()
+            , #{likeData}
+            , #{unitId}
+            , #{stdId}
+            , #{fileMngId}
         )
     </insert>
 
-    <update id="updatephoto" parameterType="PhotoVO">
-        UPDATE unit
-        SET    unit_id = #{unitId}
-             , book_id = #{bookId}
-             , unit_nm = #{unitName}
-        WHERE  unit_id = #{unitId}
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진 수정
+-->
+    <update id="updatePhoto" parameterType="PhotoVO">
+        UPDATE photo
+        SET    photo_id = #{photoID}
+             , photo_mng_id = #{photoMngId}
+             , photo_dt = now()
+             , like_data = #{likeData}
+             , unit_id = #{unitId}
+             , std_id = #{stdId}
+             , file_mng_id = #{fileMngId}
+        WHERE  photo_id = #{photoId}
     </update>
 
-    <delete id="deletephoto" parameterType="PhotoVO">
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진 삭제
+-->
+    <delete id="deletePhoto" parameterType="PhotoVO">
         DELETE
-        FROM  unit
-        WHERE unit_id = #{unitId}
+        FROM  photo
+        WHERE photo_id = #{photoId}
     </delete>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진 상세 정보
+-->
     <select id="photoDetail" parameterType="PhotoVO" resultType="com.takensoft.ai_lms.lms.photo.vo.PhotoVO">
-        SELECT unit_id
-            , book_id
-            , unit_nm
-        WHERE unit_id = #{unitId}
-        FROM unit
+        SELECT photo_id
+            , photo_mng_id
+            , photo_dt
+            , like_data
+            , unit_id
+            , std_id
+            , file_mng_id
+        FROM photo
+        WHERE photo_id = #{photoId}
     </select>
 
 </mapper>
(파일 끝에 줄바꿈 문자 없음)
src/main/resources/mybatis/mapper/lms/photoMng-SQL.xml
--- src/main/resources/mybatis/mapper/lms/photoMng-SQL.xml
+++ src/main/resources/mybatis/mapper/lms/photoMng-SQL.xml
@@ -6,15 +6,24 @@
     <resultMap id="photoMngMap" type="photoMngVO">
         <result property="photoMngId" column="photo_mng_id"/>
         <result property="sclsId" column="scls_id"/>
-
     </resultMap>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진첩 목록 출력
+-->
     <select id="photoMngList" resultType="com.takensoft.ai_lms.lms.photoMng.vo.PhotoMngVO">
         SELECT photo_mng_id
             , scls_id
         FROM photo_manage
     </select>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진첩 등록
+-->
     <insert id="insertPhotoMng" parameterType="PhotoMngVO">
         INSERT INTO photo_manage (
             photo_mng_id
@@ -25,6 +34,11 @@
         )
     </insert>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진첩 수정
+-->
     <update id="updatePhotoMng" parameterType="PhotoMngVO">
         UPDATE photo_manage
         SET    photo_mng_id = #{photoMngId}
@@ -32,17 +46,27 @@
         WHERE  photo_mng_id = #{photoMngId}
     </update>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진첩 삭제
+-->
     <delete id="deletePhotoMng" parameterType="PhotoMngVO">
         DELETE
         FROM  photo_manage
         WHERE photo_mng_id = #{photoMngId}
     </delete>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 사진첩 상세 정보
+-->
     <select id="photoDetail" parameterType="PhotoMngVO" resultType="com.takensoft.ai_lms.lms.photoMng.vo.PhotoMngVO">
         SELECT photo_mng_id
             , scls_id
-        WHERE photo_mng_id = #{photoMngId}
         FROM photo_manage
+        WHERE photo_mng_id = #{photoMngId}
     </select>
 
 </mapper>
(파일 끝에 줄바꿈 문자 없음)
src/main/resources/mybatis/mapper/lms/unit-SQL.xml
--- src/main/resources/mybatis/mapper/lms/unit-SQL.xml
+++ src/main/resources/mybatis/mapper/lms/unit-SQL.xml
@@ -8,13 +8,24 @@
         <result property="unitName" column="unit_nm"/>
     </resultMap>
 
-    <select id="unitList" resultType="com.takensoft.ai_lms.lms.unit.vo.UnitVO">
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 단원 목록 출력
+-->
+    <select id="unitList" parameterType="UnitVO" resultType="com.takensoft.ai_lms.lms.unit.vo.UnitVO">
         SELECT unit_id
             , book_id
             , unit_nm
         FROM unit
+        WHERE book_id = #{bookId}
     </select>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 단원 등록
+-->
     <insert id="insertUnit" parameterType="UnitVO">
         INSERT INTO unit (
             unit_id
@@ -27,6 +38,11 @@
         )
     </insert>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 단원 수정
+-->
     <update id="updateUnit" parameterType="UnitVO">
         UPDATE unit
         SET    unit_id = #{unitId}
@@ -35,18 +51,28 @@
         WHERE  unit_id = #{unitId}
     </update>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 단원 삭제
+-->
     <delete id="deleteUnit" parameterType="UnitVO">
         DELETE
         FROM  unit
         WHERE unit_id = #{unitId}
     </delete>
 
+    <!--
+    작 성 자 : 김건택
+    작 성 일 : 2024.07.25
+    내   용 : 단원 상세 정보
+-->
     <select id="unitDetail" parameterType="UnitVO" resultType="com.takensoft.ai_lms.lms.unit.vo.UnitVO">
         SELECT unit_id
             , book_id
             , unit_nm
-        WHERE unit_id = #{unitId}
         FROM unit
+        WHERE unit_id = #{unitId}
     </select>
 
 </mapper>
(파일 끝에 줄바꿈 문자 없음)
Add a comment
List