Skip to content
Snippets Groups Projects
Commit b5279ec1 authored by nahyun's avatar nahyun
Browse files

connect

parent 5895eb1d
No related branches found
No related tags found
No related merge requests found
{
"name": "springweb",
"lockfileVersion": 3,
"requires": true,
"packages": {}
}
......@@ -34,7 +34,7 @@ public class FavoriteMusicRequestDto {
music.setCollectionName(this.collectionName);
music.setCollectionViewUrl(this.collectionViewUrl);
/// …. 중간 생략 …. 더 씀
System.out.println(music.toString());
return music;
}
......
......@@ -4,12 +4,13 @@ import java.io.IOException;
import java.util.List;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.client.RestTemplate;
import com.fasterxml.jackson.databind.ObjectMapper;
import jakarta.transaction.Transactional;
//import jakarta.transaction.Transactional;
import kr.ajousw.myspringweb.dto.FavoriteMusicRequestDto;
import kr.ajousw.myspringweb.dto.MusicList;
import kr.ajousw.myspringweb.entity.FavoriteMusic;
......@@ -33,7 +34,8 @@ public class MusicService {
try {
String response = restTemplate.getForObject("https://itunes.apple.com/search?term=name&entity=album",
String response = restTemplate.getForObject(
"https://itunes.apple.com/search?term=" + name + "&entity=album",
String.class);
ObjectMapper mapper = new ObjectMapper();
......
server.port = 8098
server.port = 8888
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
......
This diff is collapsed.
<!doctype html>
<html>
<head>
<title> muiBasic </title>
<meta charset="UTF-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
<link rel="icon" href="/favicon.ico" type="image/x-icon">
</head>
<body>
<div id="app"></div>
<script src="./app.bundle.js" type="text/javascript"></script>
</body>
</html>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment