728x90

JAVA/SpringBoot 25

게시판 프로젝트 - REST API 방식

댓글 등록 기능 구현 @RestController 어노테이션과 jQuery의 Ajax를 이용해 화면의 움직임, 새로고침 없이 데이터를 주고 받는 비동기 처리에 대해 알아볼 것 - REST API? Representational State Trasnsfer Application Programming Interface . REST API는 애플리케이션을 통합하는 유연하고 간단한 방법을 제공하며, 마이크로서비스 아키텍처에서 컴포넌트를 연.결하는 가장 일반적인 방법 . HTTP URI 을 통해 자원(resource)을 명시하고 HTTP Method(POST, GET, PUT, DELETE, PATCH) 을 통해 해당 자원에 대한 CRUD을 적용하는 것을 의미한다. rest api 방식서 사용할 수 있는 http..

JAVA/SpringBoot 2023.11.06

게시판 프로젝트 - 댓글 CRUD 처리

댓글 테이블 생성 create table tb_comment ( id bigint not null auto_increment comment '댓글 번호 (PK)' , post_id bigint not null comment '게시글 번호 (FK)' , content varchar(1000) not null comment '내용' , writer varchar(20) not null comment '작성자' , delete_yn tinyint(1) not null comment '삭제 여부' , created_date datetime not null default CURRENT_TIMESTAMP comment '생성일시' , modified_date datetime comment '최종 수정일시' , pr..

JAVA/SpringBoot 2023.11.06

게시판 - CRUD 글 등록 , 조회, 상세 페이지 조회, 삭제

비즈니스 로직을 담당하는 모델, 사용자가 보는 화면을 처리하는 뷰, 서비스와 ui를 연결해주는 컨트롤러 개발 package com.study.domain.post; import com.study.common.dto.SearchDto; import com.study.common.paging.Pagination; import com.study.common.paging.PagingResponse; import lombok.RequiredArgsConstructor; import org.springframework.stereotype.Service; import javax.transaction.Transactional; import java.util.Collections; import java.util.List..

JAVA/SpringBoot 2023.11.06

게시판 프로젝트 2, CRUD

CRUD란 Create, Read,Update, Delete DB에 게시글을 관리할 테이블을 생성한다. 생성전, show databases; //현재 있는 데이터베이스 보기 use board; // board 사용 crate table 'tb_post' ( 'id' bigint(20) not null auto_increment comment 'pk' , //각 행에 대해 자동으로 증가하는 primary key 'title' varchar(100) not null comment '제목', 'content' varchar(3000) not null comment '내용', ''writer' varchar(20) not null comment '작성자', 'view_cnt' int(11) not null co..

JAVA/SpringBoot 2023.11.06

IntelliJ, SpringBoot, MariaDB, Thymeleaf, MyBatis로 만드는 게시판 1

https://github.com/Hanboreum/Board GitHub - Hanboreum/Board: 스프링부트를 이용한 게시판 구현 스프링부트를 이용한 게시판 구현. Contribute to Hanboreum/Board development by creating an account on GitHub. github.com 스프링 부트 프로젝트의 구조 - src/main/java 클래스, 인터페이스 등 자바 관련 파일이 위치함. -. BoardApplication class SpringApplication.run()을 호출해 웹 어플리케이션을 실행하는 역할을 한다. -. src/main.resources html, css,fonts, images, plugin,scriopts 등의 정적 리소스 파일..

JAVA/SpringBoot 2023.11.06
728x90
반응형