ksmart_Framework/spring(10)
-
thymeleaf 와 Model 객체 사용법_sts
검색 키워드 : thymeleaf 연결 2022.02.08 - [Framework/springboot] - 스프링부트 개발환경 구축_sts 스프링부트 개발환경 구축_sts 01. 스프링부트 파일 다운로드 더보기 https://github.com/spring-projects/sts4/wiki/Previous-Versions GitHub - spring-projects/sts4: The next generation of tooling for Spring Boot, including support.. moon09-developer.tistory.com model 객체로 title 값을 넣는다. Model 객체를 파라미터로 받아서 데이터를 메인으로 넘길 수 있다. package ksmart.hellospring..
2022.02.17 -
기본문법_sts
[문법] th:text="${key}" : 텍스트 지정 = 특정 key 변수 호출 이름 : 나이 : 성별 : [문법] th:each="n_data : ${name}" th:text="${n_data}" : 단순 변수 지정 및 데이터 결합 이름 : 나이 : 성별 : [문법] th:if / th:unless : if else 조건문 처리 이름 : 이름 : [문법] th:switch / th:case : switch 문 분기 처리 실시 이름 : 1번 투케이 2번 투케이 ELSE 투케이 [문법] th:each : List 객체 데이터 for 반복 출력 실시 [출처] 20. (spring/스프링) [thymeleaf/타임리프] 자주 사용하는 th 기본 문법 설명 - text , if else , switch , ..
2022.02.17 -
Hello Spring Boot!_sts
스프링부트에서 Hello Spring Boot 출력하기 1. 포트번호, thymelelaf 쿠키 설정 2. API 생성하기 해당 클래스는 웹 프로젝트 실행 시, REST API를 통해 넘어오는 메서드들을 조작하는 컨트롤러의 역할을 한다. src/main/java 안 패키지를 잡고 새 패키지를 만든다. 패키지명 ksmart.springboot2.controller 클래스명 MainController Controller 어노테이션은 해당 클래스가 Controller로써 동작할것임을 명시해주는 용도로 해당 어노테이션이 붙여진 클래스는 자동으로 Controller로 등록된다. 클래스 위에 적어줌으로써 하위 메서드들의 경로를 단축시켜주는것처럼 작동하지는 않는다. API 요청 할 때 "http://localhost..
2022.02.17 -
스프링부트 개발환경 구축_sts
01. 스프링부트 파일 다운로드 더보기 https://github.com/spring-projects/sts4/wiki/Previous-Versions GitHub - spring-projects/sts4: The next generation of tooling for Spring Boot, including support for Cloud Foundry manifest file The next generation of tooling for Spring Boot, including support for Cloud Foundry manifest files, Concourse CI pipeline definitions, BOSH deployment manifests, and more... - Availabl..
2022.02.08